1 |
- import{d as x,v as c,m as R,b5 as T,aX as O,r as p,o as d,E as f,B as o,j as B,u as i,M as I,L as E,I as V,aQ as y}from"./index.b2b87cd1.js";import{e as W,f as q,h as L}from"./index.20e50fbb.js";import{r as D}from"./columnRenderHelper.75250d33.js";import{k as M}from"./status.7cff7b18.js";import{u as U}from"./use-page-search.33590006.js";import{h as $}from"./export.90180929.js";import"./xlsx.ed122d16.js";const h=[{value:"1",label:"\u4E70\u65B9\u516C\u53F8\u4E1A\u52A1\u5BA1\u6838"},{value:"2",label:"\u5BA1\u6838\u6210\u529F"},{value:"3",label:"\u4E70\u5BB6\u9A73\u56DE"},{value:"4",label:"\u5DF2\u64A4\u9500\u5BF9\u8D26"}],j=[{value:"1",label:"\u56DE\u7968\u6807\u7B7E"},{value:"2",label:"\u4ED8\u6B3E\u6807\u7B7E"},{value:"3",label:"\u4ED8\u6B3E\u56DE\u7968\u6700\u5C11\u6709\u4E00\u4E2A"},{value:"4",label:"\u4ED8\u6B3E\u56DE\u7968\u90FD\u6709"}],z=[{type:"selection",width:40,align:"center"},{label:"\u5BF9\u8D26\u7F16\u7801",prop:"payNo",width:150,align:"left"},{label:"\u5BF9\u8D26\u603B\u989D",prop:"total_fee",width:110,align:"total_fee"},{label:"\u72B6\u6001",prop:"status",width:140,transform:u=>{var e;return((e=h.find(a=>u===a.value))==null?void 0:e.label)||"--"},...D(h)},{label:"\u4F9B\u5E94\u5546\u7AEF",prop:"has_account",width:80,...D(M,"has_account")},{label:"\u5356\u51FA\u65B9\u516C\u53F8\u7F16\u7801",prop:"supplierNo",width:150,align:"left"},{label:"\u5356\u51FA\u65B9\u516C\u53F8\u540D\u79F0",prop:"supplierName",minWidth:160,align:"left"},{label:"\u4E70\u5165\u65B9\u516C\u53F8\u7F16\u7801",prop:"companyNo",width:150,align:"left"},{label:"\u4E70\u5165\u65B9\u516C\u53F8\u540D\u79F0",prop:"companyName",minWidth:180,align:"left"},{label:"\u7533\u8BF7\u4EBA",prop:"apply_name",width:70,align:"left"},{label:"\u7533\u8BF7\u65F6\u95F4",width:140,prop:"addtime"},{label:"\u64CD\u4F5C",fixed:"right",width:135,slot:"operation"}],G={title:"\u8BA2\u5355\u5BF9\u8D26",columns:z,apis:{httpList:W,httpAdd:!0,httpDelete:q},superUserNoAction:!0,showDelete:()=>!1,payProps:{prop:"payNo",type:"1"},returnProps:{prop:"payNo",type:"2"},showPayTagFn:({status:u},e)=>String(u)==="2"&&e.includes("013"),showReturnTagFn:({status:u},e)=>String(u)==="2"&&e.includes("014")},v={formItems:[{field:"timer",type:"date_picker",otherOptions:{type:"daterange",startProp:"startTime",endProp:"endTime",startPlaceholder:"\u5F00\u59CB\u65E5\u671F",endPlaceholder:"\u7ED3\u675F\u65E5\u671F"}},{field:"supplierNo",type:"supplier-query"},{field:"status",type:"select",placeholder:"\u5BA1\u6838\u72B6\u6001",span:4,options:h},{field:"status",type:"select",placeholder:"\u6807\u7B7E\u72B6\u6001",span:4,options:j},{field:"group",type_field:"group_type",type:"input_group",otherOptions:{inputGroupOptions:[{value:"payNo",label:"\u5BF9\u8D26\u7F16\u7801"}]}}]},ee=x({__name:"index",setup(u){const e="orderRecord",a="/purchase/orderRecordDetail",n=c([]),l=c(!1),{push:m}=R(),g=c(null),{run:C}=T({success:()=>g.value.onSearch()}),{hasPermissionWithCode:_}=O("orderRecord"),b={pageSearchHook:()=>U(void 0,void 0,v)},A=s=>{C(L({payNo:s,status:"4"}))},w={content:{create:()=>m(a),preview:({payNo:s})=>m(`${a}?id=${s}`)}};async function N(){if(n.value.length===0){y.warning("\u8BF7\u9009\u62E9\u4E00\u6761\u5BF9\u8D26\u5355");return}if(n.value.length>1){y.warning("\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u5BF9\u8D26\u5355");return}await $({url:"paycgdexport",name:"\u5BF9\u8D26\u5355\u660E\u7EC6\u8868",onStart:()=>l.value=!0,onSuccess:()=>l.value=!1,onFail:()=>l.value=!1,params:{payNo:n.value[0].payNo}})}return(s,r)=>{const F=p("ElButton"),P=p("ElTooltip"),k=p("PageContainer"),S=p("PageAuth");return d(),f(S,{pageName:e},{default:o(()=>[B(k,{hooks:b,events:w,contentConfig:i(G),"search-config":i(v),"get-content-ref":t=>g.value=t,onContentSelectChange:r[1]||(r[1]=t=>n.value=t)},{content_header:o(()=>[i(_)("038")?(d(),f(F,{key:0,size:"small",loading:l.value,onClick:r[0]||(r[0]=()=>N())},{default:o(()=>[I(" \u5BF9\u8D26\u5355\u660E\u7EC6\u5BFC\u51FA ")]),_:1},8,["loading"])):E("",!0)]),content_action:o(t=>[B(P,{placement:"top",content:"\u64A4\u9500\u5BF9\u8D26\u7533\u8BF7"},{default:o(()=>[String(t.status)==="2"?(d(),f(F,{key:0,type:"primary",link:"",text:"",icon:i(V)("refresh-right"),onClick:()=>A(t.payNo)},null,8,["icon","onClick"])):E("",!0)]),_:2},1024)]),_:1},8,["contentConfig","search-config","get-content-ref"])]),_:1})}}});export{ee as default};
|