chunk-13fbaf8a.36d67b0b.js 14 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-13fbaf8a"],{"29de":function(t,e,i){},"53f3":function(t,e,i){"use strict";i.r(e);var a,s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"xq-statistics-page"},[a("mescroll-vue",{ref:"wordListBox",staticClass:"customerBoxmescroll",attrs:{down:t.mescrollDown,up:t.mescrollUp},on:{init:t.mescrollInit}},[a("div",{staticClass:"xq-header-box"},[a("statisticstop",{attrs:{orgName:t.totalObj.org_name,type:t.activeIndex},on:{switchDate:t.switchDate}})],1),a("div",{staticClass:"xq-callup-main"},[a("div",{staticClass:"xq-callup-all"},[a("div",{staticClass:"xq-measure-total flex align-center justify-between"},[a("div",{staticClass:"xq-total-left flex align-center"},[a("div",{staticClass:"xq-total-icon"},[a("img",{attrs:{src:i("7c7e"),width:"100%",height:"100%",alt:""}})]),a("span",{staticClass:"font30 color384855 ml10"},[t._v("定金数量及金额")])]),a("div",{staticClass:"xq-total-right flex align-center justify-end"},[a("span",{staticClass:"color2476FE font32 fontw700"},[t._v(t._s(t.totalObj.depmoney)+" 元")])])]),a("div",{staticClass:"xq-callupall-content"},[t._l(t.showFieldArr,(function(e,i){return a("div",{directives:[{name:"show",rawName:"v-show",value:!e.hidden,expression:"!item.hidden"}],key:i,staticClass:"everydeliverybox",style:{width:e.width}},[a("span",{staticClass:"font36"},[t._v(t._s(t.totalObj[e.field])+t._s(e.unity||""))]),a("span",{staticClass:"mt10 xq-block ellipsis color89A0B7 font24"},[t._v(t._s(e.name))])])})),t._l(t.totalObj.package,(function(e,i){return a("div",{key:"p"+i,staticClass:"everydeliverybox",style:{width:"25%"}},[a("span",{staticClass:"font36"},[t._v(t._s(e.num))]),a("span",{staticClass:"mt10 xq-block ellipsis color89A0B7 font24"},[t._v(t._s(e.name))])])}))],2)]),a("van-sticky",{attrs:{"offset-top":"0"}},[a("div",{staticClass:"xq-filter-box flex align-center"},[a("div",{on:{click:function(e){return t.sortFunc("depnum")}}},[a("span",{class:{"xq-active-filter":t.depnumActive}},[t._v("定金数量")]),a("div",{staticClass:"flex-column align-center justify-center ml5"},[a("i",{staticClass:"iconfont icon-shixinjiantou-xiangshang upicon",class:{sortActive:"depnum asc"==t.filterObj.order}}),a("i",{staticClass:"iconfont icon-shixinjiantou-xiangshang-copy downicon",class:{sortActive:"depnum desc"==t.filterObj.order}})])]),a("div",{on:{click:function(e){return t.sortFunc("depmoney")}}},[a("span",{class:{"xq-active-filter":t.depmoneyActive}},[t._v("定金金额")]),a("div",{staticClass:"flex-column align-center justify-center ml5"},[a("i",{staticClass:"iconfont icon-shixinjiantou-xiangshang upicon",class:{sortActive:"depmoney asc"==t.filterObj.order}}),a("i",{staticClass:"iconfont icon-shixinjiantou-xiangshang-copy downicon",class:{sortActive:"depmoney desc"==t.filterObj.order}})])]),a("div",{on:{click:function(e){return t.sortFunc("package_depnum")}}},[a("span",{class:{"xq-active-filter":t.packageDepnumActive}},[t._v("签单产品")]),a("div",{staticClass:"flex-column align-center justify-center ml5"},[a("i",{staticClass:"iconfont icon-shixinjiantou-xiangshang upicon",class:{sortActive:"package_depnum asc"==t.filterObj.order}}),a("i",{staticClass:"iconfont icon-shixinjiantou-xiangshang-copy downicon",class:{sortActive:"package_depnum desc"==t.filterObj.order}})])])])]),t._l(t.deliveryOrgArr,(function(e,i){return a("div",{key:e.id,staticClass:"xq-callup-item",class:{"xq-active-border":t.activeItem==e.id},on:{click:function(i){return t.jumpDeliveryPage(e,"depart")}}},[a("div",{staticClass:"xq-callupall-header flex align-center justify-between font28 color384855"},[a("div",{staticClass:"flex align-center"},[a("div",{staticClass:"xq-vertical"}),a("span",{staticClass:"ml10 font28"},[t._v(t._s(e.name))]),a("span",{staticClass:"font24 color89A0B7 ml10"},[t._v("总"+t._s(e.employee_count)+"人")])]),a("div",{staticClass:"flex align-center justify-end"},[a("span",{staticClass:"color2476FE font24 fontw600"},[t._v("定金数量及金额:"+t._s(e.depmoney))]),a("van-icon",{attrs:{name:"arrow",color:"#2476FE",size:"16"}})],1)]),a("div",{staticClass:"xq-callupall-content"},[t._l(t.showFieldArr,(function(i,s){return a("div",{directives:[{name:"show",rawName:"v-show",value:!i.hidden,expression:"!f.hidden"}],key:s,staticClass:"everydeliverybox",style:{width:i.width}},[a("span",{staticClass:"font36"},[t._v(t._s(e[i.field])+t._s(i.unity||""))]),a("span",{staticClass:"mt10 xq-block ellipsis color89A0B7 font24"},[t._v(t._s(i.name))])])})),t._l(e.package,(function(e,i){return a("div",{key:"p"+i,staticClass:"everydeliverybox",style:{width:"25%"}},[a("span",{staticClass:"font36"},[t._v(t._s(e.num))]),a("span",{staticClass:"mt10 xq-block ellipsis color89A0B7 font24"},[t._v(t._s(e.name))])])}))],2)])})),t._l(t.deliveryEmployeeArr,(function(e,s){return a("div",{key:e.id,staticClass:"xq-callup-item",class:{"xq-active-border":t.activeItem==e.id},on:{click:function(i){return t.jumpDeliveryPage(e,"employee")}}},[a("div",{staticClass:"xq-callupall-header flex align-center justify-between font28 color384855"},[a("div",{staticClass:"flex align-center"},[a("div",{staticClass:"xq-staff-avatar"},[e.user&&e.user.headimgurl?[a("img",{attrs:{src:e.user.headimgurl,width:"100%",height:"100%",alt:""}})]:[a("img",{attrs:{src:i("ee87"),width:"100%",height:"100%",alt:""}})]],2),a("span",[t._v(t._s(e.name))])]),a("div",{staticClass:"flex align-center justify-end"},[a("span",{staticClass:"color2476FE font24 fontw600"},[t._v("定金数量及金额:"+t._s(e.depmoney))]),a("van-icon",{attrs:{name:"arrow",color:"#2476FE",size:"16"}})],1)]),a("div",{staticClass:"xq-callupall-content"},[t._l(t.showFieldArr,(function(i,s){return a("div",{directives:[{name:"show",rawName:"v-show",value:!i.hidden,expression:"!f.hidden"}],key:s,staticClass:"everydeliverybox",style:{width:i.width}},[a("span",{staticClass:"font36"},[t._v(t._s(e[i.field])+t._s(i.unity||""))]),a("span",{staticClass:"mt10 xq-block ellipsis color89A0B7 font24"},[t._v(t._s(i.name))])])})),t._l(e.package,(function(e,i){return a("div",{key:"p"+i,staticClass:"everydeliverybox",style:{width:"25%"}},[a("span",{staticClass:"font36"},[t._v(t._s(e.num))]),a("span",{staticClass:"mt10 xq-block ellipsis color89A0B7 font24"},[t._v(t._s(e.name))])])}))],2)])})),a("nonedata",{attrs:{len:t.datalength,datashow:t.datashow}})],2)]),a("van-calendar",{attrs:{"allow-same-day":"","min-date":t.minDate,"max-date":t.maxDate,type:"range",color:"#249EFB","default-date":t.defaultDate},on:{confirm:t.onConfirm,opened:t.calendarOpened},model:{value:t.showCalendar,callback:function(e){t.showCalendar=e},expression:"showCalendar"}}),a("wzhload",{directives:[{name:"show",rawName:"v-show",value:t.loadFlag,expression:"loadFlag"}]})],1)},n=[],r=i("d0afc"),l=i("f3f3"),o=i("fc11"),c=(i("6d73"),i("473d")),d=(i("0cc8"),i("3104")),m=(i("b0c0"),i("e9c4"),i("d3b7"),i("3ca3"),i("ddb0"),i("159b"),i("b64b"),i("99af"),i("8d6b")),h=i("a92e"),u=i("4f8e"),f=i("5880"),p=i("5a0c"),v=i.n(p),b=i("d0af"),g={name:"delivery",components:(a={},Object(o["a"])(a,d["a"].name,d["a"]),Object(o["a"])(a,c["a"].name,c["a"]),Object(o["a"])(a,"MescrollVue",m["a"]),Object(o["a"])(a,"nonedata",h["a"]),Object(o["a"])(a,"statisticstop",b["a"]),a),data:function(){return{loadFlag:!1,datashow:!1,showCalendar:!1,activeIndex:"0",scrollPosition:0,activeItem:null,minDate:new Date(2018,0,1),maxDate:new Date,filterObj:{order:"",org_id:"",start_time:"",end_time:""},totalObj:{},deliveryOrgArr:[],deliveryEmployeeArr:[],tab:[{name:"今日",type:"0"},{name:"近一周",type:"1"},{name:"近一月",type:"2"},{name:"其他时间",type:"3"}],showFieldArr:[{name:"定金数量",field:"depnum",width:"33.33%"},{name:"定金率",field:"deprate",width:"25%",unity:"%",hidden:!0},{name:"定金金额",field:"depmoney",width:"33.33%"},{name:"平均定金周期",field:"agvcycle",width:"33.33%"},{name:"一次到店定金",field:"oneshop_depnum",width:"30%"},{name:"一次到店定金率",field:"oneshop_deprate",width:"30%",unity:"%",hidden:!0},{name:"一次到店定金平均周期",field:"one_agvcycle",width:"40%"},{name:"二次到店定金",field:"twoshop_depnum",width:"30%"},{name:"二次到店定金率",field:"twoshop_deprate",width:"30%",unity:"%",hidden:!0},{name:"二次到店定金平均周期",field:"two_agvcycle",width:"39%"},{name:"三次到店定金",field:"threeshop_depnum",width:"22%"},{name:"三次到店定金率",field:"threeshop_deprate",width:"30%",unity:"%",hidden:!0},{name:"三次到店定金平均周期",field:"three_agvcycle",width:"39%"}],mescroll:null,mescrollDown:{},mescrollUp:{auto:!1,callback:this.getFuncList,onScroll:this.onScroll,page:{num:0,size:10},htmlLoading:"",htmlNodata:"",noMoreSize:0}}},computed:Object(l["a"])(Object(l["a"])({},Object(f["mapState"])({jumpNewPage:function(t){return t.jumpNewPage}})),{},{datalength:function(){return this.deliveryOrgArr.length+this.deliveryEmployeeArr.length},defaultDate:function(){return[new Date(this.filterObj.start_time),new Date(this.filterObj.end_time)]},depnumActive:function(){return"depnum desc"==this.filterObj.order||"depnum asc"==this.filterObj.order},depmoneyActive:function(){return"depmoney desc"==this.filterObj.order||"depmoney asc"==this.filterObj.order},packageDepnumActive:function(){return"package_depnum desc"==this.filterObj.order||"package_depnum asc"==this.filterObj.order}}),mounted:function(){this.initPageData()},activated:function(){this.initPageData()},methods:Object(l["a"])(Object(l["a"])({},Object(f["mapMutations"])(["setJumpNewPage"])),{},{onScroll:function(t,e,i){this.scrollPosition=e},initPageData:function(){var t=this;this.filterObj=Object(l["a"])(Object(l["a"])({},this.filterObj),{},{start_time:v()(new Date).format("YYYY/MM/DD"),end_time:v()(new Date).format("YYYY/MM/DD")});var e=this.$route.query;this.filterObj.org_id=e.orgid?e.orgid:"";var i=this.getSessionStorage();this.jumpNewPage?this.$nextTick((function(){t.setJumpNewPage(!1),t.switchDate({type:e.dateType||"0"},"jump",e),t.mescroll.scrollTo(0,0)})):i.orgid?(this.scrollPosition=i.position,this.deliveryOrgArr=i.orgArr,this.deliveryEmployeeArr=i.employeeArr,this.totalObj=i.totalObj,this.filterObj=i.filterObj,this.activeItem=i.itemId,this.activeIndex=i.dateIndex,this.$nextTick((function(){t.mescroll.scrollTo(parseInt(i.position||0),0)}))):this.mescroll.resetUpScroll()},calendarOpened:function(){var t=document.querySelector(".van-calendar__body").scrollTop;document.querySelector(".van-calendar__body").scrollTop=t-1},switchDate:function(t,e,i){switch(this.activeIndex=t.type,t.type){case"0":this.filterObj=Object(l["a"])(Object(l["a"])({},this.filterObj),{},{start_time:v()(new Date).format("YYYY/MM/DD"),end_time:v()(new Date).format("YYYY/MM/DD")}),this.mescroll.resetUpScroll();break;case"1":this.filterObj=Object(l["a"])(Object(l["a"])({},this.filterObj),{},{start_time:this.utils.getCurrentWeekFirstDay(),end_time:this.utils.getCurrentWeekLastDay()}),this.mescroll.resetUpScroll();break;case"2":this.filterObj=Object(l["a"])(Object(l["a"])({},this.filterObj),{},{start_time:this.utils.getmonthfirstday(),end_time:this.utils.getmonthlastday()}),this.mescroll.resetUpScroll();break;case"3":if("jump"==e){var a=i.start_time,s=i.end_time;this.filterObj=Object(l["a"])(Object(l["a"])({},this.filterObj),{},{start_time:a,end_time:s}),this.mescroll.resetUpScroll()}else this.showCalendar=!0;break;default:this.mescroll.resetUpScroll();break}},getWeekDate:function(){var t=new Date,e=t.getTime()-5184e5,i=v()(new Date(e)).format("YYYY/MM/DD"),a=v()(t).format("YYYY/MM/DD");return{start_time:i,end_time:a}},getMonthDate:function(){var t=new Date,e=t.getTime()-2592e6,i=v()(new Date(e)).format("YYYY/MM/DD"),a=v()(t).format("YYYY/MM/DD");return{start_time:i,end_time:a}},onConfirm:function(t){var e=Object(r["a"])(t,2),i=e[0],a=e[1];this.filterObj=Object(l["a"])(Object(l["a"])({},this.filterObj),{},{start_time:v()(i).format("YYYY/MM/DD"),end_time:v()(a).format("YYYY/MM/DD")}),this.mescroll.resetUpScroll(),this.showCalendar=!1},sortFunc:function(t){this.filterObj.order=="".concat(t," asc")?this.filterObj.order="".concat(t," desc"):this.filterObj.order="".concat(t," asc"),this.mescroll.resetUpScroll()},setSessionStorage:function(){var t={position:this.scrollPosition,orgArr:this.deliveryOrgArr,employeeArr:this.deliveryEmployeeArr,totalObj:this.totalObj,filterObj:this.filterObj,orgid:this.filterObj.org_id||"0",itemId:this.activeItem,dateIndex:this.activeIndex};sessionStorage.setItem("delivery#".concat(this.filterObj.org_id),JSON.stringify(t))},getSessionStorage:function(){var t=sessionStorage.getItem("delivery#".concat(this.filterObj.org_id))?JSON.parse(sessionStorage.getItem("delivery#".concat(this.filterObj.org_id))):{};return t},jumpDeliveryPage:function(t,e){if(this.activeItem=t.id,this.setSessionStorage(),this.setJumpNewPage(!0),"depart"==e){var a=(new Date).getTime();this.$$router.addRoute({path:"/".concat(a),name:"".concat(a),component:function(){return i.e("chunk-dd2631bc").then(i.bind(null,"be40"))},meta:{title:"定金数量统计|".concat(t.name)}}),this.$router.push({path:"/".concat(a),query:{orgid:t.id,type:"depart",dateType:this.activeIndex,start_time:this.filterObj.start_time,end_time:this.filterObj.end_time}})}else this.$router.push({path:"/deliveryCus",query:{eid:t.id,type:"employee",dateType:this.activeIndex,start_time:this.filterObj.start_time,end_time:this.filterObj.end_time,orgName:this.totalObj.org_name}})},getDepositIndex:function(){var t=this;Object(u["n"])(Object(l["a"])({},this.filterObj)).then((function(e){0==e.data.code&&(t.totalObj=e.data.data)}))},getDepositOrg:function(){var t=this;Object(u["o"])(Object(l["a"])({},this.filterObj)).then((function(e){0==e.data.code&&(t.deliveryOrgArr=e.data.data)}))},mescrollInit:function(t){this.mescroll=t},getFuncList:function(t,e){var i=this;i.loadFlag=!0,i.datashow=!1;var a=Object(l["a"])({page:t.num,limit:10},this.filterObj);Object.keys(a).forEach((function(t){a[t]||delete a[t]})),this.getDepositIndex(),this.getDepositOrg(),Object(u["m"])(a).then((function(a){"0"==a.data.code&&(1===t.num&&(i.deliveryEmployeeArr=[]),i.deliveryEmployeeArr=i.deliveryEmployeeArr.concat(a.data.data),i.$nextTick((function(){e.endSuccess(a.data.data.length)}))),i.loadFlag=!1,i.datashow=!0}))}})},y=g,j=(i("7e30"),i("2877")),_=Object(j["a"])(y,s,n,!1,null,"ad31d4cc",null);e["default"]=_.exports},"7e30":function(t,e,i){"use strict";i("29de")}}]);