(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-01f7","chunk-445a"],{"3ojK":function(e,t,i){"use strict";var a=i("c2Co"),s=i("4XAY"),n=i("Ew9n"),l=i("raay"),o=i("eOwn"),c=i("BzA1"),r=i("w4ZA"),d=i("3gPr"),u=i("CjUg"),m=i("8OTK"),h=i("f6dm"),f={name:"LeadsDetail",components:{SlideView:n.a,CRMDetailHead:l.a,Activity:o.a,CRMEditBaseInfo:r.a,RelativeFiles:d.a,RelativeHandle:u.a,ImportInfo:c.a,CRMAllCreate:m.default},mixins:[h.a],props:{id:[String,Number],listenerIDs:{type:Array,default:function(){return["crm-main-container"]}},noListenerIDs:{type:Array,default:function(){return[]}},noListenerClass:{type:Array,default:function(){return["el-table__body"]}}},data:function(){return{loading:!1,crmType:"leads",headDetails:[{title:"姓名",value:""},{title:"线索来源",value:""},{title:"手机",value:""},{title:"负责人",value:""},{title:"创建时间",value:""}],tabCurrentName:"Activity",isCreate:!1,showImportInfo:!0,importList:[]}},computed:{activityHandle:function(){var e=[];return this.canCreateFollowRecord&&(e=[{type:"log",label:"写跟进"}]),e},tabNames:function(){return[{label:"活动",name:"Activity"},{label:"详细资料",name:"CRMEditBaseInfo"},{label:this.getTabName("附件",this.tabsNumber.fileCount),name:"RelativeFiles"},{label:"操作记录",name:"RelativeHandle"}]}},mounted:function(){},methods:{getDetial:function(){var e=this;this.loading=!0,Object(a.i)({id:this.id}).then(function(t){e.detailData=t.data,0!==e.detailData.dataAuth&&(e.headDetails[0].value=t.data.name,e.headDetails[1].value=t.data.source,e.headDetails[2].value=t.data.mobile,e.headDetails[3].value=t.data.owner_user_id_info.realname||"",e.headDetails[4].value=t.data.create_time,e.loading=!1)}).catch(function(){e.loading=!1,e.hideView()}),this.getBaseInfo()},getBaseInfo:function(){var e=this;this.loading=!0,Object(s.y)({id:this.id,types:"crm_"+this.crmType,action_id:this.id,module:"crm",controller:this.crmType,action:"read",system:1}).then(function(t){e.importList=t.data,e.loading=!1}).catch(function(){e.loading=!1})},hideView:function(){this.$emit("hide-view")}}},p=(i("H4tY"),i("KHd+")),v=Object(p.a)(f,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("slide-view",{directives:[{name:"empty",rawName:"v-empty",value:!e.canShowDetail,expression:"!canShowDetail"}],attrs:{"listener-ids":e.listenerIDs,"no-listener-ids":e.noListenerIDs,"no-listener-class":e.noListenerClass,"body-style":{padding:0,height:"100%"},"xs-empty-icon":"nopermission","xs-empty-text":"暂无权限"},on:{afterEnter:e.viewAfterEnter,close:e.hideView}},[i("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],ref:"crmDetailMain",staticClass:"detail-main"},[e.canShowDetail&&e.detailData?i("flexbox",{staticClass:"d-container",attrs:{direction:"column",align:"stretch"}},[i("c-r-m-detail-head",{attrs:{detail:e.detailData,"head-details":e.headDetails,id:e.id,"crm-type":e.crmType},on:{handle:e.detailHeadHandle,close:e.hideView}},[i("template",{slot:"name"},[i("el-tooltip",{attrs:{content:0==e.detailData.star?"添加关注":"取消关注",effect:"dark",placement:"top"}},[i("i",{staticClass:"wk wk-focus-on focus-icon",class:{active:0!=e.detailData.star},on:{click:function(t){e.toggleStar()}}})])],1)],2),e._v(" "),i("flexbox",{staticClass:"d-container-bd",attrs:{align:"stretch"}},[i("el-tabs",{staticClass:"d-container-bd--left",attrs:{type:"border-card"},model:{value:e.tabCurrentName,callback:function(t){e.tabCurrentName=t},expression:"tabCurrentName"}},e._l(e.tabNames,function(t,a){return i("el-tab-pane",{key:a,attrs:{label:t.label,name:t.name,lazy:""}},[i(t.name,{tag:"component",attrs:{detail:e.detailData,id:e.id,handle:e.activityHandle,"crm-type":e.crmType}})],1)})),e._v(" "),i("transition",{attrs:{name:"slide-fade"}},[i("el-tabs",{directives:[{name:"show",rawName:"v-show",value:e.showImportInfo,expression:"showImportInfo"}],staticClass:"d-container-bd--right",attrs:{value:"chiefly-contacts",type:"border-card"}},[i("el-tab-pane",{attrs:{label:"重要信息",name:"chiefly-contacts",lazy:""}},[i("import-info",{staticClass:"import-info",attrs:{list:e.importList}})],1)],1)],1)],1)],1):e._e()],1),e._v(" "),i("el-button",{staticClass:"firse-button",on:{click:function(t){e.showImportInfo=!e.showImportInfo}}},[e._v("重"),i("br"),e._v("要"),i("br"),e._v("信"),i("br"),e._v("息"),i("br"),i("i",{staticClass:"el-icon-arrow-right el-icon--right",class:{"is-reverse":!e.showImportInfo}})]),e._v(" "),e.isCreate?i("c-r-m-all-create",{attrs:{action:{type:"update",id:e.id,batchId:e.detailData.batchId},"crm-type":e.crmType},on:{"save-success":e.editSaveSuccess,close:function(t){e.isCreate=!1}}}):e._e()],1)},[],!1,null,"dd0dbed6",null);v.options.__file="Detail.vue";t.a=v.exports},"4p7F":function(e,t,i){},"6Mk1":function(e,t,i){},"77fj":function(e,t,i){"use strict";var a=i("Btlj");i.n(a).a},Btlj:function(e,t,i){},BzA1:function(e,t,i){"use strict";var a=i("a/5N"),s={name:"ImportInfo",components:{},props:{list:Array},data:function(){return{}},computed:{showList:function(){return this.list.filter(function(e){return"file"!==e.form_type})}},watch:{},mounted:function(){},beforeDestroy:function(){},methods:{getValueContent:function(e){if("map_address"===e.form_type)return e.value?e.value.detail_address:"";if("structure"===e.form_type||"user"===e.form_type||"checkbox"===e.form_type){if(Object(a.a)(e.value)){var t={structure:"name",user:"realname",checkbox:""}[e.form_type];return e.value.map(function(e){return t?e[t]:e}).join(",")}return""}if("single_user"===e.form_type)return Object(a.c)(e.value)&&e.value.realname?e.value.realname:"";if("customer"===e.form_type||"business"===e.form_type||"contract"===e.form_type||"contacts"===e.form_type||"category"===e.form_type||"statusName"===e.form_type||"typeName"===e.form_type){var i={customer:"name",business:"name",contract:"name",contacts:"name",category:"name",statusName:"name",typeName:"name"}[e.form_type];return Object(a.a)(e.value)?e.value.length>0?e.value[0][i]:"":e.value?e.value[i]:""}return e.value}}},n=(i("m7P8"),i("KHd+")),l=Object(n.a)(s,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"content"},[i("div",{staticClass:"content-title"},[e._v("基本信息")]),e._v(" "),e._l(e.showList,function(t,a){return i("p",{key:a,staticClass:"detail-cell"},[i("span",{staticClass:"detail-cell__label"},[e._v("\n "+e._s(t.name)+"\n ")]),i("br"),e._v(" "),i("span",{staticClass:"detail-cell__value"},[e._v("\n "+e._s(e.getValueContent(t))+"\n ")])])})],2)},[],!1,null,"17796cac",null);l.options.__file="ImportInfo.vue";t.a=l.exports},CrBE:function(e,t,i){},DXRq:function(e,t,i){},"GlV/":function(e,t,i){},H4tY:function(e,t,i){"use strict";var a=i("6Mk1");i.n(a).a},"I+NK":function(e,t,i){"use strict";var a=i("PWYh");i.n(a).a},IvXA:function(e,t,i){"use strict";var a=i("UDEy");i.n(a).a},J2r4:function(e,t,i){"use strict";var a=i("ew76");i.n(a).a},Lc7H:function(e,t,i){},MeAA:function(e,t,i){"use strict";var a=i("DXRq");i.n(a).a},"N8+3":function(e,t,i){"use strict";var a=i("epE4");i.n(a).a},PWYh:function(e,t,i){},TuF4:function(e,t,i){},UDEy:function(e,t,i){},Vm8M:function(e,t,i){"use strict";var a=i("7Qib"),s={name:"MapView",components:{},props:{title:{type:String,default:""},lat:{type:[String,Number],default:0},lng:{type:[String,Number],default:0}},data:function(){return{}},computed:{},mounted:function(){var e=this;this.$el.style.zIndex=Object(a.q)(),document.body.appendChild(this.$el),Object(a.l)().then(function(){var t=new BMap.Map("choicemap",{enableMapClick:!1}),i=new BMap.Point(parseFloat(e.lng),parseFloat(e.lat));t.centerAndZoom(i,18),t.enableScrollWheelZoom();var a=new BMap.Marker(i);t.addOverlay(a);var s=new BMap.InfoWindow(e.title);a.addEventListener("click",function(){t.openInfoWindow(s,i)})})},destroyed:function(){this.$el&&this.$el.parentNode&&this.$el.parentNode.removeChild(this.$el)},methods:{hiddenView:function(){this.$emit("hidden")}}},n=(i("I+NK"),i("KHd+")),l=Object(n.a)(s,function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"map-view"},[t("div",{attrs:{id:"choicemap"}}),this._v(" "),t("i",{staticClass:"el-icon-close map-close",on:{click:this.hiddenView}})])},[],!1,null,"33a9f6bf",null);l.options.__file="MapView.vue";t.a=l.exports},VvvF:function(e,t,i){},ZX9L:function(e,t,i){"use strict";var a={name:"TimeTypeSelect",props:{defaultType:[String,Object],width:{type:Number,default:200},options:{type:Array,default:function(){return[{label:"今天",value:"today"},{label:"昨天",value:"yesterday"},{label:"本周",value:"week"},{label:"上周",value:"lastWeek"},{label:"本月",value:"month"},{label:"上月",value:"lastMonth"},{label:"本季度",value:"quarter"},{label:"上季度",value:"lastQuarter"},{label:"本年",value:"year"},{label:"去年",value:"lastYear"}]}}},data:function(){return{selectType:{label:"本年",value:"year"},showTypePopover:!1,showCustomContent:!1,sureCustomContent:!1,startTime:"",endTime:""}},computed:{typeShowValue:function(){return this.sureCustomContent?this.startTime||this.endTime?(this.startTime||"")+"-"+(this.endTime||""):"":this.selectType.label}},watch:{defaultType:function(){this.selectType.value!=this.defaultType&&(this.selectType=this.getDefaultTypeValue(this.defaultType))}},mounted:function(){void 0!==this.defaultType?"string"==typeof this.defaultType?this.selectType=this.getDefaultTypeValue(this.defaultType):this.defaultType.label?this.selectType=this.defaultType:"default"==this.defaultType.type?this.selectType=this.getDefaultTypeValue(this.defaultType.value):"custom"==this.defaultType.type&&(this.sureCustomContent=!0,this.showCustomContent=!0,this.startTime=this.defaultType.startTime,this.endTime=this.defaultType.endTime):this.$emit("change",{type:"default",value:this.selectType.value})},methods:{getDefaultTypeValue:function(e){for(var t=0;t0&&i.push({type:s,name:t[a],list:n})}return i},moreTypes:function(){var e=[];return this.data.permission&&(this.data.permission.is_recheck&&e.push({type:"withdraw",name:"撤销",icon:"reset"}),this.data.permission.is_update&&e.push({type:"edit",name:"编辑",icon:"edit"}),this.data.permission.is_delete&&e.push({type:"delete",name:"删除",icon:"delete"})),e},canCheck:function(){return this.data.permission&&this.data.permission.is_check}},watch:{},mounted:function(){},beforeDestroy:function(){},methods:{handleClick:function(e){this.$emit("handle",e,this.data,this.index,this.section)},checkRelationDetail:function(e,t){this.$emit("handle","relate-detail",{type:e,id:t},this.index,this.section)},handleTypeDrop:function(e){this.$emit("handle",e,this.data,this.index,this.section)}}},u=(i("gXkk"),Object(n.a)(d,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"section"},[i("div",{staticClass:"examine-cell"},[i("flexbox",{staticClass:"person"},[e.data.create_user_info?i("xr-avatar",{staticClass:"person__hd",attrs:{name:e.data.create_user_info.realname,id:e.data.create_user_info.id,size:40,src:e.data.create_user_info.img,disabled:!1}}):e._e(),e._v(" "),i("div",{staticClass:"person__bd"},[i("div",{staticClass:"person__bd-name"},[e._v(e._s(e.data.create_user_info.realname))]),e._v(" "),i("div",{staticClass:"person__bd-des"},[e._v(e._s("创建审批于 "+e.data.create_time))])]),e._v(" "),i("div",{staticClass:"rt-setting"},[i("span",{staticClass:"dep"},[i("span",[e._v(e._s(e.data.category_name)+" - ")]),e._v(" "),i("span",[e._v(e._s(e.getTaskStatusName(e.data.check_status)))])]),e._v(" "),i("span",{staticClass:"bg-color",style:{"background-color":e.getTaskStatusColor(e.data.check_status)}})])],1),e._v(" "),i("div",{staticClass:"examine-cell__bd"},[e.data.content?i("p",{staticClass:"examine-cell__bd--content"},[e._v(e._s(e.data.content))]):e._e(),e._v(" "),i("flexbox",{staticClass:"examine-content"},[i("i",{class:["wk","examine-content__hd","wk-"+e.iconObj.icon],style:{backgroundColor:e.iconObj.color}}),e._v(" "),i("div",{staticClass:"examine-content__bd"},[i("div",[i("a",{on:{click:function(t){e.handleClick("detail")}}},[e._v(e._s(e.data.category_name))])]),e._v(" "),e.data.causeTitle?i("div",{staticClass:"examine-content__bd--des"},[e._v(e._s(e.data.causeTitle))]):e._e()])]),e._v(" "),i("div",{staticClass:"examine-stage"},[i("i",{class:e.getStatusIcon(e.data.check_status),style:{color:e.getTaskStatusColor(e.data.check_status)}}),e._v(" "),i("span",[e._v(e._s(""+(e.data.examine_name||"")+e.getTaskStatusName(e.data.check_status)))])]),e._v(" "),e.relateList.length?i("div",{staticClass:"examine-relate"},[i("div",{staticClass:"examine-relate__hd"},[e._v("相关信息")]),e._v(" "),i("div",{staticClass:"examine-relate__bd"},e._l(e.relateList,function(t,a){return i("flexbox",{key:a,staticClass:"relate-cell",attrs:{align:"stretch"}},[i("div",{staticClass:"relate-cell__hd"},[i("i",{staticClass:"wk wk-contacts"}),e._v(" "),i("span",[e._v(e._s("相关"+t.name)+":")])]),e._v(" "),i("div",{staticClass:"relate-cell__bd"},e._l(t.list,function(a,s){return i("div",{key:s,staticClass:"relate-cell__bd--item text-one-line"},[i("a",{on:{click:function(i){e.checkRelationDetail(t.type,a[t.type+"_id"]||a.id)}}},[e._v(e._s(a[t.type+"_name"]||a.name))])])}))])}))]):e._e()],1)],1),e._v(" "),i("div",{staticClass:"section__ft"},[e.canCheck?i("el-button",{staticClass:"xr-btn--red handle-button",attrs:{icon:"wk wk-close",type:"primary"},on:{click:function(t){e.handleClick("reject")}}},[e._v("拒绝")]):e._e(),e._v(" "),e.canCheck?i("el-button",{staticClass:"xr-btn--green handle-button",attrs:{icon:"wk wk-success",type:"primary"},nativeOn:{click:function(t){e.handleClick("pass")}}},[e._v("通过")]):e._e(),e._v(" "),e.moreTypes.length>0?i("el-dropdown",{staticStyle:{float:"right"},attrs:{trigger:"click"},on:{command:e.handleTypeDrop}},[i("el-button",{staticClass:"handle-button",attrs:{icon:"el-icon-more"}}),e._v(" "),i("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},e._l(e.moreTypes,function(t,a){return i("el-dropdown-item",{key:a,attrs:{icon:e._f("wkIconPre")(t.icon),command:t.type}},[e._v(e._s(t.name))])}))],1):e._e()],1)])},[],!1,null,"b4b4f672",null));u.options.__file="ExamineCell.vue";var m=u.exports,h=i("t2rG"),f={name:"ExamineCategorySelect",components:{Draggable:i.n(h).a},props:{show:{type:Boolean,default:!1}},data:function(){return{loading:!1,showDialog:!1,categorys:[]}},watch:{show:function(e){this.showDialog=e,this.categorys&&0==this.categorys.length&&this.getDetail()}},mounted:function(){},methods:{getDetail:function(){var e=this;this.loading=!0,Object(a.a)().then(function(t){e.loading=!1,e.categorys=t.data.map(function(e){var t=e.icon?e.icon.split(","):[];return t.length>1?(e.iconClass=t[0],e.iconColor=t[1]):(e.iconClass="wk wk-approve",e.iconColor="#9376FF"),e})}).catch(function(){e.loading=!1})},selectCategorys:function(e){this.$emit("select",e),this.$emit("close")},closeView:function(){this.$emit("close")},draggableEnd:function(){Object(a.b)({examineIds:this.categorys.map(function(e){return e.category_id})}).then(function(e){}).catch(function(){})}}},p=(i("J2r4"),Object(n.a)(f,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("el-dialog",{attrs:{visible:e.showDialog,"close-on-click-modal":!1,title:"审批类型",width:"500px"},on:{"update:visible":function(t){e.showDialog=t},close:e.closeView}},[i("div",{staticClass:"title"},[e._v("可拖拽图标调整显示顺序(管理后台可自定义配置审批类型)")]),e._v(" "),i("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],staticClass:"categorys"},[i("draggable",{staticClass:"vux-flexbox",staticStyle:{"flex-wrap":"wrap"},attrs:{options:{dragClass:"sortable-drag",forceFallback:!1}},on:{end:e.draggableEnd},model:{value:e.categorys,callback:function(t){e.categorys=t},expression:"categorys"}},e._l(e.categorys,function(t,a){return i("div",{key:a,staticClass:"category-item",on:{click:function(i){e.selectCategorys(t)}}},[i("div",{staticClass:"category-icon",style:{backgroundColor:t.iconColor}},[i("i",{class:t.iconClass})]),e._v(" "),i("div",{staticClass:"category-label text-one-line"},[e._v(e._s(t.title))])])}))],1)])},[],!1,null,"332cd420",null));p.options.__file="ExamineCategorySelect.vue";var v=p.exports,_=i("P2sY"),y=i.n(_),g=i("m1cH"),b=i.n(g),C=i("4XAY"),w=i("KTTK"),x=i("ViDN"),k=i("EP+0"),T=i("lcu+"),I=i("Q4J0"),L=i("7Qib"),D={name:"XhExpenses",components:{},mixins:[I.a],props:{},data:function(){return{mainList:[],imageIndex:-1,totalMoney:"0",showItems:[{field:"start_address",name:"出发城市",formType:"text"},{field:"end_address",name:"目的城市",formType:"text"},{field:"start_time",name:"开始时间",formType:"datetime"},{field:"end_time",name:"结束时间",formType:"datetime"},{field:"traffic",name:"交通费(元)",formType:"number"},{field:"stay",name:"住宿费(元)",formType:"number"},{field:"diet",name:"餐饮费(元)",formType:"number"},{field:"other",name:"其他费用(元)",formType:"number"}]}},computed:{},watch:{value:function(e){this.dataValue=e,e.list&&e.list.length>0?this.mainList=e.list.map(function(e){return e.imgList&&(e.imgList.url=e.imgList.file_path),e}):this.mainList.push(this.getValueItem())}},mounted:function(){this.dataValue.list&&this.dataValue.list.length>0?this.mainList=this.dataValue.list:this.mainList.push(this.getValueItem())},methods:{addFiles:function(e){this.imageIndex=e,document.getElementById("imageFileInput").click()},uploadImageFile:function(e){for(var t=this,i=e.target.files,a=0;a0?this.mainList=e.list:this.mainList.push(this.getValueItem())}},mounted:function(){this.dataValue.list&&this.dataValue.list.length>0?this.mainList=this.dataValue.list:this.mainList.push(this.getValueItem())},methods:{getInputDisable:function(e){return"duration"==e},deleteItems:function(e){this.mainList.splice(e,1),this.calculateValueChange()},addItems:function(){this.mainList.push(this.getValueItem())},datePickerChange:function(e){var t=this.mainList[e];if(t.start_time&&t.end_time){var i=S()(t.start_time),a=S()(t.end_time).diff(i,"hours"),s=Math.floor(a/24),n=a%24;n>=4&&n<8?s+=.5:n>=8&&(s+=1),t.duration=s,this.calculateValueChange()}},valueChange:function(){this.submitValueChange(!1)},calculateValueChange:function(){for(var e=0,t=0;t0?e.value[0].batchId:"":"checkbox"==e.data.form_type?e.value&&e.value.length>0?e.value.join(","):"":e.value},hidenView:function(){this.$emit("hiden-view")},getTitle:function(){return"update"==this.action.type?"编辑"+this.categoryTitle:"新建"+this.categoryTitle},getPaddingLeft:function(e,t){return e.showblock&&1==e.showblock?"0":e.styleIndex%2==0?"0":"40px"},getPaddingRight:function(e,t){return e.showblock&&1==e.showblock?"0":e.styleIndex%2==0?"40px":"0"}}},K=(i("cp9R"),Object(n.a)(z,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("create-view",{attrs:{loading:e.loading,"body-style":{height:"100%"}}},[i("flexbox",{staticClass:"crm-create-container",attrs:{direction:"column",align:"stretch"}},[i("flexbox",{staticClass:"crm-create-header"},[i("div",{staticStyle:{flex:"1","font-size":"17px",color:"#333","font-weight":"bold"}},[e._v(e._s(e.title))]),e._v(" "),i("i",{staticClass:"el-icon-close close",on:{click:e.hidenView}})]),e._v(" "),i("div",{staticClass:"crm-create-flex"},[i("create-sections",{attrs:{title:"基本信息"}},[i("flexbox",{attrs:{direction:"column",align:"stretch"}},[i("div",{staticClass:"crm-create-body"},[i("el-form",{ref:"crmForm",staticClass:"crm-create-box",attrs:{model:e.crmForm,"label-position":"top"}},e._l(e.crmForm.crmFields,function(t,a){return i("el-form-item",{key:t.key,class:{"crm-create-block-item":t.showblock,"crm-create-item":!t.showblock},style:{"padding-left":e.getPaddingLeft(t,a),"padding-right":e.getPaddingRight(t,a)},attrs:{prop:"crmFields."+a+".value",rules:e.crmRules[t.key]}},[i("div",{staticStyle:{display:"inline-block"},attrs:{slot:"label"},slot:"label"},[i("div",{staticClass:"form-label"},[e._v("\n "+e._s(t.data.name)+"\n "),i("span",{staticStyle:{color:"#999"}},[e._v("\n "+e._s(t.data.inputTips?"("+t.data.inputTips+")":"")+"\n ")])])]),e._v(" "),i(e._f("typeToComponentName")(t.data.form_type),{tag:"component",attrs:{value:t.value,index:a,item:t,relation:t.relation,radio:!1,disabled:t.disabled},on:{"value-change":e.fieldValueChange}})],1)}))],1)])],1),e._v(" "),i("div",{staticClass:"img-accessory"},[i("div",{staticClass:"img-box"},[i("el-upload",{ref:"imageUpload",attrs:{action:e.crmFileSaveUrl,headers:e.httpHeader,data:{type:"img",batchId:e.batchId},"on-preview":e.handleFilePreview,"before-remove":e.beforeRemove,"on-success":e.imgFileUploadSuccess,"file-list":e.imgFileList,name:"file",multiple:"",accept:"image/*","list-type":"picture-card"}},[i("p",{staticClass:"add-img"},[i("span",{staticClass:"el-icon-picture"}),e._v(" "),i("span",[e._v("添加图片")])]),e._v(" "),i("i",{staticClass:"el-icon-plus"})])],1),e._v(" "),i("p",{staticClass:"add-accessory"},[i("el-upload",{ref:"fileUpload",attrs:{action:e.crmFileSaveUrl,headers:e.httpHeader,data:{type:"file",batchId:e.batchId},"on-preview":e.handleFilePreview,"before-remove":e.handleFileRemove,"on-success":e.fileUploadSuccess,"file-list":e.fileList,name:"file",multiple:"",accept:"*.*"}},[i("p",[i("i",{staticClass:"wukong wukong-file"}),e._v("\n 添加附件\n ")])])],1)]),e._v(" "),i("related-business",{staticClass:"related-business",attrs:{"selected-infos":e.relatedBusinessInfo},on:{"value-change":e.relativeValueChange}}),e._v(" "),e.showExamine?i("create-sections",{attrs:{title:"审核信息"}},[i("template",{slot:"header"},[1===e.examineInfo.config||0===e.examineInfo.config?i("div",{staticClass:"examine-type"},[e._v(e._s(1===e.examineInfo.config?"固定审批流":"授权审批人"))]):e._e(),e._v(" "),e.examineInfo&&e.examineInfo.remark?i("el-tooltip",{attrs:{content:e.examineInfo.remark,effect:"dark",placement:"top"}},[i("i",{staticClass:"wk wk-help wk-help-tips",staticStyle:{height:"13px"}})]):e._e()],1),e._v(" "),i("create-examine-info",{ref:"examineInfo",attrs:{"types-id":e.categoryId,types:"oa_examine"},on:{"value-change":e.examineValueChange}})],2):e._e()],1),e._v(" "),i("div",{staticClass:"handle-bar"},[i("el-button",{staticClass:"handle-button",nativeOn:{click:function(t){return e.hidenView(t)}}},[e._v("取消")]),e._v(" "),i("el-button",{directives:[{name:"debounce",rawName:"v-debounce",value:e.saveField,expression:"saveField"}],staticClass:"handle-button",attrs:{type:"primary"}},[e._v("保存")])],1)],1)],1)},[],!1,null,"5dee738f",null));K.options.__file="ExamineCreateView.vue";var q=K.exports,W=i("slnp"),Z=i("yPq4"),Y=i("QhmF"),Q={name:"Index",components:{ExamineTabsHead:o,ExamineCell:m,ExamineCategorySelect:v,ExamineCreateView:q,ExamineDetail:W.a,CRMAllDetail:Z.a,ExamineHandle:Y.a},mixins:[c.a],props:{},data:function(){return{tabsSelectValue:"",selectList:[],examineType:"",list:[],loading:!1,noMore:!1,scrollKey:Date.now(),page:1,selectId:"",showCategorySelect:!1,isCreate:!1,createAction:{type:"save"},createInfo:{},detailIndex:0,rowID:"",rowData:{},showDview:!1,relatedID:"",relatedCRMType:"",showRelatedDetail:!1,showExamineHandle:!1,recordId:"",examineStatus:1}},computed:{scrollDisabled:function(){return this.loading||this.noMore},tabs:function(){return"my"==this.examineType?[{label:"全部",name:"all"},{label:"待审批",name:"0"},{label:"审批通过",name:"2"},{label:"审批拒绝",name:"4"}]:"wait"==this.examineType?[{label:"全部",name:"all"},{label:"待我审批的",name:"0"},{label:"我已审批的",name:"1"}]:[]}},watch:{},mounted:function(){this.examineType=this.$route.params.type,this.getSelectList(),this.tabsSelectValue=(this.examineType,"0")},beforeRouteUpdate:function(e,t,i){this.examineType=e.params.type,this.selectId="",this.tabsSelectValue=(this.examineType,"0"),this.$refs.tabsHead.getDefaultSelectValue(),this.refreshList(),i()},beforeDestroy:function(){},methods:{refreshList:function(){this.page=1,this.list=[],this.noMore=!1,this.scrollKey=Date.now()},getList:function(){var e=this;this.loading=!0;var t={page:this.page,limit:15,category_id:this.selectId},i=null,s="all"==this.tabsSelectValue?"all":this.tabsSelectValue;"my"==this.examineType?(t.check_status=s,i=a.j):"wait"==this.examineType&&(t.examine_by="0"==s?1:"all"==s?"all":2,i=a.k),i(t).then(function(i){e.loading=!1;var a="all"==e.tabsSelectValue?"all":e.tabsSelectValue,s=!1;"my"==e.examineType&&t.check_status==a?s=!0:"wait"==e.examineType&&t.examine_by==("0"==a?1:"all"==a?"all":2)&&(s=!0),s?(e.noMore||(e.list=e.list.concat(i.data.page.list),e.page++),e.noMore=i.data.page.lastPage):e.refreshList()}).catch(function(){e.noMore=!0,e.loading=!1})},getSelectList:function(){var e=this;Object(a.a)().then(function(t){e.selectList=t.data.map(function(t){var i=e.getCategoryIcon(t.icon);return i.label=t.title,i.command=t.category_id,i}),e.selectList.unshift({icon:"wk wk-approve",color:"#9376FF",command:"",label:"全部审批"})}).catch(function(){e.loading=!1})},tabsChange:function(e){this.refreshList()},tabsSelect:function(e){this.selectId=e,this.refreshList()},cellHandle:function(e,t,i){var s=this;this.detailIndex=i,"detail"==e?(this.showRelatedDetail=!1,this.rowID=t.examine_id,this.showDview=!0):"relate-detail"==e?(this.showDview=!1,this.relatedID=t.id,this.relatedCRMType=t.type,this.showRelatedDetail=!0):"edit"==e?(t.title=t.category_name,this.createInfo=t,this.createAction={type:"update",id:t.examine_id,data:t},this.isCreate=!0):"delete"==e?this.$confirm("确定删除?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){Object(a.d)({id:t.examine_id}).then(function(e){s.list.splice(i,1),s.$message({type:"success",message:"删除成功!"})})}).catch(function(){s.$message({type:"info",message:"已取消删除"})}):"reject"!=e&&"pass"!=e&&"withdraw"!=e||(this.rowID=t.examine_id,this.examineStatus={pass:1,reject:2,withdraw:4}[e],this.rowData=t,this.showExamineHandle=!0)},selcetExamineCategory:function(e){this.createInfo=e,this.createAction={type:"save"},this.isCreate=!0},createClick:function(){this.showCategorySelect=!0},createHideView:function(){this.isCreate=!1},examineHandleCallBack:function(e){this.refreshDataByHandle()},refreshDataByHandle:function(){this.refreshList()},detailHandleCallBack:function(e,t){this.detailIndex=t,this.refreshDataByHandle()},exportClick:function(){var e=this;if(""!==this.selectId){this.loading=!0;var t={category_id:this.selectId},i="all"==this.tabsSelectValue?"all":this.tabsSelectValue;"my"==this.examineType?t.check_status=i:"wait"==this.examineType&&(t.examine_by="0"==i?1:"all"==i?"all":2),Object(a.e)(t).then(function(t){Object(L.c)(t),e.loading=!1}).catch(function(){e.loading=!1})}else this.$message.error("请选择一种审批类型导出")}}},J=(i("IvXA"),Object(n.a)(Q,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"main"},[i("examine-tabs-head",{ref:"tabsHead",attrs:{tabs:e.tabs,"select-list":e.selectList,"select-value":e.tabsSelectValue},on:{"update:selectValue":function(t){e.tabsSelectValue=t},change:e.tabsChange,select:e.tabsSelect,add:e.createClick,export:e.exportClick}}),e._v(" "),i("div",{directives:[{name:"infinite-scroll",rawName:"v-infinite-scroll",value:e.getList,expression:"getList"}],key:""+e.scrollKey+e.tabsSelectValue,staticClass:"cell-section",attrs:{"infinite-scroll-distance":"100","infinite-scroll-disabled":"scrollDisabled"}},[e._l(e.list,function(t,a){return i("examine-cell",{key:a,attrs:{data:t,index:a},on:{handle:e.cellHandle}})}),e._v(" "),e.loading?i("p",{staticClass:"scroll-bottom-tips"},[e._v("加载中...")]):e._e(),e._v(" "),e.noMore?i("p",{staticClass:"scroll-bottom-tips"},[e._v("没有更多了")]):e._e()],2),e._v(" "),i("examine-category-select",{attrs:{show:e.showCategorySelect},on:{select:e.selcetExamineCategory,close:function(t){e.showCategorySelect=!1}}}),e._v(" "),e.isCreate?i("examine-create-view",{attrs:{"category-id":e.createInfo.category_id,type:e.createInfo.type,"category-title":e.createInfo.category_name,action:e.createAction},on:{"save-success":e.refreshList,"hiden-view":e.createHideView}}):e._e(),e._v(" "),e.showDview?i("examine-detail",{staticClass:"d-view",attrs:{id:e.rowID,"detail-index":e.detailIndex,"no-listener-class":["examine-content"]},on:{"hide-view":function(t){e.showDview=!1},"on-examine-handle":e.detailHandleCallBack}}):e._e(),e._v(" "),i("c-r-m-all-detail",{attrs:{visible:e.showRelatedDetail,"crm-type":e.relatedCRMType,id:e.relatedID,"no-listener-class":["relate-cell"]},on:{"update:visible":function(t){e.showRelatedDetail=t}}}),e._v(" "),i("examine-handle",{attrs:{show:e.showExamineHandle,id:e.rowID,"record-id":e.rowData.examineRecordId,detail:e.rowData,status:e.examineStatus,"examine-type":"oa_examine"},on:{close:function(t){e.showExamineHandle=!1},save:e.examineHandleCallBack}})],1)},[],!1,null,"14ff51ac",null));J.options.__file="index.vue";t.default=J.exports},cp9R:function(e,t,i){"use strict";var a=i("TuF4");i.n(a).a},dDIi:function(e,t,i){"use strict";var a=i("VvvF");i.n(a).a},deZW:function(e,t,i){},eOwn:function(e,t,i){"use strict";var a=i("m1cH"),s=i.n(a),n=i("QbLZ"),l=i.n(n),o=i("7Dod"),c=i("6iAj"),r=i("4XAY"),d=i("KTTK"),u=i("mkuN"),m=i("zMq1"),h=i("ye9D"),f=i("NYF1"),p=i("YIeP"),v=i("7Qib");var _={methods:{dispatch:function(e,t,i){for(var a=this.$parent||this.$root,s=a.$options.componentName;a&&(!s||s!==e);)(a=a.$parent)&&(s=a.$options.componentName);a&&a.$emit.apply(a,[t].concat(i))},broadcast:function(e,t,i){(function e(t,i,a){this.$children.forEach(function(s){s.$options.componentName===t?s.$emit.apply(s,[i].concat(a)):e.apply(s,[t,i].concat([a]))})}).call(this,e,t,i)}}},y={name:"LogAdd",components:{CrmRelative:u.a,AddImageList:m.a,AddFileList:h.a,AddRelateList:f.a,CommonWords:p.a},mixins:[_],props:{showBusiness:{type:Boolean,default:!1},showContacts:{type:Boolean,default:!1},contacts:Array,contactsId:[String,Number],followTypes:Array,id:[String,Number],crmType:{type:String,default:""}},data:function(){return{isUnfold:!1,content:"",imgFiles:[],businessAction:{},files:[],showBusinessPopover:!1,business:[],selectContactsId:"",followType:"",nextTime:"",showRelativeType:"",batchId:Object(v.s)()}},computed:{autosize:function(){return this.isUnfold?{minRows:3,maxRows:6}:{minRows:1,maxRows:1}}},watch:{followTypes:function(){this.getDefalutFollowType()},content:function(e){var t=!!(e&&e.length>0);this.dispatch("SlideView","setEditClose",[t])},contactsId:function(){this.selectContactsId=this.contactsId||""},id:{handler:function(){this.businessAction={type:"condition",data:{moduleType:this.crmType,customer_id:this.id}}},immediate:!0}},created:function(){this.selectContactsId=this.contactsId||"",this.getDefalutFollowType()},beforeDestroy:function(){},methods:{getDefalutFollowType:function(){this.followTypes&&this.followTypes.length>0?this.followType=this.followTypes[0].value:this.followType=""},resetInfo:function(){this.nextTime="",this.isUnfold=!1,this.content="",this.dispatch("SlideView","setEditClose",[!1]),this.imgFiles=[],this.files=[],this.business=[],this.selectContactsId=this.contactsId||"",this.showRelativeType="",this.batchId=Object(v.s)(),this.getDefalutFollowType()},commonWordsSelect:function(e){var t=this;this.content?this.$confirm("您选中的常用语将覆盖当前填写内容?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning",customClass:"is-particulars"}).then(function(){t.content=e}).catch(function(){}):this.content=e},checkRelativeInfos:function(e){"business"==this.showRelativeType&&(this.business=e.data)},barClick:function(e){this.showRelativeType=e,"business"==e?this.showBusinessPopover=!0:"file"==e?this.$refs.fileInput.click():"img"==e&&this.$refs.imgInput.click()},uploadFile:function(e){var t=e.target.files;if(t.length){for(var i=0;i0&&e.isUnfold?i("add-image-list",{attrs:{data:e.imgFiles},on:{delete:e.deleteImage,"delete-all":function(t){e.deleteAllFile(2)},upload:e.uploadFile}}):e._e(),e._v(" "),e.files.length>0&&e.isUnfold?i("add-file-list",{attrs:{data:e.files},on:{delete:e.deleteFile,"delete-all":function(t){e.deleteAllFile(1)}}}):e._e(),e._v(" "),e.business.length>0&&e.isUnfold?i("add-relate-list",{attrs:{data:e.business,type:"business"},on:{delete:e.deleteRelate}}):e._e(),e._v(" "),e.isUnfold?i("div",{staticClass:"bar-cont"},[i("el-button",{staticClass:"handle-button",attrs:{type:"text",icon:"wk wk-picture"},on:{click:function(t){e.barClick("img")}}},[e._v("图片")]),e._v(" "),i("el-button",{staticClass:"handle-button",attrs:{type:"text",icon:"wk wk-file"},on:{click:function(t){e.barClick("file")}}},[e._v("附件")]),e._v(" "),e.showBusiness?i("el-popover",{attrs:{placement:"bottom",width:"700","popper-class":"no-padding-popover",trigger:"click"},model:{value:e.showBusinessPopover,callback:function(t){e.showBusinessPopover=t},expression:"showBusinessPopover"}},[i("crm-relative",{ref:"crmrelative",attrs:{show:e.showBusinessPopover,radio:!1,action:e.businessAction,"selected-data":{business:e.business},"crm-type":"business"},on:{close:function(t){e.showBusinessPopover=!1},changeCheckout:e.checkRelativeInfos}}),e._v(" "),i("el-button",{staticClass:"handle-button",staticStyle:{"margin-left":"10px"},attrs:{slot:"reference",type:"text",icon:"wk wk-associate"},on:{click:function(t){e.barClick("business")}},slot:"reference"},[e._v("关联商机")])],1):e._e(),e._v(" "),i("el-button",{directives:[{name:"debounce",rawName:"v-debounce",value:e.sendClick,expression:"sendClick"}],staticClass:"send-btn",attrs:{type:"primary"}},[e._v("发布")])],1):e._e(),e._v(" "),i("input",{ref:"fileInput",staticClass:"file-input",attrs:{accept:"*.*",type:"file",multiple:""},on:{change:e.uploadFile}}),e._v(" "),i("input",{ref:"imgInput",staticClass:"file-input",attrs:{accept:"image/*",type:"file",multiple:""},on:{change:e.uploadFile}})],1)},[],!1,null,"2caf5be7",null);b.options.__file="LogAdd.vue";var C=b.exports,w=i("O8VQ"),x=i("/G0b"),k=i("8OTK"),T=i("C3Po"),I=i("ZoMv"),L=i("Z+Ht"),D=i("vvxI"),F=i("ZX9L"),V=i("ehos"),$=i("L2JU"),S={name:"Activity",components:{LogAdd:C,LogCell:w.a,CRMAllCreate:k.default,TaskQuickAdd:T.a,TimeTypeSelect:F.a,LogEditDialog:x.a,CRMFullScreenDetail:function(){return Promise.all([i.e("chunk-024e"),i.e("chunk-6d9c"),i.e("chunk-0069"),i.e("chunk-9aaae")]).then(i.bind(null,"3z7q"))}},mixins:[L.a,D.a],props:{handle:{type:Array,default:function(){return[]}},id:[String,Number],contactsId:[String,Number],crmType:{type:String,default:""},isSeas:{type:Boolean,default:!1},typeList:{type:Array,default:function(){return[]}},detail:{type:Object,default:function(){return{}}}},data:function(){return{loading:!1,isSearchRequest:!1,filterValue:{},timeOptions:[{label:"全部",value:""},{label:"最近7天",value:"7"},{label:"最近30天",value:"30"},{label:"最近60天",value:"60"}],contacts:[],followTypes:[],handleType:"",activityType:{icon:"all",color:"#2362FB",command:"",label:"全部活动"},list:[],noMore:!1,page:1,isCRMCreate:!1,createActionInfo:{type:"relative",crmType:this.crmType,data:{}},createCRMType:"",isTaskCreate:!1,showFullDetail:!1,relationID:"",relationCrmType:"",scrollKey:Date.now(),logEditData:null,logEditPosition:{seciton:0,index:0},logEditDialogVisible:!1}},computed:l()({},Object($.b)(["crm"]),{canCreateFollowRecord:function(){return this.crm&&this.crm.activity&&this.crm.activity.save},showRelate:function(){return"customer"==this.crmType},scrollDisabled:function(){return this.loading||this.noMore},taskParams:function(){var e={};return e[this.crmType+"_ids"]=this.id,e},taskProps:function(){var e={};e[this.crmType]=[this.detail];var t={};return t[this.crmType+"Ids"]=[this.id],{relatedObj:e,relatedObjIds:t}}}),watch:{id:function(){this.initInfo(),this.refreshLogList()}},created:function(){this.debouncedRefreshLogList=Object(V.debounce)(300,this.refreshLogList),this.initInfo()},methods:{getLogTypeList:function(){var e=this;Object(c.r)().then(function(t){e.followTypes=t.data.map(function(e){return{value:e,label:e}})}).catch(function(){})},getContactsList:function(){var e=this;Object(o.I)({customer_id:this.id}).then(function(t){e.contacts=t.data.list}).catch(function(){})},sendLog:function(e){var t=this;if(e.content){var i={category:e.followType,activity_type:I.a.keyToTypeData[this.crmType],activity_type_id:e.id,content:e.content,next_time:e.nextTime||"",is_event:0,file_id:[].concat(s()(e.files.map(function(e){return e.file_id})),s()(e.images.map(function(e){return e.file_id}))),business_ids:[].concat(s()(e.business.map(function(e){return e.business_id}))),contacts_ids:e.contactsId};this.sendLoading=!0,Object(r.a)(i).then(function(e){t.sendLoading=!1,t.$message.success("发布成功"),t.$refs.logAdd&&t.$refs.logAdd.resetInfo(),t.refreshLogList()}).catch(function(){t.sendLoading=!1})}else this.$message.error("请输入跟进内容")},handleClick:function(e){var t=this;if(this.handleType==e?this.handleType="":this.handleType=e,"log"==e)this.isTaskCreate=!1,this.$nextTick(function(){t.$refs.logAdd&&(t.$refs.logAdd.isUnfold=t.handleType==e)});else if("task"==e)this.isTaskCreate=!0,this.$nextTick(function(){t.$refs.taskAdd.inputFocus()});else{this.isTaskCreate=!1;var i={type:"relative",crmType:this.crmType,data:{}};"contacts"==this.crmType?(i.data.customer=Object(v.t)(this.detail),"business"==e&&(i.relativeData={contactsId:this.detail.contactsId})):"customer"==this.crmType?i.data.customer=Object(v.t)(this.detail):"business"==this.crmType?(i.data.customer=Object(v.t)(this.detail),i.data.business=Object(v.t)(this.detail),"contacts"==e&&(i.relativeData={businessId:this.detail.businessId})):"contract"==this.crmType&&(i.data.customer=Object(v.t)(this.detail),i.data.contract=Object(v.t)(this.detail)),this.createActionInfo=i,this.createCRMType=e,this.isCRMCreate=!0}},initInfo:function(){var e=this;this.$nextTick(function(){e.$refs.logAdd&&e.$refs.logAdd.resetInfo(),e.$refs.taskAdd&&e.$refs.taskAdd.resetSendData()}),this.filterValue={search:"",timeLine:{label:"全部",value:""}},this.getLogTypeList(),this.showRelate&&this.getContactsList()},refreshLogList:function(e){this.isSearchRequest=e||!1,this.page=1,this.noMore=!1,this.list=[],this.scrollKey=Date.now()},handleSelectClick:function(e){this.activityType=e,this.refreshLogList()},timeTypeChange:function(e){this.filterValue.timeLine=e,this.refreshLogList()},getLogList:function(){var e=this;this.loading=!0;var t={module:this.crmType,page:this.page,crmType:I.a[this.crmType],activity_type:this.activityType.command||"",activity_type_id:this.id};this.filterValue.search&&(t.search=this.filterValue.search),this.filterValue.timeLine.type&&("custom"===this.filterValue.timeLine.type?(t.start_date=this.filterValue.timeLine.startTime.replace(/\./g,"-"),t.end_date=this.filterValue.timeLine.endTime.replace(/\./g,"-")):t.interval_day=this.filterValue.timeLine.value||""),Object(r.c)(t).then(function(t){if(e.loading=!1,!e.noMore)if(e.page++,e.list.length){var i=e.list[e.list.length-1];t.data.time&&t.data.list.length&&i.time!=t.data.time&&e.list.push(t.data)}else t.data.time&&t.data.list.length&&e.list.push(t.data);e.noMore=t.data.lastPage,e.isSearchRequest&&e.$nextTick(function(){e.$refs.activitySearchInput.focus()})}).catch(function(){e.noMore=!0,e.loading=!1})},createCRMSuccess:function(){this.handleType="",this.refreshLogList()},createCRMClose:function(){this.isCRMCreate=!1,this.handleType=""},checkCRMDetail:function(e,t){this.relationID=t,this.relationCrmType=e,this.showFullDetail=!0},getActivityIcon:function(e){return this.getXrIcon(this.getActivityType(e))},getActivityTypeColor:function(e){return this.getXrIconColor(this.getActivityType(e))},logCellDelete:function(e,t,i){this.list[i].list.splice(t,1),0==this.list[i].list.length&&this.list.splice(i,1),this.scrollKey=Date.now()},logCellEdit:function(e,t,i){this.logEditData=e,this.logEditPosition={seciton:i,index:t},this.logEditDialogVisible=!0},logEditSave:function(e){this.logEditPosition.seciton>=0&&this.logEditPosition.index>=0&&this.list[this.logEditPosition.seciton].list.splice(this.logEditPosition.index,1,e),this.getLogList()}}},R=(i("N8+3"),Object(g.a)(S,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{directives:[{name:"infinite-scroll",rawName:"v-infinite-scroll",value:e.getLogList,expression:"getLogList"}],key:e.scrollKey,staticClass:"main",attrs:{"infinite-scroll-distance":"100","infinite-scroll-disabled":"scrollDisabled"}},[i("div",[!e.isSeas&&e.handle&&e.handle.length?i("div",{staticClass:"main-handle"},e._l(e.handle,function(t,a){return i("el-button",{key:a,class:{"is-select":e.handleType===t.type},attrs:{type:"primary",icon:"wk wk-add"},on:{click:function(i){e.handleClick(t.type)}}},[e._v("\n "+e._s(t.label)+"\n ")])})):e._e(),e._v(" "),!e.isSeas&&e.handle&&e.handle.length?[!e.isTaskCreate&&e.canCreateFollowRecord?i("log-add",{ref:"logAdd",staticClass:"log-add",attrs:{id:e.id,"show-business":e.showRelate,"show-contacts":e.showRelate,contacts:e.contacts,"contacts-id":e.contactsId,"follow-types":e.followTypes,"crm-type":e.crmType},on:{send:e.sendLog,focus:function(t){e.handleType="log"},close:function(t){e.handleClick(e.handleType)}}}):i("task-quick-add",{ref:"taskAdd",staticClass:"task-quick-add",attrs:{params:e.taskParams,props:e.taskProps},on:{focus:function(t){e.handleType="task"},send:e.refreshLogList}})]:e._e(),e._v(" "),i("div",{staticClass:"log",class:{"is-top":e.handle&&0==e.handle.length}},[i("flexbox",{staticClass:"log__header",attrs:{justify:"flex-end"}},[i("el-input",{ref:"activitySearchInput",attrs:{placeholder:"关键字搜索","prefix-icon":"el-icon-search"},nativeOn:{keyup:function(t){if(!("button"in t)&&e._k(t.keyCode,"enter",13,t.key,"Enter"))return null;e.debouncedRefreshLogList(!0)}},model:{value:e.filterValue.search,callback:function(t){e.$set(e.filterValue,"search",t)},expression:"filterValue.search"}}),e._v(" "),i("time-type-select",{attrs:{width:190,options:e.timeOptions,"default-type":e.filterValue.timeLine},on:{change:e.timeTypeChange}}),e._v(" "),e.typeList.length>1?i("el-dropdown",{attrs:{trigger:"click"},on:{command:e.handleSelectClick}},[i("span",{staticClass:"el-dropdown-link"},[i("i",{class:["wk","dropdown-icon","wk-"+e.activityType.icon],style:{backgroundColor:e.activityType.color}}),e._v(e._s(e.activityType.label)),i("i",{staticClass:"el-icon-arrow-down el-icon--right"})]),e._v(" "),i("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},e._l(e.typeList,function(t,a){return i("el-dropdown-item",{key:a,attrs:{command:t}},[i("i",{class:["wk","dropdown-icon","wk-"+t.icon],style:{backgroundColor:t.color}}),e._v(e._s(t.label))])}))],1):e._e()],1),e._v(" "),e._l(e.list,function(t,a){return i("div",{key:a,staticClass:"log-section"},[i("div",{staticClass:"log-section__title"},[i("span",{staticClass:"section-title"},[i("span",{staticClass:"section-title__time"},[e._v(e._s(t.time))])])]),e._v(" "),e._l(t.list,function(s,n){return[1==s.type?i("div",{key:n,staticClass:"log-cell",class:{"only-one":1==t.list.length}},[i("log-cell",{attrs:{item:s,section:a,index:n,"can-delete":!e.isSeas},on:{"crm-detail":e.checkCRMDetail,delete:e.logCellDelete,edit:e.logCellEdit}}),e._v(" "),i("i",{staticClass:"wk wk-message log-cell__mark"})],1):i("div",{key:n,staticClass:"log-cell activity-cell",class:{"only-one":1==t.list.length}},[2==s.type?i("div",{staticClass:"activity-cell"},[i("span",{staticClass:"activity-cell__label"},[e._v(e._s(s.update_time)+" "+e._s(s.create_user_name)+"创建了"+e._s(e.getActivityTypeName(s.activity_type))+":")]),i("span",{staticClass:"activity-cell__content",on:{click:function(t){e.checkCRMDetail(e.getActivityType(s.activity_type),s.activity_type_id)}}},[e._v(e._s(s.activity_type_name||"查看详情"))])]):3==s.type?i("div",{staticClass:"activity-cell"},[i("span",{staticClass:"activity-cell__label"},[e._v(e._s(s.update_time)+" "+e._s(s.create_user_name)+"将商机:")]),e._v(" "),i("span",{staticClass:"activity-cell__content",on:{click:function(t){e.checkCRMDetail("business",s.activity_type_id)}}},[e._v(e._s(s.activity_type_name))]),e._v(" "),i("span",[e._v(e._s(" "+s.content))])]):4==s.type?i("log-cell",{attrs:{item:s,section:a,index:n,"can-delete":""},on:{"crm-detail":e.checkCRMDetail,delete:e.logCellDelete}}):e._e(),e._v(" "),i("i",{staticClass:"log-cell__mark",class:e.getActivityIcon(s.activity_type),staticStyle:{"background-color":"#FB9323"},style:{backgroundColor:e.getActivityTypeColor(s.activity_type)}})],1)]})],2)}),e._v(" "),e.loading?i("p",{staticClass:"scroll-bottom-tips"},[e._v("加载中...")]):e._e(),e._v(" "),e.noMore?i("p",{staticClass:"scroll-bottom-tips"},[e._v("没有更多了")]):e._e()],2)],2),e._v(" "),e.isCRMCreate?i("c-r-m-all-create",{attrs:{"crm-type":e.createCRMType,action:e.createActionInfo},on:{"save-success":e.createCRMSuccess,close:e.createCRMClose}}):e._e(),e._v(" "),i("c-r-m-full-screen-detail",{attrs:{visible:e.showFullDetail,"crm-type":e.relationCrmType,id:e.relationID},on:{"update:visible":function(t){e.showFullDetail=t}}}),e._v(" "),i("log-edit-dialog",{attrs:{visible:e.logEditDialogVisible,data:e.logEditData},on:{"update:visible":function(t){e.logEditDialogVisible=t},save:e.logEditSave}})],1)},[],!1,null,"344bab02",null));R.options.__file="index.vue";t.a=R.exports},"ej9+":function(e,t,i){"use strict";var a={name:"BaseTabsHead",components:{},props:{selectValue:[String,Number],tabs:Array},data:function(){return{currentValue:""}},computed:{},watch:{selectValue:function(){this.currentValue=this.selectValue}},mounted:function(){this.currentValue=this.selectValue},beforeDestroy:function(){},methods:{handleTabsClick:function(e,t){this.$emit("update:selectValue",e.name),this.$emit("change",e.name)}}},s=(i("kr3W"),i("KHd+")),n=Object(s.a)(a,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("flexbox",{staticClass:"base-tabs-head",attrs:{justify:"space-between"}},[i("div",[e._t("left")],2),e._v(" "),i("el-tabs",{on:{"tab-click":e.handleTabsClick},model:{value:e.currentValue,callback:function(t){e.currentValue=t},expression:"currentValue"}},e._l(e.tabs,function(e,t){return i("el-tab-pane",{key:t+e.name,attrs:{label:e.label,name:e.name}})})),e._v(" "),i("div",[e._t("right")],2)],1)},[],!1,null,"fa74c14a",null);n.options.__file="index.vue";t.a=n.exports},epE4:function(e,t,i){},ew76:function(e,t,i){},gXkk:function(e,t,i){"use strict";var a=i("CrBE");i.n(a).a},"i+04":function(e,t,i){"use strict";var a=i("sckx");i.n(a).a},kr3W:function(e,t,i){"use strict";var a=i("4p7F");i.n(a).a},m1cH:function(e,t,i){"use strict";t.__esModule=!0;var a,s=i("rfXi"),n=(a=s)&&a.__esModule?a:{default:a};t.default=function(e){if(Array.isArray(e)){for(var t=0,i=Array(e.length);t1?{icon:t[0],color:t[1]}:{icon:"wk wk-approve",color:"#9376FF"}}}}},sckx:function(e,t,i){},slnp:function(e,t,i){"use strict";var a=i("7qmR"),s=i("Ew9n"),n=i("3biH"),l=i("/407"),o=i("hwzM"),c=i("7Qib"),r=i("oWzH"),d={name:"ExamineDetail",components:{SlideView:s.a,ExamineInfo:n.a,RelatedBusinessCell:l.a,CRMFullScreenDetail:function(){return Promise.all([i.e("chunk-6d9c"),i.e("chunk-0069"),i.e("chunk-7be5")]).then(i.bind(null,"3z7q"))},FileCell:o.a},filters:{fileName:function(e){return(e.name&&e.name.length>10?e.name.substring(0,10)+"...":e.name)+"("+Object(c.h)(e.size)+")"}},mixins:[r.a],props:{id:[String,Number],detailIndex:[String,Number],detailSection:[String,Number],noListenerClass:{type:Array,default:function(){return["list-box"]}}},data:function(){return{loading:!1,category_id:"",type:"",detail:null,list:[],category_name:"",fileList:[],imgList:[],travelList:[],travelField:[{prop:"vehicle",label:"交通工具"},{prop:"trip",label:"单程往返"},{prop:"start_address",label:"出发城市"},{prop:"end_address",label:"目的城市"},{prop:"start_time",label:"开始时间"},{prop:"end_time",label:"结束时间"},{prop:"duration",label:"时长(天)"},{prop:"description",label:"备注"}],expensesField:[{prop:"start_address",label:"出发城市"},{prop:"end_address",label:"目的城市"},{prop:"start_time",label:"开始时间"},{prop:"end_time",label:"结束时间"},{prop:"traffic",label:"交通费(元)"},{prop:"stay",label:"住宿费(元)"},{prop:"diet",label:"餐饮费(元)"},{prop:"other",label:"其他费用(元)"},{prop:"description",label:"费用明细描述"}],relatedID:"",relatedCRMType:"",showRelatedDetail:!1}},computed:{relatedListData:function(){for(var e=this,t={},i=["contacts","customer","business","contract"],a=function(a){var s=i[a],n=e.detail[s+"List"]||[];n.length>0&&(t[s]=n.map(function(e){return e.id&&(e[s+"Id"]=e.id),e}))},s=0;s0&&this.$bus.emit("preview-image-bus",{index:i,data:t.map(function(e){return e.file_path&&(e.url=e.file_path),e})}):"download"===e&&Object(c.d)({path:t.url,name:t.name})},imgZoom:function(e,t){this.$bus.emit("preview-image-bus",{index:t,data:e.map(function(e){return e.file_path&&(e.url=e.file_path),e})})},downloadFile:function(e){Object(c.d)({path:e.url,name:e.name})},examineHandle:function(e){this.$emit("on-examine-handle",e,this.detailIndex),this.$emit("handle",e,this.detailIndex)}}},u=(i("dDIi"),i("KHd+")),m=Object(u.a)(d,function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("slide-view",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],staticClass:"d-view",attrs:{"listener-ids":["workbench-main-container"],"no-listener-class":e.noListenerClass},on:{afterEnter:e.viewAfterEnter,close:e.hideView}},[e.detail?i("flexbox",{staticClass:"detail-main",attrs:{orient:"vertical"}},[i("flexbox",{staticClass:"detail-header"},[i("div",{staticClass:"header-icon",style:{backgroundColor:e.detailIcon.color}},[i("i",{class:["wk","wk-"+e.detailIcon.icon]})]),e._v(" "),i("div",{staticClass:"header-name"},[e._v(e._s(e.category_name))])]),e._v(" "),i("div",{staticClass:"detail-body"},[i("flexbox",{attrs:{gutter:0,align:"stretch",wrap:"wrap"}},e._l(e.list,function(t,a){return"examine_cause"!==t.form_type&&"business_cause"!==t.form_type?i("flexbox-item",{key:a,staticClass:"b-cell",attrs:{span:.5}},["checkbox"===t.form_type?i("div",{staticClass:"b-cell-b"},[i("div",{staticClass:"b-cell-name"},[e._v(e._s(t.name))]),e._v(" "),i("div",{staticClass:"b-cell-value"},[i("flexbox",{staticStyle:{padding:"0px 10px 10px 0px"},attrs:{gutter:0,wrap:"wrap"}},e._l(t.value,function(t,a){return i("div",{key:a},[e._v("\n "+e._s(t)+"  \n ")])}))],1)]):"file"===t.form_type?i("div",{staticClass:"b-cell-b"},[i("div",{staticClass:"b-cell-name"},[e._v(e._s(t.name))]),e._v(" "),i("div",{staticClass:"b-cell-value"},e._l(t.value,function(a,s){return i("flexbox",{key:s,staticClass:"f-item"},[i("i",{staticClass:"wukong wukong-file f-img"}),e._v(" "),i("div",{staticClass:"f-name"},[e._v(e._s(e._f("fileName")(a)))]),e._v(" "),i("el-button",{attrs:{type:"text"},nativeOn:{click:function(i){e.handleFile("preview",t.value,s)}}},[e._v("预览")]),e._v(" "),i("el-button",{attrs:{type:"text"},nativeOn:{click:function(t){e.handleFile("download",a,s)}}},[e._v("下载")])],1)}))]):i("div",{staticClass:"b-cell-b"},[i("div",{staticClass:"b-cell-name"},[e._v(e._s(t.name))]),e._v(" "),i("div",{staticClass:"b-cell-value"},[e._v(e._s(t.value))])])]):e._e()})),e._v(" "),e.imgList.length>0?i("div",{staticClass:"img-box"},e._l(e.imgList,function(t,a){return i("div",{key:a,staticClass:"img-list",on:{click:function(t){e.imgZoom(e.imgList,a)}}},[i("img",{directives:[{name:"src",rawName:"v-src",value:t.file_path,expression:"imgItem.file_path"}],key:t.file_path})])})):e._e(),e._v(" "),e.fileList.length?i("div",{staticClass:"section"},[i("div",{staticClass:"section__hd"},[i("i",{staticClass:"wukong wukong-file"}),e._v(" "),i("span",[e._v("附件")]),e._v(" "),i("span",[e._v("("+e._s(e.fileList.length)+")")])]),e._v(" "),i("div",{staticClass:"section__bd"},e._l(e.fileList,function(t,a){return i("file-cell",{key:a,attrs:{data:t,list:e.fileList,"cell-index":a}})}))]):e._e(),e._v(" "),e.type&&3==e.type&&e.travelList&&e.travelList.length>0?i("div",{staticClass:"table-sections"},[i("div",{staticClass:"table-sections__title"},[e._v("行程")]),e._v(" "),i("el-table",{staticStyle:{"font-size":"13px"},attrs:{data:e.travelList,align:"center","header-align":"center",stripe:""}},e._l(e.travelField,function(e,t){return i("el-table-column",{key:t,attrs:{prop:e.prop,label:e.label,"show-overflow-tooltip":""}})}))],1):e._e(),e._v(" "),e.type&&5==e.type&&e.travelList&&e.travelList.length>0?i("div",{staticClass:"table-sections"},[i("div",{staticClass:"table-sections__title"},[e._v("报销")]),e._v(" "),i("el-table",{staticStyle:{"font-size":"13px"},attrs:{data:e.travelList,align:"center","header-align":"center",stripe:""}},[e._l(e.expensesField,function(e,t){return i("el-table-column",{key:t,attrs:{prop:e.prop,label:e.label,"show-overflow-tooltip":""}})}),e._v(" "),i("el-table-column",{attrs:{label:"发票",width:"50"},scopedSlots:e._u([{key:"default",fn:function(t){return[i("flexbox",{attrs:{justify:"center"}},[i("el-button",{attrs:{type:"text"},nativeOn:{click:function(i){e.handleFile("preview",t.row.imgList,0)}}},[e._v(e._s(t.row.imgList?t.row.imgList.length:0)+"张")])],1)]}}])})],2)],1):e._e(),e._v(" "),Object.keys(e.relatedListData).length>0?i("div",{staticClass:"section"},[i("div",{staticClass:"section__hd"},[i("i",{staticClass:"wukong wukong-relevance"}),e._v(" "),i("span",[e._v("相关信息")])]),e._v(" "),i("div",{staticClass:"section__bd"},e._l(e.relatedListData,function(t,a){return i("div",{key:a},e._l(t,function(t,s){return i("related-business-cell",{key:s,attrs:{data:t,"cell-index":s,type:a,"show-foot":!1},nativeOn:{click:function(i){e.checkRelatedDetail(a,t)}}})}))}))]):e._e(),e._v(" "),i("div",{staticClass:"examine-section"},[i("examine-info",{staticClass:"create-sections-content",attrs:{id:e.id,"record-id":e.detail.flow_id,"examine-type":"oa_examine"},on:{"on-handle":e.examineHandle}})],1)],1)],1):e._e(),e._v(" "),i("c-r-m-full-screen-detail",{attrs:{visible:e.showRelatedDetail,"crm-type":e.relatedCRMType,id:e.relatedID},on:{"update:visible":function(t){e.showRelatedDetail=t}}})],1)},[],!1,null,"a857c570",null);m.options.__file="ExamineDetail.vue";t.a=m.exports},t1Sh:function(e,t,i){"use strict";var a=i("Lc7H");i.n(a).a},tnRl:function(e,t,i){}}]);