1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5174],{13865:(e,r,s)=>{"use strict";s.d(r,{A:()=>c});var t=s(42525),n=s(13897);let a={src:"/_next/static/media/close.71e31dbd.svg",height:16,width:16,blurWidth:0,blurHeight:0};var o=s(92463),i=s(32733);s(54651);var l=s(75035);let c=function(e){let{className:r="",show:s=!1,onClose:c=()=>{},disableOverlayClose:d=!1,children:u}=e,[h,x]=n.useState(!1),m=n.useRef(null),A=(0,l.A)(()=>x(!1),450);return n.useEffect(()=>{s?x(!0):A()},[s]),h&&(0,t.jsx)("div",{className:"modal-background",onClick:e=>{!d&&m.current&&e.target instanceof Element&&!m.current.contains(e.target)&&c()},children:(0,t.jsxs)("div",{className:"modal "+(s?"modal-open":"modal-close")+" "+r,ref:m,children:[u,(0,t.jsx)(o.A,{className:"!absolute top-0 right-0 m-1",onClick:c,children:(0,t.jsx)(i.default,{src:a,alt:"Cerrar"})})]})})}},23926:(e,r,s)=>{"use strict";s.d(r,{A:()=>p});var t=s(42525),n=s(13897),a=s(19163),o=s(45843),i=s(21747),l=s(90603),c=s(70751),d=s(56251),u=s(9805),h=s(21589),x=s(95937),m=s(722);let A=e=>{let{proveedores:r,idProveedorSeleccionado:s,setIdProveedorSeleccionado:n}=e;return(0,t.jsx)(m.B8,{rowComponent:j,rowCount:r.length,rowHeight:40,rowProps:{proveedores:r,idProveedorSeleccionado:s,setIdProveedorSeleccionado:n}})},j=e=>{let{index:r,proveedores:s,idProveedorSeleccionado:n,setIdProveedorSeleccionado:a,style:i}=e,l=s[r];return(0,t.jsxs)(d.A,{onClick:()=>a(l.prov),selected:l.prov===n,style:{...i,borderTop:0!==r?"1px solid #e5e7eb":void 0},children:[(0,t.jsx)(u.A,{children:(0,t.jsx)(h.A,{size:"small",checked:l.prov===n})}),(0,t.jsx)(x.A,{children:(0,t.jsx)(o.A,{children:"".concat(l.prov," - ").concat(l.nombre)})})]})},p=e=>{let{proveedores:r,idProveedorSeleccionado:s,setIdProveedorSeleccionado:d,onClickElegirProveedor:u,loading:h}=e,[x,m]=n.useState(""),j=n.useMemo(()=>0===x.length?r:r.filter(e=>e.nombre.toLocaleUpperCase().includes(x.toLocaleUpperCase())||String(e.prov).includes(x)),[r,x]);return n.useEffect(()=>{d(null)},[j]),(0,t.jsxs)(a.A,{className:"p-4",sx:{minHeight:{xs:"40vh",sm:"auto"},maxHeight:{xs:"60vh",sm:"50vh"}},children:[(0,t.jsx)(o.A,{variant:"bold",mb:2,children:"Seleccionar el proveedor:"}),(0,t.jsx)(i.A,{mb:2,children:(0,t.jsx)(l.A,{placeholder:"Buscar proveedor...",fullWidth:!0,value:x,onChange:e=>m(e.target.value)})}),(0,t.jsx)(a.A,{className:"flex-grow mb-4 min-h-[30%] min-w-[400px]",children:(0,t.jsx)(A,{proveedores:j,idProveedorSeleccionado:s,setIdProveedorSeleccionado:d})}),(0,t.jsx)(c.A,{className:"w-80 self-center",variant:"contained",onClick:u,loading:h,disabled:null===s,children:"Elegir Proveedor"})]})}},42965:(e,r,s)=>{Promise.resolve().then(s.bind(s,90553))},43731:(e,r,s)=>{"use strict";s.d(r,{A:()=>t});let t={src:"/_next/static/media/visibility.fc59a7fd.svg",height:24,width:24,blurWidth:0,blurHeight:0}},47785:(e,r,s)=>{"use strict";s.d(r,{A:()=>t});let t={src:"/_next/static/media/visibility_off.726f4afc.svg",height:24,width:24,blurWidth:0,blurHeight:0}},48523:(e,r,s)=>{"use strict";s.d(r,{Z:()=>c});var t=s(13897),n=s(95486),a=s(90048),o=s(79643),i=s(88096),l=s(77774);function c(){let e=(0,l.useRouter)(),{updateNotificaciones:r}=(0,a.A)(),[s,c]=t.useState(!1),[d,u]=t.useState([]),[h,x]=t.useState(!1),[m,A]=t.useState(""),[j,p]=t.useState(null),[g,f]=t.useState(!1),[v,y]=t.useState(!1),{state:{user:b},setUser:w,setMenu:C}=t.useContext(i.o),S=async s=>{let{response:t,body:a}=await (0,n.BJ)(s.prov);if(!t.ok)return void(0,o.Rm)(a.message);w({id_usuario:s.id_usuario,prov:s.prov,nombre_prov:s.nombre,cuit:Number(s.cuit),username:m||(null==b?void 0:b.username)}),C(a.data),await P(),await r(),f(!1),b&&e.push("/")},k=async()=>{try{let e=d.find(e=>e.prov===j);if(!e)return(0,o.Rm)("Seleccione un proveedor"),Promise.reject();y(!0),await S(e)}catch(e){Promise.reject(e)}finally{y(!1)}},N=async()=>{try{let{response:e,body:r}=await (0,n.hp)();if(!e.ok)return void(0,o.Rm)("Ocurri\xf3 un error al obtener los proveedores");u(r.data)}catch(e){console.error(e)}},P=async()=>{try{let{response:e,body:r}=await (0,n.BS)();if(!e.ok)return void(0,o.Rm)(r.message);Array.isArray(r.data)||c(r.data.es_hogar)}
1catch(e){console.log(e),(0,o.Rm)("Ha ocurrido un error obteniendo el tipo de proveedor")}};return{proveedorTipoHogar:s,proveedoresDisponibles:d,setResetPasswordFlag:x,resetPasswordFlag:h,setProveedoresDisponibles:u,username:m,setUsername:A,idProveedorSeleccionado:j,setIdProveedorSeleccionado:p,showProveedores:g,setShowProveedores:f,loadingButtonProveedor:v,onClickElegirProveedor:k,obtenerProveedores:N,elegirProveedor:S,obtenerTipoProveedor:P}}},54651:()=>{},86974:(e,r,s)=>{"use strict";s.d(r,{A:()=>l});var t=s(42525);s(13897);var n=s(90603),a=s(68959),o=s(53919);let i=(0,a.X1)(e=>{let{inputRef:r,...s}=e;return(0,t.jsx)(n.A,{...s,inputRef:r})}),l=e=>{let{mask:r,...s}=e,n=o.M[r]?o.M[r]:{mask:r};return(0,t.jsx)(i,{...n,...s})}},90048:(e,r,s)=>{"use strict";s.d(r,{A:()=>i});var t=s(13897),n=s(88096),a=s(95486),o=s(79643);let i=function(){let{setNotificaciones:e}=t.useContext(n.o),r=async()=>{try{let{response:r,body:s}=await (0,a.bi)();if(!r.ok)return void e(null);e(s.data)}catch(e){console.error(e),(0,o.Rm)("Ha ocurrido un error al obtener las notificaciones")}},s=async e=>{try{let s=await (0,a.p9)(e);return s.response.ok&&r(),s}catch(e){throw console.error(e),(0,o.Rm)("Ha ocurrido un error al marcar como leido este mensaje"),e}};return{updateNotificaciones:r,updateMailAsRead:s}}},90553:(e,r,s)=>{"use strict";s.d(r,{default:()=>eo});var t=s(42525),n=s(13897),a=s(32733),o=s(13865),i=s(19163),l=s(45843),c=s(28737),d=s(70751),u=s(90603),h=s(90992),x=s(92463),m=s(92094),A=s(21747),j=s(80173),p=s(30058),g=s(86974),f=s(88096),v=s(95486),y=s(79643),b=s(16039),w=s(43731),C=s(47785);let S=function(e){var r;let{show:s,onClose:S}=e,{state:{user:k}}=n.useContext(f.o),N=null!=(r=null==k?void 0:k.username)?r:"",[P,_]=n.useState(!1),[R,E]=n.useState(!1),[O,B]=n.useState(null),[I,T]=n.useState(""),[W,z]=n.useState(""),[H,J]=n.useState(""),[D,G]=n.useState(!1),[F,L]=n.useState(b.DN),[Z,U]=n.useState(!1),[V,M]=n.useState({longitud:!1,mayusculas:!1,numeros:!1,simbolos:!1}),[X,Q]=n.useState(!1),[Y,K]=n.useState(!1),[q,$]=n.useState(!1),[ee,er]=n.useState(!1),es=n.useRef(null);n.useEffect(()=>{s&&(_(!1),E(!0),B(null),T(""),z(""),J(""),L(b.DN),G(!1),K(!1),$(!1),er(!1))},[s]),n.useEffect(()=>{s&&R&&et()},[s,R]);let et=async()=>{try{let{response:e,body:r}=await (0,v.ZL)(N);if(!e.ok)return void B(r.message);_(!0),G(!0)}catch(e){console.log(e),B("Volv\xe9 a iniciar sesi\xf3n para restablecer tu contrase\xf1a correctamente")}finally{E(!1)}},en=async()=>{try{Q(!0);let{response:e,body:r}=await (0,v.dm)(N,I,H);if(!e.ok)return void(0,y.Rm)(r.message);S()}catch(e){console.log(e),(0,y.Rm)("Ha ocurrido un error inesperado")}finally{Q(!1),K(!1)}},ea=async()=>{J(""),E(!0),_(!1),B(null),L(b.DN)};return n.useEffect(()=>{if(!D)return void L(b.DN);let e=setInterval(()=>{L(r=>r<=1?(clearInterval(e),0):r-1)},1e3);return()=>clearInterval(e)},[D]),n.useEffect(()=>{M({longitud:I.length>=b.wz,mayusculas:(0,y.Zn)(I),numeros:(0,y.JP)(I),simbolos:(0,y.sD)(I)})},[I]),(0,t.jsx)(o.A,{show:s,onClose:S,disableOverlayClose:!0,children:(0,t.jsxs)(i.A,{className:"max-h-[75vh] overflow-y-auto",gap:5,children:[(0,t.jsxs)(o.A,{show:Y,onClose:()=>K(!1),disableOverlayClose:!0,children:[(0,t.jsx)(l.A,{className:"text-center",variant:"title",mb:6,children:"\xbfRealmente desea reestablecer su contrase\xf1a?"}),(0,t.jsxs)(c.A,{container:!0,spacing:2,children:[(0,t.jsx)(c.A,{size:"grow",children:(0,t.jsx)(d.A,{fullWidth:!0,variant:"outlined",onClick:()=>K(!1),children:"Cancelar"})}),(0,t.jsx)(c.A,{size:"grow",children:(0,t.jsx)(d.A,{fullWidth:!0,variant:"contained",loading:X,onClick:en,children:"Confirmar"})})]})]}),(0,t.jsx)(l.A,{variant:"title",children:"Restablecer contrase\xf1a"}),(0,t.jsx)(c.A,{container:!0,spacing:2,children:(0,t.jsxs)(c.A,{size:{xs:12,sm:8},children:[(0,t.jsx)(l.A,{variant:"bold",mb:2,children:"Direcci\xf3n de correo"}),(0,t.jsx)(u.A,{fullWidth:!0,disabled:!0,value:N})]})}),R&&(0,t.jsxs)(i.A,{alignItems:"center",gap:2,py:4,children:[(0,t.jsx)(h.A,{}),(0,t.jsx)(l.A,{children:"Enviando c\xf3digo de verificaci\xf3n..."})]}),O&&(0,t.jsxs)(i.A,{alignItems:"center",gap:2,py:4,children:[(0,t.jsx)(l.A,{color:"error.main",textAlign:"center",children:O}),(0,t.jsx)(d.A,{variant:"contained",onClick:S,children:"Cerrar"})]}),P&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(c.A,{container:!0,spacing:2,children:[(0,t.jsxs)(c.A,{size:{xs:12,sm:6},children:[(0,t.jsx)(l.A,{variant:"bold",mb:2,children:"Nueva contrase\xf1a"}),(0,t.jsx)(u.A,{fullWidth:!0,autoComplete:"new-password",ref:es,type:q?"text":"password",value:I,onChange:e=>T(e.target.value),onFocus:()=>U(!0),onBlur:()=>U(!1),slotProps:{input:{endAdornment:(0,t.jsx)(x.A,{onClick:()=>$(e=>!e),children:(0,t.jsx)(a.default,{src:q?w.A:C.A,alt:"Visibilidad"})})}}}),(0,t.jsx)(m.A,{open:Z,anchorEl:null==es?void 0:es.current,placement:"top-start",sx:{zIndex:2001},children:(0,t.jsxs)(i.A,{className:"bg-white border border-black rounded-[10px] p-4 mb-2",gap:2,children:[(0,t.jsx)(l.A,{children:"La contrase\xf1a debe tener:"}),(0,t.jsxs)(A.A,{children:[(0,t.jsx)(l.A,{color:V.longitud?"success.main":"error.main",children:"* Un m\xednimo de 10 caracteres"}),(0,t.jsx)(l.A,{color:V.mayusculas?"success.main":"error.main",children:"* Letras may\xfasculas y min\xfasculas"}),(0,t.jsx)(l.A,{color:V.numeros?"success.main":"error.main",children:"* Caracteres num\xe9ricos"}),(0,t.jsx)(l.A,{color:V.simbolos?"success.main":"error.main",children:"* S\xedmbolos (-!$%^&*, etc.)"})]})]})})]}),(0,t.jsxs)(c.A,{size:{xs:12,sm:6},children:[(0,t.jsx)(l.A,{variant:"bold",mb:2,children:"Repetir contrase\xf1a"}),(0,t.jsx)(u.A,{fullWidth:!0,autoComplete:"new-password",type:ee?"text":"password",helperText:0!==I.length&&0!==W.length&&I!==W?"Las contrase\xf1as no coinciden":"",value:W,onChange:e=>z(e.target.value),slotProps:{input:{endAdornment:(0,t.jsx)(x.A,{onClick:()=>er(e=>!e),children:(0,t.jsx)(a.default,{src:ee?w.A:C.A,alt:"Visibilidad"})})}}})]})]}),(0,t.jsx)(l.A,{className:"text-center",variant:"title",children:"Queremos confirmar tu identidad"}),(0,t.jsx)(l.A,{className:"text-center",children:"Ingres\xe1 los 6 d\xedgitos que enviamos a tu correo electr\xf3nico"}),(0,t.jsx)(c.A,{className:"justify-center",container:!0,children:(0,t.jsx)(c.A,{size:{xs:12,sm:6},children:(0,t.jsx)(g.A,{mask:"000000",slotProps:{htmlInput:{inputMode:"numeric",maxLength:b.k$,style:{textAlign:"center",fontSize:"40px"}}},variant:"standard",value:H,onAccept:e=>J(e)})})}),(0,t.jsx)(c.A,{className:"justify-center",container:!0,children:(0,t.jsx)(c.A,{size:{xs:12,sm:6},children:F>0?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(l.A,{variant:"body2",color:"gray",textAlign:"center",gutterBottom:!0,children:["C\xf3digo de verificaci\xf3n v\xe1lido durante:"," ",(0,y.ks)(F)]}),(0,t.jsx)(A.A,{mt:2,children:(0,t.jsx)(j.A,{variant:"determinate",value:F/b.DN*100})})]}):(0,t.jsx)(A.A,{display:"flex",justifyContent:"center",children:(0,t.jsx)(d.A,{variant:"contained",startIcon:(0,t.jsx)(p.A,{color:"inherit"}),onClick:ea,children:"Reenviar c\xf3digo"})})})}),(0,t.jsxs)(c.A,{container:!0,className:"mt-auto justify-end",spacing:2,children:[(0,t.jsx)(c.A,{size:{xs:6},children:(0,t.jsx)(d.A,{fullWidth:!0,variant:"outlined",onClick:S,children:"Cerrar"})}),(0,t.jsx)(c.A,{size:{xs:6},children:(0,t.jsx)(d.A,{fullWidth:!0,variant:"contained",disabled:0===I.length||I!==W||H.length!==b.k$,onClick:()=>K(!0),children:"Confirmar"})})]})]})]})})};var k=s(93347),N=s(59035),P=s(99983),_=s(23060),R=s(67710),E=s(79401),O=s(23926),B=s(16973),I=s.n(B),T=s(77774),W=s(48523),z=s(90048),H=s(4208),J=s(20421),D=s(45400),G=s(63709),F=s(56251),L=s(95937),Z=s(89364),U=s(75919),V=s(63019),M=s(31985),X=s(91742),Q=s(77964),Y=s(973),K=s(67014),q=s(1538);let $={[b.jG]:(0,t.jsx)(M.A,{},"Gane Tiempo"),[b.Rs]:(0,t.jsx)(X.A,{},"Reportes"),[b.Hp]:(0,t.jsx)(Y.A,{},"Configuracion")},ee=n.memo(e=>{var r;let{menu:s,sidebarOpen:a,setSidebarOpen:o}=e,i=(0,H.A)(q.default.breakpoints.down("sm")),[l,c]=n.useState(!0),d=(0,T.useRouter)(),u=(0,T.usePathname)(),[h,x]=n.useMemo(()=>{let e=u.slice(1,u.length).split("/");return[e[0],e[e.length-1]]},[u]);return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(G.Ay,{children:(0,t.jsxs)(F.A,{selected:!a&&s.controlador===h,onClick:()=>{a?c(e=>!e):(o(!0),c(!0))},sx:{borderRadius:1},children:[(0,t.jsx)(A.A,{mr:2,children:$[s.id_menu]||(0,t.jsx)(Q.A,{},"default-icon-".concat(s.id_menu))}),a&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(L.A,{primary:s.name,sx:{whiteSpace:"nowrap"}}
1),(0,t.jsx)(K.A,{sx:{transform:l?"rotate(180deg)":"rotate(0deg)",transition:"transform 0.2s ease"}})]})]})}),a&&(0,t.jsx)(Z.A,{in:l,timeout:"auto",unmountOnExit:!0,children:(0,t.jsx)(D.A,{sx:{marginLeft:2,padding:0},children:null==(r=s.children)?void 0:r.map(e=>(0,t.jsx)(G.Ay,{sx:{paddingBottom:0,paddingTop:0},children:(0,t.jsx)(F.A,{selected:e.controlador===x,onClick:()=>{d.push("/".concat(s.controlador,"/").concat(e.controlador)),i&&o(!1)},sx:{borderRadius:1},children:(0,t.jsx)(L.A,{primary:e.name})})},e.id_menu))})})]})}),er=function(e){let{header:r,children:s}=e,{state:{menu:a}}=n.useContext(f.o),o=(0,H.A)(q.default.breakpoints.down("sm")),[l,c]=n.useState(!1),[d,u]=n.useState(null);return n.useEffect(()=>{a&&u({...a,children:a.children.filter(e=>e.children&&e.children.length>0)})},[a]),n.useEffect(()=>{c(!o)},[o]),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(J.A,{sx:{borderBottom:"1px solid rgba(0, 0, 0, 0.12)"},children:[(0,t.jsx)(x.A,{className:"me-2",onClick:()=>c(e=>!e),children:l?(0,t.jsx)(V.A,{}):(0,t.jsx)(U.A,{})}),r]}),(0,t.jsxs)(i.A,{direction:"row",className:"h-[calc(100dvh_-_96px)]",children:[o&&l&&(0,t.jsx)(A.A,{onClick:()=>c(!1),sx:{zIndex:2,position:"absolute",height:"calc(100dvh - 96px)",width:"100%",backgroundColor:"rgba(1, 1, 1, 0.5)"}}),(0,t.jsx)(i.A,{sx:{position:o?"absolute":"relative",zIndex:11,backgroundColor:"white",height:"calc(100dvh - 96px)",overflowY:"auto",width:l?400:94*!o,borderRight:"1px solid rgba(0, 0, 0, 0.12)",transition:"width .2s ease-in-out"},children:(0,t.jsx)(D.A,{children:d&&d.children.map(e=>(0,t.jsx)(ee,{menu:e,sidebarOpen:l,setSidebarOpen:c},e.id_menu))})}),(0,t.jsx)(A.A,{className:"flex h-full w-full pt-5 p-8",sx:{backgroundColor:"#F8F9FC"},children:(0,t.jsx)(i.A,{className:"flex-grow overflow-auto",gap:2,children:s})})]})]})},es={src:"/_next/static/media/logo_col.c8fbe4c6.png",height:109,width:109,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAATlBMVEX+KCcAT6IBSZEATJv/KCUCSZNzO2QASZkBS5VMaXH/JiFJP3MBS5YATJr/KSgAS5YBSpX/KioATsQwQ36kNk/tLTB8OV6ZNlYDUJ//LS6QnzlOAAAAGHRSTlP8OJqq0O98GdEA6IX35q65il8Nj6BVnHkrzXANAAAACXBIWXMAAA3XAAAN1wFCKJt4AAAAP0lEQVR4nGPgZGdi5WFm5GRg55Dg4BZhE2IQkOAV52JgEGTgkODnk2SQZEEwBCRY2VgYuERBinmFxbjZGWDaAWdYAtlbDLnBAAAAAElFTkSuQmCC",blurWidth:8,blurHeight:8},et={src:"/_next/static/media/user_icon.2953cd97.svg",height:24,width:24,blurWidth:0,blurHeight:0};var en=s(26522),ea=s(1896);let eo=function(e){let{children:r}=e,{state:{user:s,menu:c,notificaciones:u},setUser:h,setUsuarioGenerico:m,setMenu:j}=n.useContext(f.o),{updateNotificaciones:p}=(0,z.A)(),{proveedoresDisponibles:g,idProveedorSeleccionado:b,setIdProveedorSeleccionado:w,showProveedores:C,setShowProveedores:B,loadingButtonProveedor:H,onClickElegirProveedor:J,obtenerProveedores:D}=(0,W.Z)(),[G,F]=n.useState(!1),[L,Z]=n.useState(!1),[U,V]=n.useState(!1),M=(0,y.OX)("cuit"),X=(0,T.useRouter)(),Q=(0,T.usePathname)();n.useEffect(()=>{K()},[]);let Y=()=>{let e=encodeURIComponent(Q+window.location.search);X.push("/login?callbackUrl=".concat(e))},K=async()=>{try{if(!s||!c){let e=await (0,v.dy)();if(!e.response.ok||Array.isArray(e.body.data))return Y();let r=await (0,v.BJ)(e.body.data.prov);if(!r.response.ok)return Y();h({id_usuario:e.body.data.id_usuario,prov:e.body.data.prov,nombre_prov:e.body.data.prov_nombre,cuit:e.body.data.prov_cuit,username:e.body.data.username}),m(e.body.data.usuario_generico),j(r.body.data)}D(),p()}catch(e){console.log(e),Y()}},q=async()=>{try{V(!0),await (0,v.ri)(),X.push("/login"),h(null),j(null)}catch(e){console.log(e)}finally{V(!1)}},$=()=>(0,t.jsx)(O.A,{proveedores:g,idProveedorSeleccionado:b,setIdProveedorSeleccionado:w,onClickElegirProveedor:J,loading:H});return(0,t.jsx)(n.Suspense,{children:(0,t.jsxs)(er,{header:(0,t.jsxs)(i.A,{direction:"row",className:"w-full justify-between",children:[(0,t.jsx)(()=>(0,t.jsxs)(A.A,{display:"flex",gap:1,alignItems:"center",onClick:()=>X.push("/"),sx:{cursor:"pointer"},children:[(0,t.jsx)(a.default,{src:es,alt:"Logo",width:40}),(0,t.jsx)(l.A,{variant:"h6",color:"primary",fontWeight:700,children:"Proveedores"})]}),{}),(0,t.jsx)(()=>{var e;let[r,o]=n.useState(!1),c=null==u?void 0:u.filter(e=>null===e.visto),d=n.useRef(null);return s?(0,t.jsx)(i.A,{direction:"column",spacing:1,children:(0,t.jsxs)(i.A,{className:"py-1 px-2",direction:"row",alignItems:"center",justifyContent:"space-between",gap:2,children:[(0,t.jsxs)(i.A,{direction:"row",alignItems:"center",gap:2,children:[(0,t.jsx)(x.A,{className:"!bg-[#27559B]",ref:d,onClick:()=>o(!0),children:(0,t.jsx)(a.default,{src:et,alt:"Usuario",width:30})}),(0,t.jsxs)(k.A,{anchorEl:d.current,open:r,onClose:()=>
1o(!1),children:[(0,t.jsxs)(i.A,{className:"px-4 py-2",sx:{display:{xs:"flex",sm:"none"}},spacing:.5,children:[(0,t.jsx)(l.A,{variant:"bold",children:s.prov+" - "+s.nombre_prov}),(0,t.jsx)(l.A,{variant:"smallGray",children:M(s.cuit)}),(0,t.jsx)(l.A,{variant:"smallGray",sx:{fontSize:"0.75rem"},children:s.username})]}),(0,t.jsx)(N.A,{sx:{display:{xs:"flex",sm:"none"}}}),(0,t.jsx)(P.A,{onClick:()=>B(!0),children:"Cambiar Proveedor"}),(0,t.jsx)(P.A,{onClick:()=>Z(!0),children:"Restablecer contrase\xf1a"}),(0,t.jsxs)(P.A,{onClick:()=>F(!0),sx:{justifyContent:"center",color:"primary.main"},children:[(0,t.jsx)(en.A,{sx:{mr:1}}),"Cerrar Sesi\xf3n"]})]}),(0,t.jsxs)(i.A,{sx:{display:{xs:"none",sm:"none",md:"flex"}},spacing:0,children:[(0,t.jsx)(l.A,{variant:"bold",children:s.prov+" - "+s.nombre_prov}),(0,t.jsx)(l.A,{variant:"smallGray",children:M(s.cuit)}),(0,t.jsx)(l.A,{variant:"smallGray",sx:{fontSize:"0.75rem",opacity:.8,maxWidth:"250px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:s.username})]})]}),(0,t.jsx)(i.A,{children:(0,t.jsx)(_.A,{title:"Notificaciones",placement:"bottom",children:(0,t.jsx)(I(),{href:"/notificaciones",children:(0,t.jsx)(x.A,{children:(0,t.jsx)(R.A,{badgeContent:null!=(e=null==c?void 0:c.length)?e:0,color:"error",invisible:!(null==c?void 0:c.length),children:(0,t.jsx)(ea.A,{})})})})})})]})}):null},{})]}),children:[(0,t.jsx)(o.A,{show:G,onClose:()=>F(!1),children:(0,t.jsxs)(i.A,{children:[(0,t.jsx)(l.A,{variant:"title",mb:4,children:"\xbfDesea cerrar la sesi\xf3n?"}),(0,t.jsx)(d.A,{variant:"contained",onClick:q,loading:U,children:"Cerrar sesi\xf3n"})]})}),(0,t.jsx)(S,{show:L,onClose:()=>Z(!1)}),(0,t.jsx)(A.A,{sx:{display:{xs:"none",sm:"block"}},children:(0,t.jsx)(o.A,{className:"w-1/3 overflow-x-hidden",show:C,onClose:()=>B(!1),children:$()})}),(0,t.jsx)(E.A,{sx:{display:{xs:"block",sm:"none"}},anchor:"bottom",open:C,onOpen:()=>B(!0),onClose:()=>B(!1),children:$()}),r]})})}},95486:(e,r,s)=>{"use strict";s.d(r,{$5:()=>i,BJ:()=>c,BS:()=>p,EV:()=>o,ZL:()=>d,bi:()=>m,dm:()=>u,dy:()=>h,hp:()=>j,iD:()=>l,p9:()=>A,ri:()=>x});var t=s(16039),n=s(79643),a=s(914);async function o(e,r,s){try{let n=await (0,a.f)(t.xs+"/usuarios/validacion",{method:"POST",body:JSON.stringify({mail:e,...null!==r&&{cuit_proveedor:r},...null!==s&&{id_proveedor:s}})});return{response:n,body:await n.json()}}catch(e){return Promise.reject(e)}}async function i(e,r,s,n,o,i,l,c){try{let d=await (0,a.f)(t.xs+"/usuarios",{method:"POST",body:JSON.stringify({codigo_generado:e,cuit_proveedor:r,mail:s,password:n,...0!==i&&{tipo_documento:o},...0!==i&&{nro_documento:i},...0!==l.length&&{nombre:l},...0!==c.length&&{apellido:c}})});return{response:d,body:await d.json()}}catch(e){return Promise.reject(e)}}async function l(e,r){try{let s=await (0,n.tW)(r),o=await (0,n.tW)(r,n.vA.SHA1),i=await (0,a.f)(t.xs+"/usuarios/login",{method:"POST",body:JSON.stringify({username:e,password:s,password2:o})});return{response:i,body:await i.json()}}catch(e){return Promise.reject(e)}}async function c(e){try{let r=await (0,a.f)(t.xs+"/usuarios/proveedor/"+e);return{response:r,body:await r.json()}}catch(e){return Promise.reject(e)}}async function d(e){try{let r=await (0,a.f)(t.xs+"/usuarios/reset_request",{method:"POST",body:JSON.stringify({mail:e})});return{response:r,body:await r.json()}}catch(e){return Promise.reject(e)}}async function u(e,r,s){try{let o=await (0,n.tW)(r),i=await (0,a.f)(t.xs+"/usuarios/reset",{method:"POST",body:JSON.stringify({codigo_generado:s,mail:e,password:o})});return{response:i,body:await i.json()}}catch(e){return Promise.reject(e)}}async function h(){try{let e=await fetch(t.xs+"/usuarios/session",{credentials:"include"});return{response:e,body:await e.json()}}catch(e){return Promise.reject(e)}}async function x(){try{let e=await (0,a.f)(t.xs+"/usuarios/logout",{method:"POST"});return{response:e,body:await e.json()}}catch(e){return Promise.reject(e)}}async function m(){try{let e=await (0,a.f)(t.xs+"/notificaciones");return{response:e,body:await e.json()}}catch(e){return Promise.reject(e)}}async function A(e){try{let r=await (0,a.f)(t.xs+"/notificaciones/"+e,{method:"POST"});return{response:r,body:await r.json()}}catch(e){return Promise.reject(e)}}async function j(){try{let e=await (0,a.f)(t.xs+"/usuarios/proveedores",{method:"GET"});return{response:e,body:await e.json()}}catch(e){return Promise.reject(e)}}async function p(){try{let e=await (0,a.f)(t.xs+"/proveedores/es_hogar",{method:"GET"});return{response:e,body:await e.json()}}catch(e){return Promise.reject(e)}}}},e=>{e.O(0,[5580,2974,7829,5070,1304,107,7144,7964,603,2094,1355,3709,173,9863,2733,8737,9401,6973,1554,3964,5825,9643,3599,8954,6657,7358],()=>e(e.s=42965)),_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.