diff --git a/src/api/plugin/workflow/form-variable.js b/src/api/plugin/workflow/form-variable.js new file mode 100644 index 0000000..ccd7d13 --- /dev/null +++ b/src/api/plugin/workflow/form-variable.js @@ -0,0 +1,50 @@ +import request from '@/router/axios'; + +const prefix = '/api/blade-workflow/design/form/variable' + +export const getList = (current, size, params) => { + return request({ + url: `${prefix}/list`, + method: 'get', + params: { + ...params, + current, + size, + } + }) +} + +export const getDetail = (params) => { + return request({ + url: `${prefix}/detail`, + method: 'get', + params + }) +} + +export const remove = (ids) => { + return request({ + url: `${prefix}/remove`, + method: 'post', + params: { + ids, + } + }) +} + +export const add = (row) => { + return request({ + url: `${prefix}/submit`, + method: 'post', + data: row + }) +} + +export const update = (row) => { + return request({ + url: `${prefix}/update`, + method: 'post', + data: row + }) +} + diff --git a/src/views/plugin/workflow/mixins/ex-form.js b/src/views/plugin/workflow/mixins/ex-form.js index 4bcff6b..aebdfc4 100644 --- a/src/views/plugin/workflow/mixins/ex-form.js +++ b/src/views/plugin/workflow/mixins/ex-form.js @@ -162,6 +162,8 @@ export default { form = { ...form, copyUser, assignee } } if (valid) { + form['wf_form_option'] = JSON.stringify(this.option) + form['wf_form_variable'] = JSON.stringify(form) startProcess(form).then(res => { if (isExForm === true) { resolve(res, done) @@ -201,6 +203,8 @@ export default { form = { ...form, copyUser, assignee } } if (valid) { + form['wf_form_option'] = JSON.stringify(this.option) + form['wf_form_variable'] = JSON.stringify(form) startProcessByKey(form).then(res => { if (isExForm === true) { resolve(res, done) @@ -266,6 +270,8 @@ export default { reject() return } + variables['wf_form_option'] = JSON.stringify(this.option) + variables['wf_form_variable'] = JSON.stringify(this.form) const { taskId, processInstanceId, processDefinitionName, processDefinitionId } = this.process const param = { taskId, processInstanceId, processDefinitionName, processDefinitionId, pass, diff --git a/src/views/plugin/workflow/process/components/detail.vue b/src/views/plugin/workflow/process/components/detail.vue index 521b8df..608e603 100644 --- a/src/views/plugin/workflow/process/components/detail.vue +++ b/src/views/plugin/workflow/process/components/detail.vue @@ -7,12 +7,9 @@ :offset-top="114">