|
- (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/reportExcel/weekReport"],{106:function(e,t,n){"use strict";(function(e){n(5),n(6);o(n(4));var t=o(n(107));function o(e){return e&&e.__esModule?e:{default:e}}wx.__webpack_require_UNI_MP_PLUGIN__=n,e(t.default)}).call(this,n(1)["createPage"])},107:function(e,t,n){"use strict";n.r(t);var o=n(108),r=n(110);for(var i in r)"default"!==i&&function(e){n.d(t,e,(function(){return r[e]}))}(i);n(112);var s,a=n(17),c=Object(a["default"])(r["default"],o["render"],o["staticRenderFns"],!1,null,"1b1577ad",null,!1,o["components"],s);c.options.__file="pages/reportExcel/weekReport.vue",t["default"]=c.exports},108:function(e,t,n){"use strict";n.r(t);var o=n(109);n.d(t,"render",(function(){return o["render"]})),n.d(t,"staticRenderFns",(function(){return o["staticRenderFns"]})),n.d(t,"recyclableRender",(function(){return o["recyclableRender"]})),n.d(t,"components",(function(){return o["components"]}))},109:function(e,t,n){"use strict";var o;n.r(t),n.d(t,"render",(function(){return r})),n.d(t,"staticRenderFns",(function(){return s})),n.d(t,"recyclableRender",(function(){return i})),n.d(t,"components",(function(){return o}));try{o={uLineProgress:function(){return n.e("uview-ui/components/u-line-progress/u-line-progress").then(n.bind(null,601))},uParse:function(){return Promise.all([n.e("common/vendor"),n.e("uview-ui/components/u-parse/u-parse")]).then(n.bind(null,569))}}}catch(a){if(-1===a.message.indexOf("Cannot find module")||-1===a.message.indexOf(".vue"))throw a;console.error(a.message),console.error("1. 排查组件名称拼写是否正确"),console.error("2. 排查组件是否符合 easycom 规范,文档:https://uniapp.dcloud.net.cn/collocation/pages?id=easycom"),console.error("3. 若组件不符合 easycom 规范,需手动引入,并在 components 中注册该组件")}var r=function(){var e=this,t=e.$createElement,n=(e._self._c,e.isShowXJTop1List,null),o=(e.isShowXJTop1List,null),r=(e.isShowXJTop1List,null),i=(e.isShowXJTop1List,null),s=(e.isShowXJTop1List,null),a=(e.isShowXJTop1List,null),c=(e.isShowXJTop1List,null),u=(e.isShowXJTop1List,null),l=e.isShowXJTop1List?e.__map(e.weekObj.XJTop1List,(function(t,n){var o=e.__get_orig(t),r=e.$options.filters.setColor(n);return{$orig:o,g0:r}})):null,p=(e.isShowStatistics,null),m=(e.isShowStatistics,null),f=(e.isShowStatistics,null),b=(e.isShowStatistics,null),d=(e.isShowStatistics,null),h=(e.isShowStatistics,null),g=(e.isShowStatistics,null),w=e.isShowStatistics?e.__map(e.tableHead,(function(t,n){var o=e.__get_orig(t),r=e.__get_style([t.style]);return{$orig:o,s0:r}})):null,j=e.isShowZXLTopList?e.__map(e.weekObj.ZXLTopList,(function(t,n){var o=e.__get_orig(t),r=e.$options.filters.setColor(n);return{$orig:o,g1:r}})):null,k=e.isShowJDLTopList?e.__map(e.weekObj.JDLTopList,(function(t,n){var o=e.__get_orig(t),r=e.$options.filters.setColor(n);return{$orig:o,g2:r}})):null;e.$mp.data=Object.assign({},{$root:{m0:n,m1:o,m2:r,m3:i,m4:s,m5:a,m6:c,m7:u,l0:l,m8:p,m9:m,m10:f,m11:b,m12:d,m13:h,m14:g,l1:w,l2:j,l3:k}})},i=!1,s=[];r._withStripped=!0},110:function(e,t,n){"use strict";n.r(t);var o=n(111),r=n.n(o);for(var i in o)"default"!==i&&function(e){n.d(t,e,(function(){return o[e]}))}(i);t["default"]=r.a},111:function(e,t,n){"use strict";function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function r(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var s=function(){n.e("components/gaoyia-parse/parse").then(function(){return resolve(n(586))}.bind(null,n)).catch(n.oe)},a={components:{uParse:s},data:function(){return{tableHead:[{title:"顾问",style:{flex:1}},{title:"接待量",style:{flex:1}},{title:"平均接待时长",style:{flex:2}},{title:"平均执行率",style:{flex:2}},{title:"对比上周",style:{flex:1.5}}],id:"",needList:["JDLTop","ZXLTop","XJTop1"],numlist:[{name:"接待量 (次)",num:"",setName:"receptionCount1",percent:"",percentName:"receptionCountPK",preNum:"",preNumName:"receptionCount2"},{name:"有效接待 (次)",num:"",setName:"activeCustomer1",percent:"",percentName:"activeCustomerPK",preNum:"",preNumName:"activeCustomer2"},{name:"平均执行率(%)",num:"",setName:"fraction1",percent:"",percentName:"fractionPK",preNum:"",preNumName:"fraction2"},{name:"平均接待时长(分)",num:"",setName:"avgDuration1",percent:"",percentName:"avgDurationPK",preNum:"",preNumName:"avgDuration2"},{name:"违禁接待 (次)",num:"",setName:"prohibitedNum1",percent:"",percentName:"prohibitedNumPK",preNum:"",preNumName:"prohibitedNum2",class:"down"},{name:"客户画像触达 (次)",num:"",setName:"reachSum1",percent:"",percentName:"reachSumPK",preNum:"",preNumName:"reachSum2"},{name:"已标记",num:"",setName:"labelledReceptionNum1",percent:"",percentName:"labelledReceptionNumPK",preNum:"",preNumName:"labelledReceptionNum2"},{name:"未标记",num:"",setName:"unlabelledReceptionNum1",percent:"",percentName:"unlabelledReceptionNumPK",preNum:"",preNumName:"unlabelledReceptionNum2",class:"down"}],weekObj:{},projectName:""}},computed:{rankTop:function(){var e=this;return function(t){var n={};try{return e.weekObj.customerInfo1.length&&e.weekObj.customerInfo2.length&&(n.ranktype=e.weekObj.customerInfo1.length-e.weekObj.customerInfo2.length>0?"上升":"下降",n.people=Math.abs(e.weekObj.customerInfo1.length-e.weekObj.customerInfo2.length)),e.weekObj.customerInfo1&&e.weekObj.customerInfo1.length>0&&(n.topName=e.weekObj.customerInfo1[0].name,n.topPk=Math.abs(e.weekObj.customerInfo1[0].pk),n.lastName=e.weekObj.customerInfo1[e.weekObj.customerInfo1.length-1].name,n.lastPk=Math.abs(e.weekObj.customerInfo1[e.weekObj.customerInfo1.length-1].pk)),e.weekObj.customerInfo1.length&&e.weekObj.customerInfo2.length&&(n.class=e.weekObj.customerInfo1.length-e.weekObj.customerInfo2.length>0?"up":"down"),e.weekObj.fractionPK&&(n.fractionPKName=e.weekObj.fractionPK>0?"上涨":"下跌",n.fractionPK=Math.abs(e.weekObj.fractionPK)),e.weekObj.XJTop1List&&e.weekObj.XJTop1List.length>0&&(n.fractionBastName=e.weekObj.XJTop1List[0].title,n.fractionBastValue=e.weekObj.XJTop1List[0].value),e.weekObj.XJTop1List&&e.weekObj.XJTop1List.length>0&&(n.fractionLastName=e.weekObj.XJTop1List[e.weekObj.XJTop1List.length-1].title,n.fractionLastValue=e.weekObj.XJTop1List[e.weekObj.XJTop1List.length-1].value),n[t]||""}catch(o){return console.log(o),""}}},isShowStatistics:function(){return this.weekObj.customerInfo1&&this.weekObj.customerInfo1.length>0},isShowXJTop1List:function(){return this.weekObj.XJTop1List&&this.weekObj.XJTop1List.length>0},isShowZXLTopList:function(){return this.weekObj.ZXLTopList&&this.weekObj.ZXLTopList.length>0},isShowJDLTopList:function(){return this.weekObj.JDLTopList&&this.weekObj.JDLTopList.length>0}},onLoad:function(e){e.id&&(this.id=e.id),this.getMessage()},onShareAppMessage:function(){return{title:"".concat(this.projectName,"数智工牌周报"),path:"/pages/reportExcel/weekReport?id=".concat(this.id)}},methods:{getMessage:function(){var e=this;this.$u.get("/zkMessage/findByProjectId",{id:this.id}).then((function(t){console.log(t);var n=JSON.parse(t.zkMessage.content);console.log(n),e.bubbleSort(n.customerInfo1,"pk"),e.bubbleSort(n.customerInfo2,"pk"),n.customerInfo1.reverse(),n.customerInfo2.reverse(),e.weekObj=r(r({},t.zkMessage),n),e.weekObj.createTimeName=e.getTimeLines(e.weekObj.weekDate,1),console.log(e.weekObj,"this.weekObj"),e.projectName=t.projectName,e.numlist.forEach((function(e){n[e.setName]&&(e.num=n[e.setName]),n[e.percentName]&&(e.percent=n[e.percentName]),n[e.preNumName]&&(e.preNum=n[e.preNumName])})),e.init()})).catch((function(e){console.log(e)}))},init:function(){var e=this;console.log(this.weekObj,"this.weekObj"),this.needList.forEach((function(t){if(e.weekObj[t]&&Object.keys(e.weekObj[t]).length>0)for(var n in e.weekObj[t+"List"]=[],e.weekObj[t])e.weekObj[t+"List"].push({title:n,value:e.weekObj[t][n]})})),this.sortInitArr()},sortInitArr:function(){var e=this;this.needList.forEach((function(t){e.weekObj[t+"List"]&&e.bubbleSort(e.weekObj[t+"List"])})),this.reverseList()},reverseList:function(){var e=this;this.needList.forEach((function(t){e.weekObj[t+"List"]&&e.weekObj[t+"List"].reverse()})),console.log(this.weekObj,"12312312312")},bubbleSort:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",n=0;n<e.length-1;n+=1)for(var o=0;o<e.length-1-n;o+=1)if(e[o][t]>e[o+1][t]){var r=e[o];e[o]=e[o+1],e[o+1]=r}},getTimeLine:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n="--";if(!e)return n;var o=new Date(e.replace(/-/g,"/"));o.setDate(o.getDate()-7);var r=e.split(" "),i=r[0],s=i.split("-"),a=o.getMonth()+1<10?"0".concat(o.getMonth()+1):o.getMonth()+1,c=o.getDate()<10?"0".concat(o.getDate()):o.getDate();return n=1==t?"".concat(a,".").concat(c,"-").concat(s[1],".").concat(s[2]):"".concat(a,"月").concat(c,"日~").concat(s[1],"月").concat(s[2],"日"),n},getTimeLines:function(e){if(!e)return"";var t=e.split("~"),n=t[0].split("-"),o=t[1].split("-");return"".concat(n[1],"月").concat(n[2],"日~").concat(o[1],"月").concat(o[2],"日")}},filters:{fomatDate:function(e){if(!e)return"--";var t=e.split(" "),n=t[0],o=n.split("-");return"".concat(o[1],"-").concat(o[2])},getTimeLine:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;if(!e)return"--";console.log(e.replace(/-/g,"/"));var n=new Date(e.replace(/-/g,"/"));n.setDate(n.getDate()-7);var o=e.split(" "),r=o[0],i=r.split("-"),s=n.getMonth()+1<10?"0".concat(n.getMonth()+1):n.getMonth()+1,a=n.getDate()<10?"0".concat(n.getDate()):n.getDate();return 1==t?"".concat(s,".").concat(a,"-").concat(i[1],".").concat(i[2]):"".concat(s,"月").concat(a,"日~").concat(i[1],"月").concat(i[2],"日")},setColor:function(e){var t="";switch(e){case 0:t="#E7483C";break;case 1:t="#FF8C13";break;case 2:t="#FFCC00";break;default:t="#4FC78F";break}return t}}};t.default=a},112:function(e,t,n){"use strict";n.r(t);var o=n(113),r=n.n(o);for(var i in o)"default"!==i&&function(e){n.d(t,e,(function(){return o[e]}))}(i);t["default"]=r.a},113:function(e,t){throw new Error("Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):\nModuleBuildError: Module build failed (from ./node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js):\nError: ENOENT: no such file or directory, open 'D:\\hezhong\\NewZkgj\\pages\\reportExcel\\weekReport.vue'\n at D:\\applaction\\1Hbuilderx\\HBuilderX\\plugins\\uniapp-cli\\node_modules\\webpack\\lib\\NormalModule.js:316:20\n at D:\\applaction\\1Hbuilderx\\HBuilderX\\plugins\\uniapp-cli\\node_modules\\loader-runner\\lib\\LoaderRunner.js:367:11\n at D:\\applaction\\1Hbuilderx\\HBuilderX\\plugins\\uniapp-cli\\node_modules\\loader-runner\\lib\\LoaderRunner.js:203:19\n at D:\\applaction\\1Hbuilderx\\HBuilderX\\plugins\\uniapp-cli\\node_modules\\enhanced-resolve\\lib\\CachedInputFileSystem.js:85:15\n at processTicksAndRejections (internal/process/task_queues.js:79:11)")}},[[106,"common/runtime","common/vendor"]]]);
- //# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/reportExcel/weekReport.js.map
|