Commit 96b1b66f authored by 陈珠河's avatar 陈珠河

Style: 新建表单工作时,渲染参数接口调整

parent 5aa1386c
......@@ -23,11 +23,12 @@ const Api = {
* @param {*} linkId
* @param {*} linkKey
*/
getBusinessStartForm(businessDefinitionId) {
getBusinessStartForm(businessDefinitionId, taskId) {
return config.doGetPromise(
baseUrl + '/v1.1.0/workflow/workflowForm/getBusinessStartForm',
{
businessDefinitionId
businessDefinitionId,
taskId
}
);
},
......
......@@ -169,7 +169,7 @@ export default {
this.currentLink.masterMen.forEach(user => {
this.$set(user, 'checked', true);
// 如果提交所有人,禁止状态,不能改变选中
if (val.completingToAll) this.$set(user, 'disabled', true) ;
if (val.completingToAll) this.$set(user, 'disabled', true);
this.mainCheckedKeys.push(user.organInfo.rid);
});
this.currentLink.normalMen.forEach(user => {
......
......@@ -42,7 +42,7 @@
ref="submitTask"
:nextLinks="submitData.subTask"
:nextLinkUsers="submitData.userInfos"
@closed="submitTaskDialogVisible = false"
@closed="handleSubmitTaskClose"
@save="handleSubmitTaskSave"
></submit-task>
<!-- 转办 -->
......@@ -125,7 +125,8 @@ export default {
submitTaskDialogVisible: false, // 提交dialog
submitData: {},
transformDialogVisible: false, // 转办dialog
returnTaskVisible: false // 退回dialog
returnTaskVisible: false, // 退回dialog
createTaskId: '' // 新建工作后保存时的taskId
};
},
......@@ -145,8 +146,8 @@ export default {
},
// 刷新
refresh() {
this.fetch();
refresh(taskId) {
this.fetch(taskId);
},
handleResultHtml(data, key) {
......@@ -158,10 +159,12 @@ export default {
return {};
}
},
fetch() {
/**
* 新建工作时,保存的时候后端返回tId
*/
fetch(tId) {
let taskId = getTaskId() || this.childrenData.taskId;
const linkId = getLinkId() || this.childrenData.linkId;
const linkId = tId ? tId : getLinkId() || this.childrenData.linkId;
const linkKey = getLinkKey() || this.childrenData.linkKey;
// console.log(taskId, linkId, linkKey)
let apiFn = 'renderFormByTaskId';
......@@ -177,9 +180,7 @@ export default {
taskId = getFinishForm();
apiFn = 'renderFinishForm';
}
this.isLoading = true;
Api[apiFn](taskId, linkId, linkKey)
.then(res => {
this.isLoading = false;
......@@ -420,7 +421,9 @@ export default {
// console.log(res)
if (res.status === 0) {
notification('success', '保存成功!');
this.refresh();
if (!res.data.taskId) return false;
this.createTaskId = res.data.taskId;
this.refresh(res.data.taskId);
} else {
notification('warning', res.message || '保存失败,请重试!');
}
......@@ -777,6 +780,12 @@ export default {
/* eslint-disable no-eval */
eval(item.operation);
}
},
// 关闭提交后的对话框事件
handleSubmitTaskClose() {
this.submitTaskDialogVisible = false;
this.refresh(this.createTaskId);
}
}
};
......
import Vue from 'vue';
import Vuex from 'vuex';
const packageConfig = require('../../../package.json');
const packageConfig = require('./../../package.json');
Vue.use(Vuex);
......
......@@ -127,12 +127,6 @@ export default {
}
},
navigationList(newVal) {
if (newVal.length > 0) {
}
},
currentTab() {
const len = this.tabsData.length;
for (let i = 0; i < len; i++) {
......
......@@ -137,7 +137,6 @@ export default {
});
this.passSubmiting = false;
}, 3000);
} else {
this.$message({
type: 'warning',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment