Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
iBiz-Vue-R7
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
22
议题
22
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
iBiz-R7前端标准模板
iBiz-Vue-R7
提交
d434ac00
提交
d434ac00
编写于
11月 16, 2022
作者:
Mosher
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update:更新
上级
225f6fe1
变更
2
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
115 行增加
和
28 行删除
+115
-28
VIEW.vue.ftl
@CONTROL/视图布局面板/实体工作流动态编辑视图(分页关系)/VIEW.vue.ftl
+47
-3
VIEW-BASE.vue.ftl
@VIEW/实体工作流动态编辑视图(分页关系)/VIEW-BASE.vue.ftl
+68
-25
未找到文件。
@CONTROL/视图布局面板/实体工作流动态编辑视图(分页关系)/VIEW.vue.ftl
浏览文件 @
d434ac00
<div class="view-container ${view.getViewType()?lower_case} ${srffilepath2(view.getCodeName())}<#if view.getPSSysCss?? && view.getPSSysCss()??> ${view.getPSSysCss().getCssName()}</#if>">
<app-studioaction :viewTitle="$t(model.srfCaption)" viewName="${view.getCodeName()?lower_case}"></app-studioaction>
<card class='view-card <#if !view.isShowCaptionBar()> view-no-caption</#if> <#if !view.hasPSControl('toolbar')> view-no-toolbar</#if>' :disHover="true" :padding="0" :bordered="false">
<#ibizinclude>
../@MACRO/VIEW_CAPTION.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW_CAPTION.vue.ftl
</#ibizinclude>
<div slot="extra">
<div class='toolbar-container'>
<tooltip :transfer="true" :max-width="600" v-for="(linkItem, index) in linkModel" :key="index">
...
...
@@ -14,5 +14,48 @@
</tooltip>
</div>
</div>
<div class="content-container">
<#if view.getPSControls?? && view.getPSControls()??>
<#list view.getPSControls() as singleControl>
<#if singleControl.getControlType?? && singleControl.getControlType()?? && singleControl.getControlType() == 'DRTAB'>
<tabs :animated="false" name="${singleControl.codeName?lower_case}" class="content-container__drtab">
<tab-pane tab="${singleControl.codeName?lower_case}" label="<#if singleControl.getEditItemCaption?? && singleControl.getEditItemCaption()??>${singleControl.getEditItemCaption()}<#else>activeForm.logicName</#if>">
<component
:is="activeForm.name"
:isautoload="true"
:viewState="viewState"
:viewparams="viewparams"
:context="context"
:autosave="false"
:viewtag="viewtag"
:showBusyIndicator="activeForm.showBusyIndicator"
:updateAction="activeForm.updateAction"
:removeAction="activeForm.removeAction"
:loaddraftAction="activeForm.loaddraftAction"
:loadAction="activeForm.loadAction"
:createAction="activeForm.createAction"
:WFSubmitAction="activeForm.WFSubmitAction"
:WFStartAction="activeForm.WFStartAction"
name="form"
ref='form'
@save="form_save($event)"
@remove="form_remove($event)"
@load="form_load($event)"
@closeview="closeView($event)">
</component>
</tab-pane>
<#if singleControl.getPSDEDRTabPages?? && singleControl.getPSDEDRTabPages()??>
<#list singleControl.getPSDEDRTabPages() as tabPage>
<tab-pane tab="${singleControl.codeName?lower_case}" label="${tabPage.getCaption()}" name="${tabPage.name}">
TODO 视图
</tab-pane>
</#list>
</#if>
</tabs>
</#if>
</#list>
</#if>
</div>
</card>
</div>
\ No newline at end of file
@VIEW/实体工作流动态编辑视图(分页关系)/VIEW-BASE.vue.ftl
浏览文件 @
d434ac00
...
...
@@ -19,13 +19,24 @@
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public allForm: any = {
<#if view.getAllPSControls?? && view.getAllPSControls()??>
<#if view.getAllPSControls?? && view.getAllPSControls()??>
<#list view.getAllPSControls() as singleControl>
<#if singleControl.getControlType?? && singleControl.getControlType()?? && singleControl.getControlType() == "FORM">
"${singleControl.getName()}":{name:"view_${singleControl.getName()}",autosave:"${singleControl.isEnableAutoSave()?c}",showBusyIndicator:"${singleControl.isShowBusyIndicator()?c}",updateAction:"<#if singleControl.getUpdatePSControlAction()?? && singleControl.getUpdatePSControlAction().getPSAppDEMethod()??>${singleControl.getUpdatePSControlAction().getPSAppDEMethod().getCodeName()}</#if>",removeAction:"<#if singleControl.getRemovePSControlAction()?? && singleControl.getRemovePSControlAction().getPSAppDEMethod()??>${singleControl.getRemovePSControlAction().getPSAppDEMethod().getCodeName()}</#if>",loaddraftAction:"<#if singleControl.getGetDraftPSControlAction()?? && singleControl.getGetDraftPSControlAction().getPSAppDEMethod()??>${singleControl.getGetDraftPSControlAction().getPSAppDEMethod().getCodeName()}</#if>",loadAction:"<#if singleControl.getGetPSControlAction()?? && singleControl.getGetPSControlAction().getPSAppDEMethod()??>${singleControl.getGetPSControlAction().getPSAppDEMethod().getCodeName()}</#if>",createAction:"<#if singleControl.getCreatePSControlAction()?? && singleControl.getCreatePSControlAction().getPSAppDEMethod()??>${singleControl.getCreatePSControlAction().getPSAppDEMethod().getCodeName()}</#if>",WFSubmitAction:"<#if singleControl.getWFSubmitPSControlAction()?? && singleControl.getWFSubmitPSControlAction().getPSAppDEMethod()??>${singleControl.getWFSubmitPSControlAction().getPSAppDEMethod().getCodeName()}</#if>",WFStartAction:"<#if singleControl.getWFStartPSControlAction()?? && singleControl.getWFStartPSControlAction().getPSAppDEMethod()??>${singleControl.getWFStartPSControlAction().getPSAppDEMethod().getCodeName()}</#if>"}<#if singleControl_has_next>,</#if>
</#if>
<#if singleControl.getControlType?? && singleControl.getControlType()?? && singleControl.getControlType() == "FORM">
"${singleControl.getName()}": {
name: "view_${singleControl.getName()}",
autosave: ${singleControl.isEnableAutoSave()?c},
showBusyIndicator: ${singleControl.isShowBusyIndicator()?c},
updateAction: "<#if singleControl.getUpdatePSControlAction()?? && singleControl.getUpdatePSControlAction().getPSAppDEMethod()??>${singleControl.getUpdatePSControlAction().getPSAppDEMethod().getCodeName()}</#if>",
removeAction:"<#if singleControl.getRemovePSControlAction()?? && singleControl.getRemovePSControlAction().getPSAppDEMethod()??>${singleControl.getRemovePSControlAction().getPSAppDEMethod().getCodeName()}</#if>",
loaddraftAction:"<#if singleControl.getGetDraftPSControlAction()?? && singleControl.getGetDraftPSControlAction().getPSAppDEMethod()??>${singleControl.getGetDraftPSControlAction().getPSAppDEMethod().getCodeName()}</#if>",
loadAction:"<#if singleControl.getGetPSControlAction()?? && singleControl.getGetPSControlAction().getPSAppDEMethod()??>${singleControl.getGetPSControlAction().getPSAppDEMethod().getCodeName()}</#if>",
createAction:"<#if singleControl.getCreatePSControlAction()?? && singleControl.getCreatePSControlAction().getPSAppDEMethod()??>${singleControl.getCreatePSControlAction().getPSAppDEMethod().getCodeName()}</#if>",
WFSubmitAction:"<#if singleControl.getWFSubmitPSControlAction()?? && singleControl.getWFSubmitPSControlAction().getPSAppDEMethod()??>${singleControl.getWFSubmitPSControlAction().getPSAppDEMethod().getCodeName()}</#if>",
WFStartAction:"<#if singleControl.getWFStartPSControlAction()?? && singleControl.getWFStartPSControlAction().getPSAppDEMethod()??>${singleControl.getWFStartPSControlAction().getPSAppDEMethod().getCodeName()}</#if>"
}<#if singleControl_has_next>,</#if>
</#if>
</#list>
</#if>
</#if>
};
/**
...
...
@@ -34,16 +45,46 @@
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public viewRefData:any = {
<#if view.getPSAppViewRefs?? && view.getPSAppViewRefs()??>
<#if view.getPSAppViewRefs?? && view.getPSAppViewRefs()??>
<#list view.getPSAppViewRefs() as viewRef>
<#if viewRef.getName?? && viewRef.getName()?? && viewRef.getRefPSAppView?? && viewRef.getRefPSAppView()??>
<#assign refAppView = viewRef.getRefPSAppView() />
<#if viewRef.getName?? && viewRef.getName()?? && viewRef.getRefPSAppView?? && viewRef.getRefPSAppView()??>
<#assign refAppView = viewRef.getRefPSAppView() />
"${viewRef.getName()}":{viewname:"${srffilepath2(refAppView.getCodeName())}",title:this.$t("<#if refAppView.getPSAppDataEntity()??>entities.${refAppView.getPSAppDataEntity().getCodeName()?lower_case}.views.${refAppView.getPSDEViewCodeName()?lower_case}.caption<#else>app.views.${refAppView.getCodeName()?lower_case}.caption</#if>"), width: <#if refAppView.getWidth?? && refAppView.getWidth() gt 0>${refAppView.getWidth()?c}<#else>800</#if>, height: <#if refAppView.getHeight?? && refAppView.getHeight() gt 0>${refAppView.getHeight()?c}<#else>500</#if>}<#if viewRef_has_next>,</#if>
</#if>
</#if>
</#list>
</#if>
</#if>
};
/**
* form 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public form_load($event: any, $event2?: any) {
}
/**
* form 部件 save 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public form_save($event: any, $event2?: any) {
}
/**
* form 部件 remove 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public form_remove($event: any, $event2?: any) {
}
/**
* 获取工具栏按钮
*
...
...
@@ -59,9 +100,9 @@
this.appEntityService.GetWFLink(JSON.parse(JSON.stringify(this.context)),datas,true).then((response:any) =>{
if (response && response.status === 200) {
this.linkModel = response.data;
if
(response.headers && response.headers['process-form'])
{
if
(response.headers && response.headers['process-form'])
{
this.computeActivedForm(response.headers['process-form']);
}
else
{
}
else
{
this.computeActivedForm(null);
}
resolve(response.data);
...
...
@@ -84,14 +125,14 @@
*
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public computeActivedForm(inputForm:any){
if
(!inputForm)
{
public computeActivedForm(inputForm:any)
{
if
(!inputForm)
{
this.activeForm = this.allForm && Object.values(this.allForm)[0];
return;
}
if
(this.allForm && Object.keys(this.allForm).length >0)
{
if
(this.allForm && Object.keys(this.allForm).length > 0)
{
Object.keys(this.allForm).forEach((name:string) =>{
<#noparse>if
(Object.is(name,`wfform_${inputForm.toLowerCase()}`))
{</#noparse>
<#noparse>if
(Object.is(name,`wfform_${inputForm.toLowerCase()}`))
{</#noparse>
this.activeForm = this.allForm[name];
}
})
...
...
@@ -103,7 +144,7 @@
*
* @memberof ${srfclassname('${view.codeName}')}Base
*/
public dynamic_toolbar_click(linkItem:any, $event:any){
public dynamic_toolbar_click(linkItem:any, $event:any)
{
let datas: any[] = [];
let xData: any = this.$refs.form;
if (xData.getDatas && xData.getDatas instanceof Function) {
...
...
@@ -115,7 +156,6 @@
return;
}
const { data: _data } = response;
if (this.viewdata) {
this.$emit('viewdataschange', [{ ..._data }]);
this.$emit('close');
...
...
@@ -124,27 +164,30 @@
}
});
}
if
(linkItem && linkItem.sequenceflowview && <#noparse>this.viewRefData[`WFACTION@${linkItem.sequenceflowview}`]</#noparse>)
{
if
(linkItem && linkItem.sequenceflowview && <#noparse>this.viewRefData[`WFACTION@${linkItem.sequenceflowview}`]</#noparse>)
{
let tempContext:any = Util.deepCopy(this.context);
Object.assign(tempContext,{${appde.getCodeName()?lower_case}:datas && datas[0].srfkey});
let tempViewParam:any = {actionView:linkItem.sequenceflowview,actionForm:linkItem.sequenceflowform};
let targetView:any = <#noparse>this.viewRefData[`WFACTION@${linkItem.sequenceflowview}`];</#noparse>
const appmodal = this.$appmodal.openModal({
viewname:targetView.viewname, title:(this.$t(targetView.title) as string), height: targetView.height, width: targetView.width}, tempContext,
tempViewParam);
const appmodal = this.$appmodal.openModal({
viewname: targetView.viewname, title: (this.$t(targetView.title) as string), height: targetView.height, width: targetView.width}, tempContext,
tempViewParam);
appmodal.subscribe((result: any) => {
if (!result || !Object.is(result.ret, 'OK')) {
return;
}
let tempSubmitData:any = Util.deepCopy(datas);
tempSubmitData.forEach((element:any) => {
Object.assign(element,result.datas && result.datas[0]);
tempSubmitData.forEach((element:
any) => {
Object.assign(element,
result.datas && result.datas[0]);
});
submit(tempSubmitData,linkItem);
submit(tempSubmitData,
linkItem);
});
}
else
{
submit(datas,linkItem);
}
else
{
submit(datas,
linkItem);
}
}
</#assign>
<#assign mounted_block>
this.getWFLinkModel();
</#assign>
<#ibizinclude>
../@MACRO/VIEW-BASE.vue.ftl
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录