1 |
- import{d as S,D as c,z as x,aZ as R,bo as T,w as p,o as d,M as f,J as o,x as B,u as i,T as E,Q as O,W,aS as y}from"./index.3f1baf7c.js";import{d as I,e as V,h as q}from"./index.549cfc82.js";import{r as z}from"./columnRenderHelper.f0c4dba2.js";import{u as M}from"./use-page-search.2d986760.js";import{h as U}from"./export.1ffd744c.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"}],$=[{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"}],G=[{type:"selection",minWidth:55,align:"left"},{label:"\u5BF9\u8D26\u7F16\u53F7",prop:"payNo",width:160,align:"left"},{label:"\u72B6\u6001",prop:"status",width:140,transform:u=>{var e;return((e=h.find(a=>u===a.value))==null?void 0:e.label)||"--"},...z(h)},{label:"\u5BF9\u8D26\u603B\u989D",prop:"total_fee",width:110,align:"total_fee"},{label:"\u5356\u51FA\u65B9\u516C\u53F8\u7F16\u53F7",prop:"supplierNo",width:155,align:"left"},{label:"\u5356\u51FA\u65B9\u516C\u53F8\u540D\u79F0",prop:"supplierName",minWidth:160,align:"left"},{label:"\u4E70\u5165\u65B9\u516C\u53F8\u7F16\u53F7",prop:"companyNo",width:160,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"}],H={title:"\u8BA2\u5355\u5BF9\u8D26",columns:G,apis:{httpList:I,httpAdd:!0,httpDelete:V},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")},D={formItems:[{field:"group",type_field:"group_type",type:"input_group",otherOptions:{inputGroupOptions:[{value:"payNo",label:"\u5BF9\u8D26\u7F16\u53F7"}]}},{field:"supplierNo",type:"supplier-query"},{field:"timer",type:"date_picker",otherOptions:{type:"daterange",startProp:"startTime",endProp:"endTime",startPlaceholder:"\u5F00\u59CB\u65E5\u671F",endPlaceholder:"\u7ED3\u675F\u65E5\u671F"}},{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=W(" \u5BF9\u8D26\u5355\u660E\u7EC6\u5BFC\u51FA "),Y=S({__name:"index",setup(u){const e="orderRecord",a="/purchase/orderRecordDetail",n=c([]),l=c(!1),{push:F}=x(),m=c(null),{run:C}=R({success:()=>m.value.onSearch()}),{hasPermissionWithCode:v}=T("orderRecord"),_={pageSearchHook:()=>M(void 0,void 0,D)},b=s=>{C(q({payNo:s,status:"4"}))},A={content:{create:()=>F(a),preview:({payNo:s})=>F(`${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 U({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 g=p("ElButton"),w=p("ElTooltip"),P=p("PageContainer"),k=p("PageAuth");return d(),f(k,{pageName:e},{default:o(()=>[B(P,{hooks:_,events:A,contentConfig:i(H),"search-config":i(D),"get-content-ref":t=>m.value=t,onContentSelectChange:r[1]||(r[1]=t=>n.value=t)},{content_header:o(()=>[i(v)("038")?(d(),f(g,{key:0,size:"small",loading:l.value,onClick:r[0]||(r[0]=()=>N())},{default:o(()=>[J]),_:1},8,["loading"])):E("",!0)]),content_action:o(t=>[B(w,{placement:"top",content:"\u64A4\u9500\u5BF9\u8D26\u7533\u8BF7"},{default:o(()=>[String(t.status)==="2"?(d(),f(g,{key:0,type:"primary",link:"",text:"",icon:i(O)("refresh-right"),onClick:()=>b(t.payNo)},null,8,["icon","onClick"])):E("",!0)]),_:2},1024)]),_:1},8,["contentConfig","search-config","get-content-ref"])]),_:1})}}});export{Y as default};
|