import{_ as w}from"./DUQr9DrG.js";import{_ as L}from"./-OJeObNb.js";import{_ as x}from"./gxHWKiUc.js";import{_ as C}from"./4FMzYxPj.js";import P from"./CJYlvWEf.js";import{u as S,a as j}from"./G-fJibjS.js";import{d,b as m,o as a,w as n,e as u,f as e,g as o,R as p,M as G,a as A,F as E,E as v,A as z}from"./JQJBiNWj.js";import{_ as Z}from"./BKjSwDAM.js";import q from"./Cr9ZZaT-.js";import{_ as H}from"./DUfBvrYn.js";import{_ as J}from"./G7u0egV4.js";import{_ as K}from"./D_VCVGq0.js";import Q from"./D42GNhrT.js";import{h as W}from"./CH1bAkoS.js";import{D as T}from"./DKM0wLqG.js";import{T as X}from"./BKl0aY3w.js";import{E as Y}from"./Cs-oNAkj.js";import{u as oo}from"./CL7Msd7o.js";import{u as eo}from"./f6QOa6wf.js";import"./BwwR4PPN.js";import"./B6O9xiO5.js";import"./HM4z-iuB.js";import"./DqVYbxj5.js";import"./CxkaGOlL.js";import"./BgAkS4D_.js";import"./CcHzNBpc.js";import"./C_Bx0xg7.js";import"./Dm5UwSfy.js";import"./Dc_YXEFz.js";import"./CeWG_dyW.js";import"./CDSORL4U.js";import"./F98GHXdS.js";import"./D7gSulp_.js";import"./-CGeDbWH.js";import"./ChMy_Kon.js";import"./yKVtex9U.js";import"./CbtPaznW.js";import"./DmwTwIPt.js";import"./B-La3K3C.js";import"./DvBDpJyt.js";import"./FcRkkR--.js";import"./Dk4pWsnS.js";import"./BSHuRY0P.js";import"./BBDFeM-T.js";import"./BuR5k2Xw.js";import"./ClVEEBFD.js";import"./2JTb7YQn.js";import"./3oa0FK2h.js";import"./BHFADP6o.js";import"./CXVd19p6.js";import"./Bli8EQqv.js";import"./BagArUDo.js";import"./CRodc3LN.js";import"./DncddsCV.js";import"./DNRi6U01.js";import"./BYfmWBgX.js";import"./BWs0r_ue.js";import"./CpvritYQ.js";import"./BlGPNclf.js";const to={class:"base-grid"},no=d({__name:"InformacoesGerais",setup(f){const t=S();return(_,c)=>{const s=P,i=x,r=C;return a(),m(r,{title:"Informações gerais"},{default:n(()=>[u("div",to,[e(i,{name:"nomeTunel",label:"Nome:",class:"col-span-12 lg:col-span-4"},{default:n(()=>[e(s,{id:"nomeTunel",name:"nomeTunel",disabled:!o(t)},null,8,["disabled"])]),_:1}),e(i,{name:"codigoSir",label:"Código do SIR:",class:"col-span-12 lg:col-span-3"},{default:n(()=>[e(s,{id:"codigo-sir",name:"codigoSir",disabled:!o(t)},null,8,["disabled"])]),_:1})])]),_:1})}}}),io=Object.assign(no,{__name:"AtivosElementoTuneisInformacoesGerais"}),ao={class:"base-grid"},so=d({__name:"Caracteristicas",setup(f){const t=S();return(_,c)=>{const s=q,i=x,r=C;return a(),m(r,{title:"Características"},{default:n(()=>[u("div",ao,[e(i,{name:"comprimento",label:"Comprimento (m):",class:"col-span-12 lg:col-span-3"},{default:n(()=>[e(s,{id:"comprimento",name:"comprimento",placeholder:"0,00","min-fraction-digits":2,"max-fraction-digits":2,disabled:!o(t)},null,8,["disabled"])]),_:1}),e(i,{name:"largura",label:"Largura (m):",class:"col-span-12 lg:col-span-3"},{default:n(()=>[e(s,{id:"largura",name:"largura",placeholder:"0,00","min-fraction-digits":2,"max-fraction-digits":2,disabled:!o(t)},null,8,["disabled"])]),_:1}),e(i,{name:"altura",label:"Altura (m):",class:"col-span-12 lg:col-span-3"},{default:n(()=>[e(s,{id:"altura",name:"altura",placeholder:"0,00","min-fraction-digits":2,"max-fraction-digits":2,disabled:!o(t)},null,8,["disabled"])]),_:1}),e(i,{name:"profundidade",label:"Profundidade (m):",class:"col-span-12 lg:col-span-3"},{default:n(()=>[e(s,{id:"profundidade",name:"profundidade",placeholder:"0,00","min-fraction-digits":2,"max-fraction-digits":2,disabled:!o(t)},null,8,["disabled"])]),_:1})])]),_:1})}}}),mo=Object.assign(so,{__name:"AtivosElementoTuneisCaracteristicas"}),ro={class:"flex flex-col gap-5"},be=d({__name:"[id]",setup(f){const t=oo({view:p.ATV_VISUALIZAR_CADASTRO_TUNEIS,add:p.ATV_EDITAR_CADASTRO_TUNEIS,remove:p.ATV_REMOVER_CADASTRO_TUNEIS}),{ready:_,elementoId:c,idTitle:s,isEditMode:i,initialValues:r,isSubmiting:k,refreshForm:I,toggleEditMode:g,handleSubmitForm:h,deleteElemento:R}=j(X.Tuneis,t.value.add,t.value.view),U=W(Y),b=G("formRef");return eo(b),(lo,co)=>{const F=w,y=L,$=io,N=Z,M=mo,V=H,l=J,D=z,O=K,B=Q;return a(),A(E,null,[e(F,{title:`Cadastros - Túneis ${o(s)}`},null,8,["title"]),u("div",ro,[o(_)?(a(),m(B,{ref_key:"formRef",ref:b,key:o(I),resolver:o(U),"initial-values":o(r),class:"space-y-10",onSubmit:o(h)},{default:n(()=>[e($),e(N),e(M),e(V),e(O,{"show-menu":!0},{default:n(()=>[o(i)&&o(c)!==o(T)?(a(),A(E,{key:0},[o(t).remove?(a(),m(l,{key:0,mode:"delete",class:"max-sm:w-full",onClick:o(R)},null,8,["onClick"])):v("",!0),e(l,{mode:"cancel",class:"ms-auto",onClick:o(g)},null,8,["onClick"])],64)):(a(),m(D,{key:1,to:"./",class:"ms-auto"},{default:n(()=>[e(l,{mode:o(c)!==o(T)?"back":"cancel"},null,8,["mode"])]),_:1})),o(i)&&o(t).add?(a(),m(l,{key:2,mode:"save",label:"Salvar",type:"submit",loading:o(k)},null,8,["loading"])):o(t).add?(a(),m(l,{key:3,mode:"edit",label:"Editar",onClick:o(g)},null,8,["onClick"])):v("",!0)]),_:1})]),_:1},8,["resolver","initial-values","onSubmit"])):(a(),m(y,{key:0}))])],64)}}});export{be as default};
