猎户系统

28.82959f692bfe6299a1b6.js 11KB

1
  1. webpackJsonp([28],{"3uEH":function(e,t,s){"use strict";var i={components:{selfInput:s("McOJ").a},props:{title:{type:String,default:"所属客服"},clearable:{type:Boolean,default:!0},reset:{type:Boolean,default:!1},width:{type:String},afferent_users:{type:Array}},watch:{reset:function(){this.selectUserId="",this.selectUser={}}},data:function(){return{resetFlag:!1,visible:!1,loading:!1,userList:[],userTotal:0,selectUserId:"",selectUser:{},input_keyword:""}},mounted:function(){console.log(this.selectUser)},methods:{screenClick:function(){this.visible=!0,0==this.userList.length?this.init():this.serviceInit()},serviceInit:function(e){var t=this;this.userList.forEach(function(e){e.is_open=!1,e.user_list.forEach(function(e,s){e.user_id==t.selectUserId&&(t.selectUser=e)})}),"define"==e&&this.$emit("customerDefine",this.selectUser)},clear:function(){this.selectUserId="",this.selectUser={},this.input_keyword="",this.resetFlag=!this.resetFlag,this.init(),this.$emit("customerDefine","")},defineEvent:function(){""!=this.selectUserId?(this.serviceInit("define"),this.visible=!1):this.$message({message:"请选择客服",type:"warning"})},init:function(){var e=this;this.loading=!0,this.$axios.get(this.URL.BASEURL+this.URL.userList,{params:{user_name:this.input_keyword}}).then(function(t){t=t.data;e.loading=!1,t&&0==t.errno?(e.userList=t.rst.list,e.serviceInit(),e.userTotal=t.rst.count):4002!=t.errno&&e.$message({message:t.err,type:"warning"})}).catch(function(t){e.loading=!1})},openEvent:function(e){var t=this.userList[e];t.is_open=!t.is_open,this.$set(this.userList,e,t)},selectUserEvent:function(e,t){this.selectUserId=t}}},a={render:function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"common-screen-item"},[e.title&&""!=e.title?s("label",{staticClass:"common-screen-label"},[e._v(e._s(e.title))]):e._e(),e._v(" "),s("div",{class:["common-screen-self-box","common-input-select",e.selectUser&&e.selectUser.user_id&&e.clearable?"common-input-select-hover":""],style:e.width?"width:"+e.width:"",on:{click:e.screenClick}},[s("div",{class:["common-screen-self-con",e.selectUser&&e.selectUser.user_id&&""!=e.selectUser.user_id?"":"common-screen-self-placeholder"]},[s("div",{staticClass:"common-screen-self-con-div"},[e.selectUser&&e.selectUser.user_id&&""!=e.selectUser.user_id?[s("span",[e._v(e._s(e.selectUser.name))])]:s("span",[e._v("请选择")])],2),e._v(" "),s("i",{staticClass:"el-icon-circle-close other-icon",on:{click:function(t){return t.stopPropagation(),e.clear.apply(null,arguments)}}})]),e._v(" "),e._m(0)]),e._v(" "),s("el-dialog",{attrs:{title:"",visible:e.visible,"close-on-click-modal":!1,width:"400px","append-to-body":"",center:"",top:"15vh"},on:{"update:visible":function(t){e.visible=t}}},[s("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}]},[s("div",{staticClass:"propoverItem"},[s("self-input",{staticStyle:{"margin-top":"0"},attrs:{reset:e.resetFlag,hasLabel:!1,width:"90%"},on:{inputChange:function(t){e.input_keyword=t,e.init("userSearch")}}}),e._v(" "),s("div",{staticClass:"allMember"},[e._v("全部成员("+e._s(e.userTotal)+"):")]),e._v(" "),s("div",{staticClass:"memberBoxBig self-scrollbar-3"},[e._l(e.userList,function(t,i){return[s("div",{key:i+"userList"+t.department_id,staticClass:"memberBox"},[s("i",{class:["el-icon-caret-bottom",t.is_open?"reversalAnimation":""],on:{click:function(t){return e.openEvent(i)}}}),e._v(" "),s("div",{staticClass:"meberList"},[s("div",{staticClass:"department"},[s("div",{staticClass:"flex"},[s("i",{staticClass:"el-icon-s-cooperation"}),e._v(" "),s("span",[e._v(e._s(t.department_name?t.department_name:"部门"+(i+1)))])])]),e._v(" "),e._l(t.user_list,function(i){return s("div",{key:i.user_id,staticClass:"memberItem",style:t.is_open?"display:none":"",on:{click:function(t){return e.selectUserEvent("user",i.user_id)}}},[s("div",{staticClass:"flex",staticStyle:{flex:"1"}},[s("img",{staticClass:"memberImg",attrs:{src:i.avatar,alt:""}}),e._v(" "),s("div",{staticClass:"memberInfo"},[s("div",{staticClass:"name"},[e._v(e._s(i.name))]),e._v(" "),s("div",{staticClass:"other"},[e._v("部门:"+e._s(i.department_list&&i.department_list.join(",")))])])]),e._v(" "),s("div",{class:["checkbox",e.selectUserId==i.user_id?"checkbox_active":""]},[s("i",{staticClass:"el-icon-check"})])])})],2)])]})],2)],1),e._v(" "),s("div",{staticClass:"buttons"},[s("el-button",{attrs:{type:"primary",plain:"",size:"mini"},on:{click:function(t){e.visible=!1}}},[e._v("取消")]),e._v(" "),s("el-button",{attrs:{type:"primary",size:"mini"},on:{click:e.defineEvent}},[e._v("确定")])],1)])])],1)},staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"common-screen-self-icon"},[t("i",{staticClass:"el-icon-arrow-down"})])}]};var n=s("VU/8")(i,a,!1,function(e){s("POxC")},"data-v-b36d5b36",null);t.a=n.exports},POxC:function(e,t){},XNCx:function(e,t,s){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=s("McOJ"),a=s("gzej"),n=s("3uEH"),r=s("erru"),l=s("VULP"),o={components:{selfInput:i.a,datePicker:a.a,serviceSingle:n.a,selfChannel:r.a,detial:l.a},data:function(){return{type:"",loading:!1,page:1,pages:0,total:0,page_size:20,input_keyword:"",resetFlag:!1,tableData:[],transfer_time:[],user_id:"",assignment_status:"",drawerSize:"60%",detialDrawer:!1,rowPro:{},height:""}},created:function(){this.height=document.documentElement.clientHeight-460>400?document.documentElement.clientHeight-460:400,this.type=this.$route.params.type,this.init(1)},methods:{changeDrawerSize:function(){this.drawerSize="100%"==this.drawerSize?"60%":"100%"},closeDrawer:function(){this.detialDrawer=!1},showDetial:function(e){var t=this;this.rowPro=e,this.drawerSize="60%",this.detialDrawer=!0,this.$nextTick(function(){t.$refs.detial.acIdx=0,t.$refs.detial.init()})},serviceSingleEvent:function(e){e&&e.user_id?this.user_id=e.user_id:this.user_id="",this.init(1)},goBack:function(){localStorage.setItem("transter",this.type),this.$router.go(-1)},changeTime:function(e){!e||e&&0==e.length?this.transfer_time=[]:this.transfer_time=e,this.init(1)},resetEvent:function(){this.resetFlag=!this.resetFlag,this.input_keyword="",this.user_id="",this.assignment_status="",this.transfer_time=[],this.init(1)},init:function(e){var t=this;this.page=e||this.page,this.loading=!0,this.$axios.get(this.URL.BASEURL+this.URL.customerAssignmentList,{params:{assignment_date_start:this.transfer_time&&this.transfer_time.length>1?this.transfer_time[0]:"",assignment_date_end:this.transfer_time&&this.transfer_time.length>1?this.transfer_time[1]:"",customer_name:this.input_keyword,page:this.page,page_size:this.page_size,type:"off"==this.type?2:1,user_id:this.user_id,assignment_status:this.assignment_status}}).then(function(e){e=e.data;t.loading=!1,e&&0==e.errno?(t.tableData=e.rst.data,t.total=e.rst.pageInfo.total,t.pages=e.rst.pageInfo.pages):4002!=e.errno&&t.$message({message:e.err,type:"warning"})}).catch(function(e){t.loading=!1})},handleCurrentChange:function(e){this.init(e)}}},c={render:function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}]},[s("div",{staticClass:"backBox",on:{click:e.goBack}},[s("div",{staticClass:"back"},[s("i",{staticClass:"el-icon-back"}),e._v(" "),s("span",{staticClass:"back_main_title"},[e._v(e._s("off"==e.type?"离职迁移":"on"==e.type?"在职迁移":"返回")+"/")]),s("span",[e._v("分配记录")])])]),e._v(" "),s("div",{staticClass:"self-hint",staticStyle:{"margin-bottom":"10px"}},[s("i",{staticClass:"el-icon-message-solid"}),e._v(" "),s("div",[e._v("由于企业微信限制,列表仅展示在"+e._s(e.$store.state.simpleName)+"操作的分配记录,"+e._s(e.$store.state.simpleName)+"分配记录将不会展示")])]),e._v(" "),s("div",{staticClass:"screenBox"},[s("self-input",{attrs:{reset:e.resetFlag},on:{inputChange:function(t){e.input_keyword=t,e.init(1)}}}),e._v(" "),s("service-single",{attrs:{title:"接替员工",reset:e.resetFlag},on:{customerDefine:e.serviceSingleEvent}}),e._v(" "),s("date-picker",{attrs:{title:"分配时间",reset:e.resetFlag},on:{changeTime:e.changeTime}}),e._v(" "),s("self-channel",{attrs:{title:"转接状态",reset:e.resetFlag,type:"assignment_status"},on:{channelDefine:function(t){e.assignment_status=t,e.init(1)}}}),e._v(" "),s("div",{staticClass:"reset",on:{click:e.resetEvent}},[e._v("重置")])],1),e._v(" "),s("div",{staticClass:"tableInfo"},[s("div",[s("div",{staticClass:"flex"},[s("i",{staticClass:"el-icon-user-solid"}),e._v(" "),s("div",{staticClass:"totalCustom"},[e._v("共有"),s("span",[e._v(e._s(e.total))]),e._v("个已分配客户")])])])]),e._v(" "),s("el-table",{ref:"multipleTable",staticStyle:{width:"100%"},attrs:{height:e.height,data:e.tableData,"tooltip-effect":"dark"}},[s("el-table-column",{attrs:{prop:"customer_name",label:"客户名称","show-overflow-tooltip":"",align:"center"}}),e._v(" "),s("el-table-column",{attrs:{prop:"takeover_username",label:"接替员工","show-overflow-tooltip":"",align:"center"}}),e._v(" "),s("el-table-column",{attrs:{label:"转接状态",align:"center","min-width":"100"},scopedSlots:e._u([{key:"default",fn:function(t){return[-1==t.row.status?[s("span",[e._v("迁移失败")]),e._v(" "),s("p",{staticClass:"c-757D9C f12"},[e._v("("+e._s(t.row.err_msg)+")")])]:e._e(),e._v(" "),1==t.row.status?s("span",[e._v("已转接")]):e._e(),e._v(" "),2==t.row.status?s("span",[e._v("客户转接中")]):e._e(),e._v(" "),3==t.row.status?s("span",[e._v("客户已拒绝")]):e._e(),e._v(" "),4==t.row.status?s("span",[e._v("接替成员客户达到上限")]):e._e(),e._v(" "),5==t.row.status?s("span",[e._v("无接替记录")]):e._e()]}}])}),e._v(" "),s("el-table-column",{attrs:{prop:"takeover_time",label:"分配时间","show-overflow-tooltip":"",align:"center"}}),e._v(" "),s("el-table-column",{attrs:{label:"操作",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[s("div",{staticClass:"flex",staticStyle:{"justify-content":"center"}},[t.row.takeover_userid?s("div",{staticClass:"c-00B38A pointer",staticStyle:{margin:"0 6px"},on:{click:function(s){return e.showDetial(t.row)}}},[e._v("详情")]):e._e()])]}}])})],1),e._v(" "),s("div",{directives:[{name:"show",rawName:"v-show",value:e.total>0,expression:"total > 0"}],staticClass:"pagination"},[s("el-pagination",{attrs:{background:"","current-page":e.page,layout:"prev, pager, next","page-count":Number(e.pages)},on:{"current-change":e.handleCurrentChange}})],1),e._v(" "),s("el-drawer",{attrs:{size:e.drawerSize,visible:e.detialDrawer,"with-header":!1},on:{"update:visible":function(t){e.detialDrawer=t}}},[s("detial",{ref:"detial",attrs:{rowProp:{customer_id:e.rowPro.customer_id,user_id:e.rowPro.takeover_userid}},on:{changeDrawerSize:e.changeDrawerSize,closeDrawer:e.closeDrawer}})],1)],1)},staticRenderFns:[]};var u=s("VU/8")(o,c,!1,function(e){s("xJRw")},"data-v-2e635a8d",null);t.default=u.exports},xJRw:function(e,t){}});