1 line
11 KiB
JavaScript
1 line
11 KiB
JavaScript
webpackJsonp([215],{"MHL+":function(t,e){},fvEe:function(t,e){},oeHx:function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=a("d7EF"),l=a.n(i),r=a("//Fk"),o=a.n(r),s=a("woOf"),n=a.n(s),c=a("Dd8w"),m=a.n(c),u=a("NYxO"),d=a("3MlD"),p=a("bzuE"),f=a("Dod7"),h={components:{DialogChooseSingleUser:d.a},name:"task_detail",data:function(){return{uploadUrl:f.a.uploadUrl,ftpPrefix:f.a.ftpPrefix,formData:{targetList:[],taglocationappearanceImage:[],deletetag_appearanceImage:[],initFileList:[],taskType:null,heldPerson:null,ccNames:""},loading:!1,initFileList:[],replyList:[],dealList:[],typeList:[],levelList:[],dialogImageUrl:"",dialogVisible:!1,chooseUserVisible:!1,type:null,btnHandleShow:!1,btnCompleteShow:!1,btnReturnShow:!1,btnReplyShow:!1,redirect:"",config:p.a}},mounted:function(){this.initialize(),this.$route.query.type&&(this.type=this.$route.query.type),this.$route.query.redirect&&(this.redirect=this.$route.query.redirect),this.$route.query.id&&(this.formData.id=this.$route.query.id,this.getDetail())},methods:m()({},Object(u.d)({removeTagNav:"tagNav/removeTagNav"}),{getDetail:function(){var t=this;this.loading=!0,this.$api.taskMainAPI.detail(this.formData.id).then(function(e){if(0===e.code){if(t.formData=n()({},t.formData,e.taskMain),e.ccIdList){var a="";e.ccIdList.forEach(function(t){a+=t.name+","}),a=a.substring(0,a.length-1),t.formData.ccNames=a}if(e.heldPerson&&(t.formData.heldPerson=parseInt(e.heldPerson.employeeId),t.formData.heldPersonName=e.heldPerson.userName),56===t.formData.statusId?(t.btnHandleShow=!0,t.btnReturnShow=!0,t.btnReplyShow=!0):57===t.formData.statusId?(t.btnCompleteShow=!0,t.btnReplyShow=!0):t.formData.statusId,371===t.type&&(t.btnHandleShow=!1,t.btnReturnShow=!1,t.btnReplyShow=!1,t.btnCompleteShow=!1),e.initFileList&&e.initFileList.length>0){t.initFileList=[];for(var i=0;i<e.initFileList.length;i++){var l={name:e.initFileList[i].id,url:t.ftpPrefix+e.initFileList[i].filePath};t.initFileList.push(l)}}e.dealList&&e.dealList.length>0&&(t.dealList=e.dealList),e.replyList&&e.replyList.length>0&&(t.replyList=e.replyList),t.loading=!1}}).catch(function(e){t.loading=!1})},initialize:function(){var t=this;o.a.all([this.$api.dictAPI.getDictsByType("task_type"),this.$api.dictAPI.getDictsByType("task_level")]).then(function(e){var a=l()(e,2),i=a[0],r=a[1];0===i.code&&(t.typeList=i.datas),0===r.code&&(t.levelList=r.datas)}).catch(function(t){console.log(t)})},back:function(){this.removeTagNav({path:this.$route.path,title:this.$route.meta.name}),375==this.$route.query.type?this.$router.push({path:"/task/untreated",quey:{t:Date.now()}}):378==this.$route.query.type?this.$router.push({path:"/task/unacceptance",quey:{t:Date.now()}}):382==this.$route.query.type?this.$router.push({path:"/task/acceptance",quey:{t:Date.now()}}):this.$router.go(-1)},save_back:function(){this.removeTagNav({path:this.$route.path,title:this.$route.meta.name}),this.redirect?this.$router.push({path:this.redirect,quey:{t:Date.now()}}):this.$router.push({path:"/task/index",quey:{t:Date.now()}})},getUser:function(t){var e=this,a=t.id,i=this.formData.id;this.$confirm("确认将任务转派给【"+t.name+"】吗?","提示",{type:"warning"}).then(function(){e.$api.taskMainAPI.reventTurnToSend({taskId:i,userId:a}).then(function(t){0===t.code?(e.$message({message:t.msg,type:"success"}),e.save_back()):e.$message({message:t.msg?t.msg:"转派失败,请重试",type:"error"})}).catch(function(t){e.$message({message:"转派失败,请重试",type:"error"})})})},reply:function(){this.$router.push({path:"/task/reply",query:{id:this.formData.id,redirect:this.$route.path}})},send:function(){this.chooseUserVisible=!0},handle:function(){this.$router.push({path:"/task/handle",query:{id:this.formData.id,t:Date.now(),redirect:this.$route.path}})},check:function(){this.$router.push({path:"/task/check",query:{id:this.formData.id,t:Date.now(),redirect:this.$route.path}})},replyDetail:function(t){},dealDetail:function(t){this.$router.push({path:"/task/check_detail",query:{id:t.id,t:Date.now()}})},handlePictureCardPreview:function(t){this.dialogImageUrl=t.url,this.dialogVisible=!0}})},v={render:function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"sys-box taskinfo"},[a("div",{staticClass:"sys-operate"},[a("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.back()}}},[t._v(t._s(t.config.cancelText))]),t._v(" "),t.btnHandleShow?a("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.handle()}}},[t._v("处理")]):t._e(),t._v(" "),t.btnReturnShow?a("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.send()}}},[t._v("转派")]):t._e(),t._v(" "),t.btnReplyShow?a("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.reply()}}},[t._v("回复")]):t._e(),t._v(" "),t.btnCompleteShow?a("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.check()}}},[t._v("验收")]):t._e()],1),t._v(" "),a("div",{staticClass:"sys-form"},[a("el-form",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],ref:"form",attrs:{"label-width":"110px",model:t.formData}},[a("el-divider",{attrs:{"content-position":"left"}},[t._v("任务信息")]),t._v(" "),a("div",{staticClass:"flex"},[a("el-form-item",{staticClass:"form-inline",attrs:{label:"任务编号:"}},[a("div",{staticClass:"form-p"},[t._v(" "+t._s(t.formData.taskNo))])]),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"处理状态:"}},[a("div",{staticClass:"form-p"},[t._v(" "+t._s(t.formData.statusName))])]),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"发起人:"}},[a("div",{staticClass:"form-p"},[t._v(" "+t._s(t.formData.applyPersonName))])]),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"关联单号:"}},[a("div",{staticClass:"form-p"},[t._v(" "+t._s(null==t.formData.linkOrderNo||""==t.formData.linkOrderNo?"无":t.formData.linkOrderNo))])]),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"关联单据类型:"}},[a("div",{staticClass:"form-p"},[t._v(" "+t._s(null==t.formData.linkOrderTypeName?"无":t.formData.linkOrderTypeName))])]),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"发起时间"}},[a("div",{staticClass:"form-p"},[t._v(" "+t._s(t.formData.createTime))])])],1),t._v(" "),a("el-divider"),t._v(" "),a("el-form-item",{attrs:{label:"主题"}},[a("el-input",{attrs:{readonly:""},model:{value:t.formData.title,callback:function(e){t.$set(t.formData,"title",e)},expression:"formData.title"}})],1),t._v(" "),a("div",{staticClass:"flex"},[a("el-form-item",{staticClass:"form-inline",attrs:{label:"任务类型"}},[a("el-select",{attrs:{value:t.formData.taskType,readonly:""}},t._l(t.typeList,function(t){return a("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}),1)],1),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"任务等级"}},[a("el-select",{attrs:{value:t.formData.taskLevel,readonly:""}},t._l(t.levelList,function(t){return a("el-option",{key:t.id,attrs:{label:t.name,value:t.id}})}),1)],1),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"要求完成时间"}},[a("el-date-picker",{attrs:{readonly:"",type:"datetime",format:"yyyy-MM-dd HH:mm:ss","value-format":"yyyy-MM-dd HH:mm:ss"},model:{value:t.formData.expireDate,callback:function(e){t.$set(t.formData,"expireDate",e)},expression:"formData.expireDate"}})],1)],1),t._v(" "),a("el-form-item",{attrs:{label:"详细描述"}},[a("el-input",{attrs:{type:"textarea",readonly:"",autosize:{minRows:4}},model:{value:t.formData.detail,callback:function(e){t.$set(t.formData,"detail",e)},expression:"formData.detail"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"照片上传"}},[a("el-upload",{class:{hide:!0},attrs:{accept:".png,.jpg,.jpeg",disabled:"",action:t.uploadUrl,"file-list":t.initFileList,"list-type":"picture-card","on-preview":t.handlePictureCardPreview}},[a("i",{staticClass:"el-icon-plus"})])],1),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"责任人",prop:""}},[a("el-input",{attrs:{readonly:""},model:{value:t.formData.heldPersonName,callback:function(e){t.$set(t.formData,"heldPersonName",e)},expression:"formData.heldPersonName"}})],1),t._v(" "),a("el-form-item",{staticClass:"form-inline",attrs:{label:"责任部门"}},[a("el-input",{attrs:{readonly:""},model:{value:t.formData.deptName,callback:function(e){t.$set(t.formData,"deptName",e)},expression:"formData.deptName"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"抄送人"}},[a("el-input",{attrs:{readonly:""},model:{value:t.formData.ccNames,callback:function(e){t.$set(t.formData,"ccNames",e)},expression:"formData.ccNames"}})],1),t._v(" "),a("el-form-item",{attrs:{label:"回复信息"}},[a("el-table",{attrs:{data:t.replyList,"header-cell-style":{fontWeight:"normal",textAlign:"center",backgroundColor:"#eceff4",color:"#222"},border:""}},[a("el-table-column",{attrs:{prop:"replytime",align:"center",label:"回复时间","show-overflow-tooltip":"",width:"170"}}),t._v(" "),a("el-table-column",{attrs:{prop:"reason","show-overflow-tooltip":"",align:"center",label:"原因分析"}}),t._v(" "),a("el-table-column",{attrs:{prop:"solution",align:"center","show-overflow-tooltip":"",label:"解决方案"}}),t._v(" "),a("el-table-column",{attrs:{prop:"replyername",width:"140",align:"center",label:"回复人"}})],1)],1),t._v(" "),a("el-form-item",{attrs:{label:"处理记录"}},[a("el-table",{attrs:{data:t.dealList,"header-cell-style":{fontWeight:"normal",textAlign:"center",backgroundColor:"#eceff4",color:"#222"},border:""}},[a("el-table-column",{attrs:{prop:"replytime",label:"处理时间",width:"170","show-overflow-tooltip":"",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("el-link",{attrs:{type:"primary"},on:{click:function(a){return t.dealDetail(e.row)}}},[t._v(t._s(e.row.replytime))])]}}])}),t._v(" "),a("el-table-column",{attrs:{prop:"replyername",align:"center","show-overflow-tooltip":"",label:"处理人"}}),t._v(" "),a("el-table-column",{attrs:{prop:"reason",align:"center","show-overflow-tooltip":"",label:"原因分析"}}),t._v(" "),a("el-table-column",{attrs:{prop:"solution",align:"center","show-overflow-tooltip":"",label:"解决方案"}}),t._v(" "),a("el-table-column",{attrs:{prop:"statusName",align:"center",label:"处理结果","show-overflow-tooltip":""}})],1)],1)],1),t._v(" "),a("el-dialog",{attrs:{visible:t.dialogVisible},on:{"update:visible":function(e){t.dialogVisible=e}}},[a("img",{attrs:{width:"100%",src:t.dialogImageUrl,alt:""}})]),t._v(" "),a("DialogChooseSingleUser",{attrs:{visible:t.chooseUserVisible},on:{"update:visible":function(e){t.chooseUserVisible=e},change:t.getUser}})],1)])},staticRenderFns:[]};var y=a("VU/8")(h,v,!1,function(t){a("fvEe"),a("MHL+")},"data-v-3e471a5a",null);e.default=y.exports}}); |