1import{dV as i,d0 as e,da as l,bN as r,bu as d,c as n}from"./index-SW_ThLYf.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};a.SENTRY_RELEASE={id:"bec1de57eae065682d34a4d342eab128bf62b115"}}catch{}})();try{(function(){var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new a.Error().stack;s&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[s]="2a37085e-67f3-441e-a2dc-c4d88d815cf1",a._sentryDebugIdIdentifier="sentry-dbid-2a37085e-67f3-441e-a2dc-c4d88d815cf1")})()}catch{}const c=a=>e.jsxs("div",{className:"row",children:[e.jsx("div",{className:"row",children:e.jsx("div",{className:"col-sm-12",children:e.jsx("h1",{className:"text-center",children:"Aquà tienes tu factura"})})}),e.jsxs("div",{className:"col-sm-offset-4 col-sm-4",children:["Hola ",a.clientName,", a continuación puedes descargar la factura que te envÃa ",a.userName,e.jsx("br",{}),e.jsx(n,{label:"Descargar factura",onClick:a.handleAction}),e.jsx("h2",{children:"¿Conoces Declarando? "}),e.jsx("p",{children:"La asesorÃa fiscal premium que ayuda a más de 40.000 autónomos"}),e.jsx(n,{onClick:()=>a.handleGoBlog(),label:"Más información sobre Declarando"}),e.jsx("h4",{children:"VENTAJAS DE USAR DECLARANDO"}),e.jsxs("ul",{children:[e.jsx("li",{children:"Más ahorro: hasta 4.000⬠al año entre impuestos y renta"}),e.jsx("li",{children:"100% online: nuestra plataforma está accesible desde tu ordenador o teléfono móvil, sin necesidad de desplazarte para ver a tu gestor"}),e.jsx("li",{children:"Sin errores: aplicamos automáticamente todos los requisitos que pide Hacienda en tu contabilidad e impuestos"}),e.jsx("li",{children:"Totalmente seguro: todos tu datos están encriptados y tus cuentas totalmente seguras"})]})]})]}),f=a=>{const s=i();return e.jsx(u,{...a,params:s})};class u extends l.Component{constructor(s){super(s),this.repositoryFactory=new r,this.repositoryV2=this.repositoryFactory.getInvoiceByTokenV2Repository(),this.state={valid:null,userName:"",clientName:""}}getFileKey=()=>this.props?.params?.key;componentDidMount(){const s=this.getFileKey();this.repositoryV2.invoiceByToken(s).then(t=>{const o=t.data;o.valid?this.setState({valid:!0,userName:o.userName,clientName:o.clientName}):this.setState({valid:!1})})}handleDownloadFactura=()=>{const s=this.getFileKey(),t=this.repositoryV2.invoicePdfByToken(s);window.open(t,"_blank")};goBlog=()=>{window.open("https://declarando.es/","_blank")};render(){let s=null;return this.state.valid===!0?s=e.jsx(c,{clientName:this.state.clientName,userName:this.state.userName,handleAction:this.handleDownloadFactura,handleGoBlog:this.goBlog}):this.state.valid===!1&&(s=e.jsx(d,{title:"ERROR: Archivo no encontrado",body:"No hemos encontrado la factura que estás buscando"})),s}}export{f 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.