You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
wkcrm/static/js/chunk-556b.16b4b992.js

1 line
15 KiB

4 years ago
(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-556b"],{"+yYr":function(e,t,s){},"1q41":function(e,t,s){},"31UX":function(e,t,s){"use strict";var a=s("QbLZ"),i=s.n(a),l=s("4d7F"),n=s.n(l),o=s("CMIa"),u=s("ehos"),r=s("7Qib");t.a={data:function(){return{chartObj:null,chartOtherObj:null,chartColors:["#6CA2FF","#6AC9D7","#72DCA2","#48E78D","#FECD51","#DBB375","#FF7474","#F59561","#A3AEBC","#4C84FF","#0DBEB4","#00DEDE","#FFAA00","#C7C116","#F7A57C","#F661AC","#8652EE"],chartXAxisStyle:{axisTick:{alignWithLabel:!0,lineStyle:{width:0}},axisLabel:{color:"#333"},axisLine:{lineStyle:{color:"#333"}},splitLine:{show:!1}},chartYAxisStyle:{axisTick:{alignWithLabel:!0,lineStyle:{width:0}},axisLabel:{color:"#333"},axisLine:{lineStyle:{color:"#333"}},splitLine:{show:!1}},currentPage:1,pageSizes:[15,30,45,60],pageSize:0,total:0,toolbox:{showTitle:!1,feature:{saveAsImage:{show:!0,pixelRatio:2}}}}},components:{FiltrateHandleView:o.a},props:{},computed:{},watch:{},mounted:function(){var e=this;this.debouncedResize=Object(u.debounce)(300,this.resizeFn),this.$nextTick(function(){window.addEventListener("resize",e.debouncedResize)})},beforeDestroy:function(){window.removeEventListener("resize",this.debouncedResize)},methods:{resizeFn:function(){this.chartObj&&this.chartObj.resize(),this.chartOtherObj&&this.chartOtherObj.resize()},handleSizeChange:function(e){this.pageData.limit=e,this.getList(this.pageData)},handleCurrentChange:function(e){this.pageData.page=e,this.getList(this.pageData)},requestExportInfo:function(e,t,s){return new n.a(function(a,l){e(i()({},t,{excel_types:s,excel_type:1})).then(function(e){Object(r.c)(e),a&&a(e)}).catch(function(e){l&&l(e)})})}},deactivated:function(){}}},"77fj":function(e,t,s){"use strict";var a=s("Btlj");s.n(a).a},"7DYL":function(e,t,s){"use strict";s.r(t);var a=s("31UX"),i=s("MT78"),l=s.n(i),n=s("J8QC"),o={name:"CustomerPortrayalStatistics",mixins:[a.a],props:{},data:function(){return{loading:!1,axisOption:null,list:[],type:"",postParams:{},fieldList:[]}},computed:{filterTitle:function(){return{source:"客户来源分析",industry:"客户行业分析",level:"客户级别分析"}[this.type]||""}},created:function(){this.type=this.$route.params.type},mounted:function(){this.initAxis()},beforeRouteUpdate:function(e,t,s){this.type=e.params.type,this.getDataList(this.postParams),s()},methods:{getDataList:function(e){var t=this;this.postParams=e,this.loading=!0,e.type_analyse=this.type,Object(n.b)(e).then(function(e){t.loading=!1;for(var s=[],a=[],i=[],l=[{name:"所有客户(个)"},{name:"成交客户(个)"}],n=[{field:"name",name:{source:"客户来源",industry:"客户行业",level:"客户级别"}[t.type]}],o=0;o<e.data.length;o++){var u=e.data[o];s.push({name:u[t.type],value:u.allCustomer}),a.push({name:u[t.type],value:u.dealCustomer}),i.push(u[t.type]);var r="value"+o;n.length<=e.data.length&&n.push({field:r,name:u[t.type]});for(var c=["allCustomer","dealCustomer"],h=0;h<c.length;h++){var p=c[h];l[h][r]=u[p]}}t.axisOption.legend.data=i,t.axisOption.series[0].data=s,t.axisOption.series[1].data=a,t.chartObj.setOption(t.axisOption,!0),t.fieldList=n,t.list=l}).catch(function(){t.loading=!1})},initAxis:function(){this.chartObj=l.a.init(document.getElementById("axismain")),this.axisOption=this.getChartOptione(),this.chartObj.setOption(this.axisOption,!0)},getChartOptione:function(){return{title:[{text:"全部客户",x:"20%",bottom:"25"},{text:"成交客户",x:"70%",bottom:"25"}],color:this.chartColors,toolbox:this.toolbox,tooltip:{trigger:"item",formatter:"{b} : {c}"},legend:{x:"center",y:"bottom",type:"scroll",data:[]},series:[{name:"全部客户",type:"pie",radius:["35%","50%"],center:["25%","50%"],data:[]},{name:"成交客户",type:"pie",radius:["35%","50%"],center:["75%","50%"],data:[]}]}}}},u=(s("F4Qp"),s("KHd+")),r=Object(u.a)(o,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"}],staticClass:"main-container"},[s("filtrate-handle-view",{staticClass:"filtrate-bar",attrs:{title:e.filte