You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
3.8 KiB
1 lines
3.8 KiB
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/annex/vip_coupon/index"],{"10fe":function(t,o,n){"use strict";n.r(o);var e=n("ae28"),i=n.n(e);for(var a in e)["default"].indexOf(a)<0&&function(t){n.d(o,t,(function(){return e[t]}))}(a);o["default"]=i.a},"15ab":function(t,o,n){"use strict";(function(t,o){var e=n("47a9");n("7561");e(n("3240"));var i=e(n("6fd0"));t.__webpack_require_UNI_MP_PLUGIN__=n,o(i.default)}).call(this,n("3223")["default"],n("df3c")["createPage"])},"2e00":function(t,o,n){"use strict";var e=n("9b01"),i=n.n(e);i.a},"6fd0":function(t,o,n){"use strict";n.r(o);var e=n("badf"),i=n("10fe");for(var a in i)["default"].indexOf(a)<0&&function(t){n.d(o,t,(function(){return i[t]}))}(a);n("2e00");var s=n("828b"),u=Object(s["a"])(i["default"],e["b"],e["c"],!1,null,"31a2b2cc",null,!1,e["a"],void 0);o["default"]=u.exports},"9b01":function(t,o,n){},ae28:function(t,o,n){"use strict";(function(t){var e=n("47a9");Object.defineProperty(o,"__esModule",{value:!0}),o.default=void 0;var i=e(n("af34")),a=n("77d7"),s=n("a230"),u=n("7ba4"),c=e(n("bc59")),d=e(n("cef6")),r=n("bad7"),l=n("8f59"),f={components:{home:function(){Promise.all([n.e("common/vendor"),n.e("components/home/index")]).then(function(){return resolve(n("b7a2"))}.bind(null,n)).catch(n.oe)}},mixins:[d.default],data:function(){return{couponsList:[],loading:!1,isAuto:!1,isShowAuth:!1,imgHost:r.HTTP_REQUEST_URL,page:1,limit:15,loadend:!1}},filters:{format:function(t){return t?(0,c.default)(1e3*t).format("YYYY-MM-DD"):""},money:function(t){return t?parseFloat(t):"0"}},computed:(0,l.mapGetters)(["isLogin"]),watch:{isLogin:{handler:function(t,o){},deep:!0}},onLoad:function(){this.isLogin&&this.getUseCoupons()},onShow:function(){t.removeStorageSync("form_type_cart"),this.isLogin||(0,u.toLogin)()},methods:{onLoadFun:function(){this.getUseCoupons(),this.isShowAuth=!1},authColse:function(t){this.isShowAuth=t},getUseCoupons:function(){var t=this,o=this;this.loadend||(0,a.memberCouponsList)(this.page,this.limit).then((function(n){o.loading=!0,n.data.forEach((function(t){t.ruleShow=!1,t.rules=t.rule.split("\n")})),t.page+=1,t.loadend=n.data.length<t.limit,t.couponsList=[].concat((0,i.default)(t.couponsList),(0,i.default)(n.data))}))},setCouponReceive:function(t){var o=this;(0,s.setCouponReceive)(t).then((function(n){o.$util.Tips({title:"领取成功"});for(var e=0;e<o.couponsList.length;e++)o.couponsList[e].id==t&&(o.couponsList[e].is_use=!0)})).catch((function(t){o.$util.Tips({title:t})}))},useCoupon:function(o){var n="";if(0==o.category_id&&""==o.product_id&&0==o.brand_id&&(n="/pages/goods/goods_list/index?title=默认"),0!=o.category_id&&(n=1==o.category_type?"/pages/goods/goods_list/index?cid="+o.category_id+"&title="+o.category_name:"/pages/goods/goods_list/index?sid="+o.category_id+"&title="+o.category_name),""!=o.product_id){var e=o.product_id.split(","),i=e.length;n=1==i?"/pages/goods_details/index?id="+o.product_id:"/pages/goods/goods_list/index?productId="+o.product_id+"&title=默认"}0!=o.brand_id&&(n="/pages/goods/goods_list/index?brandId="+o.brand_id+"&title=默认"),t.navigateTo({url:n})},openRule:function(t){this.couponsList[t].ruleShow=!this.couponsList[t].ruleShow}},onReachBottom:function(){this.getUseCoupons()}};o.default=f}).call(this,n("df3c")["default"])},badf:function(t,o,n){"use strict";n.d(o,"b",(function(){return e})),n.d(o,"c",(function(){return i})),n.d(o,"a",(function(){}));var e=function(){var t=this,o=t.$createElement,n=(t._self._c,t.couponsList.length),e=n?t.__map(t.couponsList,(function(o,n){var e=t.__get_orig(o),i=1!=o.coupon_type?parseFloat(o.coupon_price):null,a=o.use_min_price>0?t._f("money")(o.use_min_price):null;return{$orig:e,m0:i,f0:a}})):null,i=!t.couponsList.length&&1==t.loading;t.$mp.data=Object.assign({},{$root:{g0:n,l0:e,g1:i}})},i=[]}},[["15ab","common/runtime","common/vendor"]]]); |