chunk-7f2638f8.74ca4c87.js 12 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-7f2638f8"],{"2c3e":function(t,e,a){var i=a("da84"),n=a("83ab"),r=a("9f7f").MISSED_STICKY,o=a("c6b6"),s=a("edd0"),c=a("69f3").get,l=RegExp.prototype,u=i.TypeError;n&&r&&s(l,"sticky",{configurable:!0,get:function(){if(this!==l){if("RegExp"===o(this))return!!c(this).sticky;throw u("Incompatible receiver, RegExp required")}}})},"4d63":function(t,e,a){var i=a("83ab"),n=a("da84"),r=a("e330"),o=a("94ca"),s=a("7156"),c=a("9112"),l=a("241c").f,u=a("3a9b"),d=a("44e7"),f=a("577e"),m=a("90d8"),h=a("9f7f"),p=a("aeb0"),g=a("cb2d"),v=a("d039"),b=a("1a2d"),_=a("69f3").enforce,w=a("2626"),y=a("b622"),x=a("fce3"),k=a("107c"),E=y("match"),$=n.RegExp,R=$.prototype,C=n.SyntaxError,O=r(R.exec),I=r("".charAt),S=r("".replace),j=r("".indexOf),M=r("".slice),D=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,V=/a/g,W=/a/g,L=(a=new $(V)!==V,h.MISSED_STICKY),T=h.UNSUPPORTED_Y;y=i&&(!a||L||x||k||v((function(){return W[E]=!1,$(V)!=V||$(W)==W||"/a/i"!=$(V,"i")})));if(o("RegExp",y)){function N(t,e){var a,i,n=u(R,this),r=d(t),o=void 0===e,l=[],h=t;if(!n&&r&&o&&t.constructor===N)return t;if((r||u(R,t))&&(t=t.source,o&&(e=m(h))),t=void 0===t?"":f(t),e=void 0===e?"":f(e),h=t,r=e=x&&"dotAll"in V&&(a=!!e&&-1<j(e,"s"))?S(e,/s/g,""):e,L&&"sticky"in V&&(i=!!e&&-1<j(e,"y"))&&T&&(e=S(e,/y/g,"")),k&&(t=(o=function(t){for(var e,a=t.length,i=0,n="",r=[],o={},s=!1,c=!1,l=0,u="";i<=a;i++){if("\\"===(e=I(t,i)))e+=I(t,++i);else if("]"===e)s=!1;else if(!s)switch(!0){case"["===e:s=!0;break;case"("===e:O(D,M(t,i+1))&&(i+=2,c=!0),n+=e,l++;continue;case">"===e&&c:if(""===u||b(o,u))throw new C("Invalid capture group name");o[u]=!0,c=!(r[r.length]=[u,l]),u="";continue}c?u+=e:n+=e}return[n,r]}(t))[0],l=o[1]),o=s($(t,e),n?this:R,N),(a||i||l.length)&&(e=_(o),a&&(e.dotAll=!0,e.raw=N(function(t){for(var e,a=t.length,i=0,n="",r=!1;i<=a;i++)"\\"===(e=I(t,i))?n+=e+I(t,++i):r||"."!==e?("["===e?r=!0:"]"===e&&(r=!1),n+=e):n+="[\\s\\S]";return n}(t),r)),i&&(e.sticky=!0),l.length&&(e.groups=l)),t!==h)try{c(o,"source",""===h?"(?:)":h)}catch(t){}return o}for(var z=l($),F=0;z.length>F;)p(N,$,z[F++]);(R.constructor=N).prototype=R,g(n,"RegExp",N,{constructor:!0})}w("RegExp")},"61f7":function(t,e,a){"use strict";a.d(e,"a",(function(){return r})),a.d(e,"c",(function(){return c})),a.d(e,"b",(function(){return l}));var i=a("fc11"),n=a("f3f3");function r(t,e){/(y+)/.test(e)&&(e=e.replace(RegExp.$1,(t.getFullYear()+"").substr(4-RegExp.$1.length)));var a,i,n={"M+":t.getMonth()+1,"d+":t.getDate(),"h+":t.getHours(),"m+":t.getMinutes(),"s+":t.getSeconds()};for(a in n)new RegExp("(".concat(a,")")).test(e)&&(i=n[a]+"",e=e.replace(RegExp.$1,1===RegExp.$1.length?i:("00"+i).substr(i.length)));return e}a("ac1f"),a("00b4"),a("5319"),a("4d63"),a("c607"),a("2c3e"),a("25f0"),a("498a"),a("d3b7"),a("b64b"),a("99af");var o={min:"%s最小长度为:min",max:"%s最大长度为:max",length:"%s长度必须为:length",range:"%s长度为:range",pattern:"$s格式错误"};function s(t,e){t.message=function(t){return e.replace("%s",t||"")}}function c(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return Object(n.a)({required:!0,message:t,type:"string"},e)}function l(t){return u.pattern(/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/,t)}s(c,"请输入%s"),s(l,"%s格式不正确");var u=Object.keys(o).reduce((function(t,e){return t[e]=function(t){var a=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"",r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},o="range"===e?{min:t[0],max:t[1]}:Object(i.a)({},e,t);return Object(n.a)(Object(n.a)({message:a.replace(":".concat(e),"range"===e?"".concat(t[0],"-").concat(t[1]):t),type:"string"},o),r)},s(t[e],o[e]),t}),{})},"7ea7":function(t,e,a){},"82f1":function(t,e,a){"use strict";a.r(e);var i=a("c964"),n=a("f3f3"),r=(a("96cf"),a("a434"),a("b7be")),o=a("2f62"),s=a("61f7");n={name:"index",filters:{formatDate:function(t){if(0!==t)return t=new Date(1e3*t),Object(s.a)(t,"yyyy-MM-dd hh:mm")}},data:function(){return{loading:!1,grid:{xl:7,lg:7,md:12,sm:24,xs:24},formValidate:{is_show:"",store_name:"",page:1,limit:15},value:"",columns1:[{title:"ID",key:"id",width:80},{title:"拼团图片",slot:"image",minWidth:90},{title:"拼团名称",key:"title",minWidth:130},{title:"原价",key:"ot_price",minWidth:100},{title:"拼团价",key:"price",minWidth:120},{title:"拼团人数",key:"count_people",minWidth:100},{title:"参与人数",key:"count_people_all",minWidth:100},{title:"成团数量",key:"count_people_pink",minWidth:100},{title:"限量",key:"quota_show",minWidth:100},{title:"限量剩余",key:"quota",minWidth:100},{title:"活动状态",slot:"start_name",minWidth:100},{title:"结束时间",slot:"stop_time",minWidth:150},{title:"上架状态",slot:"is_show",minWidth:120},{title:"操作",slot:"action",fixed:"right",minWidth:170}],tableList:[],total:0,statisticsList:[]}},computed:Object(n.a)(Object(n.a)({},Object(o.e)("media",["isMobile"])),{},{labelWidth:function(){return this.isMobile?void 0:80},labelPosition:function(){return this.isMobile?"top":"left"}}),activated:function(){this.getList()},methods:{exports:function(){var t=this,e=this.formValidate;e={is_show:e.is_show,store_name:e.store_name};Object(r.pb)(e).then((function(t){location.href=t.data[0]})).catch((function(e){t.$Message.error(e.msg)}))},add:function(){this.$router.push({path:"/admin/marketing/store_combination/create"})},edit:function(t){this.$router.push({path:"/admin/marketing/store_combination/create/"+t.id+"/0"})},copy:function(t){this.$router.push({path:"/admin/marketing/store_combination/create/"+t.id+"/1"})},del:function(t,e,a){var i=this;e={title:e,num:a,url:"marketing/combination/".concat(t.id),method:"DELETE",ids:""};this.$modalSure(e).then((function(t){i.$Message.success(t.msg),i.tableList.splice(a,1)})).catch((function(t){i.$Message.error(t.msg)}))},viewInfo:function(t){this.$router.push({path:"/admin/marketing/store_combination/statistics/"+t.id})},getList:function(){var t=this;this.loading=!0,Object(r.j)(this.formValidate).then(function(){var e=Object(i.a)(regeneratorRuntime.mark((function e(a){var i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:i=a.data,t.tableList=i.list,t.total=a.data.count,t.loading=!1;case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){t.loading=!1,t.$Message.error(e.msg)}))},pageChange:function(t){this.formValidate.page=t,this.getList()},userSearchs:function(){this.formValidate.page=1,this.getList()},onchangeIsShow:function(t){var e=this;t={id:t.id,status:t.is_show};Object(r.k)(t).then(function(){var t=Object(i.a)(regeneratorRuntime.mark((function t(a){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e.$Message.success(a.msg);case 1:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.$Message.error(t.msg)}))}}},a("abf5"),o=a("2877"),a=Object(o.a)(n,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("div",{staticClass:"i-layout-page-header"},[a("div",{staticClass:"i-layout-page-header"},[a("span",{staticClass:"ivu-page-header-title"},[t._v(t._s(t.$route.meta.title))])])]),a("Card",{staticClass:"ivu-mt",attrs:{bordered:!1,"dis-hover":""}},[a("Form",{ref:"formValidate",attrs:{model:t.formValidate,"label-width":t.labelWidth,"label-position":t.labelPosition},nativeOn:{submit:function(t){t.preventDefault()}}},[a("Row",{attrs:{type:"flex",gutter:24}},[a("Col",t._b({},"Col",t.grid,!1),[a("FormItem",{attrs:{label:"拼团状态:",clearable:""}},[a("Select",{attrs:{placeholder:"请选择",clearable:""},on:{"on-change":t.userSearchs},model:{value:t.formValidate.is_show,callback:function(e){t.$set(t.formValidate,"is_show",e)},expression:"formValidate.is_show"}},[a("Option",{attrs:{value:1}},[t._v("开启")]),a("Option",{attrs:{value:0}},[t._v("关闭")])],1)],1)],1),a("Col",t._b({},"Col",t.grid,!1),[a("FormItem",{attrs:{label:"商品搜索:",prop:"store_name","label-for":"store_name"}},[a("Input",{attrs:{search:"","enter-button":"",placeholder:"请输入请输入商品名称/ID"},on:{"on-search":t.userSearchs},model:{value:t.formValidate.store_name,callback:function(e){t.$set(t.formValidate,"store_name",e)},expression:"formValidate.store_name"}})],1)],1)],1),a("Row",{attrs:{type:"flex"}},[a("Button",{directives:[{name:"auth",rawName:"v-auth",value:["marketing-store_combination-create"],expression:"['marketing-store_combination-create']"}],staticClass:"bnt mr15",attrs:{type:"primary",icon:"md-add"},on:{click:t.add}},[t._v("添加拼团商品")]),a("Button",{directives:[{name:"auth",rawName:"v-auth",value:["export-storeCombination"],expression:"['export-storeCombination']"}],staticClass:"export",attrs:{icon:"ios-share-outline"},on:{click:t.exports}},[t._v("导出")])],1)],1),a("Table",{staticClass:"mt25",attrs:{columns:t.columns1,data:t.tableList,loading:t.loading,"highlight-row":"","no-userFrom-text":"暂无数据","no-filtered-userFrom-text":"暂无筛选结果"},scopedSlots:t._u([{key:"is_fail",fn:function(t){var e=t.row;return t.index,[1===e.is_fail?a("Icon",{attrs:{type:"md-checkmark",color:"#0092DC",size:"14"}}):a("Icon",{attrs:{type:"md-close",color:"#ed5565",size:"14"}})]}},{key:"image",fn:function(t){var e=t.row;return t.index,[a("div",{directives:[{name:"viewer",rawName:"v-viewer"}],staticClass:"tabBox_img"},[a("img",{directives:[{name:"lazy",rawName:"v-lazy",value:e.image,expression:"row.image"}]})])]}},{key:"stop_time",fn:function(e){var i=e.row;return e.index,[a("span",[t._v(" "+t._s(t._f("formatDate")(i.stop_time)))])]}},{key:"is_show",fn:function(e){var i=e.row;return e.index,[a("i-switch",{attrs:{value:i.is_show,"true-value":1,"false-value":0,disabled:!!i.stop_status,size:"large"},on:{"on-change":function(e){return t.onchangeIsShow(i)}},model:{value:i.is_show,callback:function(e){t.$set(i,"is_show",e)},expression:"row.is_show"}},[a("span",{attrs:{slot:"open"},slot:"open"},[t._v("开启")]),a("span",{attrs:{slot:"close"},slot:"close"},[t._v("关闭")])])]}},{key:"start_name",fn:function(e){var i=e.row;return e.index,[a("Tag",{directives:[{name:"show",rawName:"v-show",value:"进行中"===i.start_name,expression:"row.start_name === '进行中'"}],attrs:{color:"blue"}},[t._v("进行中")]),a("Tag",{directives:[{name:"show",rawName:"v-show",value:"未开始"===i.start_name,expression:"row.start_name === '未开始'"}],attrs:{color:"volcano"}},[t._v("未开始")]),a("Tag",{directives:[{name:"show",rawName:"v-show",value:"已结束"===i.start_name,expression:"row.start_name === '已结束'"}],attrs:{color:"cyan"}},[t._v("已结束")])]}},{key:"action",fn:function(e){var i=e.row,n=e.index;return[0===i.stop_status?a("a",{on:{click:function(e){return t.edit(i)}}},[t._v("编辑")]):t._e(),0===i.stop_status?a("Divider",{attrs:{type:"vertical"}}):t._e(),a("a",{on:{click:function(e){return t.copy(i)}}},[t._v("复制")]),a("Divider",{attrs:{type:"vertical"}}),a("a",{on:{click:function(e){return t.del(i,"删除拼团商品",n)}}},[t._v("删除")]),a("Divider",{attrs:{type:"vertical"}}),a("a",{on:{click:function(e){return t.viewInfo(i)}}},[t._v("统计")])]}}])}),a("div",{staticClass:"acea-row row-right page"},[a("Page",{attrs:{total:t.total,current:t.formValidate.page,"show-elevator":"","show-total":"","page-size":t.formValidate.limit},on:{"on-change":t.pageChange}})],1)],1)],1)}),[],!1,null,"3997dfea",null);e.default=a.exports},abf5:function(t,e,a){"use strict";var i=a("7ea7");a.n(i).a},c607:function(t,e,a){var i=a("da84"),n=a("83ab"),r=a("fce3"),o=a("c6b6"),s=a("edd0"),c=a("69f3").get,l=RegExp.prototype,u=i.TypeError;n&&r&&s(l,"dotAll",{configurable:!0,get:function(){if(this!==l){if("RegExp"===o(this))return!!c(this).dotAll;throw u("Incompatible receiver, RegExp required")}}})},edd0:function(t,e,a){var i=a("13d2"),n=a("9bf2");t.exports=function(t,e,a){return a.get&&i(a.get,e,{getter:!0}),a.set&&i(a.set,e,{setter:!0}),n.f(t,e,a)}}}]);