| 1 |
- (window.webpackJsonp=window.webpackJsonp||[]).push([[36,5,10,19,20],{498:function(t,e,n){var content=n(502);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,n(21).default)("1df0c15c",content,!0,{sourceMap:!1})},499:function(t,e,n){"use strict";n(22),n(65);e.a={head:function(){var t=this.$store.getters.headerMeta;return{title:t.title,link:[{rel:"icon",type:"image/x-icon",href:t.ico}],meta:[{hid:"description",name:"description",content:t.description},{hid:"keywords",name:"keywords",content:t.keywords}]}}}},500:function(t,e,n){"use strict";n.r(e);n(309);var o={data:function(){return{priceSlice:{}}},components:{},props:{firstSize:{type:Number,default:14},secondSize:{type:Number,default:14},color:{type:String},weight:{type:[String,Number],default:400},price:{type:[String,Number],default:""},showSubscript:{type:Boolean,default:!0},subscriptSize:{type:Number,default:14},lineThrough:{type:Boolean,default:!1}},created:function(){this.priceFormat()},watch:{price:function(t){this.priceFormat()}},methods:{priceFormat:function(){var t=this.price,e={};null!==t&&(t=parseFloat(t),t=String(t).split("."),e.first=t[0],e.second=t[1],this.priceSlice=e)}}},r=(n(501),n(9)),component=Object(r.a)(o,(function(){var t=this,e=t._self._c;return e("span",{class:(t.lineThrough?"line-through":"")+"price-format",style:{color:t.color,"font-weight":t.weight}},[t.showSubscript?e("span",{style:{"font-size":t.subscriptSize+"px","margin-right":"1px"}},[t._v("¥")]):t._e(),t._v(" "),e("span",{style:{"font-size":t.firstSize+"px","margin-right":"1px"}},[t._v(t._s(t.priceSlice.first))]),t._v(" "),t.priceSlice.second?e("span",{style:{"font-size":t.secondSize+"px"}},[t._v("."+t._s(t.priceSlice.second))]):t._e()])}),[],!1,null,null,null);e.default=component.exports},501:function(t,e,n){"use strict";n(498)},502:function(t,e,n){var o=n(20)((function(i){return i[1]}));o.push([t.i,".price-format{align-items:baseline;display:flex}",""]),o.locals={},t.exports=o},504:function(t,e,n){var content=n(506);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,n(21).default)("36820b1b",content,!0,{sourceMap:!1})},505:function(t,e,n){"use strict";n(504)},506:function(t,e,n){var o=n(20)((function(i){return i[1]}));o.push([t.i,".null-data[data-v-847c0814]{padding:100px}.null-data .img-null[data-v-847c0814]{height:150px;width:150px}",""]),o.locals={},t.exports=o},508:function(t,e,n){"use strict";n.r(e);var o={components:{},props:{img:{type:String},text:{type:String,default:"暂无数据"},imgStyle:{type:String,default:""}},methods:{}},r=(n(505),n(9)),component=Object(r.a)(o,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"bg-white flex-col col-center null-data"},[e("img",{staticClass:"img-null",style:t.imgStyle,attrs:{src:t.img,alt:""}}),t._v(" "),e("div",{staticClass:"muted m-t-8"},[t._v(t._s(t.text))])])}),[],!1,null,"847c0814",null);e.default=component.exports},509:function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"a",(function(){return r}));n(22),n(65),n(69),n(70),n(32),n(38),n(49),n(50),n(51),n(19),n(106),n(67),n(13);var o=function(t){var time=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3,e=arguments.length>2?arguments[2]:void 0,n=new Date(0).getTime();return function(){var o=(new Date).getTime();if(o-n>time){for(var r=arguments.length,c=new Array(r),l=0;l<r;l++)c[l]=arguments[l];t.apply(e,c),n=o}}};var r=function(t){var e=document.createElement("input");e.setAttribute("value",t),document.body.appendChild(e),e.select();try{if(document.execCommand("copy"))return Promise.resolve();throw new Error}catch(t){return Promise.reject(t)}finally{document.body.removeChild(e)}}},510:function(t,e,n){var content=n(517);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,n(21).default)("784a15af",content,!0,{sourceMap:!1})},514:function(t,e,n){var content=n(528);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,n(21).default)("71c4f711",content,!0,{sourceMap:!1})},515:function(t,e,n){"use strict";n.d(e,"a",(function(){return l}));var o=n(146);var r=n(207),c=n(107);function l(t){return function(t){if(Array.isArray(t))return Object(o.a)(t)}(t)||Object(r.a)(t)||Object(c.a)(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},516:function(t,e,n){"use strict";n(510)},517:function(t,e,n){var o=n(20)((function(i){return i[1]}));o.push([t.i,".ad-item[data-v-127365e2]{cursor:pointer;height:100%;width:100%}",""]),o.locals={},t.exports=o},522:function(t,e,n){"use strict";n.r(e);n(22),n(26),n(33),n(34),n(25),n(13),n(24);var o=n(10),r=(n(204),n(509),n(14));function c(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}var l={components:{},props:{item:{type:Object,default:function(){return{}}}},computed:function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?c(Object(n),!0).forEach((function(e){Object(o.a)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},Object(r.c)(["ossDomain"])),methods:{goPage:function(t){var e=t.link,n=e.type,path=e.path,o=e.params;switch(n){case"goods":case"seckill":case"category":path+="?id=".concat(o.id),this.$router.push({path:path});break;default:this.$router.push({path:path})}}}},d=l,f=(n(516),n(9)),component=Object(f.a)(d,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"ad-item",on:{click:function(e){return e.stopPropagation(),t.goPage(t.item)}}},[t.ossDomain&&t.item.url?e("el-image",{staticStyle:{width:"100%",height:"100%"},attrs:{src:t.$getImageUri(t.item.url)}}):t._e()],1)}),[],!1,null,"127365e2",null);e.default=component.exports},526:function(t,e,n){t.exports=n.p+"img/coupons_img_receive.7169d0c.png"},527:function(t,e,n){"use strict";n(514)},528:function(t,e,n){var o=n(20),r=n(208),c=n(529),l=n(530),d=o((function(i){return i[1]})),f=r(c),h=r(l);d.push([t.i,".coupons-list[data-v-15fa95b0]{flex-wrap:wrap;padding:0 18px;position:relative}.coupons-list .item[data-v-15fa95b0]{cursor:pointer;margin-bottom:20px;margin-right:16px;position:relative}.coupons-list .item .info[data-v-15fa95b0]{background:url("+f+") no-repeat;background-size:100%;height:80px;padding:0 10px;width:240px}.coupons-list .item .info.gray[data-v-15fa95b0]{background-image:url("+h+")}.coupons-list .item .info .info-hd[data-v-15fa95b0]{overflow:hidden}.coupons-list .item .tips[data-v-15fa95b0]{background-color:#f2f2f2;height:30px;padding:0 8px;position:relative}.coupons-list .item .tips .tips-con[data-v-15fa95b0]{background-color:#f2f2f2;left:0;padding:10px;position:absolute;top:30px;width:100%;z-index:99}.coupons-list .item .receice[data-v-15fa95b0]{height:45px;position:absolute;right:0;top:0;width:58px}.coupons-list .item .choose[data-v-15fa95b0]{background-color:#ffe72c;color:#007b44;padding:1px 5px;position:absolute;right:0;top:0}.coupons-list .more[data-v-15fa95b0]{bottom:20px;cursor:pointer;position:absolute;right:30px}",""]),d.locals={},t.exports=d},529:function(t,e,n){t.exports=n.p+"img/bg_coupon_s.7cd7066.png"},530:function(t,e,n){t.exports=n.p+"img/bg_coupon.dc72a74.png"},533:function(t,e,n){"use strict";n.r(e);n(32),n(22),n(26),n(33),n(34),n(25);var o=n(515),r=n(7),c=n(10),l=(n(48),n(68),n(309),n(13),n(24),n(14));function d(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}function f(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?d(Object(n),!0).forEach((function(e){Object(c.a)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}var h={props:{list:{type:Array,default:function(){return[]}},type:{type:Number},showMore:{type:Boolean,default:!1}},data:function(){return{showTips:[],couponsList:[],id:"",isMore:!1}},methods:f(f({},Object(l.b)(["getPublicData"])),{},{onHandle:function(t){switch(this.id=t,this.type){case 0:case 1:case 2:break;case 3:this.getCoupon();break;case 4:this.selectId==t&&(this.id=""),this.$emit("use",this.id),this.selectId=this.id}},getCoupon:function(){var t=this;return Object(r.a)(regeneratorRuntime.mark((function e(){var n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.$post("coupon/receive",{id:t.id});case 2:n=e.sent,n.msg,1==n.code&&(t.getPublicData(),t.$emit("reflash"));case 6:case"end":return e.stop()}}),e)})))()},onShowTips:function(t){var e=this.showTips;this.showTips[t]=e[t]?0:1,this.showTips=Object.assign([],this.showTips)},changeShow:function(){var t=this;this.isMore=!this.isMore,this.list.forEach((function(e,n){e.isShow=!0,!t.isMore&&n>=4&&(e.isShow=!1)})),this.couponsList=Object(o.a)(this.list)}}),watch:{list:{handler:function(t){var e=this;t.length&&4==this.type&&(this.id=t[0].id,this.selectId=this.id,this.$emit("use",this.id));var n=t.map((function(t){return 0}));this.showTips=n,this.list.forEach((function(t,n){t.isShow=!0,e.showMore&&n>=4&&(t.isShow=!1)})),this.couponsList=this.list},immediate:!0,deep:!0}}},v=(n(527),n(9)),component=Object(v.a)(h,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"coupons-list flex"},[t._l(t.couponsList,(function(o,r){return[e("div",{directives:[{name:"show",rawName:"v-show",value:o.isShow,expression:"item.isShow"}],key:r,staticClass:"item",on:{"!click":function(e){return t.onHandle(o.id)}}},[e("div",{class:["info white",{gray:2==t.type||1==t.type||o.is_get}]},[e("div",{staticClass:"info-hd flex"},[3!=o.condition_type?e("div",{staticStyle:{width:"50%"}},[e("price-formate",{attrs:{price:o.money,"first-size":38,"second-size":38}})],1):t._e(),t._v(" "),3==o.condition_type?e("div",{staticStyle:{width:"50%"}},[e("span",{staticStyle:{"font-size":"38px"}},[t._v("\n "+t._s(o.discount_ratio)+" ")]),e("span",[t._v("折")])]):t._e(),t._v(" "),e("div",{staticClass:"m-l-8 flex-1",staticStyle:{width:"50%"}},[e("div",{staticClass:"line-1"},[t._v(t._s(o.name))]),t._v(" "),e("div",{staticClass:"xs line-1"},[t._v("\n "+t._s(o.condition||o.condition_tips)+"\n ")])])]),t._v(" "),e("div",{staticClass:"info-time xs"},[t._v(t._s(o.use_time_text2))])]),t._v(" "),e("div",{staticClass:"tips flex row-between",on:{click:function(e){return e.stopPropagation(),t.onShowTips(r)}}},[e("div",{staticClass:"muted xs"},[t._v("\n "+t._s(o.use_scene||o.goods_tips)+"\n ")]),t._v(" "),o.tips?e("div",[e("i",{class:t.showTips[r]?"el-icon-arrow-up":"el-icon-arrow-down"}),t._v(" "),o.tips&&t.showTips[r]?e("div",{staticClass:"tips-con xs lighter"},[t._v("\n "+t._s(o.tips)+"\n ")]):t._e()]):t._e(),t._v(" "),3!=t.type||o.is_get?t._e():e("div",{staticClass:"primary sm",staticStyle:{color:"red"}},[t._v("\n 立即领取\n ")])]),t._v(" "),o.is_get?e("img",{staticClass:"receice",attrs:{src:n(526),alt:""}}):t._e(),t._v(" "),4==t.type&&t.id==o.id?e("div",{staticClass:"choose xs"},[t._v("\n 已选择\n ")]):t._e()])]})),t._v(" "),t.showMore&&t.list.length>4?e("div",{staticClass:"more muted",on:{click:t.changeShow}},[t._v("\n "+t._s(t.isMore?"收起":"更多")+"\n "),e("i",{class:t.isMore?"el-icon-arrow-up":"el-icon-arrow-down"})]):t._e()],2)}),[],!1,null,"15fa95b0",null);e.default=component.exports;installComponents(component,{PriceFormate:n(500).default})},561:function(t,e,n){t.exports=n.p+"img/coupon_null.73b15be.png"},589:function(t,e,n){var content=n(639);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,n(21).default)("225563f4",content,!0,{sourceMap:!1})},638:function(t,e,n){"use strict";n(589)},639:function(t,e,n){var o=n(20)((function(i){return i[1]}));o.push([t.i,".get-coupons{padding:16px 0}.get-coupons .coupons{padding:0 14px}.get-coupons .coupons .title{font-size:20px;padding:16px 18px}",""]),o.locals={},t.exports=o},719:function(t,e,n){"use strict";n.r(e);var o=n(7),r=(n(48),{mixins:[n(499).a],asyncData:function(t){return Object(o.a)(regeneratorRuntime.mark((function e(){var n,o,data,r;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t.query,n=t.$get,e.next=3,n("coupon/lists");case 3:return o=e.sent,data=o.data,e.next=7,n("Pc/getPage",{params:{type:4}});case 7:return r=e.sent,e.abrupt("return",{couponList:data.lists,adData:r.data});case 9:case"end":return e.stop()}}),e)})))()},data:function(){return{couponList:[],adData:{}}},methods:{getCouponsList:function(){var t=this;return Object(o.a)(regeneratorRuntime.mark((function e(){var n,data;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.$get("coupon/lists");case 2:n=e.sent,data=n.data,1==n.code&&(t.couponList=data.lists);case 6:case"end":return e.stop()}}),e)})))()}}}),c=(n(638),n(9)),component=Object(c.a)(r,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"get-coupons"},[e("div",{staticClass:"banner flex-col m-b-16"},[t.adData.content?e("ad-item",{attrs:{item:t.adData.content}}):t._e()],1),t._v(" "),e("div",{staticClass:"coupons bg-white",staticStyle:{width:"70%","margin-left":"15%"}},[e("div",{staticClass:"title bold"},[t._v("每日领券")]),t._v(" "),e("div",{staticClass:"list"},[t.couponList.length?e("coupons-list",{attrs:{list:t.couponList,type:3},on:{reflash:t.getCouponsList}}):e("null-data",{attrs:{img:n(561),text:"暂无优惠券~"}})],1)])])}),[],!1,null,null,null);e.default=component.exports;installComponents(component,{AdItem:n(522).default,CouponsList:n(533).default,NullData:n(508).default})}}]);
|