(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["plugins/miaosha/goods/goods"],{"1a89":function(t,e,n){"use strict";var o,i=function(){var t=this,e=t.$createElement,n=(t._self._c,Number(110));t.$mp.data=Object.assign({},{$root:{m0:n}})},a=[];n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return o}))},"420b":function(t,e,n){"use strict";n.r(e);var o=n("1a89"),i=n("f750");for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);n("c300");var r,s=n("f0c5"),c=Object(s["a"])(i["default"],o["b"],o["c"],!1,null,"510536b6",null,!1,o["a"],r);e["default"]=c.exports},"46ef":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o=a(n("4795")),i=n("2f62");function a(t){return t&&t.__esModule?t:{default:t}}function r(t,e,n,o,i,a,r){try{var s=t[a](r),c=s.value}catch(p){return void n(p)}s.done?e(c):Promise.resolve(c).then(o,i)}function s(t){return function(){var e=this,n=arguments;return new Promise((function(o,i){var a=t.apply(e,n);function s(t){r(a,o,i,s,c,"next",t)}function c(t){r(a,o,i,s,c,"throw",t)}s(void 0)}))}}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}function p(t){for(var e=1;e0&&(e.is_vip=!0,e.discount=e.detail.vip_card_appoint.discount),e.is_vip_card_user=e.detail.vip_card_appoint.is_vip_card_user}))}))}))},onHide:function(){clearInterval(this.time)},onUnload:function(){clearInterval(this.time)},computed:p({},(0,i.mapState)("gConfig",{iphone:function(t){return t.iphone},iphoneHeight:function(t){return t.iphoneHeight}}),{},(0,i.mapState)({mall:function(t){return t.mallConfig.mall}})),onShareAppMessage:function(){return this.$shareAppMessage({path:"/plugins/miaosha/goods/goods",title:this.detail.app_share_title?this.detail.app_share_title:this.detail.name,imageUrl:this.detail.app_share_pic?this.detail.app_share_pic:"",params:{id:this.detail.id}})},methods:{attr:function(t){this.appAttr=t},request:function(t){var e=this;return s(o.default.mark((function n(){var i,a,r;return o.default.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return i=t.url,a=t.data,n.next=3,e.$request({url:i,data:a});case 3:if(r=n.sent,0!==r.code){n.next=6;break}return n.abrupt("return",r.data);case 6:case"end":return n.stop()}}),n)})))()},attrtap:function(t){this.selectAttr=null!==t?t:{}},joinCart:function(){var t=this;"none"===this.appAttr.display?this.show=Math.random():this.$request({url:this.$api.miaosha.add_cart,method:"post",data:{miaosha_goods_id:this.selectAttr.goods_id,attr_id:this.selectAttr.id,num:this.appAttr.number}}).then((function(e){0===e.code&&(t.appAttr.display="none")}))},buy:function(){if("none"===this.appAttr.display)this.show=Math.random();else{for(var t=this.detail.mch_id,e=[],n={id:this.detail.id,attr:[],num:this.appAttr.number,goods_attr_id:this.selectAttr.id,cart_id:0},o=0;o