PageSourceSearch

https://craibas.al.gov.br/build/assets/Edit-n_1lsqlK.js

js craibas.al.gov.br collected 2026-10-02 23:55:22 UTC 6,028 bytes, 1 lines download raw bytes

1import{c as I,a as J,j as t,H as K,L as B}from"./app-CTaY8UJf.js";import{A as M}from"./app-layout-DHg6PkRO.js";import{T as P}from"./tiptap-editor-Btoe9qvv.js";import Q from"./arrow-left-CPptMQyl.js";import"./app-CNmQMdEi.js";import"./button-DXCKLHtj.js";import"./index-sraz7nLe.js";import"./index-CsfSsVkk.js";import"./index-Svmmcv6D.js";import"./x-DmP7A1Bz.js";import"./createLucideIcon-CmjF8lT1.js";import"./index-CJBlix5Q.js";import"./index-DHUBBKJC.js";import"./index-BE_AIKwc.js";import"./video-CWkR2iFG.js";import"./chevron-right-Dcl2lTY9.js";import"./dropdown-menu-D6OZoFra.js";import"./index-DXg2b8Vm.js";import"./index-msf3AG1t.js";import"./avatar-BRFzpAWX.js";import"./index-fQ3brVpV.js";import"./index-BGC6_Qsa.js";import"./index-C_SHgnPd.js";import"./layers-Cb0hKdx0.js";import"./shield-check-CXJJ4XEh.js";import"./file-text-jraIksbC.js";import"./file-check-tR1YCl9R.js";import"./message-square-BtERmk2L.js";import"./users-BYuco8Ea.js";import"./trending-up-CsQX3MuM.js";import"./handshake-ppgb6oUe.js";import"./calendar-CEIt2YqY.js";import"./trending-down-B7TczfdV.js";import"./building-BaJqVYxM.js";import"./list-Dehc_B-t.js";import"./activity-D1Ey-wIS.js";import"./search-BOJp92ky.js";import"./breadcrumbs-ByKSkPWt.js";import"./input-7aHhCeCr.js";import"./index-CZjtIso7.js";import"./unlink-D7dkgNo-.js";import"./list-ordered-BA4QZELo.js";import"./link-D5YEb8HE.js";function Fe(G){const e=I.c(62),{estrutura:i}=G,H=i.description??"";let v;e[0]!==i.order||e[1]!==i.title||e[2]!==H?(v={title:i.title,description:H,order:i.order},e[0]=i.order,e[1]=i.title,e[2]=H,e[3]=v):v=e[3];const{data:l,setData:o,put:R,processing:E,errors:r}=J(v);let S;e[4]!==i.id||e[5]!==R?(S=s=>{s.preventDefault(),R(`/portal/admin/estrutura-organizacional/${i.id}`)},e[4]=i.id,e[5]=R,e[6]=S):S=e[6];const F=S;let z,w;e[7]===Symbol.for("react.memo_cache_sentinel")?(z={title:"Admin",href:"/portal/admin"},w={title:"Estrutura Organizacional",href:"/portal/admin/estrutura-organizacional"},e[7]=z,e[8]=w):(z=e[7],w=e[8]);const V=`/portal/admin/estrutura-organizacional/${i.id}/edit`;let a;e[9]!==V?(a=[z,w,{title:"Editar Estrutura",href:V}],e[9]=V,e[10]=a):a=e[10];let A;e[11]===Symbol.for("react.memo_cache_sentinel")?(A=t.jsx(K,{title:"Editar Estrutura Organizacional"}),e[11]=A):A=e[11];let D;e[12]===Symbol.for("react.memo_cache_sentinel")?(D=t.jsx("div",{className:"mb-6",children:t.jsxs(B,{href:"/portal/admin/estrutura-organizacional",className:"inline-flex items-center gap-2 text-gray-600 hover:text-gray-900",children:[t.jsx(Q,{size:20}),"Voltar"]})}),e[12]=D):D=e[12];let L;e[13]===Symbol.for("react.memo_cache_sentinel")?(L=t.jsx("h1",{className:"text-3xl font-bold mb-6",children:"Editar Estrutura Organizacional"}),e[13]=L):L=e[13];let k;e[14]===Symbol.for("react.memo_cache_sentinel")?(k=t.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:["Título ",t.jsx("span",{className:"text-red-500",children:"*"})]}),e[14]=k):k=e[14];let m;e[15]!==o?(m=s=>o("title",s.target.value),e[15]=o,e[16]=m):m=e[16];let n;e[17]!==l.title||e[18]!==m?(n=t.jsx("input",{type:"text",value:l.title,onChange:m,placeholder:"Digite o título...",maxLength:100,className:"w-full px-4 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500"}),e[17]=l.title,e[18]=m,e[19]=n):n=e[19];let c;e[20]!==r.title?(c=r.title&&t.jsx("p",{className:"mt-1 text-sm text-red-600",children:r.title}),e[20]=r.title,e[21]=c):c=e[21];let d;e[22]!==n||e[23]!==c?(d=t.jsxs("div",{children:[k,n,c]}),e[22]=n,e[23]=c,e[24]=d):d=e[24];let C;e[25]===Symbol.for("react.memo_cache_sentinel")?(C=t.jsx("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:"Descrição"}),e[25]=C):C=e[25];let p;e[26]!==o?(p=s=>o("description",s),e[26]=o,e[27]=p):p=e[27];let u;e[28]!==l.description||e[29]!==p?(u=t.jsx(P,{value:l.description,onChange:p,placeholder:"Digite a descrição..."}),e[28]=l.description,e[29]=p,e[30]=u):u=e[30];let f;e[31]!==r.description?(f=r.description&&t.jsx("p",{className:"mt-1 text-sm text-red-600",children:r.description}),e[31]=r.description,e[32]=f):f=e[32];let x;e[33]!==u||e[34]!==f?(x=t.jsxs("div",{children:[C,u,f]}),e[33]=u,e[34]=f,e[35]=x):x=e[35];let O;e[36]===Symbol.for("react.memo_cache_sentinel")?(O=t.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:["Ordem ",t.jsx("span",{className:"text-red-500",children:"*"})]}),e[36]=O):O=e[36];let h;e[37]!==o?(h=s=>o("order",Number(s.target.value)),e[37]=o,e[38]=h):h=e[38];let b;e[39]!==l.order||e[40]!==h?(b=t.jsx("input",{type:"number",value:l.order,onChange:h,min:0,className:"w-32 px-4 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500"}),e[39]=l.order,e[40]=h,e[41]=b):b=e[41];let g;e[42]!==r.order?(g=r.order&&t.jsx("p",{className:"mt-1 text-sm text-red-600",children:r.order}),e[42]=r.order,e[43]=g):g=e[43];let y;e[44]!==b||e[45]!==g?(y=t.jsxs("div",{children:[O,b,g]}),e[44]=b,e[45]=g,e[46]=y):y=e[46];
1const q=E?"Salvando...":"Atualizar";let j;e[47]!==E||e[48]!==q?(j=t.jsx("button",{type:"submit",disabled:E,className:"px-6 py-2 bg-blue-600 text-white rounded-lg hover:bg-blue-700 disabled:opacity-50 transition",children:q}),e[47]=E,e[48]=q,e[49]=j):j=e[49];let T;e[50]===Symbol.for("react.memo_cache_sentinel")?(T=t.jsx(B,{href:"/portal/admin/estrutura-organizacional",className:"px-6 py-2 bg-gray-200 text-gray-700 rounded-lg hover:bg-gray-300 transition",children:"Cancelar"}),e[50]=T):T=e[50];let N;e[51]!==j?(N=t.jsxs("div",{className:"flex gap-4",children:[j,T]}),e[51]=j,e[52]=N):N=e[52];let _;e[53]!==F||e[54]!==d||e[55]!==x||e[56]!==y||e[57]!==N?(_=t.jsxs("div",{className:"container mx-auto px-4 py-8",children:[D,t.jsxs("div",{className:"max-w-2xl",children:[L,t.jsxs("form",{onSubmit:F,className:"space-y-6",children:[d,x,y,N]})]})]}),e[53]=F,e[54]=d,e[55]=x,e[56]=y,e[57]=N,e[58]=_):_=e[58];let $;return e[59]!==_||e[60]!==a?($=t.jsxs(M,{breadcrumbs:a,children:[A,_]}),e[59]=_,e[60]=a,e[61]=$):$=e[61],$}export{Fe as default};

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.