chunk-845caf84.5e2f2d05.js 8.63 KB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-845caf84"],{"0bf2":function(e,t,a){"use strict";a("d46e")},"867e":function(e,t,a){"use strict";a.d(t,"b",(function(){return r})),a.d(t,"c",(function(){return i})),a.d(t,"g",(function(){return o})),a.d(t,"e",(function(){return s})),a.d(t,"a",(function(){return l})),a.d(t,"f",(function(){return c})),a.d(t,"d",(function(){return h}));var n=a("b775");function r(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-gold-triangle-statistics-list",method:"post",data:e})}function i(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-personal-performance-statistics-list",method:"post",data:e})}function o(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-tech-performance-statistics-list",method:"post",data:e})}function s(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-store-consume-performance-statistics-list",method:"post",data:e})}function l(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-department-consume-performance-statistics-list",method:"post",data:e})}function c(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-store-total-performance-statistics-list",method:"post",data:e})}function h(e){return Object(n["a"])({url:"/api/Extend/LqStatistics/get-salary-statistics-list",method:"post",data:e})}},d46e:function(e,t,a){},e437:function(e,t,a){"use strict";a.r(t);var n=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"personal-performance-statistics-container"},[a("el-card",{staticClass:"search-card"},[a("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[a("span",[a("i",{staticClass:"el-icon-user"}),e._v(" 健康师个人开单业绩统计")])]),a("div",{staticClass:"search-form"},[a("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:e.searchForm}},[a("el-form-item",{attrs:{label:"统计月份"}},[a("el-date-picker",{attrs:{type:"month",placeholder:"选择月份",format:"yyyy年MM月","value-format":"yyyyMM",clearable:!1},on:{change:e.handleSearch},model:{value:e.searchForm.statisticsMonth,callback:function(t){e.$set(e.searchForm,"statisticsMonth",t)},expression:"searchForm.statisticsMonth"}})],1),a("el-form-item",{attrs:{label:"员工姓名"}},[a("el-input",{attrs:{placeholder:"请输入员工姓名",clearable:""},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSearch(t)}},model:{value:e.searchForm.employeeName,callback:function(t){e.$set(e.searchForm,"employeeName",t)},expression:"searchForm.employeeName"}})],1),a("el-form-item",{attrs:{label:"门店名称"}},[a("el-input",{attrs:{placeholder:"请输入门店名称",clearable:""},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSearch(t)}},model:{value:e.searchForm.storeName,callback:function(t){e.$set(e.searchForm,"storeName",t)},expression:"searchForm.storeName"}})],1),a("el-form-item",{attrs:{label:"岗位"}},[a("el-input",{attrs:{placeholder:"请输入岗位",clearable:""},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.handleSearch(t)}},model:{value:e.searchForm.position,callback:function(t){e.$set(e.searchForm,"position",t)},expression:"searchForm.position"}})],1),a("el-form-item",[a("el-button",{attrs:{type:"primary",loading:e.loading},on:{click:e.handleSearch}},[a("i",{staticClass:"el-icon-search"}),e._v(" 查询\n                    ")]),a("el-button",{on:{click:e.handleReset}},[a("i",{staticClass:"el-icon-refresh"}),e._v(" 重置\n                    ")])],1)],1)],1)]),a("el-card",{staticClass:"table-card"},[a("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[a("span",[a("i",{staticClass:"el-icon-s-grid"}),e._v(" 健康师个人开单业绩列表")])]),a("div",{staticClass:"table-container"},[a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],staticStyle:{width:"100%"},attrs:{data:e.tableData,"element-loading-text":"加载中...",height:e.tableHeight,border:"",stripe:""}},[a("el-table-column",{attrs:{prop:"EmployeeName",label:"员工姓名",width:"120",fixed:"left"}}),a("el-table-column",{attrs:{prop:"StoreName",label:"门店名称",width:"150",fixed:"left"}}),a("el-table-column",{attrs:{prop:"Position",label:"岗位",width:"100",fixed:"left"}}),a("el-table-column",{attrs:{prop:"GoldTriangleTeam",label:"金三角战队",width:"120",fixed:"left"}}),a("el-table-column",{attrs:{prop:"TotalPerformance",label:"总业绩",width:"100",align:"right"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n                        "+e._s(e.formatMoney(t.row.TotalPerformance))+"\n                    ")]}}])}),a("el-table-column",{attrs:{prop:"FirstOrderPerformance",label:"首单业绩",width:"100",align:"right"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n                        "+e._s(e.formatMoney(t.row.FirstOrderPerformance))+"\n                    ")]}}])}),a("el-table-column",{attrs:{prop:"UpgradeOrderPerformance",label:"升单业绩",width:"100",align:"right"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n                        "+e._s(e.formatMoney(t.row.UpgradeOrderPerformance))+"\n                    ")]}}])}),a("el-table-column",{attrs:{prop:"FirstOrderCount",label:"首开单数量",width:"100",align:"right"}}),a("el-table-column",{attrs:{prop:"UpgradeOrderCount",label:"升单数量",width:"100",align:"right"}}),a("el-table-column",{attrs:{prop:"OrderCount",label:"订单总数",width:"100",align:"right"}}),a("el-table-column",{attrs:{prop:"CreateTime",label:"创建时间",width:"150",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v("\n                        "+e._s(e.formatDateTime(t.row.CreateTime))+"\n                    ")]}}])})],1),a("div",{staticClass:"pagination-container"},[a("el-pagination",{attrs:{"current-page":e.pagination.pageIndex,"page-sizes":[10,20,50,100],"page-size":e.pagination.pageSize,total:e.pagination.total,layout:"total, sizes, prev, pager, next, jumper"},on:{"size-change":e.handleSizeChange,"current-change":e.handleCurrentChange}})],1)],1)])],1)},r=[],i=(a("c5f6"),a("96cf"),a("1da1")),o=(a("f576"),a("867e")),s={name:"PersonalPerformanceStatistics",data:function(){return{loading:!1,tableData:[],tableHeight:400,searchForm:{statisticsMonth:this.getCurrentMonth(),employeeName:"",storeName:"",position:""},pagination:{pageIndex:1,pageSize:20,total:0}}},mounted:function(){this.calculateTableHeight(),this.handleSearch(),window.addEventListener("resize",this.calculateTableHeight)},beforeDestroy:function(){window.removeEventListener("resize",this.calculateTableHeight)},methods:{getCurrentMonth:function(){var e=new Date,t=e.getFullYear(),a=String(e.getMonth()+1).padStart(2,"0");return"".concat(t).concat(a)},calculateTableHeight:function(){var e=this;this.$nextTick((function(){var t=e.$el;if(t){var a=t.clientHeight,n=t.querySelector(".search-card"),r=t.querySelector(".table-card"),i=0;n&&(i=n.offsetHeight+20);var o=a-i-100,s=Math.max(250,o);r&&(r.style.height=s+"px");var l=t.querySelector(".table-container");if(l){var c=50,h=30,u=s-c-h;l.style.height=u+"px";var d=50,p=10;e.tableHeight=Math.max(100,u-d-p)}}}))},handleSearch:function(){var e=Object(i["a"])(regeneratorRuntime.mark((function e(){var t,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return this.loading=!0,e.prev=1,t={pageIndex:this.pagination.pageIndex,pageSize:this.pagination.pageSize,statisticsMonth:this.searchForm.statisticsMonth,employeeName:this.searchForm.employeeName,storeName:this.searchForm.storeName,position:this.searchForm.position},e.next=5,Object(o["c"])(t);case 5:a=e.sent,this.tableData=a.data.list||[],this.pagination.total=a.data.pagination.total||0,e.next=13;break;case 10:e.prev=10,e.t0=e["catch"](1),this.$message.error("查询失败: "+e.t0.message);case 13:return e.prev=13,this.loading=!1,e.finish(13);case 16:case"end":return e.stop()}}),e,this,[[1,10,13,16]])})));function t(){return e.apply(this,arguments)}return t}(),handleReset:function(){this.searchForm={statisticsMonth:this.getCurrentMonth(),employeeName:"",storeName:"",position:""},this.pagination.pageIndex=1,this.handleSearch()},handleSizeChange:function(e){this.pagination.pageSize=e,this.pagination.pageIndex=1,this.handleSearch()},handleCurrentChange:function(e){this.pagination.pageIndex=e,this.handleSearch()},formatMoney:function(e){return null===e||void 0===e?"0.00":Number(e).toLocaleString("zh-CN",{minimumFractionDigits:2,maximumFractionDigits:2})},formatDateTime:function(e){return e?new Date(e).toLocaleString("zh-CN"):"-"}}},l=s,c=(a("0bf2"),a("2877")),h=Object(c["a"])(l,n,r,!1,null,"4f0d8f35",null);t["default"]=h.exports}}]);