cxybn/public/pc/_nuxt/2bd8b53.js
2023-10-23 16:11:09 +08:00

1 line
17 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(window.webpackJsonp=window.webpackJsonp||[]).push([[29,5,12,14,15],{415:function(t,e,r){"use strict";var n=r(13),o=r(2),c=r(121),l=r(24),d=r(14),f=r(53),h=r(258),m=r(84),v=r(257),x=r(5),_=r(70),y=r(85).f,w=r(45).f,S=r(23).f,k=r(416).trim,C="Number",N=o.Number,T=N.prototype,E=f(_(T))==C,I=function(t){if(m(t))throw TypeError("Cannot convert a Symbol value to a number");var e,r,n,o,c,l,d,code,f=v(t,"number");if("string"==typeof f&&f.length>2)if(43===(e=(f=k(f)).charCodeAt(0))||45===e){if(88===(r=f.charCodeAt(2))||120===r)return NaN}else if(48===e){switch(f.charCodeAt(1)){case 66:case 98:n=2,o=49;break;case 79:case 111:n=8,o=55;break;default:return+f}for(l=(c=f.slice(2)).length,d=0;d<l;d++)if((code=c.charCodeAt(d))<48||code>o)return NaN;return parseInt(c,n)}return+f};if(c(C,!N(" 0o1")||!N("0b1")||N("+0x1"))){for(var A,z=function(t){var e=arguments.length<1?0:t,r=this;return r instanceof z&&(E?x((function(){T.valueOf.call(r)})):f(r)!=C)?h(new N(I(e)),r,z):I(e)},M=n?y(N):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger,fromString,range".split(","),O=0;M.length>O;O++)d(N,A=M[O])&&!d(z,A)&&S(z,A,w(N,A));z.prototype=T,T.constructor=z,l(o,C,z)}},416:function(t,e,r){var n=r(28),o=r(11),c="["+r(417)+"]",l=RegExp("^"+c+c+"*"),d=RegExp(c+c+"*$"),f=function(t){return function(e){var r=o(n(e));return 1&t&&(r=r.replace(l,"")),2&t&&(r=r.replace(d,"")),r}};t.exports={start:f(1),end:f(2),trim:f(3)}},417:function(t,e){t.exports="\t\n\v\f\r    \u2028\u2029\ufeff"},418:function(t,e,r){var content=r(421);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,r(16).default)("03051d40",content,!0,{sourceMap:!1})},419:function(t,e,r){"use strict";r.r(e);r(415),r(69),r(259);var n={data:function(){return{priceSlice:{}}},components:{},props:{firstSize:{type:Number,default:14},secondSize:{type:Number,default:14},color:{type:String},weight:{type:[String,Number],default:500},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)}}},o=(r(420),r(7)),component=Object(o.a)(n,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("span",{class:(t.lineThrough?"line-through":"")+"price-format",style:{color:t.color,"font-weight":t.weight}},[t.showSubscript?r("span",{style:{"font-size":t.subscriptSize+"px","margin-right":"1px"}},[t._v("¥")]):t._e(),t._v(" "),r("span",{style:{"font-size":t.firstSize+"px","margin-right":"1px"}},[t._v(t._s(t.priceSlice.first))]),t._v(" "),t.priceSlice.second?r("span",{style:{"font-size":t.secondSize+"px"}},[t._v("."+t._s(t.priceSlice.second))]):t._e()])}),[],!1,null,null,null);e.default=component.exports},420:function(t,e,r){"use strict";r(418)},421:function(t,e,r){var n=r(15)(!1);n.push([t.i,".price-format{display:flex;align-items:baseline}",""]),t.exports=n},422:function(t,e,r){var content=r(424);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,r(16).default)("7277513c",content,!0,{sourceMap:!1})},423:function(t,e,r){"use strict";r(422)},424:function(t,e,r){var n=r(15)(!1);n.push([t.i,".null-data[data-v-7fa0e58c]{padding:100px}.null-data .img-null[data-v-7fa0e58c]{width:150px;height:150px}",""]),t.exports=n},425:function(t,e,r){"use strict";r.r(e);var n={components:{},props:{img:{type:String},text:{type:String,default:"暂无数据"},imgStyle:{type:String,default:""}},methods:{}},o=(r(423),r(7)),component=Object(o.a)(n,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"bg-white column-center null-data"},[r("img",{staticClass:"img-null",style:t.imgStyle,attrs:{src:t.img,alt:""}}),t._v(" "),r("div",{staticClass:"muted mt8"},[t._v(t._s(t.text))])])}),[],!1,null,"7fa0e58c",null);e.default=component.exports},426:function(t,e,r){"use strict";r.d(e,"d",(function(){return o})),r.d(e,"c",(function(){return c})),r.d(e,"a",(function(){return l})),r.d(e,"b",(function(){return d}));var n=r(32);r(69),r(259),r(89),r(54),r(19),r(36),r(55),r(37),r(17),r(56),r(57),r(46);var o=function(t){var time=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3,e=arguments.length>2?arguments[2]:void 0,r=new Date(0).getTime();return function(){var n=(new Date).getTime();if(n-r>time){for(var o=arguments.length,c=new Array(o),l=0;l<o;l++)c[l]=arguments[l];t.apply(e,c),r=n}}};function c(t){var p="";if("object"==Object(n.a)(t)){for(var e in p="?",t)p+="".concat(e,"=").concat(t[e],"&");p=p.slice(0,-1)}return p}var l=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)}},d=function(t){return new Promise((function(e,r){var n=document.getElementById(t);if(n)return e(n);try{var o=document.createElement("script");o.setAttribute("id",t),o.setAttribute("src",t),document.body.append(o),("onload"in o?function(t){return new Promise((function(e,r){t.onload=function(){this.onerror=this.onload=null,e(t)},t.onerror=function(){this.onerror=this.onload=null,r()}}))}:function(t){return new Promise((function(e,r){t.onreadystatechange=function(){"loaded"!==this.readyState&&"complete"!==this.readyState||(this.onreadystatechange=null,e(t))}}))})(o).then((function(){return e(o)})).catch((function(){return r()}))}catch(t){r(t)}}))}},430:function(t,e,r){var content=r(439);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,r(16).default)("f37a30f2",content,!0,{sourceMap:!1})},431:function(t,e,r){var content=r(446);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,r(16).default)("a57d76be",content,!0,{sourceMap:!1})},438:function(t,e,r){"use strict";r(430)},439:function(t,e,r){var n=r(15)(!1);n.push([t.i,".goods-list[data-v-483dfcdd]{align-items:stretch}.goods-list .goods-item[data-v-483dfcdd]{display:block;box-sizing:border-box;width:224px;height:310px;margin-bottom:16px;padding:12px 12px 16px;border-radius:4px;transition:all .2s}.goods-list .goods-item[data-v-483dfcdd]:hover{transform:translateY(-8px);box-shadow:0 0 6px rgba(0,0,0,.1)}.goods-list .goods-item .goods-img[data-v-483dfcdd]{width:200px;height:200px}.goods-list .goods-item .name[data-v-483dfcdd]{margin-bottom:10px;height:40px;line-height:20px}.goods-list .goods-item .seckill .btn[data-v-483dfcdd]{padding:4px 12px;border-radius:4px;border:1px solid transparent}.goods-list .goods-item .seckill .btn.not-start[data-v-483dfcdd]{border-color:#ff2c3c;color:#ff2c3c;background-color:transparent}.goods-list .goods-item .seckill .btn.end[data-v-483dfcdd]{background-color:#e5e5e5;color:#fff}",""]),t.exports=n},442:function(t,e,r){"use strict";var n=r(4),o=r(443);n({target:"String",proto:!0,forced:r(444)("link")},{link:function(t){return o(this,"a","href",t)}})},443:function(t,e,r){var n=r(28),o=r(11),c=/"/g;t.exports=function(t,e,r,l){var d=o(n(t)),f="<"+e;return""!==r&&(f+=" "+r+'="'+o(l).replace(c,"&quot;")+'"'),f+">"+d+"</"+e+">"}},444:function(t,e,r){var n=r(5);t.exports=function(t){return n((function(){var e=""[t]('"');return e!==e.toLowerCase()||e.split('"').length>3}))}},445:function(t,e,r){"use strict";r(431)},446:function(t,e,r){var n=r(15)(!1);n.push([t.i,".ad-item[data-v-562e7d63]{width:100%;height:100%;cursor:pointer}",""]),t.exports=n},447:function(t,e,r){"use strict";r.r(e);r(415);var n={props:{list:{type:Array,default:function(){return[]}},num:{type:Number,default:5},type:{type:String},status:{type:Number}},watch:{list:{immediate:!0,handler:function(t){}}},computed:{getSeckillText:function(){switch(this.status){case 0:return"未开始";case 1:return"立即抢购";case 2:return"已结束"}}}},o=(r(438),r(7)),component=Object(o.a)(n,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"goods-list row wrap"},t._l(t.list,(function(e,n){return r("nuxt-link",{key:n,staticClass:"goods-item bg-white",style:{marginRight:(n+1)%t.num==0?0:"14px"},attrs:{to:"/goods_details/"+e.id}},[r("el-image",{staticClass:"goods-img",attrs:{lazy:"",src:e.image,alt:""}}),t._v(" "),r("div",{staticClass:"name line2"},[t._v(t._s(e.name))]),t._v(" "),"seckill"==t.type?r("div",{staticClass:"seckill row-between"},[r("div",{staticClass:"primary row"},[t._v("\n 秒杀价"),r("price-formate",{attrs:{price:e.seckill_price,"first-size":18}})],1),t._v(" "),r("div",{class:["btn bg-primary white",{"not-start":0==t.status,end:2==t.status}]},[t._v(t._s(t.getSeckillText))])]):r("div",{staticClass:"row-between wrap"},[r("div",{staticClass:"price row"},[r("div",{staticClass:"primary mr8"},[r("price-formate",{attrs:{price:e.price,"first-size":16}})],1),t._v(" "),r("div",{staticClass:"muted sm line-through"},[r("price-formate",{attrs:{price:e.market_price}})],1)]),t._v(" "),r("div",{staticClass:"muted xs"},[t._v(t._s(e.sales_sum)+"人购买")])])],1)})),1)}),[],!1,null,"483dfcdd",null);e.default=component.exports;installComponents(component,{PriceFormate:r(419).default})},448:function(t,e,r){"use strict";r.r(e);r(442),r(72);var n=r(426),o={components:{},props:{item:{type:Object,default:function(){return{}}}},methods:{goPage:function(t){var e=t.link_type,link=t.link,r=t.params;switch(e){case 3:window.open(t.link);break;default:["/goods_details"].includes(link)?link+="/".concat(r.id):link+=Object(n.c)(r),this.$router.push({path:link})}}}},c=(r(445),r(7)),component=Object(c.a)(o,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"ad-item",on:{click:function(e){return e.stopPropagation(),t.goPage(t.item)}}},[r("el-image",{staticStyle:{width:"100%",height:"100%"},attrs:{src:t.item.image}})],1)}),[],!1,null,"562e7d63",null);e.default=component.exports},457:function(t,e,r){t.exports=r.p+"img/goods_null.38f1689.png"},525:function(t,e,r){var content=r(611);content.__esModule&&(content=content.default),"string"==typeof content&&(content=[[t.i,content,""]]),content.locals&&(t.exports=content.locals);(0,r(16).default)("4d39614a",content,!0,{sourceMap:!1})},605:function(t,e,r){"use strict";var n=r(4),o=r(92),c=r(33),l=r(25),d=r(11),f=r(5),h=r(606),m=r(177),v=r(607),x=r(608),_=r(91),y=r(609),w=[],S=w.sort,k=f((function(){w.sort(void 0)})),C=f((function(){w.sort(null)})),N=m("sort"),T=!f((function(){if(_)return _<70;if(!(v&&v>3)){if(x)return!0;if(y)return y<603;var code,t,e,r,n="";for(code=65;code<76;code++){switch(t=String.fromCharCode(code),code){case 66:case 69:case 70:case 72:e=3;break;case 68:case 71:e=4;break;default:e=2}for(r=0;r<47;r++)w.push({k:t+r,v:e})}for(w.sort((function(a,b){return b.v-a.v})),r=0;r<w.length;r++)t=w[r].k.charAt(0),n.charAt(n.length-1)!==t&&(n+=t);return"DGBEFHACIJK"!==n}}));n({target:"Array",proto:!0,forced:k||!C||!N||!T},{sort:function(t){void 0!==t&&o(t);var e=c(this);if(T)return void 0===t?S.call(e):S.call(e,t);var r,n,f=[],m=l(e.length);for(n=0;n<m;n++)n in e&&f.push(e[n]);for(r=(f=h(f,function(t){return function(e,r){return void 0===r?-1:void 0===e?1:void 0!==t?+t(e,r)||0:d(e)>d(r)?1:-1}}(t))).length,n=0;n<r;)e[n]=f[n++];for(;n<m;)delete e[n++];return e}})},606:function(t,e){var r=Math.floor,n=function(t,e){var l=t.length,d=r(l/2);return l<8?o(t,e):c(n(t.slice(0,d),e),n(t.slice(d),e),e)},o=function(t,e){for(var element,r,n=t.length,i=1;i<n;){for(r=i,element=t[i];r&&e(t[r-1],element)>0;)t[r]=t[--r];r!==i++&&(t[r]=element)}return t},c=function(t,e,r){for(var n=t.length,o=e.length,c=0,l=0,d=[];c<n||l<o;)c<n&&l<o?d.push(r(t[c],e[l])<=0?t[c++]:e[l++]):d.push(c<n?t[c++]:e[l++]);return d};t.exports=n},607:function(t,e,r){var n=r(73).match(/firefox\/(\d+)/i);t.exports=!!n&&+n[1]},608:function(t,e,r){var n=r(73);t.exports=/MSIE|Trident/.test(n)},609:function(t,e,r){var n=r(73).match(/AppleWebKit\/(\d+)\./);t.exports=!!n&&+n[1]},610:function(t,e,r){"use strict";r(525)},611:function(t,e,r){var n=r(15)(!1);n.push([t.i,".goods-list .banner img{width:100%;display:block}.goods-list .sort{padding:15px 16px}.goods-list .sort .sort-name .item{margin-right:30px;cursor:pointer}.goods-list .sort .sort-name .item.active{color:#ff2c3c}",""]),t.exports=n},645:function(t,e,r){"use strict";r.r(e);var n=r(8),o=r(6),c=(r(48),r(36),r(605),r(426)),l={head:function(){return{title:this.$store.getters.headTitle,link:[{rel:"icon",type:"image/x-icon",href:this.$store.getters.favicon}]}},components:{},watchQuery:!0,asyncData:function(t){return Object(o.a)(regeneratorRuntime.mark((function e(){var r,o,c,l,d,data,f,h,m,v,x,_,y;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.$get,o=t.params,c=t.query,l=o.type,d=c.name,data=Object(n.a)({page_size:20,type:l,name:d},"type",l),1==l&&(data.sort="desc",data.sort_type="sales_sum"),e.next=7,r("pc/goodsList",{params:data});case 7:return f=e.sent,h=f.data,m=h.list,v=h.count,e.next=13,r("pc/index");case 13:x=e.sent,_=x.data,y={},e.t0=l,e.next="1"===e.t0?19:"2"===e.t0?21:"3"===e.t0?23:25;break;case 19:return y=_.host_ad,e.abrupt("break",25);case 21:return y=_.new_ad,e.abrupt("break",25);case 23:return y=_.best_ad,e.abrupt("break",25);case 25:return e.abrupt("return",{goodsList:m,count:v,ad:y});case 26:case"end":return e.stop()}}),e)})))()},data:function(){return{sortType:"",saleSort:"desc",priceSort:"desc",page:""}},created:function(){this.changeSortType=Object(c.d)(this.changeSortType,500,this)},methods:{changeSortType:function(t){switch(this.sortType=t,t){case"price":"asc"==this.priceSort?this.priceSort="desc":"desc"==this.priceSort&&(this.priceSort="asc");break;case"sales_sum":"asc"==this.saleSort?this.saleSort="desc":"desc"==this.saleSort&&(this.saleSort="asc")}this.getGoods()},changePage:function(t){this.page=t,this.getGoods()},getGoods:function(){var t=this;return Object(o.a)(regeneratorRuntime.mark((function e(){var r,n,o,c,l,d,f,h;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r=t.$route.query.name,n=t.priceSort,o=t.sortType,c=t.saleSort,l="",e.t0=o,e.next="price"===e.t0?6:"sales_sum"===e.t0?8:10;break;case 6:return l=n,e.abrupt("break",10);case 8:return l=c,e.abrupt("break",10);case 10:return e.next=12,t.$get("pc/goodsList",{params:{page_size:20,page_no:t.page,sort_type:o,sort:l,name:r}});case 12:d=e.sent,f=d.data,h=f.list,f.count,t.goodsList=h;case 17:case"end":return e.stop()}}),e)})))()}}},d=(r(610),r(7)),component=Object(d.a)(l,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"goods-list"},[n("div",{staticClass:"banner mt16"},[t.ad.image?n("ad-item",{attrs:{item:t.ad}}):t._e()],1),t._v(" "),n("div",{staticClass:"sort mb16 row bg-white"},[n("div",{staticClass:"title"},[t._v("排序方式:")]),t._v(" "),n("div",{staticClass:"sort-name ml16 row"},[n("div",{class:["item",{active:""==t.sortType}],on:{click:function(e){return t.changeSortType("")}}},[t._v("\n 综合\n ")]),t._v(" "),n("div",{class:["item",{active:"price"==t.sortType}],on:{click:function(e){return t.changeSortType("price")}}},[t._v("\n 价格\n "),n("i",{directives:[{name:"show",rawName:"v-show",value:"desc"==t.priceSort,expression:"priceSort == 'desc'"}],staticClass:"el-icon-arrow-down"}),t._v(" "),n("i",{directives:[{name:"show",rawName:"v-show",value:"asc"==t.priceSort,expression:"priceSort == 'asc'"}],staticClass:"el-icon-arrow-up"})]),t._v(" "),n("div",{class:["item",{active:"sales_sum"==t.sortType}],on:{click:function(e){return t.changeSortType("sales_sum")}}},[t._v("\n 销量\n "),n("i",{directives:[{name:"show",rawName:"v-show",value:"desc"==t.saleSort,expression:"saleSort == 'desc'"}],staticClass:"el-icon-arrow-down"}),t._v(" "),n("i",{directives:[{name:"show",rawName:"v-show",value:"asc"==t.saleSort,expression:"saleSort == 'asc'"}],staticClass:"el-icon-arrow-up"})])])]),t._v(" "),t.goodsList.length?[n("goods-list",{attrs:{list:t.goodsList}}),t._v(" "),t.count?n("div",{staticClass:"pagination row-center",staticStyle:{"padding-bottom":"38px"}},[n("el-pagination",{attrs:{background:"",layout:"prev, pager, next",total:t.count,"prev-text":"上一页","next-text":"下一页","hide-on-single-page":"","page-size":20},on:{"current-change":t.changePage}})],1):t._e()]:n("null-data",{attrs:{img:r(457),text:"暂无商品~"}})],2)}),[],!1,null,null,null);e.default=component.exports;installComponents(component,{AdItem:r(448).default,GoodsList:r(447).default,NullData:r(425).default})}}]);