import{_ as R,d as T,m as V,az as j,b9 as I,w as u,a6 as K,bn as U,x as q,r as f,o as n,c as v,b as _,l as h,C as y,F as A,D as F,u as G,G as k,I as H,b2 as N}from"./index.85ca7aac.js";import{h as O}from"./index.877c66b8.js";import{Q as i}from"./query.9a76e9ea.js";import{i as Q}from"./context.bdf6d636.js";import S from"./anchor.ae590bec.js";import"./index.f7764979.js";import"./purchase.8555e866.js";import"./types.0693477d.js";import"./porder.ec73c70a.js";import"./tootip.5dab9731.js";import"./status.367fcae1.js";import"./basic-descriptions.72d76943.js";import"./index.574a3c00.js";import"./reconciliation.9c98e6b2.js";import"./index.d48809bc.js";import"./index.619532cf.js";import"./sale.2f5cfd12.js";import"./sale.8f7a80ec.js";import"./index.6d440e94.js";import"./payment.3b647d10.js";import"./purchPay.0e8f3d24.js";import"./index.d7625f11.js";import"./ticket-return.5e019c9c.js";import"./ticketReturn.58cc42df.js";import"./index.16772edf.js";import"./tradelog.e28f1465.js";import"./tragelog.254367fc.js";import"./index.574d3558.js";import"./trade.339334a3.js";import"./index.dababe73.js";import"./refund.b1651608.js";import"./index.ae4b1d19.js";import"./inv-return.cf34e0cc.js";import"./inv-return.811ed82a.js";import"./index.af3b8070.js";import"./inv-open.a63fbc55.js";import"./inv-open.bf0f4f2d.js";const z={class:"main flex h-full"},L={"bg-white":"","min-w-230px":""},Y={"bg-white":"","flex-1":""},J=T({__name:"detail",setup(W){const{query:D}=V(),g=j(),p=I([]),l=u([]),r=u(new Map),d=u({}),w=K(()=>D.id),C=(e,t)=>{var s;const o=i[e].responseKey;return t[o]&&((s=i[e])==null?void 0:s.detail)&&t[o].length!==0};function x(e){return Object.keys(i).filter(o=>C(o,e)).map(o=>{const{api:s,component:a,requesetProp:m,responseKey:c,detail:M}=i[o],P=e[c];return{component:a,prop:m,title:M,api:s,value:P,key:o}})}async function b(){const{code:e,message:t,data:o}=await O({id:w.value});g({code:e,message:t,handler:()=>p.value=x(o)})}async function E(){await b(),p.value.forEach((e,t)=>{l.value.push(e.key),r.value.set(e.title,{top:"",index:t})})}function B(e,t){const o=r.value.get(t);r.value.set(t,{...o,top:e})}return U(Q,{goodData:d,setGoodData:e=>d.value=e}),q(()=>E()),(e,t)=>{const o=f("ElCollapseItem"),s=f("ElCollapse");return n(),v("div",z,[_("div",L,[h(S,{map:r.value},null,8,["map"])]),_("div",Y,[h(s,{modelValue:l.value,"onUpdate:modelValue":t[1]||(t[1]=a=>l.value=a)},{default:y(()=>[(n(!0),v(A,null,F(G(p),a=>(n(),k(o,{title:a.title,name:a.key,key:a.key},{default:y(()=>[(n(),k(H(a.component),N(a,{onMapOffsetTop:t[0]||(t[0]=({top:m,title:c})=>B(m,c))}),null,16))]),_:2},1032,["title","name"]))),128))]),_:1},8,["modelValue"])])])}}});var Ie=R(J,[["__file","/Users/apple/Desktop/CompanyProjects/accout-vue3-ui/src/views/search/standBook/detail.vue"]]);export{Ie as default};