From cb20bc516a5fb0250271162aa052e4ca27e09d3f Mon Sep 17 00:00:00 2001 From: huqi Date: Mon, 30 Nov 2020 14:34:57 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BD=93work=E6=97=A0=E6=B3=95=E8=8E=B7?= =?UTF-8?q?=E5=8F=96=E6=97=B6=EF=BC=8C=E5=85=B3=E9=97=AD=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- o2web/source/x_component_process_Work/Main.js | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/o2web/source/x_component_process_Work/Main.js b/o2web/source/x_component_process_Work/Main.js index ca0ba61cb3..4177c26545 100644 --- a/o2web/source/x_component_process_Work/Main.js +++ b/o2web/source/x_component_process_Work/Main.js @@ -142,6 +142,7 @@ MWF.xApplication.process.Work.Main = new Class({ } }, loadWorkByWork: function(id){ + debugger; //var getWorkLogMothed = "getWorkLog"; //以前使用worklog,现在改成record了 //var getWorkLogMothed = (this.options.worklogType.toLowerCase()==="worklog") ? "getWorkLog" : "getRecordLog"; var loadFormFlag = false; @@ -151,7 +152,7 @@ MWF.xApplication.process.Work.Main = new Class({ var json_work, json_log, json_control, json_form; var check = function(){ - if (loadWorkFlag && loadFormFlag && loadModuleFlag){ + if (loadWorkFlag && loadFormFlag && loadModuleFlag){ if (json_work && json_control && json_form && json_log){ this.parseData(json_work.data, json_control.data, json_form.data, json_log.data, json_work.data.recordList, json_work.data.attachmentList); if (this.mask) this.mask.hide(); @@ -164,7 +165,7 @@ MWF.xApplication.process.Work.Main = new Class({ layout.sessionPromise.then(function(){ this.openWork(); this.unLoading(); - }.bind(this)); + }.bind(this), function(){}); } } } else{ @@ -175,6 +176,9 @@ MWF.xApplication.process.Work.Main = new Class({ delete this.options.workcompletedid; this.loadWork(); }else{ + layout.sessionPromise.then(function(){ + this.close(); + }.bind(this), function(){}); //this.close(); } } @@ -196,6 +200,9 @@ MWF.xApplication.process.Work.Main = new Class({ loadFormFlag = true; check(); }.bind(this), "failure": function(){ + layout.sessionPromise.then(function(){ + this.close(); + }.bind(this), function(){}); //this.close(); }.bind(this)}, id, id, id, [this.options.formid || this.options.form.id]); }else{ @@ -242,6 +249,9 @@ MWF.xApplication.process.Work.Main = new Class({ loadWorkFlag = true; check(); }.bind(this), "failure": function(){ + layout.sessionPromise.then(function(){ + this.close(); + }.bind(this), function(){}); //this.close(); }.bind(this)}, id ); @@ -348,6 +358,9 @@ MWF.xApplication.process.Work.Main = new Class({ } } }else{ + layout.sessionPromise.then(function(){ + this.close(); + }.bind(this), function(){}); //this.close(); } }.bind(this), function(){ -- GitLab