PageSourceSearch

https://novalima.mg.gov.br/_next/static/chunks/pages/admin/secretaries-d0bcea804ef1f6aa.js

js novalima.mg.gov.br collected 2026-09-25 04:03:48 UTC 29,187 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[457],{82400:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/secretaries",function(){return r(67250)}])},5639:function(e,t,r){"use strict";r.d(t,{$:function(){return u}});var n=r(85893),i=r(55512),l=r(19778),a=r(64859),o=r(54346),s=r(14253),c=r(14225),d=r(67294);let u=e=>{let{isOpen:t,onClose:r,title:u,description:m,actions:x}=e,p=(0,d.useRef)(null);return(0,n.jsx)(i.a,{isOpen:t,leastDestructiveRef:p,onClose:r,children:(0,n.jsx)(l.Z,{children:(0,n.jsxs)(i._,{children:[(0,n.jsx)(a.x,{fontSize:"lg",fontWeight:"bold",children:u}),(0,n.jsx)(o.f,{children:m}),(0,n.jsxs)(s.m,{gap:4,children:[(0,n.jsx)(c.z,{ref:p,onClick:r,children:"Cancelar"}),x.map((e,t)=>(0,n.jsx)(c.z,{colorScheme:e.color,onClick:e.onClick,children:e.label},t))]})]})})})}},95427:function(e,t,r){"use strict";r.d(t,{Y:function(){return l}});var n=r(85893);r(67294);var i=r(14225);let l=e=>{let{label:t="Button",...r}=e;return(0,n.jsx)(i.z,{...r,children:t})}},73641:function(e,t,r){"use strict";r.d(t,{I:function(){return i}});var n=r(85893);r(67294);let i=e=>{let{children:t,onSubmit:r,ref:i,withArray:l}=e,a=e=>{e.preventDefault();let t=e.currentTarget,n=new FormData(t),i=n.entries(),a=Object.fromEntries(i);l&&(a=Object.keys(a).reduce((e,t)=>{if(t.includes("[")){let[r,n]=t.split("[");return n.replace("]",""),e[r]||(e[r]=[]),e[r].push(a[t]),e}return e[t]=a[t],e},{})),r(a)};return(0,n.jsx)("form",{ref:i,onSubmit:a,style:{width:"100%",height:"100%"},children:t})}},67250:function(e,t,r){"use strict";r.r(t);var n=r(85893),i=r(89509),l=r(13012),a=r(95427),o=r(73641),s=r(28410),c=r(8772),d=r(54580),u=r(47188),m=r(1378),x=r(93717),p=r(57747),h=r(61557),j=r(71293),f=r(10991),g=r(99840),v=r(80510),b=r(4693),_=r(15115),y=r(64698),N=r(38049),C=r(67294),D=r(9128),S=r(8193),k=r(60727),Q=r(80702),I=r(5639);let w=()=>{var e,t,r,u;let[w,q]=(0,C.useState)([]),[O,E]=(0,C.useState)({}),[T,Z]=(0,C.useState)(!1),[G,L]=(0,C.useState)(!1),[V,P]=(0,C.useState)([]),[R,Y]=(0,C.useState)([]),[z,F]=(0,C.useState)({}),[W,A]=(0,C.useState)([]),[B,U]=(0,C.useState)({}),[H,J]=(0,C.useState)([]),[K,M]=(0,C.useState)(),[X,$]=(0,C.useState)(),[ee,et]=(0,C.useState)(""),[er,en]=(0,C.useState)(""),[ei,el]=(0,C.useState)(""),[ea,eo]=(0,C.useState)(""),[es,ec]=(0,C.useState)(!1),[ed,eu]=(0,C.useState)(""),[em,ex]=(0,C.useState)(""),[ep,eh]=(0,C.useState)(!1),[ej,ef]=(0,C.useState)(!1),[eg,ev]=(0,C.useState)(),[eb,e_]=(0,C.useState)({per_page:10,page:1,title:"",name:""}),[ey,eN]=(0,C.useState)({last_page:0}),[eC,eD]=(0,C.useState)(null),eS=async()=>{let e=await (0,m.J_)(eb);q(e.data),eN(e.meta);let t=await D.CP({all:!0});P(t.data);let r=e.data.some(e=>!0===e.is_turism_subsecretary);ef(r)};(0,C.useEffect)(()=>{eS().catch(console.error),ev(!1)},[eb,eg]);let ek=e=>{var t,r;M(null);let n=null==e?void 0:null===(t=e.informations)||void 0===t?void 0:null===(r=t.cargos)||void 0===r?void 0:r.map(e=>({name:Object.keys(e)[0],person:Object.values(e)[0]}));Y(null==e?void 0:e.categories.map(t=>({...t,selectedSubcategories:null==e?void 0:e.subcategories}))),A(null==e?void 0:e.subcategories),eh((null==e?void 0:e.is_turism_subsecretary)||!1),$(n),E(e),L(!0),ev(!0)},eQ=()=>{eE(),Z(!1)},eI=()=>{eE(),L(!1)},ew=async e=>{try{ec(!0),e.informations={email:e.email,phone:e.phone,schedule:e.schedule,address:e.address};let t=null;(null==X?void 0:X.length)>0?t=null==X?void 0:X.map(e=>({[e.name]:e.person})):(null==ee?void 0:ee.length)>0&&(null==er?void 0:er.length)>0&&(t=[{[ee]:er}]),(null==t?void 0:t.length)>0&&(e.informations.cargos=[...t]);let r=new FormData;(null==R?void 0:R.length)>0&&r.append("categories",JSON.stringify(R));let n=ea||(null==O?void 0:O.banner_path),i=ei||(null==O?void 0:O.icon_path);r.append("informations",JSON.stringify(e.informations)),r.append("title",e.title),r.append("description",e.description),r.append("first_job",e.first_job),r.append("first_person_name",e.first_person_name),r.append("banner",n),r.append("icon",i),r.append("is_turism_subsecretary",ep?"true":"false"),r.append("tourism_portal_url",null==e?void 0:e.tourism_portal_url);let l=await (0,m.cK)(r,O.id);(null==l?void 0:l.errors)&&Object.keys(l.errors).length>0?M({...l.errors}):(eE(),L(!1),ev(!0))}catch(e){console.log(e)}finally{ec(!1)}ev(!0)},eq=async e=>{try{ec(!0),e.informations={email:e.email,phone:e.phone,schedule:e.schedule,address:e.address};let t=null==X?void 0:X.map(e=>
1({[e.name]:e.person}));e.informations.cargos=[...t];let r=new FormData;(null==R?void 0:R.length)>0&&r.append("categories",JSON.stringify(R)),r.append("informations",JSON.stringify(e.informations)),r.append("title",e.title),r.append("description",e.description),r.append("first_job",e.first_job),r.append("first_person_name",e.first_person_name),r.append("banner",ea),r.append("icon",ei),r.append("is_turism_subsecretary",ep?"true":"false"),r.append("tourism_portal_url",null==e?void 0:e.tourism_portal_url);let n=await (0,m.Lv)(r);(null==n?void 0:n.errors)&&Object.keys(n.errors).length>0?M({...n.errors}):(ev(!0),eE(),Z(!1))}catch(e){console.log(e)}finally{ec(!1)}ev(!0)},eO=e=>{e_({...eb,...e})},eE=()=>{$([]),el(""),eo(""),eu(""),ex(""),Y([]),F({}),E({}),M([]),et(""),en("")},eT=e=>{let t=eZ(e);(null==t?void 0:t.is_turism_subsecretary)&&ef(!1);let r=w.filter(t=>t.id!==e);q(r)},eZ=e=>w.find(t=>Number(t.id)===e),eG=(e,t)=>{X.forEach(r=>{r.name===e&&(r.name=t)})},eL=(e,t)=>{X.forEach(r=>{r.person===e&&(r.person=t)})},eV=()=>{E({...O,icon_path:""})},eP=e=>{e?(E({...O,icon_path:e}),el(e)):eV()},eR=()=>{E({...O,banner_path:""})},eY=e=>{e?(E({...O,banner_path:e}),eo(e)):eR()};return(0,n.jsxs)(x.k,{direction:"column",h:"100%",children:[(0,n.jsx)(x.k,{justifyContent:"center",mt:7,children:(0,n.jsx)(p.xu,{w:"50%",children:(0,n.jsx)(o.I,{onSubmit:eO,children:(0,n.jsxs)(p.xu,{style:{display:"flex",flexDirection:"row"},children:[(0,n.jsx)(s.Q,{label:"Titulo",name:"title",type:"text"}),(0,n.jsx)(p.xu,{mr:7}),(0,n.jsx)(s.Q,{label:"Nome",name:"name",type:"text"}),(0,n.jsx)(p.xu,{mr:7}),(0,n.jsx)(a.Y,{label:"filtrar",type:"submit",mt:8,w:"20%"})]})})})}),(0,n.jsxs)(h.x,{mx:35,flex:1,children:[(0,n.jsxs)(x.k,{justifyContent:"space-between",width:"100%",mt:7,mb:5,alignContent:"center",borderBottom:"2px",borderColor:"blackAlpha.300",children:[(0,n.jsx)(j.x,{mb:5,mx:5,fontSize:"3xl",fontWeight:"bold",color:"blackAlpha.700",children:"Secretarias"}),(0,n.jsx)(x.k,{children:(0,n.jsx)(a.Y,{onClick:()=>{Z(!0),eE()},label:"Cadastre uma nova secretaria"})})]}),(0,n.jsxs)(f.i,{size:"sm",children:[(0,n.jsx)(g.h,{children:(0,n.jsxs)(v.Tr,{children:[(0,n.jsx)(b.Th,{children:"Titulo"}),(0,n.jsx)(b.Th,{children:"Respons\xe1vel"}),(0,n.jsx)(b.Th,{children:"A\xe7\xf5es"})]})}),(0,n.jsx)(_.p,{children:!!w&&w.map(e=>(0,n.jsxs)(v.Tr,{children:[(0,n.jsxs)(y.Td,{children:[null==e?void 0:e.title," ",!!(null==e?void 0:e.is_turism_subsecretary)&&"(Subsecretaria de turismo)"]}),(0,n.jsx)(y.Td,{children:null==e?void 0:e.first_person_name}),(0,n.jsx)(y.Td,{children:(0,n.jsxs)(x.k,{align:"center",justifyContent:"space-around",children:[(0,n.jsx)("button",{onClick:()=>ek(e),children:(0,n.jsx)(S.QML,{})}),(0,n.jsx)("button",{onClick:()=>eD(null==e?void 0:e.id),children:(0,n.jsx)(S.YK6,{})})]})})]},null==e?void 0:e.id))})]})]}),(0,n.jsxs)(Q.Z.Root,{pagesQuantity:ey.last_page,currentPage:eb.page,onPageChange:e=>{e_({...eb,page:e})},children:[(0,n.jsx)(Q.Z.Previous,{}),(0,n.jsx)(Q.Z.PageGroup,{isInline:!0}),(0,n.jsx)(Q.Z.Next,{})]}),(0,n.jsx)(c.I,{title:"Crie uma secretaria",isOpen:T,requestClose:()=>eQ(),children:(0,n.jsx)(o.I,{onSubmit:eq,children:(0,n.jsxs)(x.k,{direction:"column",gridGap:4,children:[(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Titulo *",placeholder:"Digite seu nome aqui",name:"title",type:"text"}),!!(null==K?void 0:K.title)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite um titulo!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Descri\xe7\xe3o *",placeholder:"Digite a descri\xe7\xe3o aqui",name:"description",type:"text"}),!!(null==K?void 0:K.description)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite uma descri\xe7\xe3o!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Cargo principal",placeholder:"Digite o nome do cargo principal aqui",name:"first_job"}),!!(null==K?void 0:K.first_job)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o cargo do respons\xe1vel principal!"})}),(0,n.jsx)(p.xu,{mr:4})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{name:"first_person_name",label:"Nome do respons\xe1vel principal",placeholder:"Digite o nome da pessoa aqui"}),!!(null==K?void 0:K.first_person_name)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o nome do respons\xe1vel!"})}),(0,n.jsx)(p.xu,{mr:4})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"E-mails",placeholder:"Digite os emails aqui",name:"email"}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o email do respons\xe1vel pela secretaria!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Telefones",placeholder:"Digite os telefones aqui",name:"phone",type:"text"}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o telefone do respons\xe1vel!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Hor\xe1rio",placeholder:"Digite o hor\xe1rio aqui",name:"schedule",type:"text"}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o hor\xe1rio!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Endere\xe7o",placeholder:"Digite o endere\xe7o aqui",name:"address",type:"text"}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o endere\xe7o!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(d.A,{name:"is_turism_subsecretary",label:"Subsecretaria de turismo",options:[{label:"Sim",value:!0},{label:"N\xe3o",value:!1}],onChange:e=>{eh("true"===e)}}),!!(null==K?void 0:K.is_turism_subsecretary)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Escolha o tipo de secretaria!"})})]}),!!ep&&(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"URL portal do turismo",placeholder:"Digite a URL de portal do turismo",name:"tourism_portal_url",type:"text",defaultValue:null==O?void 0:O.tourism_portal_url}),!!(null==K?void 0:K.tourism_portal_url)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite a URL de portal do turismo!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(j.x,{mb:2,color:"black",children:"Selecione um icone *:"}),ei?(0,n.jsx)(i.O,{flexDirection:"column",description:"* Dimens\xe3o recomendada 30 x 30",deleteImage:()=>el(""),image:ei}):(0,n.jsx)(l.s,{flexDirection:"column",description:"* Dimens\xe3o recomendada 30 x 30",label:"Selecione uma imagem",setImage:el}),!!(null==K?void 0:K.icon)&&(0,n.jsx)(N.Q6,{color:"red.500",pl:2,mt:2,children:"Selecione um icone!"})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(j.x,{mb:2,color:"black",children:"Selecione um banner *:"}),ea?(0,n.jsx)(i.O,{flexDirection:"column",description:"* Dimens\xe3o recomendada 1280 x 320",deleteImage:()=>eo(""),image:ea}):(0,n.jsx)(l.s,{flexDirection:"column",description:"* Dimens\xe3o recomendada 1280 x 320",label:"Selecione uma imagem",setImage:eo}),!!(null==K?void 0:K.banner)&&(0,n.jsx)(N.Q6,{color:"red.500",pl:2,mt:2,children:"Selecione uma imagem!"})]}),(0,n.jsx)(j.x,{fontWeight:"bold",mb:1,mt:1,children:"Cargos:"}),!!X&&X.length>0&&X.map(e=>(0,n.jsxs)(x.k,{justifyContent:"center",align:"center",children:[(0,n.jsx)(s.Q,{label:"Nome do cargo",placeholder:"Digite o nome do cargo aqui",defaultValue:e.name,onChange:t=>eG(e.name,t.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(s.Q,{label:"Nome da pessoa",placeholder:"Digite o nome da pessoa aqui",defaultValue:e.person,onChange:t=>eL(e.person,t.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(p.xu,{mt:6,onClick:()=>{$(X.filter(t=>t.person!==e.person))},children:(0,n.jsx)(S.YK6,{})})]},e.name)),(0,n.jsxs)(N.NI,{children:[(0,n.jsxs)(x.k,{justifyContent:"center",align:"center",children:[(0,n.jsx)(s.Q,{label:"Nome do cargo",placeholder:"Digite o nome do cargo aqui",value:ee,onChange:e=>et(e.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(s.Q,{label:"Nome da pessoa",placeholder:"Digite o nome da pessoa aqui",value:er,onCh
1ange:e=>en(e.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(p.xu,{mt:6,onClick:()=>{X&&X.length>0?$([...X,{name:ee,person:er}]):$([{name:ee,person:er}]),et(""),en("")},children:(0,n.jsx)(S.OzW,{})})]}),!!(null==K?void 0:K.cargos)&&(0,n.jsx)(N.Q6,{color:"red.500",pl:2,mt:2,children:"Adicione um link!"})]}),(0,n.jsx)(x.k,{direction:"column",mt:2,children:(0,n.jsx)(k.h,{categories:V,selectedCategories:R,setSelectedCategories:Y,selectedTags:H,setSelectedTags:J,selectedCategory:z,setSelectedCategory:F})}),(0,n.jsx)(a.Y,{type:"submit",label:"cadastrar"})]})})}),(0,n.jsx)(c.I,{title:"Edite o item",isOpen:G,requestClose:()=>eI(),children:(0,n.jsx)(x.k,{direction:"column",w:"100%",h:"100%",p:4,align:"center",justifyContent:"center",children:(0,n.jsx)(o.I,{onSubmit:ew,children:(0,n.jsxs)(x.k,{direction:"column",gridGap:4,children:[(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Titulo *",placeholder:"Digite seu nome aqui",name:"title",type:"text",defaultValue:null==O?void 0:O.title}),!!(null==K?void 0:K.title)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite um titulo!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Descri\xe7\xe3o *",placeholder:"Digite a descri\xe7\xe3o aqui",name:"description",type:"text",defaultValue:null==O?void 0:O.description}),!!(null==K?void 0:K.description)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite uma descri\xe7\xe3o!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Cargo principal",placeholder:"Digite o nome do cargo principal aqui",name:"first_job",defaultValue:null==O?void 0:O.first_job}),(0,n.jsx)(p.xu,{mr:4})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Nome do respons\xe1vel principal",placeholder:"Digite o nome da pessoa aqui",name:"first_person_name",defaultValue:null==O?void 0:O.first_person_name}),(0,n.jsx)(p.xu,{mr:4})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"E-mails",placeholder:"Digite os emails aqui",name:"email",defaultValue:null==O?void 0:null===(e=O.informations)||void 0===e?void 0:e.email}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o email do respons\xe1vel pela secretaria!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Telefones",placeholder:"Digite os telefones aqui",name:"phone",type:"text",defaultValue:null==O?void 0:null===(t=O.informations)||void 0===t?void 0:t.phone}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o telefone do respons\xe1vel!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Hor\xe1rio",placeholder:"Digite o hor\xe1rio aqui",name:"schedule",type:"text",defaultValue:null==O?void 0:null===(r=O.informations)||void 0===r?void 0:r.schedule}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o hor\xe1rio!"})})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"Endere\xe7o",placeholder:"Digite o endere\xe7o aqui",name:"address",type:"text",defaultValue:null==O?void 0:null===(u=O.informations)||void 0===u?void 0:u.address}),!!(null==K?void 0:K.informations)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite o endere\xe7o!"})})]}),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(d.A,{name:"is_turism_subsecretary",label:"Subsecretaria de turismo",options:[{label:"Sim",value:!0},{label:"N\xe3o",value:!1}],defaultValue:O.is_turism_subsecretary?"true":"false",onChange:e=>eh("true"===e)}),!!(null==K?void 0:K.is_turism_subsecretary)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Escolha o tipo de secretaria!"})})]}),!!ep&&(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(s.Q,{label:"URL portal do turismo",placeholder:"Digite a URL de portal do turismo",name:"tourism_portal_url",type:"text",defaultValue:null==O?void 0:O.tourism_portal_url}),!!(null==K?void 0:K.tourism_portal_url)&&(0,n.jsx)(p.xu,{ml:2,mt:2,children:(0,n.jsx)(N.Q6,{color:"red.500",children:"Digite a URL de portal do turismo!"})})]})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(j.x,{mb:2,color:"black",children:"Selecione um icone *:"}),(null==O?void 0:O.icon_path)?(0,n.jsx)(i.O,{flexDirection:"column",description:"* Dimens\xe3o recomendada 30 x 30",deleteImage:()=>eV(),image:null==O?void 0:O.icon_path}):(0,n.jsx)(l.s,{flexDirection:"column",description:"* Dimens\xe3o recomendada 30 x 30",label:"Selecione uma imagem",setImage:eP}),!!(null==K?void 0:K.icon)&&(0,n.jsx)(N.Q6,{color:"red.500",pl:2,mt:2,children:"Selecione um icone!"})]}),(0,n.jsxs)(N.NI,{children:[(0,n.jsx)(j.x,{mb:2,color:"black",children:"Selecione um banner *:"}),(null==O?void 0:O.banner_path)?(0,n.jsx)(i.O,{flexDirection:"column",description:"* Dimens\xe3o recomendada 1280 x 320",deleteImage:()=>eR(),image:null==O?void 0:O.banner_path}):(0,n.jsx)(l.s,{flexDirection:"column",description:"* Dimens\xe3o recomendada 1280 x 320",label:"Selecione uma imagem",setImage:eY}),!!(null==K?void 0:K.banner)&&(0,n.jsx)(N.Q6,{color:"red.500",pl:2,mt:2,children:"Selecione uma imagem!"})]}),(0,n.jsx)(j.x,{fontWeight:"bold",mb:1,mt:1,children:"Cargos:"}),!!X&&X.length>0&&X.map(e=>(0,n.jsxs)(x.k,{justifyContent:"center",align:"center",children:[(0,n.jsx)(s.Q,{label:"Nome do cargo",placeholder:"Digite o nome do cargo aqui",defaultValue:e.name,onChange:t=>eG(e.name,t.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(s.Q,{label:"Nome da pessoa",placeholder:"Digite o nome da pessoa aqui",defaultValue:e.person,onChange:t=>eL(e.person,t.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(p.xu,{mt:6,onClick:()=>$(X.filter(t=>t.person!==e.person)),children:(0,n.jsx)(S.YK6,{})})]},e.name)),(0,n.jsxs)(N.NI,{children:[(0,n.jsxs)(x.k,{justifyContent:"center",align:"center",children:[(0,n.jsx)(s.Q,{label:"Nome do cargo",placeholder:"Digite o nome do cargo aqui",value:ee,onChange:e=>et(e.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(s.Q,{label:"Nome da pessoa",placeholder:"Digite o nome da pessoa aqui",value:er,onCh
1ange:e=>en(e.target.value)}),(0,n.jsx)(p.xu,{mr:4}),(0,n.jsx)(p.xu,{mt:6,onClick:()=>{X&&X.length>0?$([...X,{name:ee,person:er}]):$([{name:ee,person:er}]),et(""),en("")},children:(0,n.jsx)(S.OzW,{})})]}),!!(null==K?void 0:K.cargos)&&(0,n.jsx)(N.Q6,{color:"red.500",pl:2,mt:2,children:"Adicione um link!"})]}),(0,n.jsx)(x.k,{direction:"column",mt:2,children:(0,n.jsx)(k.h,{categories:V,selectedCategories:R,setSelectedCategories:Y,selectedTags:H,setSelectedTags:J,selectedCategory:z,setSelectedCategory:F})}),(0,n.jsx)(a.Y,{type:"submit",isLoading:es,label:"editar"})]})})})}),(0,n.jsx)(I.$,{isOpen:!!eC,title:"Aten\xe7\xe3o",description:"Deseja realmente excluir esse item?",onClose:()=>eD(null),actions:[{color:"red",label:"Excluir",onClick:async()=>{await (0,m.mp)(eC),eD(null),eT(eC)}}]})]})};w.layout=u.l,w.isPrivate=!0,t.default=w},9128:function(e,t,r){"use strict";r.d(t,{CP:function(){return i},K6:function(){return l},ht:function(){return a},uu:function(){return o}});var n=r(58467);let i=async(e,t)=>{try{let{data:r}=await n.Z.get("public/categories",{...(0,n.d)(t),params:e});return r}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},l=async(e,t)=>{try{let{data:r}=await n.Z.post("/categories",e,(0,n.d)(t));return r}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},a=async(e,t,r)=>{try{let{data:i}=await n.Z.put("/categories/".concat(t),e,(0,n.d)(r));return i}catch(e){var i;return null===(i=e.response)||void 0===i?void 0:i.data}},o=async(e,t)=>{try{await n.Z.delete("/categories/".concat(e),(0,n.d)(t))}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}}},1378:function(e,t,r){"use strict";r.d(t,{D5:function(){return m},F5:function(){return u},J_:function(){return l},Lv:function(){return a},OP:function(){return i},UN:function(){return o},cK:function(){return s},hd:function(){return d},mp:function(){return c}});var n=r(58467);let i=async e=>{try{let{data:t}=await n.Z.get("public/secretaries",(0,n.d)(e));return t}catch(e){var t;return null===(t=e.response)||void 0===t?void 0:t.data}},l=async(e,t)=>{try{let{data:r}=await n.Z.get("secretaries",{...(0,n.d)(t),params:e});return r}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},a=async(e,t)=>{try{let{data:r}=await n.Z.post("/secretaries",e,(0,n.d)(t));return r}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},o=async(e,t)=>{try{let{data:r}=await n.Z.get("/public/secretaries/".concat(e),(0,n.d)(t));return r}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},s=async(e,t,r)=>{try{let{data:i}=await n.Z.post("/secretaries-update/".concat(t),e,(0,n.d)(r));return i}catch(e){var i;return null===(i=e.response)||void 0===i?void 0:i.data}},c=async(e,t)=>{try{await n.Z.delete("/secretaries/".concat(e),(0,n.d)(t))}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},d=async e=>{try{let{data:t}=await n.Z.get("/public/secretaries",(0,n.d)(e));return t}catch(e){var t;return null===(t=e.response)||void 0===t?void 0:t.data}},u=async(e,t)=>{try{return await n.Z.get("/public/secretaries/",{...(0,n.d)(t),params:e})}catch(e){var r;return null===(r=e.response)||void 0===r?void 0:r.data}},m=async e=>{try{let{data:t}=await n.Z.get("/public/get-turism-subsecretary",(0,n.d)(e));return t}catch(e){var t;return null===(t=e.response)||void 0===t?void 0:t.data}}},30297:function(e,t,r){"use strict";r.d(t,{e:function(){return s}});var n=r(6789),i=r(25432),l=r(16554),a=r(65548),o=r(85893),s=(0,l.G)(function(e,t){let{className:r,justify:l,...s}=e,c=(0,n.v)();return(0,o.jsx)(a.m.div,{ref:t,className:(0,i.cx)("chakra-card__footer",r),__css:{display:"flex",justifyContent:l,...c.footer},...s})})},40607:function(e,t,r){"use strict";r.d(t,{e:function(){return s}});var n=r(6789),i=r(25432),l=r(16554),a=r(65548),o=r(85893),s=(0,l.G)(function(e,t){let{className:r,...l}=e,s=(0,n.v)();return(0,o.jsx)(a.m.div,{ref:t,className:(0,i.cx)("chakra-card__body",r),__css:s.body,...l})})},6789:function(e,t,r){"use strict";r.d(t,{Y:function(){return n},v:function(){return i}});var[n,i]=(0,r(16902).eC)("Card")},13990:function(e,t,r){"use strict";r.d(t,{Z:function(){return d}});var n=r(6789),i=r(25432),l=r(16554),a=r(33179),o=r(77030),s=r(65548),c=r(85893),d=(0,l.G)(function(e,t){let{className:r,children:l,direction:d="column",justify:u,align:m,...x}=(0,a.Lr)(e),p=(0,o.jC)("Card",e);return(0,c.jsx)(s.m.div,{ref:t,className:(0,i.cx)("chakra-card",r),__css:{display:"flex",flexDirection:d,justifyContent:u,alignItems:m,position:"relative",minWidth:0,wordWrap:"break-word",...p.container},...x,children:(0,c.jsx)(n.Y,{value:p,children:l})})})},5460:function(e,t,r){"use strict";r.d(t,{E:function(){return s}});var n=r(16554),i=r(85893),l=(0,n.G)(function(e,t){let{htmlWidth:r,htmlHeight:n,alt:l,...a}=e;return(0,i.jsx)("img",{width:r,height:n,ref:t,alt:l,...a})});l.displayName="NativeImage";var a=r(47630),o=r(65548),s=(0,n.G)(function(e,t){let{fallbackSrc:r,fallback:n,src:s,srcSet:c,align:d,fit:u,loading:m,ignoreFallback:x,crossOrigin:p,fallbackStrategy:h="beforeLoadOrError",referrerPolicy:j,...f}=e,g=null!=m||x||!(void 0!==r||void 0!==n),v=(0,a.d)({...e,crossOrigin:p,ignoreFallback:g}),b=(0,a.z)(v,h),_={ref:t,objectFit:u,objectPosition:d,...g?f:function(e,t=[]){let r=Object.assign({},e);for(let e of t)e in r&&delete r[e];return r}(f,["onError","onLoad"])};return b?n||(0,i.jsx)(o.m.img,{as:l,className:"chakra-image__placeholder",src:r,..._}):(0,i.jsx)(o.m.img,{as:l,src:s,srcSet:c,crossOrigin:p,loading:m,referrerPolicy:j,className:"chakra-image",..._})});s.displayName="Image"},22757:function(e,t,r){"use strict";r.d(t,{X:function(){return c}});var n=r(16554),i=r(77030),l=r(33179),a=r(65548),o=r(25432),s=r(85893),c=(0,n.G)(function(e,t){let r=(0,i.mq)("Heading",e),{className:n,...c}=(0,l.Lr)(e);
1return(0,s.jsx)(a.m.h2,{ref:t,className:(0,o.cx)("chakra-heading",e.className),...c,__css:r})});c.displayName="Heading"},49429:function(e,t,r){"use strict";r.d(t,{o:function(){return c}});var n=r(16554),i=r(65548),l=r(33951),a=r(25432),o=r(67294),s=r(85893),c=(0,n.G)(function(e,t){let{ratio:r=4/3,children:n,className:c,...d}=e,u=o.Children.only(n),m=(0,a.cx)("chakra-aspect-ratio",c);return(0,s.jsx)(i.m.div,{ref:t,position:"relative",className:m,_before:{height:0,content:'""',display:"block",paddingBottom:(0,l.XQ)(r,e=>`${1/e*100}%`)},__css:{"& > *:not(style)":{overflow:"hidden",position:"absolute",top:"0",right:"0",bottom:"0",left:"0",display:"flex",justifyContent:"center",alignItems:"center",width:"100%",height:"100%"},"& > img, & > video":{objectFit:"cover"}},...d,children:u})});c.displayName="AspectRatio"},66205:function(e,t,r){"use strict";r.d(t,{o:function(){return s}});var n=r(67990),i=r(3949),l=r(25432),a=r(16554),o=r(85893),s=(0,a.G)((e,t)=>{let{onClick:r,className:a,...s}=e,{onClose:c}=(0,n.vR)(),d=(0,l.cx)("chakra-modal__close-btn",a),u=(0,n.I_)();return(0,o.jsx)(i.P,{ref:t,__css:u.closeButton,className:d,onClick:(0,l.v0)(r,e=>{e.stopPropagation(),c()}),...s})});s.displayName="ModalCloseButton"},64859:function(e,t,r){"use strict";r.d(t,{x:function(){return c}});var n=r(67990),i=r(25432),l=r(16554),a=r(65548),o=r(67294),s=r(85893),c=(0,l.G)((e,t)=>{let{className:r,...l}=e,{headerId:c,setHeaderMounted:d}=(0,n.vR)();(0,o.useEffect)(()=>(d(!0),()=>d(!1)),[d]);let u=(0,i.cx)("chakra-modal__header",r),m=(0,n.I_)(),x={flex:0,...m.header};return(0,s.jsx)(a.m.header,{ref:t,className:u,id:c,...l,__css:x})});c.displayName="ModalHeader"},55512:function(e,t,r){"use strict";r.d(t,{_:function(){return s},a:function(){return o}});var n=r(14581),i=r(67990),l=r(16554),a=r(85893);function o(e){let{leastDestructiveRef:t,...r}=e;return(0,a.jsx)(i.u_,{...r,initialFocusRef:t})}var s=(0,l.G)((e,t)=>(0,a.jsx)(n.h,{ref:t,role:"alertdialog",...e}))},14253:function(e,t,r){"use strict";r.d(t,{m:function(){return s}});var n=r(67990),i=r(25432),l=r(16554),a=r(65548),o=r(85893),s=(0,l.G)((e,t)=>{let{className:r,...l}=e,s=(0,i.cx)("chakra-modal__footer",r),c=(0,n.I_)(),d={display:"flex",alignItems:"center",justifyContent:"flex-end",...c.footer};return(0,o.jsx)(a.m.footer,{ref:t,...l,__css:d,className:s})});s.displayName="ModalFooter"},41731:function(e,t,r){"use strict";r.d(t,{P:function(){return m}});var n=r(25432),i=r(16554),l=r(65548),a=r(85893),o=(0,i.G)(function(e,t){let{children:r,placeholder:i,className:o,...s}=e;return(0,a.jsxs)(l.m.select,{...s,ref:t,className:(0,n.cx)("chakra-select",o),children:[i&&(0,a.jsx)("option",{value:"",children:i}),r]})});o.displayName="SelectField";var s=r(41001),c=r(77030),d=r(33179),u=r(67294),m=(0,i.G)((e,t)=>{var r;let i=(0,c.jC)("Select",e),{rootProps:u,placeholder:m,icon:x,color:p,height:j,h:f,minH:g,minHeight:v,iconColor:b,iconSize:_,...y}=(0,d.Lr)(e),[N,C]=function(e,t){let r={},n={};for(let[i,l]of Object.entries(e))t.includes(i)?r[i]=l:n[i]=l;return[r,n]}(y,d.oE),D=(0,s.Y)(C),S={paddingEnd:"2rem",...i.field,_focus:{zIndex:"unset",...null==(r=i.field)?void 0:r._focus}};return(0,a.jsxs)(l.m.div,{className:"chakra-select__wrapper",__css:{width:"100%",height:"fit-content",position:"relative",color:p},...N,...u,children:[(0,a.jsx)(o,{ref:t,height:null!=f?f:j,minH:null!=g?g:v,placeholder:m,...D,__css:S,children:e.children}),(0,a.jsx)(h,{"data-disabled":(0,n.PB)(D.disabled),...(b||p)&&{color:b||p},__css:i.icon,..._&&{fontSize:_},children:x})]})});m.displayName="Select";var x=e=>(0,a.jsx)("svg",{viewBox:"0 0 24 24",...e,children:(0,a.jsx)("path",{fill:"currentColor",d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})}),p=(0,l.m)("div",{baseStyle:{position:"absolute",display:"inline-flex",alignItems:"center",justifyContent:"center",pointerEvents:"none",top:"50%",transform:"translateY(-50%)"}}),h=e=>{let{children:t=(0,a.jsx)(x,{}),...r}=e,n=(0,u.cloneElement)(t,{role:"presentation",className:"chakra-select__icon",focusable:!1,"aria-hidden":!0,style:{width:"1em",height:"1em",color:"currentColor"}});return(0,a.jsx)(p,{...r,className:"chakra-select__icon-wrapper",children:(0,u.isValidElement)(t)?n:null})};h.displayName="SelectIcon"},61557:function(e,t,r){"use strict";r.d(t,{x:function(){return o}});var n=r(16554),i=r(65548),l=r(25432),a=r(85893),o=(0,n.G)((e,t)=>{var r;let{overflow:n,overflowX:o,className:s,...c}=e;return(0,a.jsx)(i.m.div,{ref:t,className:(0,l.cx)("chakra-table__container",s),...c,__css:{display:"block",whiteSpace:"nowrap",WebkitOverflowScrolling:"touch",overflowX:null!=(r=null!=n?n:o)?r:"auto",overflowY:"hidden",maxWidth:"100%"}})})}},function(e){e.O(0,[9866,1228,4617,4434,4446,3820,4169,6712,9063,8990,4211,1084,7188,9118,3646,9774,2888,179],function(){return e(e.s=82400)}),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.