(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-coupon-coupon"],{"602e":function(t,e,i){"use strict";i.r(e);var n=i("bce5"),o=i.n(n);for(var a in n)["default"].indexOf(a)<0&&function(t){i.d(e,t,(function(){return n[t]}))}(a);e["default"]=o.a},7097:function(t,e,i){"use strict";i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return o})),i.d(e,"a",(function(){}));var n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return t.loadding?t._e():i("v-uni-view",{staticClass:"coupon-wrap bg-white"},[t.DataList.length>0?t._l(t.DataList,(function(e,n){return i("v-uni-view",{key:n,staticClass:"item-wrap"},[i("v-uni-view",{class:"coupon-item coupon-item-"+e.color.text,on:{click:function(i){arguments[0]=i=t.$handleEvent(i),t.lookRule(e)}}},[i("v-uni-view",{staticClass:"circles"},t._l(8,(function(t,e){return i("v-uni-text",{key:e})})),1),i("v-uni-view",{staticClass:"info"},[i("v-uni-view",[t._v(t._s(e.coupon_type.text))])],1),i("v-uni-view",{staticClass:"operation d-b-c w-b"},[i("v-uni-view",{staticClass:"flex-1 coupon-content"},[i("v-uni-view",{class:0==e.is_expire&&0==e.is_use?e.color.text:""},[10==e.coupon_type.value?[i("v-uni-view",{staticClass:"price"},[i("v-uni-text",[t._v("￥")]),i("v-uni-text",{staticClass:"f40 fb"},[t._v(t._s(e.reduce_price))])],1)]:t._e(),20==e.coupon_type.value?[i("v-uni-text",{staticClass:"f40 fb"},[t._v(t._s(e.discount))]),i("v-uni-text",[t._v("折")])]:t._e()],2),i("v-uni-view",{staticClass:"f30"},[t._v(t._s(e.name))]),i("v-uni-view",{staticClass:"f24"},[10==e.expire_type?[t._v("有效期：领取"+t._s(e.expire_day)+"天内有效")]:t._e(),20==e.expire_type?[t._v("有效期："+t._s(e.start_time.text)+"至"+t._s(e.end_time.text))]:t._e()],2)],1),i("v-uni-view",{staticClass:"btns d-c-c"},[e.state.value>0?i("v-uni-button",{class:"btn-"+e.color.text,attrs:{type:"default"},on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.receive(e.coupon_id)}}},[t._v("立即领取")]):i("v-uni-button",{staticClass:"btn-gray",attrs:{type:"default"},on:{click:function(e){e.stopPropagation(),arguments[0]=e=t.$handleEvent(e)}}},[t._v(t._s(e.state.text))])],1)],1)],1),20==e.apply_range?i("v-uni-view",{staticClass:"range_item d-b-c",on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.gotoPage("/pages/coupon/detail?coupon_id="+e.coupon_id+"&apply_range="+e.apply_range)}}},[i("v-uni-view",[t._v("仅可购买指定部分商品")]),i("v-uni-view",[i("v-uni-text",{staticClass:"icon iconfont icon-jiantou",staticStyle:{color:"#999999","font-size":"24rpx"}})],1)],1):t._e(),30==e.apply_range?i("v-uni-view",{staticClass:"range_item d-b-c",on:{click:function(i){i.stopPropagation(),arguments[0]=i=t.$handleEvent(i),t.gotoPage("/pages/coupon/detail?coupon_id="+e.coupon_id+"&apply_range="+e.apply_range)}}},[i("v-uni-view",[t._v("仅可购买指定分类商品")]),i("v-uni-view",[i("v-uni-text",{staticClass:"icon iconfont icon-jiantou",staticStyle:{color:"#999999","font-size":"24rpx"}})],1)],1):t._e()],1)})):[i("v-uni-view",{staticClass:"none-data-box"},[i("v-uni-image",{attrs:{src:"/static/none.png",mode:"widthFix"}}),i("v-uni-text",[t._v("暂无数据")])],1)]],2)},o=[]},"80dc":function(t,e,i){var n=i("24fb");e=n(!1),e.push([t.i,".coupon-wrap[data-v-18b6704b]{padding:%?30?%}.item-wrap[data-v-18b6704b]{margin-bottom:%?20?%}.range_item[data-v-18b6704b]{border:%?1?% solid #d9d9d9;border-top:none;padding:%?8?%;border-bottom-left-radius:%?10?%;border-bottom-right-radius:%?10?%;color:#666;box-shadow:0 0 %?8?% rgba(0,0,0,.1)}",""]),t.exports=e},a78c:function(t,e,i){"use strict";i.r(e);var n=i("7097"),o=i("602e");for(var a in o)["default"].indexOf(a)<0&&function(t){i.d(e,t,(function(){return o[t]}))}(a);i("e479");var s=i("f0c5"),c=Object(s["a"])(o["default"],n["b"],n["c"],!1,null,"18b6704b",null,!1,n["a"],void 0);e["default"]=c.exports},bce5:function(t,e,i){"use strict";i("7a82"),Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{loadding:!0,indicatorDots:!0,autoplay:!0,interval:2e3,duration:500,DataList:[],page:1,list_rows:10}},onShow:function(){uni.showLoading({title:"加载中"}),this.getData()},methods:{getData:function(){var t=this;t._get("coupon.coupon/lists",{page:t.page,list_rows:t.list_rows},(function(e){t.DataList=e.data.list,console.log(t.DataList),t.loadding=!1,uni.hideLoading()}))},lookRule:function(t){t.rule=!0},closeRule:function(t){t.rule=!1},receive:function(t){uni.showLoading({title:"领取中"}),this._post("user.coupon/receive",{coupon_id:t},(function(t){uni.hideLoading(),uni.showToast({title:"领取成功",duration:2e3,icon:"success"})})),this.getData()}}};e.default=n},e394:function(t,e,i){var n=i("80dc");n.__esModule&&(n=n.default),"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var o=i("4f06").default;o("e0eaeb70",n,!0,{sourceMap:!1,shadowMode:!1})},e479:function(t,e,i){"use strict";var n=i("e394"),o=i.n(n);o.a}}]);