require('../common/vendor.js');(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/goods/goods_comment_con/lottery_comment"],{"0510":function(t,e,n){},"27af":function(t,e,n){"use strict";n.r(e);var a=n("cb57"),o=n.n(a);for(var i in a)["default"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(i);e["default"]=o.a},"2e7d":function(t,e,n){"use strict";var a=n("0510"),o=n.n(a);o.a},7249:function(t,e,n){"use strict";n.r(e);var a=n("fc9e"),o=n("27af");for(var i in o)["default"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(i);n("2e7d");var r=n("828b"),d=Object(r["a"])(o["default"],a["b"],a["c"],!1,null,"543bc617",null,!1,a["a"],void 0);e["default"]=d.exports},a424:function(t,e,n){"use strict";(function(t,e){var a=n("47a9");n("f076");a(n("3240"));var o=a(n("7249"));t.__webpack_require_UNI_MP_PLUGIN__=n,e(o.default)}).call(this,n("3223")["default"],n("df3c")["createPage"])},cb57:function(t,e,n){"use strict";(function(t){var a=n("47a9");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o,i,r=a(n("7ca3")),d=a(n("89cc")),c=(n("7391"),n("5088")),s=n("df03"),u=n("8f59"),l=n("4d38"),f=t.getWindowInfo().statusBarHeight,h=(i={components:{gridsLottery:function(){Promise.all([n.e("pages/goods/common/vendor"),n.e("pages/goods/components/lottery/payLottery")]).then(function(){return resolve(n("dc6e"))}.bind(null,n)).catch(n.oe)},lotteryAleart:function(){Promise.all([n.e("common/vendor"),n.e("pages/goods/components/lotteryAleart/index")]).then(function(){return resolve(n("4b97"))}.bind(null,n)).catch(n.oe)},countDown:function(){n.e("components/countDown/index").then(function(){return resolve(n("1706"))}.bind(null,n)).catch(n.oe)}},mixins:[d.default],computed:(0,u.mapGetters)(["isLogin"]),data:function(){return{sysHeight:f,lotteryShow:!1,addressModel:!1,lottery_num:0,aleartType:0,aleartStatus:!1,lottery_draw_param:{startIndex:3,totalCount:3,winingIndex:1,speed:100},alData:{},type:"",prize:[],orderId:"",order_pay_info:{paid:1,_status:{}},isAuto:!1,isShowAuth:!1,couponsHidden:!0,couponList:[],datatime:0,imgHost:l.HTTP_REQUEST_URL}}},(0,r.default)(i,"computed",(0,u.mapGetters)(["isLogin"])),(0,r.default)(i,"watch",{isLogin:{handler:function(t,e){},deep:!0}}),(0,r.default)(i,"onLoad",(function(t){this.orderId=t.order_id,this.type=t.type,this.isLogin&&this.getLotteryData(this.type)})),(0,r.default)(i,"onShow",(function(){t.removeStorageSync("form_type_cart"),this.isLogin||(0,c.toLogin)()})),(0,r.default)(i,"methods",(o={getWiningIndex:function(t){var e=this;this.aleartType=0,(0,s.startLottery)({id:this.id}).then((function(n){e.prize.forEach((function(a,o){n.data.id===a.id&&(e.alData=n.data,e.lottery_draw_param.winingIndex=o,t(e.lottery_draw_param))}))})).catch((function(t){e.$util.Tips({title:t})}))},goIndex:function(e){t.switchTab({url:"/pages/index/index"})},goBack:function(){t.navigateBack()},getLotteryData:function(e){var n=this;(0,s.getLotteryData)(e,0).then((function(t){n.lotteryShow=!0,n.factor_num=t.data.lottery.factor_num,n.id=t.data.lottery.id,n.prize=t.data.lottery.prize,n.prize.length&&n.prize.push({name:1}),n.lottery_num=t.data.lottery_num,n.datatime=parseInt(t.data.cache_time)})).catch((function(e){t.redirectTo({url:"/pages/goods/order_details/index?order_id="+n.orderId})}))},closeLottery:function(t){this.aleartStatus=!1,this.getLotteryData(this.type),6===this.alData.type&&(this.addressModel=!0)}},(0,r.default)(o,"getWiningIndex",(function(t){var e=this;this.aleartType=0,(0,s.startLottery)({id:this.id}).then((function(n){e.prize.forEach((function(a,o){n.data.id===a.id&&(e.alData=n.data,e.lottery_draw_param.winingIndex=o,t(e.lottery_draw_param))}))})).catch((function(t){e.$util.Tips({title:t})}))})),(0,r.default)(o,"luck_draw_finish",(function(t){this.aleartType=2,this.aleartStatus=!0})),o)),i);e.default=h}).call(this,n("df3c")["default"])},fc9e:function(t,e,n){"use strict";n.d(e,"b",(function(){return a})),n.d(e,"c",(function(){return o})),n.d(e,"a",(function(){}));var a=function(){var t=this.$createElement,e=(this._self._c,this.lotteryShow&&this.prize.length);this.$mp.data=Object.assign({},{$root:{g0:e}})},o=[]}},[["a424","common/runtime","common/vendor","pages/goods/common/vendor"]]]);