提交 7c55fb53 编写于 作者: zcdtk's avatar zcdtk

表单与搜索表单代码整理

上级 579d42e4
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<div class="app-form-item-button" v-show="detailsModel.${item.name}.visible"> <div class="app-form-item-button" v-show="detailsModel.${item.name}.visible">
<nut-button v-if="detailsModel.${item.name}.visible" class="app-form-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>" style='<#if item.getHeight() gt 0>height: ${item.getHeight()}px;</#if>'>${item.caption}</nut-button> <nut-button
v-if="detailsModel.${item.name}.visible"
class="app-form-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>"
style='<#if item.getHeight() gt 0>height: ${item.getHeight()}px;</#if>'>${item.caption}</nut-button>
</div> </div>
</#if> </#if>
\ No newline at end of file
<#ibizinclude>../../@NAVPARAMS/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<#assign dritem = item.getPSDEDRItem() /> <#assign dritem = item.getPSDEDRItem() />
<#assign refView = item.getPSAppView() /> <#assign refView = item.getPSAppView() />
<#assign appDataEntity = refView.getPSAppDataEntity()/> <#assign appDataEntity = refView.getPSAppDataEntity()/>
<app-form-druipart <app-form-druipart
<#if item.getPSSysCss?? && item.getPSSysCss()??>class="${item.getPSSysCss().getCssName()}"</#if> class='<#if item.getPSSysCss?? && item.getPSSysCss()??>${item.getPSSysCss().getCssName()}</#if>'
:formState="formState" parameterName='${appde.getCodeName()?lower_case}'
refviewtype='<#if refView.getPSViewType()??>${refView.getPSViewType().getId()}</#if>'
refreshitems='<#if item.getRefreshItems()??>${item.getRefreshItems()}</#if>'
viewname='${srffilepath2(refView.codeName)}'
paramItem='<#if item.getParamItem()??>${item.getParamItem()}<#else>${appde.getCodeName()?lower_case}</#if>' paramItem='<#if item.getParamItem()??>${item.getParamItem()}<#else>${appde.getCodeName()?lower_case}</#if>'
:parentdata='<#if dritem.getParentDataJO?? && dritem.getParentDataJO()??>${dritem.getParentDataJO()}<#else>{}</#if>' style="<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() == "FLEX">height: 100%;</#if><#if item.getContentHeight() == 0><#if refView.getHeight() gt 0>height:${refView.getHeight()?c}px</#if><#else>height:${item.getContentHeight()?c}px;</#if>"
:formState="formState"
:parentdata='<#if dritem.getParentDataJO?? && dritem.getParentDataJO()??>${dritem.getParentDataJO()}<#else>{}</#if>'
:parameters="[ :parameters="[
<#if refView.getPSAppDERSPathCount() gt 0> <#if refView.getPSAppDERSPathCount() gt 0>
<#list refView.getPSAppDERSPath(refView.getPSAppDERSPathCount() - 1) as deRSPath> <#list refView.getPSAppDERSPath(refView.getPSAppDERSPathCount() - 1) as deRSPath>
...@@ -16,16 +22,12 @@ ${item.render.code} ...@@ -16,16 +22,12 @@ ${item.render.code}
{ pathName: '${srfpluralize(majorPSAppDataEntity.codeName)?lower_case}', parameterName: '${majorPSAppDataEntity.getCodeName()?lower_case}' }, { pathName: '${srfpluralize(majorPSAppDataEntity.codeName)?lower_case}', parameterName: '${majorPSAppDataEntity.getCodeName()?lower_case}' },
</#list> </#list>
</#if> </#if>
]" ]"
:context="context" :context="context"
:viewparams="viewparams" :viewparams="viewparams"
parameterName='${appde.getCodeName()?lower_case}' :navigateContext ='<@getNavigateContext item />'
refviewtype='<#if refView.getPSViewType()??>${refView.getPSViewType().getId()}</#if>' :navigateParam ='<@getNavigateParams item />'
refreshitems='<#if item.getRefreshItems()??>${item.getRefreshItems()}</#if>' :ignorefieldvaluechange="ignorefieldvaluechange"
:ignorefieldvaluechange="ignorefieldvaluechange" :data="JSON.stringify(this.data)"
viewname='${srffilepath2(refView.codeName)}' @drdatasaved="drdatasaved($event)"/>
:data="JSON.stringify(this.data)"
@drdatasaved="drdatasaved($event)"
style="<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() == "FLEX">height: 100%;</#if><#if item.getContentHeight() == 0><#if refView.getHeight() gt 0>height:${refView.getHeight()?c}px</#if><#else>height:${item.getContentHeight()?c}px;</#if>">
</app-form-druipart>
</#if> </#if>
...@@ -5,12 +5,37 @@ ...@@ -5,12 +5,37 @@
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<app-form-item ref="${item.name}rules" :checkValue="this.data.${item.name}" v-show="detailsModel.${item.name}.visible" name='${item.name}' :itemRules="this.rules.${item.name}" class='<#if item.getPSSysCss?? && item.getPSSysCss()??>${item.getPSSysCss().getCssName()}</#if>'<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??> labelStyle="${item.getLabelPSSysCss().getCssName()}"</#if> :caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>" uiStyle="${item.getDetailStyle()}" :labelWidth="${item.getLabelWidth()?c}" :isShowCaption="${item.isShowCaption()?c}" :error="detailsModel.${item.name}.error" :isEmptyCaption="${item.isEmptyCaption()?c}" labelPos="${item.getLabelPos()}"> <app-form-item
name='${item.name}'
class='<#if item.getPSSysCss?? && item.getPSSysCss()??>${item.getPSSysCss().getCssName()}</#if>'
<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>
labelStyle="${item.getLabelPSSysCss().getCssName()}"
</#if>
uiStyle="${item.getDetailStyle()}"
labelPos="${item.getLabelPos()}"
ref="${item.name}_item"
:itemValue="this.data.${item.name}"
v-show="detailsModel.${item.name}.visible"
:itemRules="this.rules.${item.name}"
:caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>"
:labelWidth="${item.getLabelWidth()?c}"
:isShowCaption="${item.isShowCaption()?c}"
:error="detailsModel.${item.name}.error"
:isEmptyCaption="${item.isEmptyCaption()?c}">
<#if item.isCompositeItem()> <#if item.isCompositeItem()>
<#assign formitems=item.getPSDEFormItems()> <#assign formitems=item.getPSDEFormItems()>
<app-range-editor v-model="data.${item.name}" :activeData="data" :disabled="detailsModel.${item.name}.disabled" name="${item.name}" editorType="${item.getEditorType()}" format="${item.getEditorParam("TIMEFMT","")}" :refFormItem="[<#list formitems as formitem><#if formitem_index gt 0>,</#if>'${formitem.name}'</#list>]" @formitemvaluechange="onFormItemValueChange" style="${item.getEditorCssStyle()}"></app-range-editor> <app-range-editor
name="${item.name}"
editorType="${item.getEditorType()}"
format="${item.getEditorParam("TIMEFMT","")}"
style="${item.getEditorCssStyle()}"
v-model="data.${item.name}"
:activeData="data"
:disabled="detailsModel.${item.name}.disabled"
:refFormItem="[<#list formitems as formitem><#if formitem_index gt 0>,</#if>'${formitem.name}'</#list>]"
@formitemvaluechange="onFormItemValueChange"/>
<#else> <#else>
${P.getEditorCode(item, "EDITOR.vue").code} ${P.getEditorCode(item, "EDITOR.vue").code}
</#if> </#if>
</app-form-item> </app-form-item>
</#if> </#if>
......
...@@ -4,7 +4,18 @@ ...@@ -4,7 +4,18 @@
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<app-form-group v-show="detailsModel.${item.name}.visible" layoutType="<#if item.getPSLayoutPos()??>${item.getPSLayoutPos().getLayout()}</#if>" titleStyle="<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>${item.getLabelPSSysCss().getCssName()}</#if>" class='<#if item.getPSSysCss?? && item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>' uiActionGroup="detailsModel.${item.name}.uiActionGroup" @groupuiactionclick="groupUIActionClick($event)" :caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>" :isShowCaption="${item.isShowCaption()?c}" uiStyle="${item.getDetailStyle()}" :titleBarCloseMode="${item.getTitleBarCloseMode()}" :isInfoGroupMode="${item.isInfoGroupMode()?c}"> <app-form-group
class='<#if item.getPSSysCss?? && item.getPSSysCss()??>${item.getPSSysCss().getCssName()}</#if>'
layoutType='<#if item.getPSLayoutPos()??>${item.getPSLayoutPos().getLayout()}</#if>'
titleStyle='<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>${item.getLabelPSSysCss().getCssName()}</#if>'
uiStyle="${item.getDetailStyle()}"
v-show="detailsModel.${item.name}.visible"
:uiActionGroup="detailsModel.${item.name}.uiActionGroup"
:caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>"
:isShowCaption="${item.isShowCaption()?c}"
:titleBarCloseMode="${item.getTitleBarCloseMode()}"
:isInfoGroupMode="${item.isInfoGroupMode()?c}"
@groupuiactionclick="groupUIActionClick($event)">
<#if item.getPSSysImage()??><#assign img=item.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)><i class="${img.getCssClass()}" style="margin-right: 2px;position: absolute;top: -51px;left: 60px;"></i></#if></#if> <#if item.getPSSysImage()??><#assign img=item.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)><i class="${img.getCssClass()}" style="margin-right: 2px;position: absolute;top: -51px;left: 60px;"></i></#if></#if>
<#assign content> <#assign content>
<#list item.getPSDEFormDetails() as formmenber> <#list item.getPSDEFormDetails() as formmenber>
......
<div v-show="detailsModel.${item.name}.visible" :style="{height:${item.getContentHeight()}px;}"><iframe src='${item.getIFrameUrl()}'></iframe></div> <div v-show="detailsModel.${item.name}.visible" :style="{height:${item.getContentHeight()}px;}">
<iframe src='${item.getIFrameUrl()}'></iframe>
</div>
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<div class="app-form-item-button" v-show="detailsModel.${item.name}.visible"> <div class="app-form-item-button" v-show="detailsModel.${item.name}.visible">
<nut-button v-if="detailsModel.${item.name}.visible" class="app-form-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>" style='<#if item.getHeight() gt 0>height: ${item.getHeight()}px;</#if>'>${item.caption}</nut-button> <nut-button
v-if="detailsModel.${item.name}.visible"
class="app-form-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>"
style='<#if item.getHeight() gt 0>height: ${item.getHeight()}px;</#if>'>${item.caption}</nut-button>
</div> </div>
</#if> </#if>
\ No newline at end of file
<#ibizinclude>../../@NAVPARAMS/FUNC/PUBLIC.vue.ftl</#ibizinclude> <#ibizinclude>../../@NAVPARAMS/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<#assign dritem = item.getPSDEDRItem() /> <#assign dritem = item.getPSDEDRItem() />
<#assign refView = item.getPSAppView() /> <#assign refView = item.getPSAppView() />
<#assign appDataEntity = refView.getPSAppDataEntity()/> <#assign appDataEntity = refView.getPSAppDataEntity()/>
<app-form-druipart <app-form-druipart
<#if item.getPSSysCss?? && item.getPSSysCss()??>class="${item.getPSSysCss().getCssName()}"</#if> class='<#if item.getPSSysCss?? && item.getPSSysCss()??>${item.getPSSysCss().getCssName()}</#if>'
:formState="formState" parameterName='${appde.getCodeName()?lower_case}'
refviewtype='<#if refView.getPSViewType()??>${refView.getPSViewType().getId()}</#if>'
refreshitems='<#if item.getRefreshItems()??>${item.getRefreshItems()}</#if>'
viewname='${srffilepath2(refView.codeName)}'
paramItem='<#if item.getParamItem()??>${item.getParamItem()}<#else>${appde.getCodeName()?lower_case}</#if>' paramItem='<#if item.getParamItem()??>${item.getParamItem()}<#else>${appde.getCodeName()?lower_case}</#if>'
:parentdata='<#if dritem.getParentDataJO?? && dritem.getParentDataJO()??>${dritem.getParentDataJO()}<#else>{}</#if>' style="<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() == "FLEX">height: 100%;</#if><#if item.getContentHeight() == 0><#if refView.getHeight() gt 0>height:${refView.getHeight()?c}px</#if><#else>height:${item.getContentHeight()?c}px;</#if>"
:formState="formState"
:parentdata='<#if dritem.getParentDataJO?? && dritem.getParentDataJO()??>${dritem.getParentDataJO()}<#else>{}</#if>'
:parameters="[ :parameters="[
<#if refView.getPSAppDERSPathCount() gt 0> <#if refView.getPSAppDERSPathCount() gt 0>
<#list refView.getPSAppDERSPath(refView.getPSAppDERSPathCount() - 1) as deRSPath> <#list refView.getPSAppDERSPath(refView.getPSAppDERSPathCount() - 1) as deRSPath>
...@@ -17,18 +22,12 @@ ${item.render.code} ...@@ -17,18 +22,12 @@ ${item.render.code}
{ pathName: '${srfpluralize(majorPSAppDataEntity.codeName)?lower_case}', parameterName: '${majorPSAppDataEntity.getCodeName()?lower_case}' }, { pathName: '${srfpluralize(majorPSAppDataEntity.codeName)?lower_case}', parameterName: '${majorPSAppDataEntity.getCodeName()?lower_case}' },
</#list> </#list>
</#if> </#if>
]" ]"
:context="context" :context="context"
:viewparams="viewparams" :viewparams="viewparams"
parameterName='${appde.getCodeName()?lower_case}' :navigateContext ='<@getNavigateContext item />'
:navigateContext ='<@getNavigateContext item />' :navigateParam ='<@getNavigateParams item />'
:navigateParam ='<@getNavigateParams item />' :ignorefieldvaluechange="ignorefieldvaluechange"
refviewtype='<#if refView.getPSViewType()??>${refView.getPSViewType().getId()}</#if>' :data="JSON.stringify(this.data)"
refreshitems='<#if item.getRefreshItems()??>${item.getRefreshItems()}</#if>' @drdatasaved="drdatasaved($event)"/>
:ignorefieldvaluechange="ignorefieldvaluechange"
viewname='${srffilepath2(refView.codeName)}'
:data="JSON.stringify(this.data)"
@drdatasaved="drdatasaved($event)"
style="<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() == "FLEX">height: 100%;</#if><#if item.getContentHeight() == 0><#if refView.getHeight() gt 0>height:${refView.getHeight()?c}px</#if><#else>height:${item.getContentHeight()?c}px;</#if>">
</app-form-druipart>
</#if> </#if>
...@@ -4,7 +4,18 @@ ...@@ -4,7 +4,18 @@
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<app-form-group v-show="detailsModel.${item.name}.visible" layoutType="<#if item.getPSLayoutPos()??>${item.getPSLayoutPos().getLayout()}</#if>" titleStyle="<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>${item.getLabelPSSysCss().getCssName()}</#if>" class='<#if item.getPSSysCss?? && item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>' uiActionGroup="detailsModel.${item.name}.uiActionGroup" @groupuiactionclick="groupUIActionClick($event)" :caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>" :isShowCaption="${item.isShowCaption()?c}" uiStyle="${item.getDetailStyle()}" :titleBarCloseMode="${item.getTitleBarCloseMode()}" :isInfoGroupMode="${item.isInfoGroupMode()?c}"> <app-form-group
class='<#if item.getPSSysCss?? && item.getPSSysCss()??>${item.getPSSysCss().getCssName()}</#if>'
layoutType='<#if item.getPSLayoutPos()??>${item.getPSLayoutPos().getLayout()}</#if>'
titleStyle='<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>${item.getLabelPSSysCss().getCssName()}</#if>'
uiStyle="${item.getDetailStyle()}"
v-show="detailsModel.${item.name}.visible"
:uiActionGroup="detailsModel.${item.name}.uiActionGroup"
:caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>"
:isShowCaption="${item.isShowCaption()?c}"
:titleBarCloseMode="${item.getTitleBarCloseMode()}"
:isInfoGroupMode="${item.isInfoGroupMode()?c}"
@groupuiactionclick="groupUIActionClick($event)">
<#if item.getPSSysImage()??><#assign img=item.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)><i class="${img.getCssClass()}" style="margin-right: 2px;position: absolute;top: -51px;left: 60px;"></i></#if></#if> <#if item.getPSSysImage()??><#assign img=item.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)><i class="${img.getCssClass()}" style="margin-right: 2px;position: absolute;top: -51px;left: 60px;"></i></#if></#if>
<#assign content> <#assign content>
<#list item.getPSDEFormDetails() as formmenber> <#list item.getPSDEFormDetails() as formmenber>
......
<div v-show="detailsModel.${item.name}.visible" :style="{height:${item.getContentHeight()}px;}"><iframe src='${item.getIFrameUrl()}'></iframe></div> <div v-show="detailsModel.${item.name}.visible" :style="{height:${item.getContentHeight()}px;}">
<iframe src='${item.getIFrameUrl()}'></iframe>
</div>
...@@ -5,9 +5,6 @@ ...@@ -5,9 +5,6 @@
<#assign import_block> <#assign import_block>
import { FormButtonModel, FormPageModel, FormItemModel, FormDRUIPartModel, FormPartModel, FormGroupPanelModel, FormIFrameModel, FormRowItemModel, FormTabPageModel, FormTabPanelModel, FormUserControlModel } from '@/model/form-detail'; import { FormButtonModel, FormPageModel, FormItemModel, FormDRUIPartModel, FormPartModel, FormGroupPanelModel, FormIFrameModel, FormRowItemModel, FormTabPageModel, FormTabPanelModel, FormUserControlModel } from '@/model/form-detail';
import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
<#if view.getViewType?? && view.getViewType() ?? && view.getViewType()=='DEMOBWFDYNAEDITVIEW'>
import { toastController, alertController } from '@ionic/core';
</#if>
</#assign> </#assign>
<#ibizinclude> <#ibizinclude>
../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl ../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册