2021-02-07 21:21:12 +08:00

1 line
5.8 KiB
JavaScript

(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/auditingPop/toExamine"],{"062b":function(t,e,s){},"42c4":function(t,e,s){"use strict";(function(t){s("40da");n(s("66fd"));var e=n(s("c255"));function n(t){return t&&t.__esModule?t:{default:t}}t(e.default)}).call(this,s("543d")["createPage"])},c255:function(t,e,s){"use strict";s.r(e);var n=s("cad7"),i=s("e543");for(var a in i)"default"!==a&&function(t){s.d(e,t,(function(){return i[t]}))}(a);s("d616");var r,o=s("f0c5"),c=Object(o["a"])(i["default"],n["b"],n["c"],!1,null,"317e45f4",null,!1,n["a"],r);e["default"]=c.exports},cad7:function(t,e,s){"use strict";var n;s.d(e,"b",(function(){return i})),s.d(e,"c",(function(){return a})),s.d(e,"a",(function(){return n}));var i=function(){var t=this,e=t.$createElement;t._self._c},a=[]},d616:function(t,e,s){"use strict";var n=s("062b"),i=s.n(n);i.a},e543:function(t,e,s){"use strict";s.r(e);var n=s("f1af"),i=s.n(n);for(var a in n)"default"!==a&&function(t){s.d(e,t,(function(){return n[t]}))}(a);e["default"]=i.a},f1af:function(t,e,s){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=s("2f62");function i(t,e){var s=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),s.push.apply(s,n)}return s}function a(t){for(var e=1;e<arguments.length;e++){var s=null!=arguments[e]?arguments[e]:{};e%2?i(Object(s),!0).forEach((function(e){r(t,e,s[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(s)):i(Object(s)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(s,e))}))}return t}function r(t,e,s){return e in t?Object.defineProperty(t,e,{value:s,enumerable:!0,configurable:!0,writable:!0}):t[e]=s,t}var o={data:function(){return{postData:{PROINST_ID:"",FINANCEPROINST_ID:"",NOWACTINST_ID:"",PROINST_NEXTID:2e3,NextACTDEF_IDS:"",APPROVED_INFO:"拟同意"},isExpense:!1,pickerIndex:[0,0],signUsers:[],needSign:!1,notUserData:!1,TransferUserList:[],NextActDefList:[],nowType:1,isSubmit:!1}},computed:a({},(0,n.mapGetters)({users:"getUser"})),methods:a(a({},(0,n.mapMutations)(["isGetTodoList","shouldReLoadingList"])),{},{pickerChange:function(t,e){if(this.pickerIndex[e]=t.detail.value,0===e&&this.getTransferUser(t.detail.value),1==this.nowType){var s=this.NextActDefList[t.detail.value];5010==s.ActDef_Type&&(_this.notUserData=!0),1===s.IsSign&&(this.notUserData=!0,this.needSign=!0)}if(3===this.nowType){var n=this.TransferUserList[t.detail.value],i=this.signUsers.findIndex((function(t){return t.USER_ID===n.USER_ID}));-1===i&&this.signUsers.push(n)}this.$forceUpdate()},choese:function(e){var s=!1;if(this.nowType=e,1!==e&&!this.NextActDefList[this.pickerIndex[0]].ActDef_ID)return t.showToast({title:"请先选择转出业务后再指定经办人。",icon:"none"}),!1;switch(e){case 1:0===this.NextActDefList.length&&(s=!0);break;default:0===this.TransferUserList.length&&(s=!0);break}return s?(t.showToast({title:"该选项没有待选项,请稍后重试或待管理人员添加待选项后重试。",icon:"none"}),!1):void 0},removeSignUsers:function(t){this.signUsers.splice(t,1)},getHighNextActDef:function(){var e=this,s=this,n={};n=this.isExpense?{action_type:"GetFlowNextActDef",FINANCEPROINST_ID:s.postData.FINANCEPROINST_ID,FINANCEPROINST_NEXTID:s.postData.PROINST_NEXTID}:{action_type:"GetNextStep",businessType:s.postData.businessType,PROINST_ID:s.postData.PROINST_ID,PROINST_NEXTID:s.postData.PROINST_NEXTID},this.$request.get(n).then((function(n){t.hideLoading(),n.Data.List[0].ActDef_Type&&5010===n.Data.List[0].ActDef_Type&&(s.notUserData=!0),1===n.Data.List[0].IsSign&&(e.notUserData=!0,e.needSign=!0),s.NextActDefList=n.Data.List,s.getTransferUser()}))},getTransferUser:function(e){var s=this,n={};n=this.isExpense?{action_type:"GetFlowTransferUser",action_data:s.users.uid,PROINST_ID:s.postData.FINANCEPROINST_ID,NextACTDEF_IDS:e}:{action_type:"GetNextStepUser",businessType:s.postData.businessType,PROINST_ID:s.postData.PROINST_ID,NextStepId:s.NextActDefList[s.pickerIndex[0]].ActDef_ID,USER_ID:s.users.UserId},t.showLoading(),this.$request.get(n).then((function(e){s.TransferUserList=e.Data.List,t.hideLoading()}))},postFn:function(){var e=this,s={};if(!e.isSubmit){if(!e.NextActDefList[e.pickerIndex[0]])return t.showToast({title:"请选择转出业务后提交。",icon:"none"}),!1;if(!this.notUserData&&!e.TransferUserList[e.pickerIndex[1]]||this.needSign&&0===this.signUsers.length)return t.showToast({title:"请选择人员后提交。",icon:"none"}),!1;if(s={action_type:"ProcessApproval",businessType:e.postData.businessType,PROINST_ID:e.postData.PROINST_ID,PROINST_NEXTID:e.postData.PROINST_NEXTID,NOWACTINST_IDS:e.postData.NOWACTINST_ID,NextACTDEF_IDS:e.NextActDefList[e.pickerIndex[0]].ActDef_ID,NextSTAFF_ID:e.TransferUserList.length>0?this.TransferUserList[e.pickerIndex[1]].USER_ID:"",APPROVED_INFO:e.postData.APPROVED_INFO,APPROVED_NAME:e.postData.ApproName},e.notUserData&&(delete s.NextSTAFF_ID,this.needSign)){var n=[],i=[];this.signUsers.map((function(t){n.push(t.USER_ID),i.push(t.USER_NAME)})),s.SignUserIds=n.toString(),s.SignUserNames=i.toString()}this.isSubmit=!0,this.$request.post(s).then((function(s){e.isSubmit=!1,"100"===s.ResultCode?(t.$emit(e.postData.businessType,!0),e.isGetTodoList(!0),e.shouldReLoadingList(!0),t.showToast({title:s.ResultDesc,success:function(){setTimeout((function(){t.navigateBack({delta:1})}),1e3)}})):t.showToast({title:s.ResultDesc||"操作错误",icon:"none"})}))}}}),onLoad:function(e){this.postData=e,this.postData.PROINST_NEXTID=2e3,this.postData.APPROVED_INFO="拟同意",t.showLoading({title:"正在加载"}),this.getHighNextActDef()},onUnload:function(){this.$util.addUserBehavior()}};e.default=o}).call(this,s("543d")["default"])}},[["42c4","common/runtime","common/vendor"]]]);