(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["plugins/scratch/prize/prize"],{"0d7d":function(t,n,a){"use strict";a.r(n);var e=a("9f58"),i=a.n(e);for(var r in e)"default"!==r&&function(t){a.d(n,t,(function(){return e[t]}))}(r);n["default"]=i.a},4195:function(t,n,a){},"5adc":function(t,n,a){"use strict";var e;a.d(n,"b",(function(){return i})),a.d(n,"c",(function(){return r})),a.d(n,"a",(function(){return e}));var i=function(){var t=this,n=t.$createElement;t._self._c},r=[]},8824:function(t,n,a){"use strict";(function(t){a("b8bc");e(a("66fd"));var n=e(a("f3d2"));function e(t){return t&&t.__esModule?t:{default:t}}t(n.default)}).call(this,a("543d")["createPage"])},"9f58":function(t,n,a){"use strict";(function(t){Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var a={name:"prize",components:{},data:function(){return{list:null,page:1,args:!1,load:!1}},onShow:function(){var t=this;t.$showLoading({title:"加载中"}),t.$request({url:t.$api.scratch.prize,data:{page:1}}).then((function(n){t.$hideLoading(),0===n.code&&(t.list=n.data)})).catch((function(n){t.$hideLoading()}))},onReachBottom:function(){var t=this;if(!t.args&&!t.load){t.load=!0;var n=t.page+1;t.$request({url:t.$api.scratch.prize,data:{page:n}}).then((function(a){if(0===a.code){var e=[n,0===a.data.length,t.list.concat(a.data)];t.page=e[0],t.args=e[1],t.list=e[2]}t.load=!1}))}},methods:{submit:function(n){var a=[{mch_id:0,scratch_id:n.id,goods_list:[{id:n.goods.id,attr:n.attr_list,num:1,cart_id:0,goods_attr_id:n.attr_id}]}];t.navigateTo({url:"/pages/order-submit/order-submit?mch_list="+JSON.stringify(a)+"&preview_url="+encodeURIComponent(this.$api.scratch.order_preview)+"&submit_url="+encodeURIComponent(this.$api.scratch.order_submit)})}}};n.default=a}).call(this,a("543d")["default"])},cc74:function(t,n,a){"use strict";var e=a("4195"),i=a.n(e);i.a},f3d2:function(t,n,a){"use strict";a.r(n);var e=a("5adc"),i=a("0d7d");for(var r in i)"default"!==r&&function(t){a.d(n,t,(function(){return i[t]}))}(r);a("cc74");var c,o=a("f0c5"),u=Object(o["a"])(i["default"],e["b"],e["c"],!1,null,"0b947c9a",null,!1,e["a"],c);n["default"]=u.exports}},[["8824","common/runtime","common/vendor"]]]);