"use strict";var t=require("../common/vendor.js"),r=require("../api/user.js"),u=require("../uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js");require("../common/request.js");const c={name:"UserCoupon",props:{},mixins:[u.MescrollMixin],data:function(){return{tabs:[{id:0,name:"\u5F85\u4F7F\u7528"},{id:1,name:"\u5DF2\u4F7F\u7528"},{id:2,name:"\u5DF2\u8FC7\u671F"}],status:0,mescroll:null,downOption:{use:!0,auto:!1},upOption:{onScroll:!1,use:!0,page:{pae:0,size:10},noMoreSize:10,textNoMore:"\u5DF2\u7ECF\u5230\u5E95\u4E86",empty:{icon:"https://cos.his.cdwjyyh.com/fs/20240423/cf4a86b913a04341bb44e34bb4d37aa2.png",tip:"\u6682\u65E0\u6570\u636E"}},dataList:[]}},watch:{},onShow(){},methods:{statusChange(a){console.log(a),this.status=a.id,this.mescroll.resetUpScroll()},navTo(a){t.index.navigateTo({url:a})},mescrollInit(a){this.mescroll=a},downCallback(){this.mescroll.resetUpScroll()},upCallback(a){var o=this,n={status:this.status,pageNum:a.num,pageSize:a.size};r.getMyCouponList(n).then(e=>{e.code==200?(a.num==1?o.dataList=e.data.list:o.dataList=o.dataList.concat(e.data.list),o.mescroll.endBySize(e.data.list.length,e.data.total)):(t.index.showToast({icon:"none",title:"\u8BF7\u6C42\u5931\u8D25"}),o.dataList=null,o.mescroll.endErr())})}}};if(!Array){const a=t.resolveComponent("u-tabs"),o=t.resolveComponent("mescroll-body");(a+o)()}const i=()=>"../uni_modules/uview-plus/components/u-tabs/u-tabs.js",d=()=>"../uni_modules/mescroll-uni/components/mescroll-body/mescroll-body.js";Math||(i+d)();function p(a,o,n,e,_,l){return{a:t.o(l.statusChange),b:t.p({current:a.status,scrollable:!1,list:a.tabs,lineColor:"#C39A58"}),c:t.f(a.dataList,(s,b,h)=>t.e({a:s.status==0},s.status==0?{}:{},{b:s.status!=0},s.status!=0?{}:{},{c:s.price!=null},s.price!=null?{d:t.t(s.price.toFixed(2))}:{},{e:s.minPrice!=null},s.minPrice!=null?{f:t.t(s.minPrice.toFixed(2))}:{},{g:t.t(s.title),h:s.status==0||s.status==2},s.status==0||s.status==2?{i:t.t(s.limitTime)}:{},{j:s.status==1},s.status==1?{k:t.t(s.useTime)}:{},{l:s.status==1},s.status==1?{}:{},{m:s.status==2},s.status==2?{}:{},{n:s.status==0},s.status==0?{}:{})),d:t.sr("mescrollRef","a740e5ca-1"),e:t.o(l.mescrollInit),f:t.o(l.downCallback),g:t.o(l.upCallback),h:t.p({top:"88rpx",bottom:"0",down:a.downOption,up:a.upOption})}}var m=t._export_sfc(c,[["render",p],["__scopeId","data-v-a740e5ca"],["__file","E:/Project/2023/\u95EE\u8BCA\u5E73\u53F0/his_user_miniapp/pages_user/myCouponList.vue"]]);wx.createPage(m);
