chunk-42ebd3f9.b2542002.js 11 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-42ebd3f9"],{"0b65":function(e,t,n){"use strict";t.a={shortcuts:[{text:"今天",value:function(){var e=new Date,t=new Date;return t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate())),[t,e]}},{text:"昨天",value:function(){var e=new Date,t=new Date;return t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-1))),e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-1))),[t,e]}},{text:"最近7天",value:function(){var e=new Date,t=new Date;return t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-6))),[t,e]}},{text:"最近30天",value:function(){var e=new Date,t=new Date;return t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),(new Date).getDate()-29))),[t,e]}},{text:"上月",value:function(){var e=new Date,t=new Date,n=new Date(t.getFullYear(),t.getMonth(),0).getDate();return t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth()-1,1))),e.setTime(e.setTime(new Date((new Date).getFullYear(),(new Date).getMonth()-1,n))),[t,e]}},{text:"本月",value:function(){var e=new Date,t=new Date;return t.setTime(t.setTime(new Date((new Date).getFullYear(),(new Date).getMonth(),1))),[t,e]}},{text:"本年",value:function(){var e=new Date,t=new Date;return t.setTime(t.setTime(new Date((new Date).getFullYear(),0,1))),[t,e]}}]}},"5dd9":function(e,t,n){"use strict";var a=n("fd59");n.n(a).a},"61f7":function(e,t,n){"use strict";function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function r(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(n,!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(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}function s(e,t){/(y+)/.test(t)&&(t=t.replace(RegExp.$1,(e.getFullYear()+"").substr(4-RegExp.$1.length)));var n={"M+":e.getMonth()+1,"d+":e.getDate(),"h+":e.getHours(),"m+":e.getMinutes(),"s+":e.getSeconds()};for(var a in n)if(new RegExp("(".concat(a,")")).test(t)){var r=n[a]+"";t=t.replace(RegExp.$1,1===RegExp.$1.length?r:o(r))}return t}function o(e){return("00"+e).substr(e.length)}n.d(t,"a",(function(){return s})),n.d(t,"c",(function(){return l})),n.d(t,"b",(function(){return m}));var c={min:"%s最小长度为:min",max:"%s最大长度为:max",length:"%s长度必须为:length",range:"%s长度为:range",pattern:"$s格式错误"},u=function(e,t){e.message=function(e){return t.replace("%s",e||"")}};function l(e){return r({required:!0,message:e,type:"string"},arguments.length>1&&void 0!==arguments[1]?arguments[1]:{})}function m(e){return f.pattern(/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/,e)}u(l,"请输入%s"),u(m,"%s格式不正确");var f=Object.keys(c).reduce((function(e,t){return e[t]=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s="range"===t?{min:e[0],max:e[1]}:i({},t,e);return r({message:n.replace(":".concat(t),"range"===t?"".concat(e[0],"-").concat(e[1]):e),type:"string"},s,{},a)},u(e[t],c[t]),e}),{})},9460:function(e,t,n){},a584:function(e,t,n){"use strict";var a;function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var i=(r(a={name:"cards",data:function(){return{}},props:{cardLists:Array}},"data",(function(){return{}})),r(a,"methods",{}),r(a,"created",(function(){})),a),s=(n("5dd9"),n("2877")),o=Object(s.a)(i,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("Row",{staticClass:"ivu-mt",attrs:{type:"flex",align:"middle",gutter:16}},e._l(e.cardLists,(function(t,a){return n("Col",{key:a,staticClass:"ivu-mb",attrs:{xs:24,sm:24,md:24,lg:12,xl:8,xxl:{span:t.col}}},[n("Card",{staticClass:"card_cent",attrs:{shadow:"",padding:0}},[n("div",{staticClass:"card_box"},[n("div",{staticClass:"card_box_cir",class:{one:a%5==0,two:a%5==1,three:a%5==2,four:a%5==3,five:a%5==4}},[n("div",{staticClass:"card_box_cir1",class:{one1:a%5==0,two1:a%5==1,three1:a%5==2,four1:a%5==3,five1:a%5==4}},[t.type?n("span",{staticClass:"iconfont",class:t.className}):n("Icon",{attrs:{type:t.className}})],1)]),n("div",{staticClass:"card_box_txt"},[n("span",{staticClass:"sp1",domProps:{textContent:e._s(t.count||0)}}),n("span",{staticClass:"sp2",domProps:{textContent:e._s(t.name)}})])])])],1)})),1)],1)}),[],!1,null,"4e72687f",null);t.a=o.exports},b430:function(e,t,n){"use strict";n.r(t);var a=n("a34a"),r=n.n(a),i=n("2f62"),s=n("b7be"),o=n("61f7"),c=n("a584"),u=n("2e83"),l=n("0b65");function m(e,t,n,a,r,i,s){try{var o=e[i](s),c=o.value}catch(e){return void n(e)}o.done?t(c):Promise.resolve(c).then(a,r)}function f(e){return function(){var t=this,n=arguments;return new Promise((function(a,r){var i=e.apply(t,n);function s(e){m(i,a,r,s,o,"next",e)}function o(e){m(i,a,r,s,o,"throw",e)}s(void 0)}))}}function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var g={name:"userPoint",components:{cardsData:c.a},filters:{formatDate:function(e){if(0!==e){var t=new Date(1e3*e);return Object(o.a)(t,"yyyy-MM-dd hh:mm")}}},data:function(){return{cardLists:[],loading:!1,options:l.a,delfromData:{},columns1:[{title:"ID",key:"id",width:80},{title:"标题",key:"title",minWidth:130},{title:"变动后积分",key:"balance",minWidth:100},{title:"积分变动",slot:"change_number",minWidth:100},{title:"备注",key:"mark",minWidth:100},{title:"用户微信昵称",key:"nickname",minWidth:150},{title:"添加时间",key:"add_time",minWidth:100}],tableList:[],grid:{xl:7,lg:10,md:12,sm:24,xs:24},tableFrom:{start_time:"",end_time:"",nickname:"",page:1,limit:15},timeVal:[],total:0}},computed:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(n,!0).forEach((function(t){p(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},Object(i.e)("admin/layout",["isMobile"]),{labelWidth:function(){return this.isMobile?void 0:96},labelPosition:function(){return this.isMobile?"top":"right"}}),created:function(){this.getList(),this.getStatistics()},methods:{getStatistics:function(){var e=this;Object(s.hb)().then(function(){var t=f(r.a.mark((function t(n){var a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:n.data,a=["ios-help-buoy","md-create","ios-help-buoy-outline","md-help-buoy"],e.cardLists=n.data.res.map((function(e,t){return e.className=a[t],e}));case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.$Message.error(t.msg)}))},onchangeTime:function(e){this.timeVal=e,this.tableFrom.start_time=e[0],this.tableFrom.end_time=e[1],this.tableFrom.page=1,this.getList()},getList:function(){var e=this;this.loading=!0,Object(s.cb)(this.tableFrom).then(function(){var t=f(r.a.mark((function t(n){var a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:a=n.data,e.tableList=a.list,e.total=n.data.count,e.loading=!1;case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.loading=!1,e.$Message.error(t.msg)}))},pageChange:function(e){this.tableFrom.page=e,this.getList()},userSearchs:function(){this.tableFrom.page=1,this.getList()},exports:function(){var e=f(r.a.mark((function e(){var t,n,a,i,s,o,c;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=[],n=[],a=[],i="",(s=JSON.parse(JSON.stringify(this.tableFrom))).page=1,o=0;case 4:if(!(o<s.page+1)){e.next=21;break}return e.next=7,this.getExcelData(s);case 7:if(c=e.sent,i||(i=c.filename),n.length||(n=c.filekey),t.length||(t=c.header),!c.export.length){e.next=16;break}a=a.concat(c.export),s.page++,e.next=18;break;case 16:return Object(u.a)(t,n,i,a),e.abrupt("return");case 18:o++,e.next=4;break;case 21:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}(),getExcelData:function(e){return new Promise((function(t,n){Object(s.Gb)(e).then((function(e){return t(e.data)}))}))}}},b=(n("c6b6"),n("2877")),h=Object(b.a)(g,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":"",padding:0}},[n("div",{staticClass:"new_card_pd"},[n("Form",{ref:"tableFrom",attrs:{inline:"",model:e.tableFrom,"label-width":e.labelWidth,"label-position":e.labelPosition},nativeOn:{submit:function(e){e.preventDefault()}}},[n("FormItem",{attrs:{label:"搜索:","label-for":"store_name"}},[n("Input",{staticClass:"input-add",attrs:{placeholder:"请输入用户ID,标题"},on:{"on-search":e.userSearchs},model:{value:e.tableFrom.nickname,callback:function(t){e.$set(e.tableFrom,"nickname",t)},expression:"tableFrom.nickname"}})],1),n("FormItem",{attrs:{label:"选择时间:","label-for":"user_time"}},[n("DatePicker",{staticClass:"input-add mr14",attrs:{editable:!1,clearable:"",value:e.timeVal,format:"yyyy/MM/dd",type:"datetimerange",placement:"bottom-start",placeholder:"选择时间",options:e.options},on:{"on-change":e.onchangeTime},model:{value:e.timeVal,callback:function(t){e.timeVal=t},expression:"timeVal"}}),n("Button",{staticClass:"mr10",attrs:{type:"primary"},on:{click:function(t){return e.userSearchs()}}},[e._v("查询")]),n("Button",{directives:[{name:"auth",rawName:"v-auth",value:["export-userPoint"],expression:"['export-userPoint']"}],staticClass:"export",on:{click:e.exports}},[e._v("导出")])],1)],1)],1)]),e.cardLists.length>=0?n("cards-data",{attrs:{cardLists:e.cardLists}}):e._e(),n("Card",{staticClass:"ive-mt",attrs:{bordered:!1,"dis-hover":""}},[n("Table",{ref:"table",attrs:{columns:e.columns1,data:e.tableList,loading:e.loading,"highlight-row":"","no-userFrom-text":"暂无数据","no-filtered-userFrom-text":"暂无筛选结果"},scopedSlots:e._u([{key:"change_number",fn:function(t){var n=t.row;return[e._v("\n "+e._s(n.pm>0?n.number:-n.number)+"\n ")]}}])}),n("div",{staticClass:"acea-row row-right page"},[n("Page",{attrs:{total:e.total,current:e.tableFrom.page,"show-elevator":"","show-total":"","page-size":e.tableFrom.limit},on:{"on-change":e.pageChange}})],1)],1)],1)}),[],!1,null,"18d5b731",null);t.default=h.exports},c6b6:function(e,t,n){"use strict";var a=n("9460");n.n(a).a},fd59:function(e,t,n){}}]);