1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2493],{10335:(e,r,s)=>{"use strict";s.d(r,{A:()=>m});var t=s(37876),a=s(14232),i=s(89099),l=s(41217),n=s(55757),o=s(46536),c=s(93514),d=s(33386),u=s(67835);let m=e=>{let{children:r,sectionKey:s,redirectToFirstPermitted:m=!1}=e,h=(0,i.useRouter)(),{isFetching:x,isError:f}=(0,u.A)(),{isFetching:b,isError:p}=(0,o.Xr)(),{canRenderByPermissionKey:j,isLoading:v}=(0,c.A)(),g=(()=>{var e;let{commerceId:r}=(0,u.A)(),{canRenderByPermissionKey:s}=(0,c.A)();if(!r)return null;let t=d.k.find(e=>!0===s(e.key));return null!=(e=null==t?void 0:t.buildHref(r))?e:null})(),_=(0,a.useMemo)(()=>Array.isArray(s)?s:[s],[s]).some(e=>!0===j(e)),A=!v&&!x&&!b&&!f&&!p&&!_&&m&&!!g;return((0,a.useEffect)(()=>{A&&g&&h.replace(g)},[A,g,h]),v||x||b)?(0,t.jsx)(n.a,{}):f?(0,t.jsx)(l.A,{error:{status:401,data:{message:"Contacte con el administrador del comercio"}}}):p?(0,t.jsx)(t.Fragment,{children:"Error leyendo datos del usuario"}):_?r:A?(0,t.jsx)(n.a,{}):(0,t.jsx)(l.A,{title:"No autorizado",error:{status:403,data:{message:"No tienes permisos para acceder a esta secci\xf3n. Contacta con el administrador del comercio."}}})}},27954:(e,r,s)=>{"use strict";s.d(r,{A:()=>c});var t=s(37876),a=s(37972),i=s(41217),l=s(79681),n=s(18124),o=s(67835);let c=e=>{var r,s;let{children:c}
1=e,{commerceDetail:d,isFetching:u,isLoading:m,error:h}=(0,o.A)();if(u||m)return(0,t.jsx)(n.A,{});if(!d||h)return(0,t.jsx)(i.A,{error:h});let{modules_access:x}=d;if(!(null==x||null==(s=x.subscription)||null==(r=s.allow_view)?void 0:r.enabled)){let e="mailto:".concat(a.Te,"?subject=Acceso a Suscripciones&body=Nombre del comercio: ").concat(d.commercial_name," - Rut: ").concat(d.legal_id);return(0,t.jsxs)("div",{className:"flex flex-col gap-4 font-archivo",children:[(0,t.jsx)("h1",{className:"text-heading-3 font-semibold text-light-black",children:"Aviso"}),(0,t.jsxs)("p",{className:"text-ui-2 text-light-black",children:["Para activar las Suscripciones, env\xedanos un correo a"," ",(0,t.jsx)("a",{className:(0,l.X)({className:"text-ui-2"}),href:e,children:a.Te})," ","escribiendo en el asunto: âAcceso a Suscripcionesâ. En el cuerpo debe ir el Nombre y el Rut de tu comercio."]})]})}return c}},38769:(e,r,s)=>{"use strict";s.d(r,{A:()=>o});var t=s(37876),a=s(48230),i=s.n(a),l=s(14561),n=s(16843);let o=e=>{let{children:r,className:s="",type:a="submit",href:o,isLoading:c=!1,width:d="fit-content",disabled:u,target:m,rel:h,...x}=e,f=(0,t.jsxs)(t.Fragment,{children:[c&&(0,t.jsx)("span",{className:"h-4 w-4 animate-spin rounded-full border-2 border-current border-b-transparent","aria-hidden":!0}),(0,t.jsx)("span",{children:r})]}),b=(0,n.cn)("gap-2","full"===d?"w-full":"w-fit",s);if(o&&!u){let e="string"==typeof o&&/^https?:\/\//.test(o);return(0,t.jsx)(l.$,{asChild:!0,className:b,children:e?(0,t.jsx)("a",{href:o,target:m,rel:h,children:f}):(0,t.jsx)(i(),{href:o,children:f})})}return(0,t.jsx)(l.$,{type:a,className:b,disabled:u||c,...x,children:f})}},41217:(e,r,s)=>{"use strict";s.d(r,{A:()=>u});var t=s(37876),a=s(48230),i=s.n(a),l=s(23138),n=s(38769),o=s(79999),c=s(66823),d=s.n(c);let u=e=>{var r;let{error:s,title:a="Ocurri\xf3 un error al cargar los datos del comercio:"}=e,c=(null==s||null==(r=s.data)?void 0:r.message)||"Error desconocido",u=(c.charAt(0).toUpperCase()+c.slice(1)).replace(".",".**").split("**");return(0,t.jsx)("div",{className:d().container,children:(0,t.jsxs)("div",{children:[(0,t.jsx)(o.K,{size:"lg",weight:"semibold",children:a}),u.map(e=>e?(0,t.jsx)(o.K,{className:d().error,children:e},e):null),(0,t.jsx)(i(),{href:l.CyH,className:d().link,children:(0,t.jsx)(n.A,{children:"Volver al inicio"})})]})})}},52077:(e,r,s)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/commerce/[commerceId]/subscriptions/subscribers",function(){return s(89271)}])},55757:(e,r,s)=>{"use strict";s.d(r,{a:()=>t.default});var t=s(67654)},66823:e=>{e.exports={container:"CommerceError_container__ojoF_",error:"CommerceError_error__nKrQS",link:"CommerceError_link__uQAdK"}},79681:(e,r,s)=>{"use strict";s.d(r,{N:()=>c,X:()=>o});var t=s(37876),a=s(14232),i=s(47137),l=s(16843),n=s(82987);let o=(0,i.F)("focus-visible:ring-offset-0disabled:cursor-not-allowed rounded-lg font-archivo text-sm font-medium text-informative-500 transition-colors hover:text-informative-700 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-secondary-200 disabled:text-neutral-500"),c=a.forwardRef((e,r)=>{let{className:s,asChild:a=!1,...i}=e,c=a?n.DX:"a";return(0,t.jsx)(c,{className:(0,l.cn)(o({className:s})),ref:r,...i})});c.displayName="Link"},89271:(e,r,s)=>{"use strict";s.r(r),s.d(r,{default:()=>b});var t=s(37876),a=s(18847),i=s.n(a),l=s(27954),n=s(10335),o=s(53259),c=s(78800),d=s(59735),u=s(53523),m=s(67654);let h=i()(()=>Promise.all([s.e(8530),s.e(2262),s.e(3314),s.e(9505),s.e(7459),s.e(4102),s.e(6942),s.e(4605)]).then(s.bind(s,15272)),{loadableGenerated:{webpack:()=>[15272]},loading:()=>(0,t.jsx)(m.default,{})}),x=i()(()=>Promise.all([s.e(8530),s.e(9418),s.e(1336),s.e(2262),s.e(3314),s.e(9505),s.e(7459),s.e(6422),s.e(5555),s.e(4102),s.e(2248),s.e(6942),s.e(8835)]).then(s.bind(s,28835)),{loadableGenerated:{webpack:()=>[28835]},loading:()=>(0,t.jsx)(m.default,{})}),f=()=>(0,t.jsx)(n.A,{sectionKey:o.rh.SUBSCRIPTION.CUSTOMER_LIST,children:(0,t.jsx)(l.A,{children:(0,t.jsx)(u.A,{desktop:(0,t.jsx)(h,{}),mobile:(0,t.jsx)(x,{})})})});f.getLayout=(0,d.k)({headerComponent:(0,t.jsx)(c.A,{title:"Suscripciones"}),config:{hideCaptcha:!0}});let b=f}},e=>{e.O(0,[9135,8230,4587,9749,748,2135,2909,3406,8181,4085,15,5715,1552,9261,6761,659,3404,636,6593,8792],()=>e(e.s=52077)),_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.