Browse Source

app2.0:流程修改;

yanshi
dyy 2 years ago
parent
commit
0ab218c78d
1 changed files with 28 additions and 9 deletions
  1. +28
    -9
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/nworkflow/myflow/single.vue

+ 28
- 9
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/nworkflow/myflow/single.vue View File

@@ -75,6 +75,7 @@ export default {
// 需要字段: mark (是 my 或者不是,表示是否自「我的」列打开)
this.type = type
this.currentTask = this.GET_PARAM()
console.log(this.type,this.currentTask);
this.LOADING('加载表单中…')
this.SET_TITLE(this.currentTask.F_Title)
// 未完成的子流程,可以编辑
@@ -92,8 +93,11 @@ export default {
processId: this.processId,
taskId: this.taskId
})
console.log(this.processInfo)
this.currentNode = this.getCurrentNode(this.processInfo)
console.log(this.currentNode)
this.processList = get(this.processInfo, 'info.TaskLogList', [])
console.log(this.processList)
// wfForms 的数组成员 t,表示表单数据项(TAB页)
// t.formId 使用表单,根据这个 formId 来获取 scheme 等信息
// t.appurl 使用移动页面,直接跳转到本地的页面;表单结构等均写死在页面里
@@ -101,14 +105,29 @@ export default {
console.log(wfForms);

// 处理没有有效表单的情况,停止加载
if (!wfForms || wfForms.every(t => !t.formId && !t.appurl)) {
this.HIDE_LOADING()
this.TOAST('移动表单数据(wfForms)中无有效表单')
return
}
//if (!wfForms || wfForms.every(t => !t.formId && !t.appurl)) {
//this.HIDE_LOADING()
//this.TOAST('移动表单数据(wfForms)中无有效表单')
//return
//}
//2022-02-14修改
if (this.type !== 'child') {
if (!wfForms || wfForms.every(t => !t.formId && !t.appurl)) {
this.HIDE_LOADING()
this.TOAST('移动表单数据(wfForms)中无有效表单')
//return
}
}
//2022-02-14修改end

// 处理移动端本地表单(也就是系统表单)的情况,直接跳转过去
const appSysPage = wfForms.find(t => t.appurl)
//const appSysPage = wfForms.find(t => t.appurl)
//2022-02-14修改
var appSysPage = null
if(wfForms && wfForms.every(t => t.formId && t.appurl)){
appSysPage = wfForms.find(t => t.appurl)
}
//2022-02-14修改end
if (this.type !== 'child' && appSysPage) {
this.sysFormJump(appSysPage.appurl, {
currentNode: this.currentNode,
@@ -204,7 +223,7 @@ export default {
return
}
this.LOADING(`提交${actionText}中…`)
this.HTTP_POST(`/newwf${actionUrl}`, actionData, `提交${actionText}失败`).then(success => {
this.HTTP_POST(`/learun/adms/newwf${actionUrl}`, actionData, `提交${actionText}失败`).then(success => {
this.HIDE_LOADING()
if (success) {
this.EMIT('task-list-change')
@@ -223,7 +242,7 @@ export default {
this.LOADING('正在提交…')
const draftFormValue = this.$refs.form.getFormValue()
const draftPostData = await this.getPostData(draftFormValue, this.scheme)
this.HTTP_POST('/newwf/draft', draftPostData, '提交草稿失败').then(success => {
this.HTTP_POST('learun/adms/newwf/draft', draftPostData, '提交草稿失败').then(success => {
this.HIDE_LOADING()
if (success) {
this.EMIT('task-list-change')
@@ -252,7 +271,7 @@ export default {
postData.parentTaskId = this.taskId
}
const errorTips = '流程发起失败'
this.HTTP_POST('/newwf/createchildflow', postData, errorTips).then(success => {
this.HTTP_POST('learun/adms/newwf/childcreate', postData, errorTips).then(success => {
this.HIDE_LOADING()
if (success) {
this.EMIT('task-list-change')


Loading…
Cancel
Save