1 line
18 KiB
JavaScript
1 line
18 KiB
JavaScript
![]() |
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-activity-goods_seckill-index"],{"0365":function(t,e,i){"use strict";i("7a82");var a=i("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,i("d81d"),i("99af");var n=i("1586"),o=a(i("5d40")),s=i("26cb"),r=i("c02f"),l=i("da5d"),c={components:{home:o.default},computed:(0,r.configMap)({statusBarHeight:0},(0,s.mapGetters)(["viewColor","keyColor"])),data:function(){return{domain:l.HTTP_REQUEST_URL,seckillList:[],timeList:[],active:5,scrollLeft:0,interval:0,status:1,countDownHour:"00",countDownMinute:"00",countDownSecond:"00",page:1,limit:8,loading:!1,loadend:!1,pageloading:!1,intoindex:""}},onLoad:function(){this.getSeckillConfig()},methods:{goBack:function(){uni.navigateBack()},getSeckillConfig:function(){var t=this;(0,n.getSeckillIndexTime)().then((function(e){var i;t.timeList=e.data.seckillTime,t.active=e.data.seckillTimeIndex,t.$nextTick((function(){t.intoindex="sort"+e.data.seckillTimeIndex})),t.timeList.map((function(t){i=t.start_time>9?t.start_time+":00":"0"+t.start_time+":00",t.time=i})),t.timeList.length&&(setTimeout((function(){t.loading=!0}),2e3),t.seckillList=[],t.page=1,t.status=t.timeList[t.active].status,t.getSeckillList(),setTimeout((function(){}),500))}))},getSeckillList:function(){var t=this,e={page:t.page,limit:t.limit,start_time:t.timeList[t.active].start_time,end_time:t.timeList[t.active].end_time};t.loadend||t.pageloading||(this.pageloading=!0,(0,n.getSeckillList)(e).then((function(e){var i=e.data.list;i.map((function(t){t.percent=0===t.stock?"0%":(100*t.sales/t.stock).toFixed(2)+"%"}));var a=i.length<t.limit;t.page++,t.seckillList=t.seckillList.concat(i),t.pageloading=!1,t.loadend=a})).catch((function(e){t.pageloading=!1})))},settimeList:function(t,e){this.active=e,this.interval&&(clearInterval(this.interval),this.interval=null),this.interval=0,this.countDownHour="00",this.countDownMinute="00",this.countDownSecond="00",this.status=this.timeList[this.active].status,this.loadend=!1,this.page=1,this.seckillList=[],this.getSeckillList()},goDetails:function(t){uni.navigateTo({url:"/pages/activity/goods_seckill_details/index?id="+t.product_id})}},onReachBottom:function(){this.getSeckillList()}};e.default=c},1586:function(t,e,i){"use strict";i("7a82");var a=i("4ea4").default;Object.defineProperty(e,"__esModule",{value:!0}),e.assistHelpList=function(t,e){return n.default.get("store/product/assist/user/"+t,e)},e.assistUserData=function(){return n.default.get("store/product/assist/count",{},{noAuth:!0})},e.getActivitycategory=function(t){return n.default.get("product/spu/active/category/"+t,{},{noAuth:!0})},e.getAssistDetail=function(t){return n.default.get("store/product/assist/detail/"+t)},e.getAssistList=function(t){return n.default.get("store/product/assist/lst",t,{noAuth:!0})},e.getAssistUser=function(t){return n.default.get("store/product/assist/share/"+t)},e.getBargainUserCancel=function(t){return n.default.post("store/product/assist/set/delete/"+t)},e.getBargainUserList=function(t){return n.default.get("store/product/assist/set/lst",t)},e.getCombinationDetail=function(t){return n.default.get("store/product/group/detail/"+t,{},{noAuth:!0})},e.getCombinationList=function(t){return n.default.get("store/product/group/lst",t,{noAuth:!0})},e.getCombinationPink=function(t){return n.default.get("store/product/group/get/"+t)},e.getCombinationPoster=function(t){return n.default.post("combination/poster",t)},e.getCombinationUser=function(t){return n.default.get("store/product/group/count",t,{noAuth:!0})},e.getCouponLst=function(t){return n.default.get("coupon/getlst",t,{noAuth:!0})},e.getMerchantServiceLst=function(t){return n.default.get("store/merchant/local",t,{noAuth:!0})},e.getNewPeopleCouponLst=function(t){return n.default.get("coupon/new_people",t,{noAuth:!0})},e.getPresellList=function(t){return n.default.get("store/product/presell/lst",t,{noAuth:!0})},e.getSeckillDetail=function(t){return n.default.get("store/product/seckill/detail/"+t,{},{noAuth:!0})},e.getSeckillIndexTime=function(){return n.default.get("store/p
|