import{u as U}from"./useFormEdit-fb8b8504-1782729249161v=1.0.0.js";import Z from"./EventHeaderInfo-ec298267-1782729249161v=1.0.0.js";import z from"./index-51e28c39-1782729249161v=1.0.0.js";import J from"./index-6acc3de6-1782729249161v=1.0.0.js";import Q from"./index-835d8e4f-1782729249161v=1.0.0.js";import G from"./index-6ed9d1e7-1782729249161v=1.0.0.js";import{u as K}from"./useSignupDetailhooks-1184235c-1782729249161v=1.0.0.js";import{p as W}from"./signupApi-7b1b451c-1782729249161v=1.0.0.js";import{a as X,_ as Y}from"./index-b309bf9f-1782729249161v=1.0.0.js";import{E as D}from"./eleVendor-5008d1ec-1782729249161v=1.0.0.js";import{y as M,r as f,c as y,m as $,al as i,z as a,I as u,J as _,R as P,u as e,k as ee,A as F,Q as te,a4 as oe,M as o}from"./vendor-1e24e3ad-1782729249161v=1.0.0.js";import"./keepAlive-20a782c5-1782729249161v=1.0.0.js";import"./SignUpUserDialog.vue_vue_type_script_setup_true_lang-e7611bd6-1782729249161v=1.0.0.js";import"./AddFormItemLine-259ea6b2-1782729249161v=1.0.0.js";import"./Imgs-0a9c1d5a-1782729249161v=1.0.0.js";import"./useDynamicFormHook-140c1b9e-1782729249161v=1.0.0.js";import"./TableItemShow-c2b3e38a-1782729249161v=1.0.0.js";import"./index.vue_vue_type_script_setup_true_lang-07f392b0-1782729249161v=1.0.0.js";import"./SignUpUnitDialog.vue_vue_type_script_setup_true_lang-68978cc6-1782729249161v=1.0.0.js";import"./SporterDataview-cd9f8cee-1782729249161v=1.0.0.js";import"./SporterDataview-42046263-1782729249161v=1.0.0.js";const ae={key:4,class:"loading-container"},ne=M({name:"signupDetail"}),re=M({...ne,props:{pageType:{type:String,default:"event"}},setup(h){const k=h,{closeCurrent:c}=U(),I=X();f(!0),y(()=>I.query.id);const l=y(()=>I.query.eventApplyMainId),m=y(()=>I.query.eventTermId),g=y(()=>r.value.eventProjectType),j=f([]),n=f([]),C=f(!1),B=t=>{C.value=!0},L=async()=>{if(n.value.length===0){D.warning("\u9879\u76EE\u4E0D\u80FD\u4E3A\u7A7A");return}if(C.value!==!1){C.value=!1;try{const t=await W({eventProjectIdList:n.value,eventApplyMainId:r.value.eventApplyMainId});t.code===0?D.success("\u9879\u76EE\u4FDD\u5B58\u6210\u529F"):D.error(t.msg)}catch(t){D.error(t)}}},{getSignupInfoData:w,getSignupCustomFieldDataDTOData:ue,eventDetail:r,personBaseData:S,getSignupInfoCustomDataByTermIdData:V,unitBaseData:x,groupBaseData:E,doubleBaseData:b}=K(l.value,k.pageType),s=y(()=>r.value.eventApplyMode),A=f(!1);$(async()=>{var v;A.value=!0,await V(m.value),await w(l.value),s.value,E.value,r.value;let t=[];if(r.value.eventProjectType==="much")switch(s.value){case"group":t=E.value.eventTermProjectListRespVOList;break;case"double":t=b.value.eventTermProjectListRespVOList;break}j.value=t==null?void 0:t.map(p=>({label:p.projectName,value:p.eventProjectId})),n.value=((v=r.value.eventProjectIds)==null?void 0:v.split(",").map(p=>Number(p)))||[],A.value=!1});const T=()=>{c()};return(t,v)=>{const p=i("el-option"),R=i("el-select"),N=i("el-form-item"),q=i("el-empty"),H=i("el-form"),O=i("HZPageLayout");return a(),u(O,{isBack:!0,title:e(I).meta.title},{default:_(()=>[P(H,{ref:"formRef"},{default:_(()=>[P(Z,{eventDetail:e(r)},{default:_(()=>[e(j).length>0?(a(),u(N,{key:0,label:"\u9879\u76EE\u9009\u62E9",prop:"type"},{default:_(()=>[P(R,{modelValue:e(n),"onUpdate:modelValue":v[0]||(v[0]=d=>ee(n)?n.value=d:null),multiple:"",style:{width:"100%"},onChange:B,onBlur:L},{default:_(()=>[(a(!0),F(te,null,oe(e(j),d=>(a(),u(p,{key:d.value,label:d.label,value:d.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})):o("v-if",!0)]),_:1},8,["eventDetail"]),o(" \u4E2A\u4EBA\u62A5\u540D\u4FE1\u606F "),e(s)==="person"?(a(),u(z,{key:0,eventProjectType:e(g),baseInfo:e(S),applyMainId:e(l),eventTermId:e(m),onCancel:e(c),onSubmit:T,showAdd:!0,pageType:"edit"},null,8,["eventProjectType","baseInfo","applyMainId","eventTermId","onCancel"])):o("v-if",!0),o(" \u5355\u4F4D\u62A5\u540D\u4FE1\u606F "),e(s)==="unit"?(a(),u(Q,{key:1,eventProjectType:e(g),baseInfo:e(x),applyMainId:e(l),eventTermId:e(m),onCancel:e(c),onSubmit:T,showAdd:!0,pageType:"edit"},null,8,["eventProjectType","baseInfo","applyMainId","eventTermId","onCancel"])):o("v-if",!0),o(" \u56E2\u961F\u62A5\u540D\u4FE1\u606F "),e(s)==="group"?(a(),u(J,{key:2,eventTermId:e(m),eventProjectType:e(g),baseInfo:e(E),applyMainId:e(l),onCancel:e(c),onSubmit:T,pageType:"edit",eventProjectIdList:e(n)},null,8,["eventTermId","eventProjectType","baseInfo","applyMainId","onCancel","eventProjectIdList"])):o("v-if",!0),o(" \u53CC\u4EBA\u62A5\u540D\u4FE1\u606F "),e(s)==="double"?(a(),u(G,{key:3,eventProjectType:e(g),baseInfo:e(b),applyMainId:e(l),eventTermId:e(m),onCancel:e(c),onSubmit:T,showAdd:!0,pageType:"edit",eventProjectIdList:e(n)},null,8,["eventProjectType","baseInfo","applyMainId","eventTermId","onCancel","eventProjectIdList"])):o("v-if",!0),e(A)?(a(),F("div",ae,[P(q,{description:"\u52A0\u8F7D\u4E2D..."})])):o("v-if",!0)]),_:1},512)]),_:1},8,["title"])}}});const Fe=Y(re,[["__scopeId","data-v-328f6e49"]]);export{Fe as default};
