1"use strict";(self.webpackChunkapp=self.webpackChunkapp||[]).push([[7863],{92871:(D,C,e)=>{e.d(C,{x:()=>K});var z=e(65938),g=e(15439),i=e(94650),c=e(32233),f=e(36895),P=e(1576),d=e(4859),h=e(99602),S=e(284),y=e(59549),T=e(24006);function I(p,u){if(1&p){const A=i.EpF();i.ynx(0),i.TgZ(1,"p"),i._uU(2,"Da quando vuoi sospendere la polizza?"),i.qZA(),i.TgZ(3,"div",6)(4,"mat-form-field",7)(5,"mat-label"),i._uU(6,"Data di sospensione"),i.qZA(),i.TgZ(7,"input",8),i.NdJ("ngModelChange",function(o){i.CHM(A);const n=i.oxw();return i.KtG(n.dataEvento=o)})("click",function(){i.CHM(A);const o=i.MAs(10);return i.KtG(o.open())}),i.qZA(),i._UZ(8,"mat-datepicker-toggle",9)(9,"mat-datepicker",10,11),i.qZA()(),i.BQk()}if(2&p){const A=i.MAs(10),t=i.oxw();i.xp6(7),i.Q6J("matDatepicker",A)("ngModel",t.dataEvento)("max",t.maxDate)("min",t.minDate),i.xp6(1),i.Q6J("for",A),i.xp6(1),i.s9C("touchUi",t.mediaObserver.isActive("xs"))}}function R(p,u){if(1&p&&i._uU(0),2&p){const A=i.oxw();i.hij(" ",A.messaggioErrore," ")}}let E=(()=>{const u=class{constructor(t,o,n){this.dialogRef=t,this.data=o,this.mediaObserver=n,this.dataEvento=new Date}ngOnInit(){this.dataEvento.setHours(-this.dataEvento.getTimezoneOffset()/60),this.dataEvento.setSeconds(0),this.dataEvento.setMinutes(0),this.dataEvento.setMilliseconds(0),this.maxDate=g(this.dataEvento).add(9,"day").toDate(),this.minDate=g(this.dataEvento).add(1,"day").toDate(),this.dataEvento=this.minDate}verificaSospensione(){this.dataEvento&&g(this.dataEvento)>=g(this.minDate)&&g(this.dataEvento)<=g(this.maxDate)&&this.dialogRef.close(g(this.dataEvento).format("YYYY-MM-DD"))}annullaVerifica(){this.dialogRef.close()}};let p=u;return u.\u0275fac=function(o){return new(o||u)(i.Y36(z.so),i.Y36(z.WI),i.Y36(c.u0))},u.\u0275cmp=i.Xpm({type:u,selectors:[["ar-verifica-sospensione-polizza"]],decls:11,vars:2,consts:[[1,"title-info"],[4,"ngIf","ngIfElse"],["showError",""],["fxLayout","row wrap","fxLayoutAlign","end center"],["mat-flat-button","","fxFlex","30%","fxFlex.lt-md","100%",1,"ar-button",3,"click"],["mat-flat-button","","fxFlex","30%","fxFlex.lt-md","100%","cdkFocusInitial","",1,"ar-button",3,"click"],[1,"row"],["fxFlex","100"],["matInput","","required","",3,"matDatepicker","ngModel","max","min","ngModelChange","click"],["matSuffix","",3,"for"],[3,"touchUi"],["picker",""]],template:function(o,n){if(1&o&&(i.TgZ(0,"mat-dialog-content")(1,"h3",0),i._uU(2,"Richiesta di sospensione"),i.qZA(),i.YNc(3,I,11,6,"ng-container",1),i.YNc(4,R,1,1,"ng-template",null,2,i.W1O),i.qZA(),i.TgZ(6,"div",3)(7,"button",4),i.NdJ("click",function(){return n.annullaVerifica()}),i._uU(8,"Annulla"),i.qZA(),i.TgZ(9,"button",5),i.NdJ("click",function(){return n.verificaSospensione()}),i._uU(10,"Ok"),i.qZA()()),2&o){const l=i.MAs(5);i.xp6(3),i.Q6J("ngIf",!n.messaggioErrore)("ngIfElse",l)}},dependencies:[f.O5,P.xw,P.Wh,P.yH,d.lW,z.xY,h.Mq,h.hl,h.nW,S.Nt,y.KE,y.hX,y.R9,T.Fj,T.JJ,T.Q7,T.On],styles:["h3.title-info[_ngcontent-%COMP%]{color:var(--primary-color);margin-bottom:5px!important}.ar-button[_ngcontent-%COMP%]{margin:10px}"]}),p})();var a=e(31059),r=e(40537),m=e(43111),s=e(74670),v=e(42684),O=e(36700),b=e(90603),M=e(71188),L=e(99571),Y=e(44476),U=e(19748),V=e(97392),F=e(28255);function B(p,u){if(1&p){const A=i.EpF();i.ynx(0),i.TgZ(1,"button",3),i.NdJ("click",function(){const n=i.CHM(A).$implicit,l=i.oxw();return i.KtG(l.doActions(n.id,n.parametri,n.descrizione))}),i._uU(2),i.qZA(),i.BQk()}if(2&p){const A=u.$implicit;i.xp6(2),i.hij(" ",A.descrizione," ")}}let K=(()=>{const u=class{constructor(t,o,n,l,x,W,Z,$,J,N,w,G,H,j){this.pagamentiService=t,this.dialog=o,this.dettaglioPolizzaAutoService=n,this.dettaglioPolizzaVitaService=l,this.dettaglioPolizzaService=x,this.clienteService=W,this.firmaService=Z,this.messageService=$,this.loaderService=J,this.navCtrl=N,this.storageService=w,this.mobileService=G,this.activatedRoute=H,this.sospensionePolizzaService=j,this.label=""}ngAfterContentInit(){this.label=this.tipologia?"Apri opzioni per "+this.tipologia+" "+this.copertura+" numero "+this.numero:"Apri dettagli"}doActions(t,o,n){if("Aggiungi"===t)this.addToCart(this.idPolizza,this.codProdotto);else if("Paga"===t)this.payImmediatly(this.idPolizza,this.codProdotto);else if("Documenti"===t)this.navCtrl.navigateRoot("documenti/"+this.idPolizza);else if("Contatta"===t){const l=null!=this.activatedRoute.snapshot.queryParams.id?this.activatedRoute.snapshot.queryParams.id:this.activatedRoute.snapshot.params.id;null!=l?this.navCtrl.navigateRoot("contatta-agenzia/"+this.idPolizza,{queryParams:{copertura:l}}):this.navCtrl.navigateRoot("contatta-agenzia/"+this.idPolizza)}else if("NuovoTagliando"===t)this.toNuovoTagliando(this.idPolizza);else if("Sinistro"===t)this.toSinistro(this.idPolizza);else if("SinistroRE"===t)this.toSinistroRe(this.idPolizza);else if("SinistroReEsterno"===t)this.toSinistro(this.idPolizza);else if("AggiungiAll"===t)this.addAllToCart(this.idPolizza);else if("PagaAll"===t)this.payAllImmediatly(this.idPolizza);else if("Stampa"===t)window.print();else if("AggiungiAll"===t)this.payAllImmediatly(this.idPolizza);else if("PagaAll"===t)this.addAllToCart(this.idPolizza);else if("Dettaglio"===t)this.toDettaglio(this.idPolizza);else if("Sospendibile"===t)this.sospendiPolizza(this.idPolizza);else if("SospendibileRE"===t)this.sospendiPolizzaRE(this.idPolizza);
1else if("VersamentoAggiuntivo"===t)this.navCtrl.navigateRoot("versamento-aggiuntivo/"+this.idPolizza);else if("VersamentoAggiuntivoAVC"===t)this.versamentoAggiuntivo();else if("SimulazionePrestazione"===t)this.simulazionePrestazione(this.idPolizza);else if("VersamentoAggiuntivoPip"===t||"VersamentoAggiuntivoFpa"==t)this.navCtrl.navigateRoot(`versamento-aggiuntivo-pip/${this.idPolizza}?action=${t}`);else if("RichiediRiscatto"===t)this.navCtrl.navigateRoot("richiesta-riscatto/"+this.idPolizza,{queryParams:{totale:!0,title:"Richiesta di riscatto - Polizza Vita - Risparmio e Investimento"}});else if("RichiediRiscattoParziale"===t)this.navCtrl.navigateRoot("richiesta-riscatto/"+this.idPolizza,{queryParams:{totale:!1,title:"Richiesta di riscatto - Polizza Vita - Risparmio e Investimento"}});else if("RichiestaAnticipazionePIP"===t||"RichiestaAnticipazioneFPD"===t||"RichiestaTrasferimentoPIP"===t||"RichiestaTrasferimentoFPD"===t||"RichiestaRiscattoPrevidenzaPIP"===t||"RichiestaRiscattoPrevidenzaFPD"===t||"RichiestaRiscattoRITAPrevidenzaPIP"===t||"RichiestaRiscattoRITAPrevidenzaFPD"===t||"RichiestaSwitchFPA"===t)n=n.replace("Richiedi","Richiesta"),this.navCtrl.navigateRoot("richiesta-vita-common/"+this.idPolizza,{queryParams:{tipoRichiestaVitaCommon:t,tipoRichiestaVitaCommonDesc:n}});else if("Reclamo"===t)this.mobileService.apriBrowserFromObs(this.clienteService.recuperaLinkReclami(),!0).subscribe();else if("Riattivabile"===t)this.navCtrl.navigateRoot(`richiesta-sospensione/${this.idPolizza}/riattiva`);else if("Prorogabile"===t)this.prorogaPolizza(this.idPolizza);else if("RimborsoSpeseVeterinarie"===t)this.navCtrl.navigateRoot(`rimborso-spese-veterinarie/${this.idPolizza}`);else if("ApriSinistroSceltaMultipla"===t)this.navCtrl.navigateRoot(`scegli-tipo-sinistro/${this.idPolizza}`);else if("RimborsoMalattia"===t){let l=null;this.mobileService.isApp()?this.loaderService.show():(l=window.open(),l.document.body.innerHTML="<html><title>Caricamento in corso...</title><body>Caricamento documento in corso...</body></html>"),this.dettaglioPolizzaService.getLinkPortaleMapfre({...(0,a.I)(this.idPolizza)}).subscribe(x=>{this.mobileService.isApp()?(this.loaderService.hide(),window.open(x,"_system")):l.location.href=x})}}versamentoAggiuntivo(){this.loaderService.show(),this.clienteService.checkConsensoFea().pipe((0,r.x)(()=>{this.loaderService.hide()})).subscribe(t=>{t.consenso?this.navCtrl.navigateRoot("versamento-aggiuntivo-avc/"+this.idPolizza):(this.loaderService.show(),this.messageService.showConfirmDialog(t.messaggio,"Conferma","Annulla","350px").subscribe(o=>{o&&this.firmaService.startAdesione({idPolizza:this.idPolizza}).pipe((0,r.x)(()=>{this.loaderService.hide()})).subscribe()}))})}simulazionePrestazione(t){this.mobileService.apriBrowserFromObs(this.dettaglioPolizzaVitaService.recuperaLinkPreventivatore({...(0,a.I)(t)}).pipe((0,r.x)(()=>{this.loaderService.hide()})),!0).subscribe()}toNuovoTagliando(t){if(this.datiPwac||this.messageService.showMessage("Impossibilie procedere, errore imprevisto",!0),this.datiPwac.giorniTotali-this.datiPwac.giorniUsati>0){const o={...this.datiPwac,codProdotto:this.codProdotto,codLineaProdotto:this.codLineaProdotto};this.storageService.set("nuovo-tagliando",o,!1),this.navCtrl.navigateRoot(`nuovo-tagliando/${t}`)}else this.messageService.showMessage("Impossibilie procedere, giorni di copertura terminati",!0)}toDettaglio(t){"FPA"===this.codAgenzia?this.navCtrl.navigateRoot(`dettaglio-polizza/${this.codAgenzia}.${this.codRamo}.${this.numeroPolizza}`):(localStorage.setItem("polizzaInfoId",t),this.navCtrl.navigateRoot("dettaglio-polizza/"+t))}toSinistro(t){this.navCtrl.navigateRoot("denuncia-sinistri/tipi",{queryParams:{idCategoria:1,idOggetto:"Auto",idPolizza:t}})}toSinistroRe(t){this.navCtrl.navigateRoot(`liquidazione-sinistro/${t}`)}toSinistroReEsterno(t,o){this.navCtrl.navigateRoot(["denuncia-sinistri/apri-sinistro-esterno"],{queryParams:{idCategoria:o.idCategoria,idPolizza:this.idPolizza,idOggetto:o.idOggetto,idTipo:o.idTipo,codiceFornitore:o.codiceFornitore}})}addToCart(t,o){this.pagamentiService.addToCart(t,o)}payImmediatly(t,o){this.pagamentiService.payImmediatly(t,o)}addAllToCart(t){this.pagamentiService.addAllToCart(t)}payAllImmediatly(t){this.pagamentiService.payAllImmediatly(t)}sospendiPolizzaRE(t){this.navCtrl.navigateRoot(`richiesta-sospensione/${t}/sospendi-re`)}sospendiPolizza(t){this.dialog.open(E,{width:"500px",data:{idPolizza:t}}).afterClosed().subscribe(n=>{n&&(this.loaderService.show(),this.dettaglioPolizzaAutoService.step1Sospensione({...(0,a.I)(t),body:{...(0,a.I)(t),dataSospensione:n}}).pipe((0,r.x)(()=>{this.loaderService.hide()})).subscribe(l=>{l.esito?l.polizzaWarning?this.messageService.showConfirmDialog(l.messaggio,"Prosegui","Visualizza","400px",!0).subscribe(x=>{x?this.goTorichiestaSospensione(l):this.toDettaglio(l.polizzaWarning)}):this.goTorichiestaSospensione(l):this.messageService.showMessage(l.messaggio,!l.esito,"500px")}))})}goTorichiestaSospensione(t){const o=this.sospensionePolizzaService.setData(this.idPolizza,{...t,polId:this.idPolizza});this.navCtrl.navigateRoot("richiesta-sospensione/"+this.idPolizza,{queryParams:{sospensioneSessionId:o}})}prorogaPolizza(t){this.loaderService.show(),this.dettaglioPolizzaAutoService.step1ProrogaSospensione({...(0,a.I)(t),body:{...(0,a.I)(t)}}).pipe((0,r.x)(()=>{this.loaderService.hide()})).subscribe(o=>{o.esito?this.goToProrogaSospensione(o):this.messageService.showMessage(o.messaggio,!o.esito,"500px")})}goToProrogaSospensione(t){const n=this.sospensionePolizzaService.setData(this.idPolizza,{dataSospensione:t.dataSospensione,dataRiattivazione:t.dataRiattivazione,targa:t.targa,premio:t.sottomotivo?.premio,sottomotivo:t.sottomotivo,sottomotivi:[t.sottomotivo],polId:this.idPolizza});this.navCtrl.navigateRoot(`richiesta-sospensione/${this.idPolizza}/proroga`,{queryParams:{sospensioneSessionId:n}})}};let p=u;return u.\u0275fac=function(o){return new(o||u)(i.Y36(m.z),i.Y36(z.uw),i.Y36(s.iM),i.Y36(s.vG),i.Y36(s.A5),i.Y36(s.$z),i.Y36(s.RR),i.Y36(v.e),i.Y36(O.D),i.Y36(b.SH),i.Y36(M.V),i.Y36(L.W),i.Y36(Y.gz),i.Y36(U.y))},u.\u0275cmp=i.Xpm({type:u,selectors:[["ar-action-button"]],inputs:{azioni:"azioni",idPolizza:"idPolizza",codProdotto:"codProdotto",codLineaProdotto:"codLineaProdotto",codAgenzia:"codAgenzia",codRamo:"codRamo",numeroPolizza:"numeroPolizza",datiPwac:"datiPwac",tipologia:"tipologia",copertura:"copertura",numero:"numero"},decls:6,vars:3,consts:[["mat-icon-button","",1,"mobile-action-menu",3,"matMenuTriggerFor"],["menu","matMenu"],[4,"ngFor","ngForOf"],["mat-menu-item","",3,"click"]],template:function(o,n){if(1&o&&(i.TgZ(0,"button",0)(1,"mat-icon"),i._uU(2,"more_vert"),i.qZA()(),i.TgZ(3,"mat-menu",null,1),i.YNc(5,B,3,1,"ng-container",2),i.qZA()),2&o){const l=i.MAs(4);i.Q6J("matMenuTriggerFor",l),i.uIk("aria-label",n.label),i.xp6(5),i.Q6J("ngForOf",n.azioni)}},dependencies:[f.sg,d.RK,V.Hw,F.VK,F.OP,F.p6],styles:["ar-action-button .mobile-action-menu{margin-top:15px;margin-bottom:15px;background-color:#f1f1f1;color:var(--secondary-color)}@media (min-width: 1025px){button:focus-visible{outline:2px solid var(--secondary-color)}}\n"],encapsulation:2}),p})()},8611:(D,C,e)=>{e.d(C,{z:()=>m});var z=e(53358),g=e(4859),i=e(97392),c=e(28255),f=e(44476),P=e(43111),d=e(42684),h=e(69814),S=e(98674),y=e(65938),T=e(99602),I=e(284),R=e(24006),E=e(94650);let a=(()=>{const v=class{};let s=v;return v.\u0275fac=function(M){return new(M||v)},v.\u0275mod=E.oAB({type:v}),v.\u0275inj=E.cJS({imports:[z.m,h.o9,S.z,i.Ps,g.ot,y.Is,T.FA,I.c,R.u5]}),s})();var r=e(71188);let m=(()=>{const v=class{};let s=v;return v.\u0275fac=function(M){return new(M||v)},v.\u0275mod=E.oAB({type:v}),v.\u0275inj=E.cJS({providers:[P.z,d.e,r.V],imports:[z.m,f.Bz,g.ot,i.Ps,c.Tx,a,y.Is]}),s})()},43111:(D,C,e)=>{e.d(C,{z:()=>T});var z=e(21086),g=e(87545),i=e(27221),c=e(94650),f=e(85210),P=e(42684),d=e(90603),h=e(22719),S=e(74670),y=e(36700);let T=(()=>{const R=class{constructor(a,r,m,s,v,O){this.carrelloService=a,this.messageService=r,this.navCtrl=m,this.toolbarService=s,this.calendarioService=v,this.loaderService=O}addToCart(a,r){this._addToCart(a,r,!1)}payImmediatly(a,r){this._addToCart(a,r,!0)}_addToCart(a,r,m){this.carrelloService.addTitoli(a,[{idPolizza:a,idTitolo:r}]).subscribe(s=>{this.toolbarService.refreshCount(),this.messageService.showMessage(s.message,s.error),m&&!s.error?this.navCtrl.navigateRoot("carrello",{queryParams:{valida:!0}}):s.error&&s.errorRedirect&&this.navCtrl.navigateRoot(s.errorRedirect)},s=>{this.messageService.showMessage("Errore "+s,!0)})}addToCartPolizzone(a,r){this._addToCartPolizzone(a,r,!1)}payImmediatlyPolizzone(a,r){this._addToCartPolizzone(a,r,!0)}_addToCartPolizzone(a,r,m){this.carrelloService.addTitoli(a,r).subscribe(s=>{this.toolbarService.refreshCount(),this.messageService.showMessage(s.message,s.error),m&&!s.error&&this.navCtrl.navigateRoot("carrello",{queryParams:{valida:!0}})},s=>{this.messageService.showMessage("Errore "+s,!0)})}payAllImmediatly(a){this._addAllToCart(a,!0)}addAllToCart(a){this._addAllToCart(a,!1)}_addAllToCart(a,r){this.carrelloService.aggiungiTuttiTitoli(a).subscribe(m=>{this.toolbarService.refreshCount(),this.messageService.showMessage(m.message,m.error),r&&!m.error&&this.navCtrl.navigateRoot("carrello",{queryParams:{valida:!0}})},m=>{this.messageService.error("Errore "+m)})}richiestaIncassoCartaDiCredito(a){return this.loaderService.show(),this.calendarioService.richiestaIncassoCartaDiCredito({body:{idPolizza:a}}).pipe((0,g.w)(m=>(m&&this.messageService.info("A breve riceverai un sms con un link per inserire la Carta di Credito"),this.loaderService.hide(),(0,z.of)(m))),(0,i.K)(()=>(this.loaderService.hide(),this.messageService.info("Errore imprevisto, riprovare"),(0,z.of)(!1))))}};let I=R;return R.\u0275fac=function(r){return new(r||R)(c.LFG(f.H),c.LFG(P.e),c.LFG(d.SH),c.LFG(h.O),c.LFG(S.IV),c.LFG(y.D))},R.\u0275prov=c.Yz7({token:R,factory:R.\u0275fac}),I})()},19748:(D,C,e)=>{e.d(C,{y:()=>g});var z=e(94650);let g=(()=>{const f=class{constructor(){this._localStorageBaseKey="sospensione-polizza-service"}getData(d){const h=localStorage.getItem(`${this._localStorageBaseKey}-${d}`);return h?JSON.parse(h):null}updateData(d,h){const S=JSON.stringify(h);localStorage.setItem(`${this._localStorageBaseKey}-${d}
1`,S)}setData(d,h){const S=d+Date.now().toString();return localStorage.setItem(`${this._localStorageBaseKey}-${S}`,JSON.stringify(h)),S}};let c=f;return f.\u0275fac=function(h){return new(h||f)},f.\u0275prov=z.Yz7({token:f,factory:f.\u0275fac,providedIn:"root"}),c})()},71188:(D,C,e)=>{e.d(C,{V:()=>g});var z=e(94650);let g=(()=>{const c=class{set(P,d,h=!0){let S=d;d&&(S=JSON.stringify(d)),h?localStorage.setItem(P,S):sessionStorage.setItem(P,S)}get(P){let d=localStorage.getItem(P);if(d||(d=sessionStorage.getItem(P)),!d)return null;try{return JSON.parse(d)}catch{return null}}};let i=c;return c.\u0275fac=function(d){return new(d||c)},c.\u0275prov=z.Yz7({token:c,factory:c.\u0275fac}),i})()},31059:(D,C,e)=>{function z(g){const i=g.split(".");return 3===i.length?{codAgenzia:i[0],codRamo:i[1],numeroPolizza:i[2],idPolizzone:null}:{idPolizzone:Number(i[0]),codAgenzia:null,codRamo:null,numeroPolizza:null}}e.d(C,{I:()=>z})}}]);
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.