"use strict";const e=require("../../common/vendor.js"),c=require("../../hooks/useNav.js"),o=require("../../api/api.js");if(!Array){(e.resolveComponent("up-icon")+e.resolveComponent("up-tag")+e.resolveComponent("z-paging")+e.resolveComponent("up-button"))()}Math||((()=>"../../uni_modules/uview-plus/components/u-icon/u-icon.js")+(()=>"../../uni_modules/uview-plus/components/u-tag/u-tag.js")+(()=>"../../uni_modules/z-paging/components/z-paging/z-paging.js")+(()=>"../../uni_modules/uview-plus/components/u-button/u-button.js"))();const t={__name:"invoice",setup(t){const{nav:n,navTo:a}=c.useNav(),l=e.ref([]),i=e.ref(null),u=async(c,t)=>{const n={current:c,pageSize:t};o.invoiceList(n).then((c=>{i.value.complete(c),e.index.hideLoading()})).catch((c=>{i.value.complete(!1),e.index.hideLoading()}))};let s=()=>!i.value;return e.onPullDownRefresh((()=>{s()||i.value.reload().catch((()=>{}))})),e.onPageScroll((e=>{s()||(i.value.updatePageScrollTop(e.scrollTop),e.scrollTop<10&&i.value.doChatRecordLoadMore())})),e.onReachBottom((()=>{s()||i.value.pageReachBottom()})),(c,o)=>({a:e.p({name:"error-circle-fill",color:"#3c9cff"}),b:e.f(l.value,((c,o,t)=>e.e({a:"c39f8dcc-2-"+t+",c39f8dcc-1",b:e.t(c.createTime),c:"c39f8dcc-3-"+t+",c39f8dcc-1",d:e.t(c.invoiceTitle),e:e.t(c.merchantInvoice||"-"),f:0==c.status},0==c.status?{g:"c39f8dcc-4-"+t+",c39f8dcc-1",h:e.p({text:"待开票",type:"warning",plain:!0,plainFill:!0})}:{},{i:1==c.status},1==c.status?{j:"c39f8dcc-5-"+t+",c39f8dcc-1",k:e.p({text:"已开票",type:"success",plain:!0,plainFill:!0})}:{},{l:-1==c.status},-1==c.status?{m:"c39f8dcc-6-"+t+",c39f8dcc-1",n:e.p({text:"取消",type:"error",plain:!0,plainFill:!0})}:{},{o:e.t(c.invoiceAmount),p:o}))),c:e.p({name:"clock-fill"}),d:e.p({name:"arrow-right"}),e:e.sr(i,"c39f8dcc-1",{k:"paging"}),f:e.o(u),g:e.o((e=>l.value=e)),h:e.p({"use-page-scroll":!0,modelValue:l.value}),i:e.o((c=>e.unref(a)("/pageMake/invoice/applyFor"))),j:e.p({customStyle:{height:"80rpx"},color:"#4879e6",text:"申请开票",shape:"circle"})})}},n=e._export_sfc(t,[["__scopeId","data-v-c39f8dcc"]]);t.__runtimeHooks=1,wx.createPage(n);
