提交 d19f115d 编写于 作者: tony001's avatar tony001

update:更新工作流提交逻辑

上级 6ab82d36
...@@ -141,21 +141,16 @@ import WFDynaEditViewEngine from '@engine/view/mob-wfdyna-edit-view-engine'; ...@@ -141,21 +141,16 @@ import WFDynaEditViewEngine from '@engine/view/mob-wfdyna-edit-view-engine';
return; return;
} }
const { data: _data } = response; const { data: _data } = response;
if (_this.viewparams) { this.closeView([{ ..._data }]);
this.$emit('viewdataschange', [{ ..._data }]);
this.closeView(_data);
} else if (this.$tabPageExp) {
this.$tabPageExp.onClose(this.$route.fullPath);
}
}); });
} }
const submitAction: Function = () => { const submitAction: Function = () => {
if (linkItem && linkItem.sequenceflowview) { if (linkItem && linkItem.sequenceflowmobview) {
<#noparse>const targetView = this.viewRefData[`WFACTION@${linkItem.sequenceflowview}`];</#noparse> <#noparse>const targetView = this.viewRefData[`WFACTION@${linkItem.sequenceflowmobview}`];</#noparse>
if (targetView) { if (targetView) {
let tempContext: any = Util.deepCopy(_this.context); let tempContext: any = Util.deepCopy(_this.context);
Object.assign(tempContext, { '${view.getPSAppDataEntity().getKeyPSAppDEField().getCodeName()?lower_case}': datas && datas[0].srfkey }); Object.assign(tempContext, { '${view.getPSAppDataEntity().getKeyPSAppDEField().getCodeName()?lower_case}': datas && datas[0].srfkey });
let tempViewParam: any = { actionView: linkItem.sequenceflowview, actionForm: linkItem.sequenceflowform }; let tempViewParam: any = { actionView: linkItem.sequenceflowmobview, actionForm: linkItem.sequenceflowmobform };
const appmodal = _this.$appmodal.openModal(); const appmodal = _this.$appmodal.openModal();
ViewOpenService.getInstance().openModal(targetView, tempContext, tempViewParam).then((result: any) => { ViewOpenService.getInstance().openModal(targetView, tempContext, tempViewParam).then((result: any) => {
if (!result || !Object.is(result.ret, 'OK')) { if (!result || !Object.is(result.ret, 'OK')) {
...@@ -211,7 +206,7 @@ import WFDynaEditViewEngine from '@engine/view/mob-wfdyna-edit-view-engine'; ...@@ -211,7 +206,7 @@ import WFDynaEditViewEngine from '@engine/view/mob-wfdyna-edit-view-engine';
} }
let tempContext: any = Util.deepCopy(this.context); let tempContext: any = Util.deepCopy(this.context);
Object.assign(tempContext, { '${view.getPSAppDataEntity().getKeyPSAppDEField().getCodeName()?lower_case}': datas && datas[0].srfkey }); Object.assign(tempContext, { '${view.getPSAppDataEntity().getKeyPSAppDEField().getCodeName()?lower_case}': datas && datas[0].srfkey });
let tempViewParam: any = { actionView: linkItem.sequenceflowview, actionForm: linkItem.sequenceflowform }; let tempViewParam: any = { actionView: linkItem.sequenceflowmobview, actionForm: linkItem.sequenceflowmobform };
ViewOpenService.getInstance().openModal(targetView, tempContext, tempViewParam).then((result: any) => { ViewOpenService.getInstance().openModal(targetView, tempContext, tempViewParam).then((result: any) => {
if (!result || !Object.is(result.ret, 'OK')) { if (!result || !Object.is(result.ret, 'OK')) {
return; return;
...@@ -248,12 +243,7 @@ import WFDynaEditViewEngine from '@engine/view/mob-wfdyna-edit-view-engine'; ...@@ -248,12 +243,7 @@ import WFDynaEditViewEngine from '@engine/view/mob-wfdyna-edit-view-engine';
return; return;
} }
let _this: any = this; let _this: any = this;
if (_this.viewparams) { this.closeView([{ ...data }]);
this.$emit('viewdataschange', [{ ...data }]);
this.closeView(data);
} else if (this.$tabPageExp) {
this.$tabPageExp.onClose(this.$route.fullPath);
}
AppCenterService.notifyMessage({ name: '${view.getPSAppDataEntity().getCodeName()}', action: 'appRefresh', data: data }); AppCenterService.notifyMessage({ name: '${view.getPSAppDataEntity().getCodeName()}', action: 'appRefresh', data: data });
this.$notice.success(data?.message ? data.message : this.$t('app.wizardpanel.success')) this.$notice.success(data?.message ? data.message : this.$t('app.wizardpanel.success'))
}).catch((error: any) => { }).catch((error: any) => {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册