customSale.js 6.3 KB

1
  1. (global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["admin/statistics/customSale"],{2288:function(t,e,n){"use strict";n.r(e);var i=n("e4c03"),o=n("5880");for(var a in o)["default"].indexOf(a)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(a);n("2626");var r,s=n("0095"),c=Object(s["a"])(o["default"],i["b"],i["c"],!1,null,"159fb798",null,!1,i["a"],r);e["default"]=c.exports},2626:function(t,e,n){"use strict";var i=n("aa30"),o=n.n(i);o.a},5880:function(t,e,n){"use strict";n.r(e);var i=n("6180"),o=n.n(i);for(var a in i)["default"].indexOf(a)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=o.a},6180:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=c(n("4838")),o=n("fd6a"),a=n("257f"),r=n("1b62"),s=n("7736");function c(t){return t&&t.__esModule?t:{default:t}}function u(t,e,n,i,o,a,r){try{var s=t[a](r),c=s.value}catch(u){return void n(u)}s.done?e(c):Promise.resolve(c).then(i,o)}function l(t){return function(){var e=this,n=arguments;return new Promise((function(i,o){var a=t.apply(e,n);function r(t){u(a,i,o,r,s,"next",t)}function s(t){u(a,i,o,r,s,"throw",t)}r(void 0)}))}}function f(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function h(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?f(Object(n),!0).forEach((function(e){p(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function p(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var d=(new Date).getMonth()+1<10?"0"+((new Date).getMonth()+1):(new Date).getMonth()+1,m="".concat((new Date).getFullYear(),"-").concat(d,"-").concat((new Date).getDate()),v=function(){n.e("components/app-wrapper-empty").then(function(){return resolve(n("c078"))}.bind(null,n)).catch(n.oe)},g=function(){n.e("components/plugin/selectList").then(function(){return resolve(n("e8a7"))}.bind(null,n)).catch(n.oe)},b=function(){n.e("components/module/shopSelect").then(function(){return resolve(n("868a"))}.bind(null,n)).catch(n.oe)},w=function(){n.e("components/module/dateSelect").then(function(){return resolve(n("f9d6"))}.bind(null,n)).catch(n.oe)},O=function(){n.e("components/pyh-rdtpicker/pyh-rdtpicker").then(function(){return resolve(n("97b1"))}.bind(null,n)).catch(n.oe)},S=function(){n.e("components/module/app-search").then(function(){return resolve(n("80f2"))}.bind(null,n)).catch(n.oe)},D={components:{SelectList:g,AppWrapperEmpty:v,DorpdownSelect:b,rangeDatePick:O,AppSearchModule:S,DateSelect:w},mixins:[r.list,r.selectShop],computed:h({},(0,s.mapGetters)(["getDictionariesInfo","getLoginInfo"])),data:function(){return{isShow:!1,customizationTime:"",menuTimeObj:"",menuShopObj:"",selectTimeId:"",shopId:"",itemId:"",selectListData:[{title:"时间",key:"time",default:"1",data:[{name:"下午",value:"1"}]},{title:"全部",key:"shopId",default:"01",data:[{name:"瑞景店",value:"01"},{name:"加州店",value:"02"}]}],nowTime:"",showTimeDropdown:!1,nowShop:"",showShopDropdown:!1,columns:[{name:"姓名",dataIndex:"name",color:"info"},{name:"开单额",dataIndex:"amount",color:"info",width:120,align:"center"},{name:"开单数",dataIndex:"num",color:"info",align:"center"}],dataList:[],params:{itemId:"",searchTime:"",startTime:"",endTime:"",shopId:""},profile:[],storageData:[],searchContent:""}},onPullDownRefresh:function(){this.resetList(),this.getList().then((function(e){t.stopPullDownRefresh()}))},onLoad:function(t){this.itemId=t.id,this.params.itemId=t.id;for(var e=[],n=this.getDictionariesInfo.dateDefaultOption,i=0;i<n.length;i++)e.push({name:n[i].name,id:n[i].value});this.menuTimeObj={title:"今天",titleChild:"时间",list:e},this.shopId=this.getLoginInfo.shopId},methods:h(h({},(0,s.mapActions)(["setUserShopAll"])),{},{searchFn:function(t){this.searchContent=t,this.filterStat()},filterStat:function(){var t=this,e=this;this.searchContent.length>0?(e.profile=[],e.storageData.forEach((function(n){var i=n.name&&n.name.indexOf(t.searchContent)>=0,o=n.py&&n.py.toLocaleUpperCase()||"",a=o.indexOf(t.searchContent.toLocaleUpperCase())>=0;(i||a)&&e.profile.push(n)}))):e.profile=e.storageData},selectShopSussess:function(t){this.params.shopId=t.selectItem.id,this.init()},selectSussess:function(t){this.params.selectTime=this.selectTimeId,1==t.custom?(this.isShow=!1,this.params.startTime=t.start,this.params.endTime=t.end,this.init()):this.init()},selectTime:function(){this.customizationTime=[m,m],this.isShow=!0},timeChange:function(t){this.isShow=!1,this.params.startTime=t[0],this.params.endTime=t[1],this.init()},timeCancel:function(t){this.isShow=!1},init:function(){var t=l(i.default.mark((function t(){return i.default.wrap((function(t){while(1)switch(t.prev=t.next){case 0:this.getList();case 1:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}(),getList:function(){var e=this,n=this;t.showLoading(),(0,o.getStatKhCgProfile)(this.params).then((function(i){t.hideLoading(),e.$util.isEmpty(i.data.list)?n.storageData=[]:(n.storageData=i.data.list,n.filterStat())}))},updateLevel:function(e){var n=e.customId,i=this,o=["大众会员","标准会员","黄金会员","钻石会员"];t.showActionSheet({itemList:o,success:function(t){var o=t.tapIndex;(0,a.changeLevel)({customId:n,level:o}).then((function(t){1==t.code&&(e.levelName=t.data.levelName,i.$msg(t.msg))})).catch((function(t){console.log("err",t)}))}})}})};e.default=D}).call(this,n("f3be")["default"])},aa30:function(t,e,n){},e4c03:function(t,e,n){"use strict";var i;n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i}));var o=function(){var t=this,e=t.$createElement,n=(t._self._c,t.__map(t.profile,(function(e,n){var i=t.__get_orig(e),o=parseFloat(e.num),a=parseFloat(e.amount);return{$orig:i,m0:o,m1:a}})));t.$mp.data=Object.assign({},{$root:{l0:n}})},a=[]},e86a:function(t,e,n){"use strict";(function(t){n("6cdc");i(n("4a15"));var e=i(n("2288"));function i(t){return t&&t.__esModule?t:{default:t}}t(e.default)}).call(this,n("f3be")["createPage"])}},[["e86a","common/runtime","common/vendor"]]]);