import{_ as w,d as S,aM as j,p as q,x as _,ai as z,bc as v,z as G,r as l,o as a,c as r,l as t,D as s,m as e,ar as L,a as n,G as y,aN as W,F as D}from"./index.js";import{c as H}from"./ticketReturn.8c918810.js";import"./porder.cb2a60e8.js";import{h as J,d as K}from"./index.80104a95.js";import{R as Q}from"./index.79a52a46.js";import X from"./return-form.0a435b.js";import Y from"./invoice-modal.328d4b.js";import{u as Z}from"./useDetail.748c7288.js";import"./orderRecord.bd0f73d4.js";import"./choose-modal.6bb55a.js";import"./_details.1548b92f.js";import"./date-range.019e953f.js";import"./_options.31f08d77.js";import"./invoice-table.f91ee7.js";import"./invoice-form.2e8999.js";import"./global.9ad647c8.js";import"./index.47e512cd.js";const $={class:"padding__container"},ee={key:0},te=S({__name:"detail",setup(oe){const N="supplyTicketReturnDetail",{hasPermissionWithCode:F}=j(N),{push:B}=q(),k=_(null),i=_(null),c=_(!0),{id:T,isDetail:p,title:R,collapses:m}=Z({baseName:"\u91C7\u8D2D\u5F00\u7968",collapseLen:20}),{isSuperUser:b}=z();v({success:()=>x()});const{run:A,data:o}=v({initalData:{}});function x(){d(),i.value&&i.value.refresh(),c.value=!1,G(()=>c.value=!0)}const{run:V}=v({success:()=>B("/supply/supplyTicketReturn")}),d=()=>A(J({hpNo:T.value})),g=E=>V(K(E));return p.value&&d(),(E,h)=>{const u=l("ElCollapseItem"),I=l("OrderRelationApproval"),M=l("OrderRelation"),O=l("ElCollapse"),P=l("ElTabPane"),U=l("ElTabs");return a(),r("div",$,[t(U,null,{default:s(()=>[t(P,{label:e(R)},{default:s(()=>[t(O,{modelValue:e(m),"onUpdate:modelValue":h[0]||(h[0]=f=>L(m)?m.value=f:null)},{default:s(()=>[t(u,{name:"1",title:e(R)},{default:s(()=>[n(" \u56DE\u7968\u8BE6\u60C5 "),e(p)?(a(),y(e(W),{key:0,columns:e(H)(f=>{var C;return(C=k.value)==null?void 0:C.onDisplay(f)}),data:e(o)},null,8,["columns","data"])):(a(),r(D,{key:1},[n(" \u521B\u5EFA\u56DE\u7968 "),t(X,{onCreate:g})],2112))]),_:1},8,["title"]),e(p)?(a(),r("div",ee,[t(u,{name:"2",title:"\u5BF9\u8D26\u8BE6\u60C5"},{default:s(()=>[t(e(Q),{ref_key:"formRef",ref:i,readonly:"",id:e(o).payNo},null,8,["id"])]),_:1}),e(o)&&["2","3","4","6","12"].includes(String(e(o).status))&&c.value?(a(),y(u,{key:0,title:"\u5173\u8054\u4FE1\u606F",name:"10"},{default:s(()=>[t(I,{readonly:"",code:e(o).hpNo},null,8,["code"])]),_:1})):n("v-if",!0),t(Y,{ref_key:"invoiceModalRef",ref:k},null,512),e(b)?n("v-if",!0):(a(),r(D,{key:1},[e(o)&&e(o).status=="11"&&e(F)("063")?(a(),y(u,{key:0,title:"\u5F85\u53D1\u7968\u4E0E\u8BA2\u5355\u5173\u8054",name:"8"},{default:s(()=>[t(M,{code:e(o).hpNo,payNo:e(o).payNo,onRefresh:d},null,8,["code","payNo"])]),_:1})):n("v-if",!0)],64))])):n("v-if",!0)]),_:1},8,["modelValue"])]),_:1},8,["label"])]),_:1})])}}});var Ee=w(te,[["__file","C:/Users/89793/Desktop/projects/settle-vue3/src/views/supply/ticketReturn/detail.vue"]]);export{Ee as default};
