chunk-c929bd1e.43713bf7.js 6.3 KB

12
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-c929bd1e"],{"2b67":function(t,i,n){"use strict";n.r(i);var e=function(){var t=this,i=t.$createElement,e=t._self._c||i;return e("div",{ref:"container",staticClass:"flash-sale "},[e("div",{staticClass:"saleBox"},[t.timeList[t.active]?e("div",{staticClass:"header"},[e("img",{attrs:{src:t.timeList[t.active].slide}})]):t._e()]),t._m(0),e("Tabs",{ref:"timeList",staticClass:"time-tabs",attrs:{"line-height":"0",animated:"","title-inactive-color":"2",sticky:""},model:{value:t.active,callback:function(i){t.active=i},expression:"active"}},t._l(t.timeList,(function(i,s){return e("Tab",{key:s},[e("div",{staticClass:"timeItem acea-row row-column-around",attrs:{slot:"title"},on:{click:function(i){return t.setTime(s)}},slot:"title"},[e("span",{staticClass:"time"},[t._v(t._s(i.time))]),e("span",{staticClass:"state"},[t._v(t._s(i.state))])]),e("div",{staticClass:"list"},t._l(t.seckillList,(function(n,s){return e("div",{key:s,staticClass:"item acea-row row-between-wrapper",on:{click:function(e){return t.goDetail(n.id,i.status)}}},[e("div",{staticClass:"pictrue"},[e("img",{attrs:{src:n.image}})]),e("div",{staticClass:"text acea-row row-column-around"},[e("div",{staticClass:"line1",domProps:{textContent:t._s(n.title)}}),e("div",{staticClass:"money"},[e("span",{staticClass:"num font-color-red",domProps:{textContent:t._s("¥"+n.price)}}),e("span",{staticClass:"ot_price",domProps:{textContent:t._s("¥"+n.ot_price)}})]),e("div",{staticClass:"stock"},[t._v("\n 限量"),e("span",{domProps:{textContent:t._s(n.quota_show+"件")}})]),e("div",{staticClass:"progress cart-color"},[e("div",{staticClass:"bg-red",style:{width:t.loading?n.percent+"%":""}}),e("div",{staticClass:"piece font-color-red",domProps:{textContent:t._s("已抢"+n.percent+"%")}})])]),1===i.status&&n.quota>0?e("div",{staticClass:"grab bg-color-red"},[t._v("\n 马上抢\n ")]):t._e(),1===i.status&&n.quota<=0?e("div",{staticClass:"grab bg-color-hui"},[t._v("\n 已售罄\n ")]):t._e(),2===i.status?e("div",{staticClass:"grab bg-color-red"},[t._v("\n 未开始\n ")]):t._e(),0===i.status?e("div",{staticClass:"grab bg-color-hui"},[t._v("\n 已结束\n ")]):t._e()])})),0),!t.status||0===t.seckillList.length&&t.page>1?e("div",{staticClass:"noCommodity"},[e("div",{staticClass:"noPictrue"},[e("img",{staticClass:"image",attrs:{src:n("0c36")}})])]):t._e(),t.seckillList.length>0?e("Loading",{attrs:{loaded:t.status,loading:t.loadingList}}):t._e()],1)})),1),e("div",{attrs:{id:"title0"}}),e("div",{attrs:{id:"title1"}}),e("div",{attrs:{id:"title2"}})],1)},s=[function(){var t=this,i=t.$createElement,e=t._self._c||i;return e("div",{staticClass:"logoPic"},[e("img",{attrs:{src:n("634a")}})])}],a=(n("f313"),n("43ab")),r=(n("96ab"),n("b649")),o=n("ca41"),c=n("3a5e"),l={name:"GoodsSeckill",components:{Tab:r["a"],Tabs:a["a"],Loading:c["a"]},props:{},data:function(){return{timeList:[],sticky:!1,loading:!1,datatime:0,active:0,seckillList:[],status:!1,loadingList:!1,page:1,limit:5}},mounted:function(){this.mountedStart()},methods:{mountedStart:function(){var t=this,i=this;Object(o["r"])().then((function(t){i.$set(i,"timeList",t.data.seckillTime),i.$set(i,"active",t.data.seckillTimeIndex),i.datatime=i.timeList[i.active].stop,i.loadingList=!1,i.getSeckillList(),i.$nextTick((function(){i.sticky=!0,i.$refs.timeList.scrollIntoView()}))})),this.$scroll(this.$refs.container,(function(){!t.loadingList&&t.getSeckillList()})),setTimeout((function(){i.loading=!0}),500)},setTime:function(t){var i=this;i.active=t,i.datatime=i.timeList[i.active].stop,i.seckillList=[],i.page=1,i.status=!1,i.loadingList=!1,i.getSeckillList()},getSeckillList:function(){var t=this;if(!t.loadingList&&!t.status){t.loadingList=!0;var i=t.timeList[t.active].id;Object(o["t"])(i,{page:t.page,limit:t.limit}).then((function(i){t.status=i.data.length<t.limit,t.seckillList.push.apply(t.seckillList,i.data),t.page++,t.loadingList=!1})).catch((function(){t.loadingList=!1}))}},goDetail:function(t,i){var n=this,e=n.timeList[n.active].stop;this.$router.push({path:"/activity/seckill_detail/"+t+"/"+e+"/"+i})}}},u=l,d=(n("bef6e"),n("623f")),f=Object(d["a"])(u,e,s,!1,null,"0ce76860",null);i["default"]=f.exports},6129:function(t,i,n){},"634a":function(t,i,n){t.exports=n.p+"h5/img/baokuan.6313c8c8.png"},bef6e:function(t,i,n){"use strict";var e=n("6129"),s=n.n(e);s.a},ca41:function(t,i,n){"use strict";n.d(i,"n",(function(){return s})),n.d(i,"m",(function(){return a})),n.d(i,"o",(function(){return r})),n.d(i,"q",(function(){return o})),n.d(i,"p",(function(){return c})),n.d(i,"r",(function(){return l})),n.d(i,"t",(function(){return u})),n.d(i,"s",(function(){return d})),n.d(i,"f",(function(){return f})),n.d(i,"a",(function(){return g})),n.d(i,"h",(function(){return p})),n.d(i,"i",(function(){return m})),n.d(i,"b",(function(){return v})),n.d(i,"e",(function(){return b})),n.d(i,"c",(function(){return h})),n.d(i,"j",(function(){return k})),n.d(i,"d",(function(){return C})),n.d(i,"g",(function(){return L})),n.d(i,"l",(function(){return _})),n.d(i,"k",(function(){return w}));var e=n("b775");function s(t){return e["a"].get("/combination/list",t,{login:!1})}function a(t){return e["a"].get("/combination/detail/"+t,{},{login:!1})}function r(t){return e["a"].get("/combination/pink/"+t)}function o(t){return e["a"].post("/combination/remove",t)}function c(t){return e["a"].post("/combination/poster",t)}function l(){return e["a"].get("/seckill/index",{},{login:!1})}function u(t,i){return e["a"].get("/seckill/list/"+t,i,{login:!1})}function d(t){return e["a"].get("/seckill/detail/"+t,{},{login:!1})}function f(t){return e["a"].get("/bargain/list",t,{login:!1})}function g(t){return e["a"].get("/bargain/detail/"+t)}function p(t){return e["a"].post("/bargain/share",t)}function m(t){return e["a"].post("/bargain/start",t)}function v(t){return e["a"].post("/bargain/help",t)}function b(t){return e["a"].post("/bargain/help/price",t)}function h(t){return e["a"].post("/bargain/help/count",t)}function k(t){return e["a"].post("/bargain/start/user",t)}function C(t){return e["a"].post("/bargain/help/list",t)}function L(t){return e["a"].post("/bargain/poster",t)}function _(t){return e["a"].get("/bargain/user/list",t)}function w(t){return e["a"].post("/bargain/user/cancel",t)}}}]);
  2. //# sourceMappingURL=chunk-c929bd1e.43713bf7.js.map