1 |
- import{am as s,da as x,aR as r,de as N,cJ as I,cK as O,ae as g,bO as j,_ as H,d as V,aM as J,ai as L,x as h,p as Q,W,r as y,o as c,G as p,D as a,l as _,m as o,J as F,M as C,a as D,bd as $}from"./index.js";import{a as q}from"./index.26d6ac45.js";import G from"./invoice-modal.8d64a9.js";import{h as K}from"./export.fc82d641.js";import{u as v,w as X}from"./xlsx.ed122d16.js";import Z from"./index.20e22e.js";import"./index.bf16817a.js";import"./execl-upload.7c83427b.js";const ee=[{type:"selection",width:40,align:"center",hide:({checkList:e})=>!e.includes("\u52FE\u9009\u5217")},{label:"\u5E8F\u53F7",type:"index",width:70,hide:({checkList:e})=>!e.includes("\u5E8F\u53F7\u5217")},{label:"\u5BF9\u8D26\u56DE\u7968\u7533\u8BF7",prop:"hpNo",width:160},{label:"\u5BF9\u8D26\u7F16\u7801",prop:"payNo",width:150},{label:"\u72B6\u6001",prop:"status",width:140,cellRenderer:({row:e,props:u})=>s(r,{size:u.size},{default:()=>{var t;return(t=x.find(n=>String(e.status)===String(n.value)))==null?void 0:t.label}})},{label:"\u53D1\u7968\u67E5\u9A8C\u65B9\u5F0F",width:100,cellRenderer:({row:e,props:u})=>s(r,{size:u.size},{default:()=>{var t;return(t=N.find(n=>String(e.checkApi)===n.value))==null?void 0:t.label}})},{label:"\u53D1\u7968\u7A0E\u524D\u91D1\u989D",width:"110px",prop:"inv_subtotal_amount"},{label:"\u53D1\u7968\u7A0E\u540E\u91D1\u989D",width:"110px",prop:"total"},{label:"\u8D2D\u4E70\u65B9\u62AC\u5934\u72B6\u6001",prop:"seller_check",width:135,cellRenderer:({row:e})=>s(r,null,{default:()=>{var u;return((u=I.find(t=>t.value==e.seller_check+""))==null?void 0:u.label)||"--"}})},{label:"\u9500\u552E\u65B9\u62AC\u5934\u72B6\u6001",prop:"buyer_check",width:135,cellRenderer:({row:e})=>s(r,null,{default:()=>{var u;return((u=O.find(t=>t.value==e.buyer_check+""))==null?void 0:u.label)||"--"}})},{label:"\u53D1\u7968\u53F7\u7801",width:110,prop:"invoiceNumber"},{label:"\u53D1\u7968\u4EE3\u7801",width:110,prop:"invoiceCode"},{label:"\u5F00\u7968\u65E5\u671F",prop:"open_time",width:120,formatter:({open_time:e})=>e?g(e).format("YYYY-MM-DD"):""},{label:"\u53D1\u7968\u72B6\u6001",width:110,prop:"invStatus_cn"},{label:"\u53D1\u7968\u7C7B\u578B",width:200,cellRenderer({row:e}){return s(r,null,{default:()=>{var u;return((u=j.find(({value:t})=>t===e.invoiceType))==null?void 0:u.label)||"--"}})}},{label:"\u7533\u8BF7\u4EBA",prop:"apply_name"},{label:"\u521B\u5EFA\u65F6\u95F4",prop:"addtime",width:180,formatter:({addtime:e})=>g(e).format("YYYY-MM-DD HH:mm:ss")},{label:"\u64CD\u4F5C",fixed:"right",slot:"operation",width:50}],ue={title:"\u91C7\u8D2D\u56DE\u7968",statusProp:"companyNo",columns:ee,apis:{httpList:q},deleteProp:"hpNo",delTooltip:"\u662F\u5426\u64A4\u56DE\u91C7\u8D2D\u56DE\u7968\u7533\u8BF7",superUserNoAction:!0,showDelete:({status:e})=>Number(e)<=3},A={formItems:[{field:"status",type:"select",placeholder:"\u5BA1\u6838\u72B6\u6001",options:x},{field:"checkApi",type:"select",placeholder:"\u53D1\u7968\u67E5\u9A8C\u65B9\u5F0F",options:N},{field:"payNo",type:"input",placeholder:"\u5BF9\u8D26\u7F16\u7801"},{field:"hpNo",type:"input",placeholder:"\u5BF9\u8D26\u7533\u8BF7\u7F16\u7801"},{field:"apply_name",type:"input",placeholder:"\u7533\u8BF7\u4EBA"},{field:"create_timer",type:"date_picker",otherOptions:{type:"daterange",startProp:"start",endProp:"end",startPlaceholder:"\u65B0\u5EFA\u8D77\u59CB\u65F6\u95F4",endPlaceholder:"\u65B0\u5EFA\u7ED3\u675F\u65F6\u95F4"}}]},te={\u4E70\u65B9\u516C\u53F8\u7F16\u7801:"",\u56DE\u7968\u7533\u8BF7\u7F16\u7801:"",\u5BF9\u8D26\u7F16\u7801:"",\u5BA1\u6838\u72B6\u6001:"",\u5BA1\u6838\u5907\u6CE8:""},oe=V({__name:"index",setup(e){const u="sellInvoiceQuery",t="/purchase/ticketReturnDetail",n=["4","10"],{hasPermissionWithCode:B}=J(u),{isSuperUser:R}=L(),E=h(null),{push:k}=Q(),{currentCompany:P}=W(),d=h(!1),b=h(null),w=h(null);async function S(){await K({url:"ile",name:"\u56DE\u7968\u6570\u636E\u8868",onStart:()=>d.value=!0,onSuccess:()=>d.value=!1,onFail:()=>d.value=!1,params:{companyNo:P.value.companyNo,...E.value.getBasicParams()}})}const M={pageSearchHook:()=>$(void 0,void 0,A)},T={content:{preview:({hpNo:i})=>k(`${t}?id=${i}`),create:()=>k(t)}};function U(){const i=v.book_new(),l=v.json_to_sheet([te]);v.book_append_sheet(i,l,"sheet"),X(i,"\u6279\u91CF\u5BFC\u5165\u56DE\u7968\u6A21\u677F.xlsx",{bookType:"xlsx"})}return(i,l)=>{const f=y("ElButton"),Y=y("PageContainer"),z=y("PageAuth");return c(),p(z,{pageName:u},{default:a(()=>[_(Y,{hooks:M,events:T,contentConfig:o(ue),"search-config":o(A),"get-content-ref":m=>E.value=m},{content_header:a(()=>[o(B)("017")?(c(),p(f,{key:0,size:"small",icon:o(F)("arrow-down-line"),loading:d.value,onClick:l[0]||(l[0]=()=>S())},{default:a(()=>[C("\u5BFC\u51FA\u56DE\u7968\u6570\u636E")]),_:1},8,["icon","loading"])):D("v-if",!0),o(B)("018")&&!o(R)?(c(),p(f,{key:1,size:"small",icon:o(F)("arrow-up-line"),onClick:l[1]||(l[1]=()=>w.value.onDisplay())},{default:a(()=>[C("\u6279\u91CF\u5BFC\u5165\u8BA4\u8BC1\u7ED3\u679C")]),_:1},8,["icon"])):D("v-if",!0),o(B)("019")?(c(),p(f,{key:2,size:"small",icon:o(F)("arrow-down-line"),onClick:l[2]||(l[2]=()=>U())},{default:a(()=>[C("\u4E0B\u8F7D\u8BA4\u8BC1\u6A21\u677F")]),_:1},8,["icon"])):D("v-if",!0)]),content_action:a(m=>[n.includes(String(m.status))?(c(),p(f,{key:0,link:"",type:"primary",icon:o(F)("scaletooriginal"),onClick:()=>b.value.onDisplay(m)},null,8,["icon","onClick"])):D("v-if",!0)]),_:1},8,["contentConfig","search-config","get-content-ref"]),_(G,{ref_key:"invoiceModalRef",ref:b},null,512),_(Z,{ref_key:"execelUploadRef",ref:w},null,512)]),_:1})}}});var de=H(oe,[["__file","C:/Users/89793/Desktop/projects/settle-vue3/src/views/supply/sellInvoiceQuery/index.vue"]]);export{de as default};
|