PageSourceSearch

https://portal.retn.net/en/342.a2fa0f4e7cee815c.js

js retn.net collected 2026-10-01 10:43:12 UTC 196,996 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkfrontend=self.webpackChunkfrontend||[]).push([[342],{85342:(Vo,ie,T)=>{T.r(ie),T.d(ie,{SettingsModule:()=>Ho});var Z=T(3848),v=T(44850),z=T(37084),P=T(36895),J=T(90455),s=T(24006),L=T(44144),Ce=T(71948),k=T(84385),Y=T(4859),M=T(4392),e=T(94650),y=T(17471),x=T(42867),U=T(8058),B=T(42649),D=T(44539);class K extends D.I{constructor(){super({}),this.addControl("failed_login",new s.NI(!1,s.kI.required)),this.addControl("password_reset_request",new s.NI(!1,s.kI.required)),this.addControl("login_from_new_system",new s.NI(!1,s.kI.required))}get failed_login(){return this.controls.failed_login}get password_reset_request(){return this.controls.password_reset_request}get login_from_new_system(){return this.controls.login_from_new_system}}class ae extends D.I{constructor(){super({}),this.addControl("maintenance_notification",new s.NI(!1,s.kI.required)),this.addControl("new_trouble_ticket",new s.NI(!1,s.kI.required)),this.addControl("ticket_closed",new s.NI(!1,s.kI.required)),this.addControl("ticket_update",new s.NI(!1,s.kI.required)),this.addControl("ticket_closure_warning",new s.NI(!1,s.kI.required))}get maintenance_notification(){return this.controls.maintenance_notification}get new_trouble_ticket(){return this.controls.new_trouble_ticket}get ticket_update(){return this.controls.ticket_update}get ticket_closure_warning(){return this.controls.ticket_closure_warning}get ticket_closed(){return this.controls.ticket_closed}}class se extends D.I{constructor(){super({}),this.addControl("new_invoice",new s.NI(!1,s.kI.required)),this.addControl("invoice_reminder_overdue",new s.NI(!1,s.kI.required)),this.addControl("new_payment_received",new s.NI(!1,s.kI.required)),this.addControl("new_billing_ticket",new s.NI(!1,s.kI.required)),this.addControl("billing_ticket_update",new s.NI(!1,s.kI.required)),this.addControl("billing_ticket_closed",new s.NI(!1,s.kI.required))}get new_invoice(){return this.controls.new_invoice}get invoice_reminder_overdue(){return this.controls.invoice_reminder_overdue}get new_payment_received(){return this.controls.new_payment_received}get new_billing_ticket(){return this.controls.new_billing_ticket}get billing_ticket_update(){return this.controls.billing_ticket_update}get billing_ticket_closed(){return this.controls.billing_ticket_closed}}class re extends D.I{constructor(){super({}),this.addControl("sales_request_sent",new s.NI(!1,s.kI.required)),this.addControl("new_order_in",new s.NI(!1,s.kI.required)),this.addControl("update_on_an_order_delivery",new s.NI(!1,s.kI.required)),this.addControl("order_delivered",new s.NI(!1,s.kI.required)),this.addControl("order_cancelled",new s.NI(!1,s.kI.required))}get sales_request_sent(){return this.controls.sales_request_sent}get new_order_in(){return this.controls.new_order_in}get update_on_an_order_delivery(){return this.controls.update_on_an_order_delivery}get order_delivered(){return this.controls.order_delivered}get order_cancelled(){return this.controls.order_cancelled}}var ue=T(39841),ne=T(78372),Oe=T(86278),me=T(64142);function Ae(_,i){1&_&&(e.TgZ(0,"div",2),e._uU(1,"ON"),e.qZA())}function Me(_,i){1&_&&(e.TgZ(0,"div",2),e._uU(1,"OFF"),e.qZA())}let W=(()=>{class _{constructor(){this.class="ON_ENABLED"}}return _.\u0275fac=function(t){return new(t||_)},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-toggler"]],inputs:{class:"class"},decls:3,vars:3,consts:[[1,"button",3,"ngClass"],["class","toggler",4,"ngIf"],[1,"toggler"]],template:function(t,n){1&t&&(e.TgZ(0,"div",0),e.YNc(1,Ae,2,0,"div",1),e.YNc(2,Me,2,0,"div",1),e.qZA()),2&t&&(e.Q6J("ngClass",n.class),e.xp6(1),e.Q6J("ngIf","ON_ENABLED"===n.class),e.xp6(1),e.Q6J("ngIf","OFF_ENABLED"===n.class))},dependencies:[P.mk,P.O5],styles:[".button[_ngcontent-%COMP%]{width:72px;height:32px;border:2px solid #144A90;display:flex;align-items:center}.toggler[_ngcontent-%COMP%]{background-color:#144a90;width:40px;height:32px;color:#fff;display:flex;align-items:center;justify-content:center}  .mat-slide-toggle-bar{display:none}.ON_ENABLED[_ngcontent-%COMP%]{justify-content:flex-start!important}.OFF_ENABLED[_ngcontent-%COMP%]{justify-content:flex-end!important;opacity:.3}"]}),_})(),Ie=(()=>{class _{getTogglerClass(t){return t.value?"ON_ENABLED":"OFF_ENABLED"}}return _.\u0275fac=function(t){return new(t||_)},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-billings-panel"]],inputs:{billingEmailForm:"billingEmailForm",b
1illingPortalForm:"billingPortalForm"},decls:44,vars:26,consts:function(){let i,t,n,o,a,r,l,p;return i="New invoice",t="Invoice reminder overdue",n="New payment received",o=" New billing ticket",a="Billing ticket update",r="Billing ticket closed",l="EMAIL",p="PORTAL",[[1,"portal-panel","flex"],[1,"label-column","space-between","flex"],i,t,n,o,a,r,[1,"toggle-column","space-between","align-center","flex",3,"formGroup"],[1,"label"],l,["color","primary","formControlName","new_invoice"],["color","primary","formControlName","invoice_reminder_overdue"],["color","primary","formControlName","new_payment_received"],["color","primary","formControlName","new_billing_ticket"],["color","primary","formControlName","billing_ticket_update"],["color","primary","formControlName","billing_ticket_closed"],[1,"toggle-column","align-center","space-between","flex",3,"formGroup"],p]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p"),e.SDv(3,2),e.qZA(),e.TgZ(4,"p"),e.SDv(5,3),e.qZA(),e.TgZ(6,"p"),e.SDv(7,4),e.qZA(),e.TgZ(8,"p"),e.SDv(9,5),e.qZA(),e.TgZ(10,"p"),e.SDv(11,6),e.qZA(),e.TgZ(12,"p"),e.SDv(13,7),e.qZA()(),e.TgZ(14,"div",8)(15,"p",9),e.SDv(16,10),e.qZA(),e.TgZ(17,"mat-slide-toggle",11),e._UZ(18,"app-toggler"),e.qZA(),e.TgZ(19,"mat-slide-toggle",12),e._UZ(20,"app-toggler"),e.qZA(),e.TgZ(21,"mat-slide-toggle",13),e._UZ(22,"app-toggler"),e.qZA(),e.TgZ(23,"mat-slide-toggle",14),e._UZ(24,"app-toggler"),e.qZA(),e.TgZ(25,"mat-slide-toggle",15),e._UZ(26,"app-toggler"),e.qZA(),e.TgZ(27,"mat-slide-toggle",16),e._UZ(28,"app-toggler"),e.qZA()(),e.TgZ(29,"div",17)(30,"p",9),e.SDv(31,18),e.qZA(),e.TgZ(32,"mat-slide-toggle",11),e._UZ(33,"app-toggler"),e.qZA(),e.TgZ(34,"mat-slide-toggle",12),e._UZ(35,"app-toggler"),e.qZA(),e.TgZ(36,"mat-slide-toggle",13),e._UZ(37,"app-toggler"),e.qZA(),e.TgZ(38,"mat-slide-toggle",14),e._UZ(39,"app-toggler"),e.qZA(),e.TgZ(40,"mat-slide-toggle",15),e._UZ(41,"app-toggler"),e.qZA(),e.TgZ(42,"mat-slide-toggle",16),e._UZ(43,"app-toggler"),e.qZA()()()),2&t&&(e.xp6(14),e.Q6J("formGroup",n.billingEmailForm),e.xp6(4),e.Tol(n.getTogglerClass(n.billingEmailForm.new_invoice)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingEmailForm.invoice_reminder_overdue)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingEmailForm.new_payment_received)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingEmailForm.new_billing_ticket)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingEmailForm.billing_ticket_update)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingEmailForm.billing_ticket_closed)),e.xp6(1),e.Q6J("formGroup",n.billingPortalForm),e.xp6(4),e.Tol(n.getTogglerClass(n.billingPortalForm.new_invoice)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingPortalForm.invoice_reminder_overdue)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingPortalForm.new_payment_received)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingPortalForm.new_billing_ticket)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingPortalForm.billing_ticket_update)),e.xp6(2),e.Tol(n.getTogglerClass(n.billingPortalForm.billing_ticket_closed)))},dependencies:[s.JJ,s.JL,J.Rr,s.sg,s.u,W],styles:[".label-column[_ngcontent-%COMP%]{flex-direction:column;margin-right:70px;height:432px;margin-bottom:40px}@media (max-width: 960px){.label-column[_ngcontent-%COMP%]{margin-right:0}}.portal-panel[_ngcontent-%COMP%]{gap:90px;font-size:16px}@media (max-width: 960px){.portal-panel[_ngcontent-%COMP%]{gap:75px}}.toggle-column[_ngcontent-%COMP%]{flex-direction:column;height:432px}.label[_ngcontent-%COMP%]{position:absolute;top:75px;font-weight:400;font-size:20px}"]}),_})(),fe=(()=>{class _{getTogglerClass(t){return t.value?"ON_ENABLED":"OFF_ENABLED"}}return _.\u0275fac=function(t){return new(t||_)},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-orders-panel"]],inputs:{orderEmailForm:"orderEmailForm",orderPortalForm:"orderPortalForm"},decls:38,vars:22,consts:function(){let i,t,n,o,a,r;return i="Sales request sent",t="New order in",n="Update on an order delivery",o="Order delivered",a="Order cancelled",r="PORTAL",[[1,"portal-panel","flex"],[1,"label-column","space-between","flex"],i,t,n,o,a,[1,"toggle-column","space-between","align-center","flex",3,"formGroup"],[1,"label"],["color","primary","formControlName","sales_request_sent"],["color","primary","formControlName","new_order_in"],["color","primary","formControlName","update_on_an_order_delivery"],["color","primary","formControlName","order_delivered"],["color","primary","formControlName","order_cancelled"],[1,"toggle-column","align-center","space-between","flex",3,"formGroup"],r]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p"),e.SDv(3,2),e.qZA(),e.TgZ(4,"p"),e.SDv(5,3),e.qZA(),e.TgZ(6,"p"),e.SDv(7,4),e.qZA(),e.TgZ(8,"p"),e.SDv(9,5),e.qZA(),e.TgZ(10,"p"),e.SDv(11,6),e.qZA()(),e.TgZ(12,"div",7)(13,"p",8),e._uU(14,"EMAIL"),e.qZA(),e.TgZ(15,"mat-slide-toggle",9),e._UZ(16,"app-toggler"),e.qZA(),e.TgZ(17,"mat-slide-toggle",10),e._UZ(18,"app-toggler"),e.qZA(),e.TgZ(19,"mat-slide-toggle",11),e._UZ(20,"app-toggler"),e.qZA(),e.TgZ(21,"mat-slide-toggle",12),e._UZ(22,"app-toggler"),e.qZA(),e.TgZ(23,"mat-slide-toggle",13),e._UZ(24,"app-toggler"),e.qZA()(),e.TgZ(25,"div",14)(26,"p",8),e.SDv(27,15),e.qZA(),e.TgZ(28,"mat-slide-toggle",9),e._UZ(29,"app-toggler"),e.qZA(),e.TgZ(30,"mat-slide-toggle",10),e._UZ(31,"app-toggler"),e.qZA(),e.TgZ(32,"mat-slide-toggle",11),e._UZ(33,"app-toggler"),e.qZA(),e.TgZ(34,"mat-slide-toggle",12),e._UZ(35,"app-toggler"),e.qZA(),e.TgZ(36,"mat-slide-toggle",13),e._UZ(37,"app-toggler"),e.qZA()()()),2&t&&(e.xp6(12),e.Q6J("formGroup",n.orderEmailForm),e.xp6(4),e.Tol(n.getTogglerClass(n.orderEmailForm.sales_request_sent)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderEmailForm.new_order_in)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderEmailForm.update_on_an_order_delivery)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderEmailForm.order_delivered)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderEmailForm.order_cancelled)),e.xp6(1),e.Q6J("formGroup",n.orderPortalForm),e.xp6(4),e.Tol(n.getTogglerClass(n.orderPortalForm.sales_request_sent)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderPortalForm.new_order_in)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderPortalForm.update_on_an_order_delivery)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderPortalForm.order_delivered)),e.xp6(2),e.Tol(n.getTogglerClass(n.orderPortalForm.order_cancelled)))},dependencies:[s.JJ,s.JL,J.Rr,s.sg,s.u,W],styles:[".label-column[_ngcontent-%COMP%]{flex-direction:column;margin-right:70px;height:360px;margin-bottom:40px}@media (max-width: 960px){.label-column[_ngcontent-%COMP%]{margin-right:0}}.portal-panel[_ngcontent-%COMP%]{gap:90px;font-size:16px}@media (max-width: 960px){.portal-panel[_ngcontent-%COMP%]{gap:75px}}.toggle-column[_ngcontent-%COMP%]{flex-direction:column;height:360px}.label[_ngcontent-%COMP%]{position:absolute;top:75px;font-weight:400;font-size:20px}"]}),_})(),Re=(()=>{class _{constructor(){this.portalPortalForm=new K,this.portalEmailForm=new K}getTogglerClass(t){return t.value?"ON_ENABLED":"OFF_ENABLED"}}return _.\u0275fac=function(t){return new(t||_)},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-portal-panel"]],inputs:{portalPortalForm:"portalPortalForm",portalEmailForm:"portalEmailForm"},decls:26,vars:14,consts:function(){let i,t,n,o;return i="Failed login",t="Password reset request",n="Login from new system",o="PORTAL",[[1,"portal-panel","flex"],[1,"label-column","space-between","flex"],i,t,n,[1,"toggle-column","space-between","align-center","flex",3,"formGroup"],[1,"label"],["color","primary","formControlName","failed_login"],["color","primary","formControlName","password_reset_request"],["color","primary","formControlName","login_from_new_system"],[1,"toggle-column","align-center","space-between","flex",3,"formGroup"],o,["color","primary","formControlName","failed_login",1,"rectangular-toggle"]]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p"),e.SDv(3,2),e.qZA(),e.TgZ(4,"p"),e.SDv(5,3),e.qZA(),e.TgZ(6,"p"),e.SDv(7,4),e.qZA()(),e.TgZ(8,"div",5)(9,"p",6),e._uU(10,"EMAIL"),e.qZA(),e.TgZ(11,"mat-slide-toggle",7),e._UZ(12,"app-toggler"),e.qZA(),e.TgZ(13,"mat-slide-toggle",8),e._UZ(14,"app-toggler"),e.qZA(),e.TgZ(15,"mat-slide-toggle",9),e._UZ(16,"app-toggler"),e.qZA()(),e.TgZ(17,"div",10)(18,"p",6),e.SDv(19,11),e.qZA(),e.TgZ(20,"mat-slide-toggle",12),e._UZ(21,"app-toggler"),e.qZA(),e.TgZ(22,"mat-slide-toggle",8),e._UZ(23,"app-toggler"),e.qZA(),e.TgZ(24,"mat-slide-toggle",9),e._UZ(25,"app-toggler"),e.qZA()()()),2&t&&(e.xp6(8),e.Q6J("formGroup",n.portalPortalForm),e.xp6(4),e.Tol(n.getTogglerClass(n.portalPortalForm.failed_login)),e.xp6(2),e.Tol(n.getTogglerClass(n.portalPortalForm.password_reset_request)),e.xp6(2),e.Tol(n.getTogglerClass(n.portalPortalForm.login_from_new_system)),e.xp6(1),e.Q6J("formGroup",n.portalEmailForm),e.xp6(4),e.Tol(n.getTogglerClass(n.portalEmailForm.failed_login)),e.xp6(2),e.Tol(n.getTogglerClass(n.portalEmailForm.password_reset_request)),e.xp6(2),e.Tol(n.getTogglerClass(n.portalEmailForm.login_from_new_system)))},dependencies:[s.JJ,s.JL,J.Rr,s.sg,s.u,W],styles:[".label-column[_ngcontent-%COMP%]{flex-direction:column;margin-right:70px;height:216px;margin-bottom:40px}@media (max-width: 960px){.label-column[_ngcontent-%COMP%]{margin-right:0}}.portal-panel[_ngcontent-%COMP%]{gap:90px;font-size:16px}@media (max-width: 960px){.portal-panel[_ngcontent-%COMP%]{gap:75px}}.toggle-column[_ngcontent-%COMP%]{flex-direction:column;height:216px}.label[_ngcontent-%COMP%]{position:absolute;top:75px;font-weight:400;font-size:20px}"]}),_})(),he=(()=>{class _{getTogglerClass(t){return t.value?"ON_ENABLED":"OFF_ENABLED"}}return _.\u0275fac=function(t){return new(t||_)},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-services-panel"]],inputs:{servicesEmailForm:"servicesEmailForm",servicesPortalForm:"servicesPortalForm"},decls:38,vars:22,consts:function(){let i,t,n,o,a,r;return i="Maintenance notification",t=" New trouble ticket",n="Ticket update",o="Ticket closure warning",a="Ticket closed",r="PORTAL",[[1,"portal-panel","flex"],[1,"label-column","space-between","flex"],i,t,n,o,a,[1,"toggle-column","space-between","align-center","flex",3,"formGroup"],[1,"label"],["color","primary","formControlName","maintenance_notification"],["color","primary","formControlName","new_trouble_ticket"],["color","primary","formControlName","ticket_update"],["color","primary","formControlName","ticket_closure_warning"],["color","primary","formControlName","ticket_closed"],[1,"toggle-column","align-center","space-between","flex",3,"formGroup"],r]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p"),e.SDv(3,2),e.qZA(),e.TgZ(4,"p"),e.SDv(5,3),e.qZA(),e.TgZ(6,"p"),e.SDv(7,4),e.qZA(),e.TgZ(8,"p"),e.SDv(9,5),e.qZA(),e.TgZ(10,"p"),e.SDv(11,6),e.qZA()(),e.TgZ(12,"div",7)(13,"p",8),e._uU(14,"EMAIL"),e.qZA(),e.TgZ(15,"mat-slide-toggle",9),e._UZ(16,"app-toggler"),e.qZA(),e.TgZ(17,"mat-slide-toggle",10),e._UZ(18,"app-toggler"),e.qZA(),e.TgZ(19,"mat-slide-toggle",11),e._UZ(20,"app-toggler"),e.qZA(),e.TgZ(21,"mat-slide-toggle",12),e._UZ(22,"app-toggler"),e.qZA(),e.TgZ(23,"mat-slide-toggle",13),e._UZ(24,"app-toggler"),e.qZA()(),e.TgZ(25,"div",14)(26,"p",8),e.SDv(27,15),e.qZA(),e.TgZ(28,"mat-slide-toggle",9),e._UZ(29,"app-toggler"),e.qZA(),e.TgZ(30,"mat-slide-toggle",10),e._UZ(31,"app-toggler"),e.qZA(),e.TgZ(32,"mat-slide-toggle",11),e._UZ(33,"app-toggler"),e.qZA(),e.TgZ(34,"mat-slide-toggle",12),e._UZ(35,"app-toggler"),e.qZA(),e.TgZ(36,"mat-slide-toggle",13),e._UZ(37,"app-toggler"),e.qZA()()()),2&t&&(e.xp6(12),e.Q6J("formGroup",n.servicesEmailForm),e.xp6(4),e.Tol(n.getTogglerClass(n.servicesEmailForm.maintenance_notification)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesEmailForm.new_trouble_ticket)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesEmailForm.ticket_update)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesEmailForm.ticket_closure_warning)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesEmailForm.ticket_closed)),e.xp6(1),e.Q6J("formGroup",n.servicesPortalForm),e.xp6(4),e.Tol(n.getTogglerClass(n.servicesPortalForm.maintenance_notification)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesPortalForm.new_trouble_ticket)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesPortalForm.ticket_update)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesPortalForm.ticket_closure_warning)),e.xp6(2),e.Tol(n.getTogglerClass(n.servicesPortalForm.ticket_closed)))},dependencies:[s.JJ,s.JL,J.Rr,s.sg,s.u,W],styles:[".label-column[_ngcontent-%COMP%]{flex-direction:column;margin-right:70px;height:360px;margin-bottom:40px}@media (max-width: 960px){.label-column[_ngcontent-%COMP%]{margin-right:0}}.portal-panel[_ngcontent-%COMP%]{gap:90px;font-size:16px}@media (max-width: 960px){.portal-panel[_ngcontent-%COMP%]{gap:75px}}.toggle-column[_ngcontent-%COMP%]{flex-direction:column;height:360px}.label[_ngcontent-%COMP%]{position:absolute;top:75px;font-weight:400;font-size:20px}"]}),_})(),Fe=(()=>{class _{constructor(t,n){this.saveNotificationsUsecase=t,this.getNotificationsUsecase=n,this.portalEmailForm=new K,this.portalPortalForm=new K,this.servicesEmailForm=new ae,this.servicesPortalForm=new ae,this.billingEmailForm=new se,this.billingPortalForm=new se,this.orderEmailForm=new re,this.orderPortalForm=new re,this.combinedForms=(0,ue.a)(this.portalEmailForm.valueChanges,this.portalPortalForm.valueChanges,this.servicesEmailForm.valueChanges,this.servicesPortalForm.valueChanges,this.billingEmailForm.valueChanges,this.billingPortalForm.valueChanges,this.orderEmailForm.valueChanges,this.orderPortalForm.valueChanges)}ngOnInit(){this.getNotificationsUsecase.execute().subscribe(t=>{this.portalEmailForm.patchValue(t.portal.email),this.portalPortalForm.patchValue(t.portal.portal),this.servicesEmailForm.patchValue(t.services.email),this.servicesPortalForm.patchValue(t.services.portal),this.billingEmailForm.patchValue(t.billing.email),this.billingPortalForm.patchValue(t.billing.portal),this.orderEmailForm.patchValue(t.orders.email),this.orderPortalForm.patchValue(t.orders.portal)}),this.combinedForms.pipe((0,ne.b)(300)).subscribe(()=>{this.saveNotificationsSetting()})}saveNotificationsSetting(){this.saveNotificationsUsecase.execute({portal:{email:this.portalEmailForm.value,portal:this.portalPortalForm.value},services:{email:this.servicesEmailForm.value,portal:this.servicesPortalForm.value},orders:{email:this.orderEmailForm.value,portal:this.orderPortalForm.value},billing:{email:this.billingEmailForm.value,portal:this.billingPortalForm.value}}).subscribe()}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(Oe.i),e.Y36(me.W))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-notifications-tab"]],decls:38,vars:16,consts:function(){let i,t,n,o;return i=" PORTAL ",t=" SERVICES ",n=" ORDERS ",o=" BILLINGS ",[[1,"notifications"],["hideToggle",""],["fpanel",""],[3,"ngClass"],i,[1,"arrow",3,"ngClass"],[3,"portalEmailForm","portalPortalForm"],["spanel",""],t,[3,"servicesEmailForm","servicesPortalForm"],["tpanel",""],n,[3,"orderEmailForm","orderPortalForm"],["fthpanel",""],o,[3,"billingEmailForm","billingPortalForm"]]},template:function(t,n){if(1&t&&(e.TgZ(0,"div",0),e._UZ(1,"mat-divider"),e.TgZ(2,"mat-expansion-panel",1,2)(4,"mat-expansion-panel-header")(5,"mat-panel-title",3),e.SDv(6,4),e.qZA(),e.TgZ(7,"mat-panel-description"),e._UZ(8,"div",5),e.qZA()(),e._UZ(9,"app-portal-panel",6),e.qZA(),e._UZ(10,"mat-divider"),e.TgZ(11,"mat-expansion-panel",1,7)(13,"mat-expansion-panel-header")(14,"mat-panel-title",3),e.SDv(15,8),e.qZA(),e.TgZ(16,"mat-panel-description"),e._UZ(17,"div",5),e.qZA()(),e._UZ(18,"app-services-panel",9),e.qZA(),e._UZ(19,"mat-divider"),e.TgZ(20,"mat-expansion-panel",1,10)(22,"mat-expansion-panel-header")(23,"mat-panel-title",3),e.SDv(24,11),e.qZA(),e.TgZ(25,"mat-panel-description"),e._UZ(26,"div",5),e.qZA()(),e._UZ(27,"app-orders-panel",12),e.qZA(),e._UZ(28,"mat-divider"),e.TgZ(29,"mat-expansion-panel",1,13)(31,"mat-expansion-panel-header")(32,"mat-panel-title",3),e.SDv(33,14),e.qZA(),e.TgZ(34,"mat-panel-description"),e._UZ(35,"div",5),e.qZA()(),e._UZ(36,"app-billings-panel",15),e.qZA(),e._UZ(37,"mat-divider"),e.qZA()),2&t){const o=e.MAs(3),a=e.MAs(12),r=e.MAs(21),l=e.MAs(30);e.xp6(5),e.Q6J("ngClass",o.expanded?"text-pink":""),e.xp6(3),e.Q6J("ngClass",o.expanded?"arrow-selected-mode":""),e.xp6(1),e.Q6J("portalEmailForm",n.portalEmailForm)("portalPortalForm",n.portalPortalForm),e.xp6(5),e.Q6J("ngClass",a.expanded?"text-pink":""),e.xp6(3),e.Q6J("ngClass",a.expanded?"arrow-selected-mode":""),e.xp6(1),e.Q6J("servicesEmailForm",n.servicesEmailForm)("
1servicesPortalForm",n.servicesPortalForm),e.xp6(5),e.Q6J("ngClass",r.expanded?"text-pink":""),e.xp6(3),e.Q6J("ngClass",r.expanded?"arrow-selected-mode":""),e.xp6(1),e.Q6J("orderEmailForm",n.orderEmailForm)("orderPortalForm",n.orderPortalForm),e.xp6(5),e.Q6J("ngClass",l.expanded?"text-pink":""),e.xp6(3),e.Q6J("ngClass",l.expanded?"arrow-selected-mode":""),e.xp6(1),e.Q6J("billingEmailForm",n.billingEmailForm)("billingPortalForm",n.billingPortalForm)}},dependencies:[P.mk,v.d,z.ib,z.yz,z.yK,z.u4,Ie,fe,Re,he],styles:[".notifications[_ngcontent-%COMP%]{margin-top:50px}mat-divider[_ngcontent-%COMP%]{border-top-color:#000}mat-expansion-panel-header[_ngcontent-%COMP%]{height:112px;padding:0}mat-expansion-panel-header[_ngcontent-%COMP%]:hover{background-color:#0000!important}mat-expansion-panel-header[_ngcontent-%COMP%]:hover   mat-panel-title[_ngcontent-%COMP%]{color:#d6117f!important}mat-expansion-panel-header[_ngcontent-%COMP%]:hover   .arrow[_ngcontent-%COMP%]{background:url(down-pink.73dcc85c4c09e433.svg) no-repeat}  .mat-expansion-panel-body{padding:24px 0!important}  .mat-tab-body-content{overflow:hidden!important}mat-panel-title[_ngcontent-%COMP%]{font-size:30px;font-weight:400;color:#000}mat-panel-description[_ngcontent-%COMP%]{justify-content:end}  .mat-expansion-panel-header.mat-expanded{height:112px!important}.arrow[_ngcontent-%COMP%]{display:block;background:url(down.a458a13ecbaa5544.svg) no-repeat;width:42px;height:30px}.arrow-selected-mode[_ngcontent-%COMP%]{background:url(up-pink.dbcabf76a50f5b7c.svg) no-repeat!important}"]}),_})();var $=T(73440);class De extends D.I{constructor(){super({}),this.addControl("id",new s.NI("")),this.addControl("email",new s.NI("")),this.addControl("role",new s.NI("")),this.addControl("role_id",new s.NI("")),this.addControl("first_name",new s.NI("",s.kI.required)),this.addControl("last_name",new s.NI("",s.kI.required)),this.addControl("phone",new s.NI("",[s.kI.pattern($.T.PHONE_REGEX)])),this.addControl("timezone",new s.NI("")),this.addControl("language",new s.NI(""))}get id(){return this.controls.id}get email(){return this.controls.email}get role(){return this.controls.role}get role_id(){return this.controls.role_id}get first_name(){return this.controls.first_name}get last_name(){return this.controls.last_name}get phone(){return this.controls.phone}get timezone(){return this.controls.timezone}get language(){return this.controls.language}}var q=T(59312),j=T(96457),b=T(77969),be=T(18507),Le=T(84177),F=T(65412),h=T(59549),ee=T(3238);function xe(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,31),e.qZA())}function Ue(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,32),e.qZA())}function ve(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,33),e.qZA())}function $e(_,i){if(1&_&&(e.TgZ(0,"mat-option",34),e._uU(1),e.qZA()),2&_){const t=i.$implicit,n=e.oxw();e.Q6J("value",t),e.xp6(1),e.Oqu(n.getTimeZoneEnumLabel(t))}}function Ge(_,i){if(1&_&&(e.TgZ(0,"mat-option",34),e._uU(1),e.qZA()),2&_){const t=i.$implicit,n=e.oxw();e.Q6J("value",t),e.xp6(1),e.Oqu(n.getLanguageEnumLabel(t))}}function we(_,i){1&_&&(e.TgZ(0,"p",35),e.SDv(1,36),e.qZA())}let Ze=(()=>{class _{constructor(t,n,o,a){this.savePersonalDetailUsecase=t,this.getPersonalDetailsUsecase=n,this.router=o,this.matDialog=a,this.personalDetailsSaved=!1,this.personalDetailForm=new De,this.languageList=Object.values(j.G),this.timeZoneList=Object.values(q.O),this.getLanguageEnumLabel=j.q,this.getTimeZoneEnumLabel=q.s}ngOnInit(){this.getPersonalDetailsUsecase.execute().subscribe(t=>{this.personalDetailForm.patchValue(t),this.personalDetailForm.role.setValue(t.role?.title||"-"),this.personalDetailForm.role_id.setValue(t.role?.name||"-")})}toDashboard(){this.personalDetailForm.dirty?this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">cancel</span>?<br> Entered data will not be saved."}}).afterClosed().subscribe(t=>{t&&this.router.navigateByUrl("/main/dashboard")}):this.router.navigateByUrl("/main/dashboard")}savePersonalData(){this.personalDetailForm.markAllAsTouched(),this.personalDetailForm.valid&&this.savePersonalDetailUsecase.execute(this.personalDetailForm.value).subscribe(t=>{this.personalDetailsSaved=!0,setTimeout(()=>{this.personalDetailsSaved=!1},8e3)})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(be.R),e.Y36(Le.j),e.Y36(M.F0),e.Y36(F.uw))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-personal-details-tab"]],decls:65,vars:11,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R,C,u,O,m,A,V;return i="Details",t="User ID:",n="Email:",o="Role:",a="Role ID:",r="First name *",l="First name",p="Last name *",S="Last name",N="Phone",d="Phone",c="Time Zone",I="Time Zone",f="Service Language",R="Service Language",C="Cancel",u="Save ",O=" This field is required ",m=" This field is required ",A=" Please enter a valid phone number ",V="YOUR CHANGES WERE SUCCESSFULLY SAVED",[[1,"details",3,"formGroup"],[1,"profile-title","margin-top","margin-left-custom","capital-gothic"],i,[1,"pink-divider"],[1,"flex","align-center","space-between"],[1,"margin-left-custom","bold"],t,[1,"width-60"],n,o,a,[1,"editable"],r,["floatLabel","never"],["matInput","","placeholder",l,"formControlName","first_name"],[4,"ngIf"],p,["placeholder",S,"matInput","","formControlName","last_name"],N,["matInput","","placeholder",d,"formControlName","phone"],c,["placeholder",I,"formControlName","timezone"],[3,"value",4,"ngFor","ngForOf"],f,["placeholder",R,"formControlName","language"],[1,"actions"],["mat-raised-button","","color","primary",1,"cancel","capital-gothic",3,"click"],C,["mat-raised-button","","color","primary",1,"save-button","capital-gothic",3,"click"],u,["class","blue-text absolute",4,"ngIf"],O,m,A,[3,"value"],[1,"blue-text","absolute"],V]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"p",1),e.SDv(2,2),e.qZA(),e._UZ(3,"mat-divider",3),e.TgZ(4,"div",4)(5,"p",5),e.SDv(6,6),e.qZA(),e.TgZ(7,"p",7),e._uU(8),e.qZA()(),e._UZ(9,"mat-divider"),e.TgZ(10,"div",4)(11,"p",5),e.SDv(12,8),e.qZA(),e.TgZ(13,"p",7),e._uU(14),e.qZA()(),e._UZ(15,"mat-divider"),e.TgZ(16,"div",4)(17,"p",5),e.SDv(18,9),e.qZA(),e.TgZ(19,"p",7),e._uU(20),e.qZA()(),e._UZ(21,"mat-divider"),e.TgZ(22,"div",4)(23,"p",5),e.SDv(24,10),e.qZA(),e.TgZ(25,"p",7),e._uU(26),e.qZA()(),e._UZ(27,"mat-divider"),e.TgZ(28,"div",11)(29,"div",4)(30,"p"),e.SDv(31,12),e.qZA(),e.TgZ(32,"mat-form-field",13),e._UZ(33,"input",14),e.YNc(34,xe,2,0,"mat-error",15),e.qZA()(),e.TgZ(35,"div",4)(36,"p"),e.SDv(37,16),e.qZA(),e.TgZ(38,"mat-form-field",13),e._UZ(39,"input",17),e.YNc(40,Ue,2,0,"mat-error",15),e.qZA()(),e.TgZ(41,"div",4)(42,"p"),e.SDv(43,18),e.qZA(),e.TgZ(44,"mat-form-field",13),e._UZ(45,"input",19),e.YNc(46,ve,2,0,"mat-error",15),e.qZA()(),e.TgZ(47,"div",4)(48,"p"),e.SDv(49,20),e.qZA(),e.TgZ(50,"mat-form-field",13)(51,"mat-select",21),e.YNc(52,$e,2,2,"mat-option",22),e.qZA()()(),e.TgZ(53,"div",4)(54,"p"),e.SDv(55,23),e.qZA(),e.TgZ(56,"mat-form-field",13)(57,"mat-select",24),e.YNc(58,Ge,2,2,"mat-option",22),e.qZA()()()()(),e.TgZ(59,"div",25)(60,"button",26),e.NdJ("click",function(){return n.toDashboard()}),e.SDv(61,27),e.qZA(),e.TgZ(62,"button",28),e.NdJ("click",function(){return n.savePersonalData()}),e.SDv(63,29),e.qZA(),e.YNc(64,we,2,0,"p",30),e.qZA()),2&t&&(e.Q6J("formGroup",n.personalDetailForm),e.xp6(8),e.Oqu(null==n.personalDetailForm.id?null:n.personalDetailForm.id.value),e.xp6(6),e.Oqu(null==n.personalDetailForm.email?null:n.personalDetailForm.email.value),e.xp6(6),e.Oqu(null==n.personalDetailForm.role?null:n.personalDetailForm.role.value),e.xp6(6),e.Oqu(null==n.personalDetailForm.role_id?null:n.personalDetailForm.role_id.value),e.xp6(8),e.Q6J("ngIf",n.personalDetailForm.first_name.hasError("required")),e.xp6(6),e.Q6J("ngIf",n.personalDetailForm.last_name.hasError("required")),e.xp6(6),e.Q6J("ngIf",n.personalDetailForm.phone.hasError("pattern")),e.xp6(6),e.Q6J("ngForOf",n.timeZoneList),e.xp6(6),e.Q6J("ngForOf",n.languageList),e.xp6(6),e.Q6J("ngIf",n.personalDetailsSaved))},dependencies:[P.sg,P.O5,s.Fj,s.JJ,s.JL,Y.lW,v.d,h.TO,h.KE,L.Nt,k.gD,ee.ey,s.sg,s.u],styles:[".details[_ngcontent-%COMP%]{min-width:30rem;width:53%;margin-top:4rem}.editable[_ngcontent-%COMP%]{background-color:#eaf2fc;padding:24px;margin-top:34px}.editable[_ngcontent-%COMP%]   mat-form-field[_ngcontent-%COMP%]{width:70%}.flex[_ngcontent-%COMP%]{height:3rem}.width-60[_ngcontent-%COMP%]{width:70%}.profile-title[_ngcontent-%COMP%]{font-size:30px;font-weight:700;margin-bottom:18px!important}.pink-divider[_ngcontent-%COMP%]{background-color:#d6117f;height:2px;border:none}mat-divider[_ngcontent-%COMP%]{height:1px;border-top-color:#000}.actions[_ngcontent-%COMP%]{display:flex;margin:54px auto 40px;justify-content:space-between;width:740px;position:relative}@media (max-width: 960px){.actions[_ngcontent-%COMP%]{width:unset;gap:10px}}.actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{width:310px;height:50px}.save-button[_ngcontent-%COMP%]{background-color:#144a90;text-transform:uppercase;font-weight:700;font-size:16px}.cancel[_ngcontent-%COMP%]{background-color:#4698ff;color:#fff;text-transform:uppercase;font-weight:700;font-size:16px}.bold[_ngcontent-%COMP%]{font-weight:700}mat-form-field[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{padding-left:1rem!important}mat-form-field[_ngcontent-%COMP%]     .mat-form-field-label{margin-left:1rem!important}mat-form-field[_ngcontent-%COMP%]   mat-select[_ngcontent-%COMP%]{padding-left:1rem!important;width:96%}mat-form-field[_ngcontent-%COMP%]   mat-label[_ngcontent-%COMP%]{margin-left:1rem!important;font-weight:300;font-size:14px}.margin-left-custom[_ngcontent-%COMP%]{margin-left:24px!important}.blue-text[_ngcontent-%COMP%]{margin-top:10px!important;color:#144a90;display:flex;justify-content:center}.absolute[_ngcontent-%COMP%]{position:absolute;top:62px;left:200px}"]}),_})();class ye extends D.I{constructor(){super({}),this.addControl("current_password",new s.NI("")),this.addControl("new_password",new s.NI("")),this.addControl("confirm_new_password",new s.NI(""))}get current_password(){return this.controls.current_password}get new_password(){return this.controls.new_password}get confirm_new_password(){return this.controls.confirm_new_password}}
1var Be=T(33079),ke=T(71122);class Ye extends D.I{constructor(){super({}),this.addControl("verification_code",new s.NI("",s.kI.required))}get verification_code(){return this.controls.verification_code}}var Q=T(97392);function qe(_,i){if(1&_&&(e.TgZ(0,"p"),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}let le=(()=>{class _{constructor(t){this.data=t}printTable(){window.print()}copyToClipboard(){const t=document.createElement("textarea");t.value=this.data.codes.join("\n"),document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t)}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(F.WI))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-backup-codes"]],decls:19,vars:2,consts:function(){let i,t,n,o;return i="Two-Factor Authentication Backup Codes",t="If you lose access to your authentication device, you can use one of these backup codes to login to your account. Each code may be used only once. Make a copy of these codes, and store it somewhere safe.",n="COPY",o="PRINT",[[1,"wrapper"],[3,"matDialogClose"],[1,"capital-gothic","text-header"],i,[1,"text-subtitle"],t,[1,"codes","flex"],[4,"ngFor","ngForOf"],[1,"actions","align-center","flex"],["src","assets/pic/vector-black.svg","alt","download"],[1,"icon-container",3,"click"],[1,"copy"],[1,"capital-gothic"],n,[1,"print"],o]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"mat-icon",1),e._uU(2,"close"),e.qZA(),e.TgZ(3,"p",2),e.SDv(4,3),e.qZA(),e.TgZ(5,"p",4),e.SDv(6,5),e.qZA(),e.TgZ(7,"div",6),e.YNc(8,qe,2,1,"p",7),e.qZA(),e.TgZ(9,"div",8),e._UZ(10,"img",9),e.TgZ(11,"div",10),e.NdJ("click",function(){return n.copyToClipboard()}),e._UZ(12,"div",11),e.TgZ(13,"p",12),e.SDv(14,13),e.qZA()(),e.TgZ(15,"div",10),e.NdJ("click",function(){return n.printTable()}),e._UZ(16,"div",14),e.TgZ(17,"p",12),e.SDv(18,15),e.qZA()()()()),2&t&&(e.xp6(1),e.Q6J("matDialogClose",!0),e.xp6(7),e.Q6J("ngForOf",n.data.codes))},dependencies:[P.sg,F.ZT,Q.Hw],styles:[".wrapper[_ngcontent-%COMP%]{padding:8px 20px 0;width:610px;box-sizing:border-box;position:relative}.wrapper[_ngcontent-%COMP%]   mat-icon[_ngcontent-%COMP%]{cursor:pointer;position:absolute;top:-15px;right:-15px}.copy[_ngcontent-%COMP%]{width:25px;height:25px;background-color:#144a90;-webkit-mask:url(/assets/pic/icons/copy-icon.svg) no-repeat center;mask:url(/assets/pic/icons/copy-icon.svg) no-repeat center;margin:0 10px}.print[_ngcontent-%COMP%]{width:30px;height:30px;background-color:#144a90;-webkit-mask:url(/assets/pic/dashboard/print.svg) no-repeat center;mask:url(/assets/pic/dashboard/print.svg) no-repeat center;margin:0 10px}.icon-container[_ngcontent-%COMP%]{display:flex;align-items:center;cursor:pointer}.icon-container[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{color:#144a90}.icon-container[_ngcontent-%COMP%]:hover   .copy[_ngcontent-%COMP%], .icon-container[_ngcontent-%COMP%]:hover   .print[_ngcontent-%COMP%]{background-color:#d6117f}.icon-container[_ngcontent-%COMP%]:hover   p[_ngcontent-%COMP%]{color:#d6117f}.text-header[_ngcontent-%COMP%]{font-size:30px;font-weight:700}.text-subtitle[_ngcontent-%COMP%]{margin:38px 0!important}.codes[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex-wrap:wrap;justify-content:center;height:180px;border:1px solid rgba(221,221,221,.87);width:-moz-fit-content;width:fit-content;margin:0 auto 20px}.codes[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{color:#144a90;padding:5px 10px;width:-moz-fit-content;width:fit-content}.codes[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]:nth-child(even){background-color:#eaf2fc}.icon-container[_ngcontent-%COMP%]{padding:0 68px 0 21px}.actions[_ngcontent-%COMP%]{justify-content:center}@media print{  body *{visibility:hidden}@page{margin-top:0;margin-bottom:0;height:100%}.codes[_ngcontent-%COMP%], .codes[_ngcontent-%COMP%]   *[_ngcontent-%COMP%]{visibility:visible!important}}"]}),_})();var Te=T(40041);function Xe(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,13),e.qZA())}function ze(_,i){1&_&&e._UZ(0,"img",14)}function Je(_,i){1&_&&(e.TgZ(0,"p",15),e.SDv(1,16),e.qZA())}let Qe=(()=>{class _{constructor(t,n){this.sendVerificationCodeUsecase=t,this.matDialog=n,this.loading=!0,this.back=new e.vpe,this.wrongCode=!1}activateAppAuth(){this.loading=!0,this.sendVerificationCodeUsecase.execute(this.form.verification_code.value,"app").subscribe(t=>{this.loading=!1,this.matDialog.open(le,{data:{codes:t}}).afterClosed().subscribe(()=>{this.back.emit(!0)})},()=>{this.loading=!1,this.errorHandling()})}errorHandling(){this.wrongCode=!0,this.formSubscription=this.form.verification_code.valueChanges.subscribe(()=>{this.wrongCode=!1,this.formSubscription.unsubscribe()})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(Te.i),e.Y36(F.uw))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-enter-code-tab"]],inputs:{form:"form"},outputs:{back:"back"},decls:15,vars:4,consts:function(){let i,t,n,o,a;return i="Enter 6-digit verification code generated by the app in the previous step. ",t="Verification code",n="ACTIVATE",o="This field is required",a="the code is incorrect. please try again",[[1,"code-tab"],i,[1,"flex","input-wrapper","align-center"],[1,"input-label"],t,["floatLabel","never",3,"formGroup"],["matInput","","formControlName","verification_code"],[4,"ngIf"],[1,"arrow-container",3,"click"],[1,"arrow"],n,["src","assets/pic/loading-icon.svg","alt","loading",4,"ngIf"],["class","absolute-text",4,"ngIf"],o,["src","assets/pic/loading-icon.svg","alt","loading"],[1,"absolute-text"],a]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"p"),e.SDv(2,1),e.qZA(),e.TgZ(3,"div",2)(4,"p",3),e.SDv(5,4),e.qZA(),e.TgZ(6,"mat-form-field",5),e._UZ(7,"input",6),e.YNc(8,Xe,2,0,"mat-error",7),e.qZA(),e.TgZ(9,"div",8),e.NdJ("click",function(){return n.activateAppAuth()}),e._UZ(10,"div",9),e.TgZ(11,"p"),e.SDv(12,10),e.qZA(),e.YNc(13,ze,1,0,"img",11),e.qZA(),e.YNc(14,Je,2,0,"p",12),e.qZA()()),2&t&&(e.xp6(6),e.Q6J("formGroup",n.form),e.xp6(2),e.Q6J("ngIf",n.form.verification_code.hasError("required")),e.xp6(
15),e.Q6J("ngIf",n.loading),e.xp6(1),e.Q6J("ngIf",n.wrongCode))},dependencies:[P.O5,s.Fj,s.JJ,s.JL,h.TO,h.KE,L.Nt,s.sg,s.u],styles:[".input-wrapper[_ngcontent-%COMP%]{margin-top:20px;gap:40px;position:relative;padding-bottom:10px}.code-tab[_ngcontent-%COMP%]{padding-top:60px;padding-left:20px}.input-label[_ngcontent-%COMP%]{margin-top:11px!important}img[_ngcontent-%COMP%]{position:absolute;top:-10px;right:-90px;width:50px}.absolute-text[_ngcontent-%COMP%]{color:#d6117f;font-size:14px;font-style:normal;font-weight:400;line-height:normal;text-transform:uppercase;position:absolute;top:74px;z-index:3;left:160px}"]}),_})(),He=(()=>{class _{constructor(){}downloadApp(t){switch(t){case 0:window.open("https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2&hl=en_US");break;case 1:window.open("https://play.google.com/store/apps/details?id=com.duosecurity.duomobile&hl=en&gl=US");break;case 2:window.open("https://play.google.com/store/apps/details?id=com.azure.authenticator&hl=en&gl=US")}}ngOnInit(){}}return _.\u0275fac=function(t){return new(t||_)},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-get-app-tab"]],decls:19,vars:0,consts:function(){let i,t,n,o;return i="Download and install one of the app for your phone or tablet",t="GOOGLE AUTHENTICATOR",n="DUO MOBILE",o="MICROSOFT AUTHENTICATOR",[[1,"apps"],[1,"title"],i,[1,"pointer","item",3,"click"],t,[1,"arrow"],n,o]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"p",1),e.SDv(2,2),e.qZA(),e._UZ(3,"mat-divider"),e.TgZ(4,"div",3),e.NdJ("click",function(){return n.downloadApp(0)}),e.TgZ(5,"p"),e.SDv(6,4),e.qZA(),e._UZ(7,"div",5),e.qZA(),e._UZ(8,"mat-divider"),e.TgZ(9,"div",3),e.NdJ("click",function(){return n.downloadApp(1)}),e.TgZ(10,"p"),e.SDv(11,6),e.qZA(),e._UZ(12,"div",5),e.qZA(),e._UZ(13,"mat-divider"),e.TgZ(14,"div",3),e.NdJ("click",function(){return n.downloadApp(2)}),e.TgZ(15,"p"),e.SDv(16,7),e.qZA(),e._UZ(17,"div",5),e.qZA(),e._UZ(18,"mat-divider"),e.qZA())},dependencies:[v.d],styles:[".apps[_ngcontent-%COMP%]{width:70%;padding-left:24px}.apps[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;height:91px}.apps[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{font-size:35px;font-style:normal;font-weight:400;line-height:normal;letter-spacing:.35px;text-transform:uppercase}.arrow[_ngcontent-%COMP%]{display:flex;align-items:center;height:39px!important;width:39px;background:url(vector-black.94756a7f7a1486c0.svg) no-repeat}mat-divider[_ngcontent-%COMP%]{background-color:#000}.title[_ngcontent-%COMP%]{margin:60px 0 20px!important}.item[_ngcontent-%COMP%]:hover   p[_ngcontent-%COMP%]{color:#d6117f}.item[_ngcontent-%COMP%]:hover   .arrow[_ngcontent-%COMP%]{background:url(vector-pink.6e5c464da2ef978d.svg) no-repeat}"]}),_})();var Ve=T(9691);function Ke(_,i){if(1&_&&(e.TgZ(0,"div",11)(1,"p"),e.SDv(2,12),e.qZA(),e.TgZ(3,"p",13),e._uU(4),e.qZA(),e.TgZ(5,"p"),e.SDv(6,14),e.qZA()()),2&_){const t=e.oxw();e.xp6(4),e.Oqu(t.code)}}let We=(()=>{class _{constructor(t){this.getApp2FADataUsecase=t,this.canScan=!0,this.code=null,this.qrCode=null}ngOnInit(){this.getApp2FADataUsecase.execute().subscribe(t=>{this.code=t.secret,this.qrCode=t.qrcode})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(Ve.g))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-scan-tab"]],decls:17,vars:2,consts:function(){let i,t,n,o,a,r;return i="" + "\ufffd#7\ufffd" + "\xB7" + "\ufffd/#7\ufffd" + " Open the authentication app",t="" + "\ufffd#10\ufffd" + "\xB7" + "\ufffd/#10\ufffd" + " Tap the \"+\" icon in the top-right of the app",n="" + "\ufffd#13\ufffd" + "\xB7" + "\ufffd/#13\ufffd" + " Scan the image to the left, using your phone's or tablet\u2019s camera ",o="CAN'T SCAN THIS QR CODE?",a="Instead of scanning, use your authentication app's \"Manual entry\" or equivalent option and provide the following time-based key (lower-case letters will work, too.)",r="Your app will then generate a 6-digit verification code, which you use below.",[[1,"scan-tab"],[1,"flex","container","align-center"],[1,"qr-container"],[3,"src"],[1,"flex","align-center"],i,t,n,[1,"pointer","text-blue",3,"click"],o,["class","hidden",4,"ngIf"],[1,"hidden"],a,[1,"bold-text"],r]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2),e._UZ(3,"img",3),e.qZA(),e.TgZ(4,"div")(5,"p",4),e.tHW(6,5),e._UZ(7,"span"),e.N_p(),e.qZA(),e.TgZ(8,"p",4),e.tHW(9,6),e._UZ(10,"span"),e.N_p(),e.qZA(),e.TgZ(11,"p",4),e.tHW(12,7),e._UZ(13,"span"),e.N_p(),e.qZA()()(),e.TgZ(14,"p",8),e.NdJ("click",function(){return n.canScan=!1}),e.SDv(15,9),e.qZA(),e.YNc(16,Ke,7,1,"div",10),e.qZA()),2&t&&(e.xp6(3),e.Q6J("src",n.qrCode,e.LSH),e.xp6(13),e.Q6J("ngIf",!n.canScan))},dependencies:[P.O5],styles:[".qr-container[_ngcontent-%COMP%]{width:130px;height:130px;background-color:#144a90;display:flex;justify-content:center;align-items:center}.scan-tab[_ngcontent-%COMP%]{padding-left:20px;padding-top:60px}.container[_ngcontent-%COMP%]{gap:40px}span[_ngcontent-%COMP%]{font-size:2rem;margin-right:.5rem}.text-blue[_ngcontent-%COMP%]{margin-top:20px!important;color:#144a90;width:-moz-fit-content;width:fit-content}.hidden[_ngcontent-%COMP%]{margin-top:20px;
1display:flex;flex-direction:column;gap:20px}.bold-text[_ngcontent-%COMP%]{color:#144a90;font-weight:600}"]}),_})();const je=["tabGroup"];let et=(()=>{class _{constructor(t){this.matDialog=t,this.user2FA=null,this.back=new e.vpe,this.enterCodeForm=new Ye}ngOnInit(){}onNext(){2!==this.tabGroup.selectedIndex&&(this.tabGroup.selectedIndex=this.tabGroup.selectedIndex+1)}onBack(){0!==this.tabGroup.selectedIndex&&(this.tabGroup.selectedIndex=this.tabGroup.selectedIndex-1)}toBack(){this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">cancel</span>?<br> Entered data will not be saved."}}).afterClosed().subscribe(t=>{t&&this.back.emit(!0)})}setSelectedClass(t){return this.tabGroup?this.tabGroup.selectedIndex<=t-1?"":"selected-step":""}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(F.uw))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-app-auth"]],viewQuery:function(t,n){if(1&t&&e.Gf(je,5),2&t){let o;e.iGM(o=e.CRH())&&(n.tabGroup=o.first)}},inputs:{user2FA:"user2FA"},outputs:{back:"back"},decls:14,vars:10,consts:function(){let i,t,n,o;return i="1.Get The App",t="2.Scan QR Code",n="3.Enter Verification Code",o="BACK",[[1,"auth"],[3,"animationDuration"],["tabGroup",""],["label",i,3,"labelClass","disabled"],["label",t,3,"labelClass","disabled"],["label",n,3,"labelClass","disabled"],[3,"form","back"],[1,"actions"],[1,"pointer",3,"ngClass","click"],[1,"back","pointer",3,"click"],o]},template:function(t,n){if(1&t&&(e.TgZ(0,"div",0)(1,"mat-tab-group",1,2)(3,"mat-tab",3),e._UZ(4,"app-get-app-tab"),e.qZA(),e.TgZ(5,"mat-tab",4),e._UZ(6,"app-scan-tab"),e.qZA(),e.TgZ(7,"mat-tab",5)(8,"app-enter-code-tab",6),e.NdJ("back",function(){return n.back.emit(!0)}),e.qZA()()(),e.TgZ(9,"div",7)(10,"div",8),e.NdJ("click",function(){return n.onBack()}),e.qZA(),e.TgZ(11,"div",8),e.NdJ("click",function(){return n.onNext()}),e.qZA()(),e.TgZ(12,"p",9),e.NdJ("click",function(){return n.toBack()}),e.SDv(13,10),e.qZA()()),2&t){const o=e.MAs(2);e.xp6(1),e.Q6J("animationDuration","0"),e.xp6(2),e.Q6J("labelClass",n.setSelectedClass(0))("disabled",!0),e.xp6(2),e.Q6J("labelClass",n.setSelectedClass(1))("disabled",!0),e.xp6(2),e.Q6J("labelClass",n.setSelectedClass(2))("disabled",!0),e.xp6(1),e.Q6J("form",n.enterCodeForm),e.xp6(2),e.Q6J("ngClass",0===o.selectedIndex?"disabled-left-arrow":"left-arrow"),e.xp6(1),e.Q6J("ngClass",2===o.selectedIndex?"disabled-right-arrow":"right-arrow")}},dependencies:[P.mk,Z.SP,Z.uX,Qe,He,We],styles:[".auth[_ngcontent-%COMP%]{background-color:#eaf2fc;padding-top:50px;padding-bottom:50px;margin-bottom:60px}  .auth .mat-tab-label{height:63px!important;font-size:16px;font-weight:700;justify-content:flex-start!important;background-color:#eaf2fc!important;border-bottom:4px solid #A6A6A6!important;border-top:none!important}  .auth .mat-tab-label .mat-tab-label-content{color:#a6a6a6!important}.left-arrow[_ngcontent-%COMP%]{height:37px;width:37px;background:url(vector-left-active.1367b2061100f3e0.svg) no-repeat}.right-arrow[_ngcontent-%COMP%]{height:37px;width:37px;background:url(vector-right-active.a9ac65b8ea044781.svg) no-repeat}.disabled-left-arrow[_ngcontent-%COMP%]{height:37px;width:37px;background:url(vector-left-disabled.e7a13d3ce14e4a9e.svg) no-repeat}.disabled-right-arrow[_ngcontent-%COMP%]{height:37px;width:37px;background:url(vector-right-disable.e085984ed832ef4f.svg) no-repeat}.actions[_ngcontent-%COMP%]{display:flex;justify-content:end;gap:10px;margin-right:30px}  .auth .mat-ink-bar{background-color:#144a90!important;height:4px!important}  .auth .selected-step{border-bottom:4px solid #144A90!important}  .auth .selected-step .mat-tab-label-content{color:#000!important}  .auth .mat-tab-labels{gap:2px!important}.back[_ngcontent-%COMP%]{color:#a6a6a6;width:-moz-fit-content;width:fit-content;margin-left:24px!important}"]}),_})();class tt extends D.I{constructor(){super({}),this.addControl("phone_number",new s.NI("",[s.kI.required,s.kI.pattern($.T.PHONE_REGEX)])),this.addControl("verification_code",new s.NI("",s.kI.required))}get phone_number(){return this.controls.phone_number}get verification_code(){return this.controls.verification_code}}var nt=T(67167);function _t(_,i){1&_&&(e.TgZ(0,"p",18),e.SDv(1,19),e.qZA())}function ot(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,20),e.qZA())}function it(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,21),e.qZA())}function at(_,i){1&_&&(e.TgZ(0,"p",22),e.SDv(1,23),e.qZA())}function st(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,24),e.qZA())}function rt(_,i){1&_&&e._UZ(0,"img",25)}function lt(_,i){1&_&&(e.TgZ(0,"p",22),e.SDv(1,26),e.qZA())}let Tt=(()=>{class _{constructor(t,n,o){this.sendPhoneNumberToVerificationUsecase=t,this.sendVerificationCodeUsecase=n,this.matDialog=o,this.user2FA=null,this.refreshUser2FAType=new e.vpe,this.back=new e.vpe,this.smsAuthForm=new tt,this.co
1deWasSent=!1,this.wrongVerificationCode=!1,this.loading=!1}toPreviousPage(){this.smsAuthForm.dirty?this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:'Are you sure you want to <span class="dedicated-text">cancel</span>?<br> Entered data will not be saved.'}}).afterClosed().subscribe(t=>{t&&this.back.emit(!0)}):this.back.emit(!0)}sendPhoneNumber(){this.smsAuthForm.phone_number.markAsTouched(),this.smsAuthForm.phone_number.valid&&this.sendPhoneNumberToVerificationUsecase.execute(this.smsAuthForm.phone_number.value,"sms").subscribe(t=>{t&&(this.codeWasSent=!0,setTimeout(()=>{this.codeWasSent=!1},8e3))})}sendVerificationCode(){this.smsAuthForm.verification_code.markAsTouched(),this.smsAuthForm.verification_code.valid&&(this.loading=!0,this.sendVerificationCodeUsecase.execute(this.smsAuthForm.verification_code.value).subscribe(t=>{this.matDialog.open(le,{data:{codes:t}}).afterClosed().subscribe(()=>{this.refreshUser2FAType.emit("sms")}),this.loading=!1},t=>{this.loading=!1,this.wrongVerificationCode=!0,this.valueChangesSubscription=this.smsAuthForm.verification_code.valueChanges.subscribe(()=>{this.wrongVerificationCode=!1,this.valueChangesSubscription.unsubscribe()})}))}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(nt.W),e.Y36(Te.i),e.Y36(F.uw))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-sms-auth"]],inputs:{user2FA:"user2FA"},outputs:{refreshUser2FAType:"refreshUser2FAType",back:"back"},decls:28,vars:8,consts:function(){let i,t,n,o,a,r,l,p,S,N,d;return i="Phone number",t="RECEIVE CODE",n="Verification code",o="ACTIVATE",a="BACK",r="Protect your account using two-factor authentication.",l=" This field is required ",p=" Please enter a valid phone number ",S="the code was sent to your phone",N=" This field is required ",d="the code is incorrect. please try again or request new code",[[1,"sms-auth",3,"formGroup"],["class","two-factor-auth__subscription",4,"ngIf"],[1,"flex","input-wrapper","align-center"],[1,"input-label"],i,["formControlName","phone_number","matInput","","name","phoneNumber","required",""],[4,"ngIf"],[1,"arrow-container",3,"click"],[1,"arrow"],t,["class","capital-gothic absolute-text",4,"ngIf"],n,["formControlName","verification_code","matInput","","name","phoneNumber","required",""],[1,"activation-code","arrow-container",3,"click"],o,["src","assets/pic/loading-icon.svg","alt","loading",4,"ngIf"],[1,"back","pointer",3,"click"],a,[1,"two-factor-auth__subscription"],r,l,p,[1,"capital-gothic","absolute-text"],S,N,["src","assets/pic/loading-icon.svg","alt","loading"],d]},template:function(t,n){1&t&&(e.TgZ(0,"div",0),e.YNc(1,_t,2,0,"p",1),e.TgZ(2,"div",2)(3,"p",3),e.SDv(4,4),e.qZA(),e.TgZ(5,"mat-form-field"),e._UZ(6,"input",5),e.YNc(7,ot,2,0,"mat-error",6),e.YNc(8,it,2,0,"mat-error",6),e.qZA(),e.TgZ(9,"div",7),e.NdJ("click",function(){return n.sendPhoneNumber()}),e._UZ(10,"div",8),e.TgZ(11,"p"),e.SDv(12,9),e.qZA()(),e.YNc(13,at,2,0,"p",10),e.qZA(),e.TgZ(14,"div",2)(15,"p",3),e.SDv(16,11),e.qZA(),e.TgZ(17,"mat-form-field"),e._UZ(18,"input",12),e.YNc(19,st,2,0,"mat-error",6),e.qZA(),e.TgZ(20,"div",13),e.NdJ("click",function(){return n.sendVerificationCode()}),e._UZ(21,"div",8),e.TgZ(22,"p"),e.SDv(23,14),e.qZA(),e.YNc(24,rt,1,0,"img",15),e.qZA(),e.YNc(25,lt,2,0,"p",10),e.qZA(),e.TgZ(26,"p",16),e.NdJ("click",function(){return n.toPreviousPage()}),e.SDv(27,17),e.qZA()()),2&t&&(e.Q6J("formGroup",n.smsAuthForm),e.xp6(1),e.Q6J("ngIf",!n.user2FA),e.xp6(6),e.Q6J("ngIf",n.smsAuthForm.phone_number.hasError("required")),e.xp6(1),e.Q6J("ngIf",n.smsAuthForm.phone_number.hasError("pattern")),e.xp6(5),e.Q6J("ngIf",n.codeWasSent),e.xp6(6),e.Q6J("ngIf",n.smsAuthForm.verification_code.hasError("required")),e.xp6(5),e.Q6J("ngIf",n.loading),e.xp6(1),e.Q6J("ngIf",n.wrongVerificationCode))},dependencies:[P.O5,s.Fj,s.JJ,s.JL,s.Q7,h.TO,h.KE,L.Nt,s.sg,s.u],styles:[".input-wrapper[_ngcontent-%COMP%]{position:relative;gap:40px}.input-wrapper[_ngcontent-%COMP%]   .input-label[_ngcontent-%COMP%]{width:130px;margin-top:11px!important}mat-form-field[_ngcontent-%COMP%]{width:250px}.sms-auth[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:20px;margin-bottom:60px;padding-left:24px}.absolute-text[_ngcontent-%COMP%]{position:absolute;color:#d6117f;font-size:14px;font-style:normal;font-weight:400;line-height:normal;text-transform:uppercase;bottom:-15px;left:170px}.back[_ngcontent-%COMP%]{color:#a6a6a6;width:-moz-fit-content;width:fit-content}.activation-code[_ngcontent-%COMP%]{position:relative}.activation-code[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{position:absolute;top:-10px;right:-90px;width:50px}.two-factor-auth__subscription[_ngcontent-%COMP%]{margin-top:20px!important;margin-bottom:58px!important}"]}),_})();var ct=T(94084);function St(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",1)(1,"p",2),e.tHW(2,10),e._UZ(3,"span",11),e.N_p(),e.qZA(),e.TgZ(4,"div",12),e.NdJ("mouseenter",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.changeNumberColor=!0)})("mouseleave",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.changeNumberColor=!1)})("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.editAuthSetting())}),e._UZ(5,"div",5),e.TgZ(6,"p"),e.SDv(7,13),e.qZA()()()}if(2&_){const t=e.oxw();e.xp6(3),e.Q6J("ngClass",t.changeNumberColor?"text-pink":"blue-text"),e.pQV(t.phoneNumber),e.QtT(2)}}let pt=(()=>{class _{constructor(t,n){this.matDialog=t,this.disable2FAUsecase=n,this.editAuthSettingEvent=ne
1w e.vpe,this.goBack=new e.vpe,this.changeNumberColor=!1}editAuthSetting(){this.editAuthSettingEvent.emit(this.authType)}back(){this.goBack.emit(!1)}disable2FA(){this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">disable</span> the two-factor <br> authentication? Entered data will not be saved."}}).afterClosed().subscribe(t=>{t&&this.disable2FAUsecase.execute().subscribe(n=>{this.goBack.emit(!1)})})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(F.uw),e.Y36(ct.C))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-turned-on-auth"]],inputs:{authType:"authType",phoneNumber:"phoneNumber"},outputs:{editAuthSettingEvent:"editAuthSettingEvent",goBack:"goBack"},decls:12,vars:2,consts:function(){let i,t,n,o,a;return i=" You use Two-Factor authentication via " + "\ufffd0\ufffd" + " for your " + "\ufffd#4\ufffd\ufffd/#4\ufffd" + " account ",t="DISABLE",n="BACK",o="Authentication codes will be sent via SMS text message to " + "\ufffd#3\ufffd" + "" + "\ufffd0\ufffd" + "" + "\ufffd/#3\ufffd" + "",a="EDIT",[[1,"wrapper"],[1,"flex","align-center"],[1,"description"],i,[1,"arrow-container",3,"click"],[1,"arrow"],t,["class","flex align-center",4,"ngIf"],[1,"back","pointer",3,"click"],n,o,[3,"ngClass"],[1,"arrow-container",3,"mouseenter","mouseleave","click"],a]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e.tHW(3,3),e._UZ(4,"br"),e.N_p(),e.qZA(),e.TgZ(5,"div",4),e.NdJ("click",function(){return n.disable2FA()}),e._UZ(6,"div",5),e.TgZ(7,"p"),e.SDv(8,6),e.qZA()()(),e.YNc(9,St,8,2,"div",7),e.TgZ(10,"p",8),e.NdJ("click",function(){return n.back()}),e.SDv(11,9),e.qZA()()),2&t&&(e.xp6(4),e.pQV("sms"==n.authType?"SMS":"App"),e.QtT(3),e.xp6(5),e.Q6J("ngIf","sms"==n.authType))},dependencies:[P.mk,P.O5],styles:[".flex[_ngcontent-%COMP%]{width:580px;gap:40px}.description[_ngcontent-%COMP%]{width:415px}.wrapper[_ngcontent-%COMP%]{padding-left:24px;display:flex;flex-direction:column;gap:20px;padding-bottom:60px}.blue-text[_ngcontent-%COMP%]{color:#144a90}.bold[_ngcontent-%COMP%]{font-weight:700}.back[_ngcontent-%COMP%]{color:#a6a6a6;width:-moz-fit-content;width:fit-content}div.arrow-container[_ngcontent-%COMP%]:hover   span.blue-text[_ngcontent-%COMP%]{color:#d6117f}"]}),_})();function Et(_,i){if(1&_&&(e.tHW(0,3,1),e.TgZ(1,"app-tooltip"),e._UZ(2,"p"),e.qZA(),e.N_p()),2&_){const t=e.oxw();e.xp6(2),e.pQV(t.tooltipsService.tooltips.change_password),e.QtT(0)}}function gt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"img",39),e.NdJ("click",function(o){return e.CHM(t),e.oxw(),e.MAs(13).type="text",e.KtG(o.stopPropagation())}),e.qZA()}}function dt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"img",40),e.NdJ("click",function(o){return e.CHM(t),e.oxw(),e.MAs(13).type="password",e.KtG(o.stopPropagation())}),e.qZA()}}function Pt(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,41),e.qZA())}function Nt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"img",42),e.NdJ("click",function(o){return e.CHM(t),e.oxw(),e.MAs(22).type="text",e.KtG(o.stopPropagation())}),e.qZA()}}function Ct(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"img",40),e.NdJ("click",function(o){return e.CHM(t),e.oxw(),e.MAs(22).type="password",e.KtG(o.stopPropagation())}),e.qZA()}}function ut(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"img",42),e.NdJ("click",function(o){return e.CHM(t),e.oxw(),e.MAs(30).type="text",e.KtG(o.stopPropagation())}),e.qZA()}}function Ot(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"img",40),e.NdJ("click",function(o){return e.CHM(t),e.oxw(),e.MAs(30).type="password",e.KtG(o.stopPropagation())}),e.qZA()}}function mt(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,43),e.qZA())}function At(_,i){1&_&&(e.TgZ(0,"p",44),e.SDv(1,45),e.qZA())}function Mt(_,i){if(1&_&&(e.tHW(0,34,1),e.TgZ(1,"app-tooltip"),e._UZ(2,"p"),e.qZA(),e.N_p()),2&_){const t=e.oxw();e.xp6(2),e.pQV(t.tooltipsService.tooltips.two_factor_authentication),e.QtT(0)}}function It(_,i){1&_&&(e.TgZ(0,"p",54),e.SDv(1,55),e.qZA())}function ft(_,i){1&_&&(e.TgZ(0,"p",56),e.SDv(1,57),e.qZA())}function Rt(_,i){1&_&&(e.TgZ(0,"p",58),e.SDv(1,59),e.qZA())}function ht(_,i){1&_&&(e.TgZ(0,"p",56),e.SDv(1,60),e.qZA())}function Ft(_,i){1&_&&(e.TgZ(0,"p",58),e.SDv(1,61),e.qZA())}function Dt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",46),e.YNc(1,It,2,0,"p",47),e.TgZ(2,"div",48),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.change2FAMethod("sms"))}),e.TgZ(3,"p",49),e._uU(4,"SMS"),e.qZA(),e.YNc(5,ft,2,0,"p",50),e.YNc(6,Rt,2,0,"p",51),e._UZ(7,"div",52),e.qZA(),e.TgZ(8,"div",53),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.change2FAMethod("app"))}),e.TgZ(9,"p",49),e._uU(10,"APP"),e.qZA(),e.YNc(11,ht,2,0,"p",50),e.YNc(12,Ft,2,0,"p",51),e._UZ(13,"div",52),e.qZA()()}if(2&_){const t=e.oxw();e.xp6(1),e.Q6J("ngIf",!t.user2FA),e.xp6(4),e.Q6J("ngIf","app"==t.user2FA||!t.user2FA),e.xp6(1),e.Q6J("ngIf","sms"==t.user2FA),e.xp6(5),e.Q6J("ngIf","sms"==t.user2FA||!t.user2FA),e.xp6(1),e.Q6J("ngIf","app"==t.user2FA)}}function bt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"app-app-auth",62),e.NdJ("back",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.refreshUser2FAType())}),e.qZA()}if(2&_){const t=e.oxw();e.Q6J("user2FA",t.user2FA)}}function Lt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"app-sms-auth",63),e.NdJ("refreshUser2FAType",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.refreshUser2FAType())})("back",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.refreshUser2FAType())}),e.qZA()}if(2&_){const t=e.oxw();e.Q6J("user2FA",t.user2FA)}}function xt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"app-turned-on-auth",64),e.NdJ("goBack",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.refreshUser2FAType())})("editAuthSettingEvent",function(o){e.CHM(t);const a=e.oxw();return e.KtG(a.change2FASetting(o))}),e.qZA()}if(2&_){const t=e.oxw();e.Q6J("phoneNumber",t.settedPhoneNumber)("authType",t.selectedTypeOfAuth)}}let Ut=(()=>{class _{constructor(t,n,o){this.changePasswordUseCase=t,this.getAccountAuthType=n,this.tooltipsService=o,this.user2FA=null,this.selectedTypeOfAuth=null,this.editingTypeOfAuth=null,this.settedPhoneNumber=null,this.up
1perCaseAndLowerCase=!0,this.digit=!0,this.length=!0,this.match=!0,this.passwordSuccessfullyChanged=!1,this.changePasswordForm=new ye}ngOnInit(){this.getUser2FA()}change2FAMethod(t){this.selectedTypeOfAuth=t}refreshUser2FAType(){this.selectedTypeOfAuth=null,this.editingTypeOfAuth=null,this.getUser2FA()}change2FASetting(t){this.editingTypeOfAuth=t}getUser2FA(){this.getAccountAuthType.execute().subscribe(t=>{t&&t.method?(this.user2FA=t.method,this.settedPhoneNumber=t.phone_number):this.user2FA=null})}changePassword(){this.changePasswordUseCase.execute(this.changePasswordForm.value).subscribe(t=>{this.changePasswordForm.reset(),this.changePasswordForm.new_password.setValue(""),this.passwordSuccessfullyChanged=!0,setTimeout(()=>{this.passwordSuccessfullyChanged=!1},8e3)},t=>{this.changePasswordForm.current_password.setErrors({incorrect:!0})})}get checkPasswordValidation(){return this.upperCaseAndLowerCase=this.hasUpperCaseAndLowerCase,this.digit=this.hasDigit,this.length=this.changePasswordForm.new_password.value.length>=8,this.changePasswordForm.new_password.value!==this.changePasswordForm.confirm_new_password.value&&(this.match=!1,this.changePasswordForm.confirm_new_password.setErrors({notMatch:!0}),this.changePasswordForm.new_password.setErrors({notMatch:!0})),this.passwordSubscription=this.changePasswordForm.new_password.valueChanges.subscribe(()=>{this.upperCaseAndLowerCase=!0,this.digit=!0,this.length=!0,this.match=!0,this.passwordSuccessfullyChanged=!1,this.passwordSubscription.unsubscribe()}),this.hasUpperCaseAndLowerCase&&this.hasDigit&&this.changePasswordForm.new_password.value.length>=8&&this.changePasswordForm.new_password.value===this.changePasswordForm.confirm_new_password.value}saveSecurityData(){this.checkPasswordValidation&&this.changePassword()}get hasUpperCaseAndLowerCase(){const t=this.changePasswordForm.new_password.value,n=t.toLowerCase(),o=t.toUpperCase();return t!==n&&t!==o}get hasDigit(){return/\d/.test(this.changePasswordForm.new_password.value)}setColorOfText(t){return 0==t?this.length?this.changePasswordForm.new_password.value.length>=8?"text-blue":"text-shadow":"text-pink":1==t?this.upperCaseAndLowerCase?this.hasUpperCaseAndLowerCase?"text-blue":"text-shadow":"text-pink":2==t?this.digit?this.hasDigit?"text-blue":"text-shadow":"text-pink":3==t?this.match?this.changePasswordForm.new_password.value===this.changePasswordForm.confirm_new_password.value?"text-blue":"text-shadow":"text-pink":"text-shadow"}setInputLetterSpacing(t){return t<=14?"":t<=17?"wider-word":t<=23?"wide-word":"widest-word"}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(Be.$),e.Y36(ke.Y),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-security-tab"]],features:[e._Bn([{provide:e.QbO,useValue:"NoopAnimations"}])],decls:63,vars:25,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R,C,u;return i="Current Password",t="New password",n="Confirm new password",o="AT LEAST 8 CHARACTERS LONG",a="UPPERCASE AND LOWERCASE LETTERS",r="DIGIT",l="CHANGE PASSWORD",p="Change Password " + "\ufffd*4:1\ufffd\ufffd#1:1\ufffd" + "" + "\ufffd#2:1\ufffd" + "" + "\ufffd0:1\ufffd" + "" + "\ufffd/#2:1\ufffd" + "" + "\ufffd/#1:1\ufffd\ufffd/*4:1\ufffd" + "",S="Incorrect password ",N="Entered passwords do not match ",d="YOUR CHANGES WERE SUCCESSFULLY SAVED",c="Two-Factor Authentication " + "\ufffd*57:1\ufffd\ufffd#1:1\ufffd" + "" + "\ufffd#2:1\ufffd" + "" + "\ufffd0:1\ufffd" + "" + "\ufffd/#2:1\ufffd" + "" + "\ufffd/#1:1\ufffd\ufffd/*57:1\ufffd" + "",I="Protect your account using two-factor authentication.",f="You will receive your authentication code as an SMS to the provided phone number. Make sure you have access to the number you want to use.",R="Two-Factor authentication via SMS is active for your account. View details.",C="Use the app on your phone or tablet to get an authentication code. Make sure you have constant access to the device where the authentication app will be installed.",u="Two-Factor authentication via App is active for your account. View details.",[[1,"security"],[1,"change-password"],[1,"title","capital-gothic"],p,[4,"ngIf"],[1,"pink-divider"],[1,"flex","change-password-wrapper","space-between"],[1,"input-wrapper",3,"formGroup"],[1,"flex","align-center","space-between"],[1,"input-label"],i,["name","aefwefg23gfweverg2tg4trbevrt","autocomplete","new-password","type","password","matInput","","formControlName","current_password",3,"ngClass"],["currentPassword",""],["width","18","height","15","src","assets/pic/eye-icon.svg","matSuffix","","class","pointer",3,"click",4,"ngIf"],["width","18","height","14","src","assets/pic/icons/closed_eye.svg","matSuffix","","class","pointer",3,"click",4,"ngIf"],t,["type","password","matInput","","formControlName","new_password",3,"ngClass"],["newPassword",""],["width","18","height","15.5","src","assets/pic/eye-icon.svg","matSuffix","","class","pointer",3,"click",4,"ngIf"],n,["type","password","matInput","","formControlName","confirm_new_password",3,"ngClass"],["confirmNewPassword",""],[1,"password-requirement"],["src","assets/pic/profile/password-change-vector.svg",1,"img-margin",3,"ngClass"],[3,"ngClass"],o,a,r,[1,"action"],[1,"arrow-container",3,"click"],[1,"arrow"],l,["class","text-blue saved-text",4,"ngIf"],[1,"flex"],c,["class","auth-wrapper",4,"ngIf"],[3,"user2FA","back",4,"ngIf"],[3,"user2FA","refreshUser2FAType","back",4,"ngIf"],[3,"phoneNumber","authType","goBack","editAuthSettingEvent",4,"ngIf"],["width","18","height","15","src","assets/pic/eye-icon.svg","matSuffix","",1,"pointer",3,"click"],["width","18","height","14","src","assets/pic/icons/closed_eye.svg","matSuffix","",1,"pointer",3,"click"],S,["width","18","height","15.5","src","assets/pic/eye-icon.svg","matSuffix","",1,"pointer",3,"click"],N,[1,"text-blue","saved-text"],d,[1,"auth-wrapper"],["class","two-factor-auth__subscription",4,"ngIf"],[1,"auth-method","first",3,"click"],[1,"auth-method__name"],["class","auth-method__description",4,"ngIf"],["class","auth-method__description bold-text",4,"ngIf"],[1,"black-arrow"],[1,"auth-method",3,"click"],[1,"two-factor-auth__subscription"],I,[1,"auth-method__description"],f,[1,"auth-method__description","bold-text"],R,C,u,[3,"user2FA","back"],[3,"user2FA","refreshUser2FAType","back"],[3,"phoneNumber","authType","goBack","editAuthSettingEvent"]]},template:function(t,n){if(1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e.tHW(3,3),e.YNc(4,Et,3,1,"app-tooltip",4),e.N_p(),e.qZA(),e._UZ(5,"mat-divider",5),e.TgZ(6,"div",6)(7,"form",7)(8,"div",8)(9,"p",9),e.SDv(10,10),e.qZA(),e.TgZ(11,"mat-form-field"),e._UZ(12,"input",11,12),e.YNc(14,gt,1,0,"img",13),e.YNc(15,dt,1,0,"img",14),e.YNc(16,Pt,2,0,"mat-error",4),e.qZA()(),e.TgZ(17,"div",8)(18,"p",9),e.SDv(19,15),e.qZA(),e.TgZ(20,"mat-form-field"),e._UZ(21,"input",16,17),e.YNc(23,Nt,1,0,"img",18),e.YNc(24,Ct,1,0,"img",14),e.qZA()(),e.TgZ(25,"div",8)(26,"p",9),e.SDv(27,19),e.qZA(),e.TgZ(28,"mat-form-field"),e._UZ(29,"input",20,21),e.YNc(31,ut,1,0,"img",18),e.YNc(32,Ot,1,0,"img",14),e.YNc(33,mt,2,0,"mat-error",4),e.qZA()()(),e.TgZ(34,"div",22)(35,"div"),e._UZ(36,"img",23),e.TgZ(37,"p",24),e.SDv(38,25),e.qZA()(),e.TgZ(39,"div"),e._UZ(40,"img",23),e.TgZ(41,"p",24),e.SDv(42,26),e.qZA()(),e.TgZ(43,"div"),e._UZ(44,"img",23),e.TgZ(45,"p",24),e.SDv(46,27),e.qZA()()()(),e.TgZ(47,"div",28)(48,"div",29),e.NdJ("click",function(){return n.saveSecurityData()}),e._UZ(49,"div",30),e.TgZ(50,"p"),e.SDv(51,31),e.qZA()(),e.YNc(52,At,2,0,"p",32),e.qZA()(),e.TgZ(53,"div")(54,"div",33)(55,"p",2),e.tHW(56,34),e.YNc(57,Mt,3,1,"app-tooltip",4),e.N_p(),e.qZA()(),e._UZ(58,"mat-divider",5),e.YNc(59,Dt,14,5,"div",35),e.YNc(60,bt,1,1,"app-app-auth",36),e.YNc(61,Lt,1,1,"app-sms-auth",37),e.YNc(62,xt,1,2,"app-turned-on-auth",38),e.qZA()()),2&t){const o=e.MAs(13),a=e.MAs(22),r=e.MAs(30);e.xp6(4),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.change_password),e.xp6(3),e.Q6J("formGroup",n.changePasswordForm),e.xp6(5),e.Q6J("ngClass",n.setInputLetterSpacing(o.value.length)),e.xp6(2),e.Q6J("ngIf","password"==o.type),e.xp6(1),e.Q6J("ngIf","text"==o.type),e.xp6(1),e.Q6J("ngIf",n.changePasswordForm.current_password.hasError("incorrect")),e.xp6(
15),e.Q6J("ngClass",n.setInputLetterSpacing(a.value.length)),e.xp6(2),e.Q6J("ngIf","password"==a.type),e.xp6(1),e.Q6J("ngIf","text"==a.type),e.xp6(5),e.Q6J("ngClass",n.setInputLetterSpacing(r.value.length)),e.xp6(2),e.Q6J("ngIf","password"==r.type),e.xp6(1),e.Q6J("ngIf","text"==r.type),e.xp6(1),e.Q6J("ngIf",n.changePasswordForm.confirm_new_password.hasError("notMatch")),e.xp6(3),e.Q6J("ngClass",n.changePasswordForm.new_password.value.length>7?"":"hidden"),e.xp6(1),e.Q6J("ngClass",n.setColorOfText(0)),e.xp6(3),e.Q6J("ngClass",n.hasUpperCaseAndLowerCase?"":"hidden"),e.xp6(1),e.Q6J("ngClass",n.setColorOfText(1)),e.xp6(3),e.Q6J("ngClass",n.hasDigit?"":"hidden"),e.xp6(1),e.Q6J("ngClass",n.setColorOfText(2)),e.xp6(7),e.Q6J("ngIf",n.passwordSuccessfullyChanged),e.xp6(5),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.two_factor_authentication),e.xp6(2),e.Q6J("ngIf",!n.selectedTypeOfAuth),e.xp6(1),e.Q6J("ngIf",n.user2FA!==n.selectedTypeOfAuth&&"app"==n.selectedTypeOfAuth||"app"==n.editingTypeOfAuth),e.xp6(1),e.Q6J("ngIf",n.user2FA!==n.selectedTypeOfAuth&&"sms"==n.selectedTypeOfAuth||"sms"==n.editingTypeOfAuth),e.xp6(1),e.Q6J("ngIf",n.user2FA==n.selectedTypeOfAuth&&n.user2FA&&!n.editingTypeOfAuth)}},dependencies:[P.mk,P.O5,s._Y,s.Fj,s.JJ,s.JL,v.d,h.TO,h.KE,h.R9,L.Nt,s.sg,s.u,U.K,et,Tt,pt],styles:[".input-wrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:53%;justify-content:space-between;padding-left:24px}@media (max-width: 960px){.input-wrapper[_ngcontent-%COMP%]{padding-left:0}}mat-form-field[_ngcontent-%COMP%]{width:60%}mat-form-field[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{letter-spacing:15px;line-height:20px;padding-left:20px;transform:translateY(-15px)}mat-form-field[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{transform:translateY(-13px)}mat-error[_ngcontent-%COMP%]{padding-left:20px}.pink-divider[_ngcontent-%COMP%]{background-color:#d6117f;height:2px;border:none;margin-bottom:20px}.title[_ngcontent-%COMP%]{margin-top:56px!important;font-size:30px;font-weight:700;margin-left:24px!important;margin-bottom:22px!important}.password-requirement[_ngcontent-%COMP%]{background-color:#eaf2fc;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;padding:20px 40px;height:90px;width:27%;font-size:14px}@media (max-width: 1190px){.password-requirement[_ngcontent-%COMP%]{width:40%;padding:20px 0}}@media (max-width: 960px){.password-requirement[_ngcontent-%COMP%]{width:45%}}.password-requirement[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]{display:flex;width:100%}.password-requirement[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{width:16px}.text-blue[_ngcontent-%COMP%]{color:#144a90}.text-shadow[_ngcontent-%COMP%]{color:#00000040}.hidden[_ngcontent-%COMP%]{visibility:hidden}mat-slide-toggle[_ngcontent-%COMP%]{margin-top:56px!important;margin-left:50px}.action[_ngcontent-%COMP%]{margin-left:24px;display:flex;position:relative;width:53%;justify-content:space-between;gap:20px;margin-top:40px}.action[_ngcontent-%COMP%]   .saved-text[_ngcontent-%COMP%]{margin-top:15px!important}.bold[_ngcontent-%COMP%]{font-weight:600;font-size:18px;line-height:40px}  .mat-radio-label-content{padding-left:40px!important}.auth-options[_ngcontent-%COMP%]{margin-bottom:38px}.wider-word[_ngcontent-%COMP%]{letter-spacing:10px!important}.wide-word[_ngcontent-%COMP%]{letter-spacing:5px!important}.widest-word[_ngcontent-%COMP%]{letter-spacing:2px!important}.input-label[_ngcontent-%COMP%]{margin-top:11px!important}.img-margin[_ngcontent-%COMP%]{margin-right:23px!important}.change-password-wrapper[_ngcontent-%COMP%]{flex-wrap:wrap}.auth-method.first[_ngcontent-%COMP%]{border-top:1px solid black}.auth-method[_ngcontent-%COMP%]{width:69%;display:flex;align-items:center;height:115px;border-top:1px solid black;border-bottom:1px solid black;cursor:pointer}@media (max-width: 1180px){.auth-method[_ngcontent-%COMP%]{width:80%}}@media (max-width: 960px){.auth-method[_ngcontent-%COMP%]{width:100%}}.auth-method[_ngcontent-%COMP%]   .auth-method__name[_ngcontent-%COMP%]{margin-right:auto!important;font-size:35px;font-style:normal;font-weight:400;line-height:normal;letter-spacing:.35px;text-transform:uppercase}.auth-method[_ngcontent-%COMP%]   .auth-method__description[_ngcontent-%COMP%]{width:315px;margin-left:10px!important}.auth-method[_ngcontent-%COMP%]   .black-arrow[_ngcontent-%COMP%]{width:100px;height:39px;background-color:#000;-webkit-mask:url(/assets/pic/vector-black.svg) no-repeat center;mask:url(/assets/pic/vector-black.svg) no-repeat center}.auth-method[_ngcontent-%COMP%]:hover   .black-arrow[_ngcontent-%COMP%]{background-color:#d6117f}.auth-method[_ngcontent-%COMP%]:hover   .auth-method__name[_ngcontent-%COMP%]{color:#d6117f}.two-factor-auth__subscription[_ngcontent-%COMP%]{margin-bottom:40px!important}.bold-text[_ngcontent-%COMP%]{font-weight:700}.auth-wrapper[_ngcontent-%COMP%]{padding-left:24px;margin-top:40px;margin-bottom:60px}"]}),_})();const vt=["tabs"];
1function $t(_,i){if(1&_&&(e.tHW(0,3,1),e.TgZ(1,"app-tooltip"),e._UZ(2,"p"),e.qZA(),e.N_p()),2&_){const t=e.oxw();e.xp6(2),e.pQV(t.tooltipsService.tooltips.account),e.QtT(0)}}let Gt=(()=>{class _{constructor(t,n,o){this.activatedRoute=t,this.breadcrumbs=n,this.tooltipsService=o}ngOnInit(){setTimeout(()=>{this.tabGroup.selectedTabChange.subscribe(t=>{this.breadcrumbsSetup(t.index)}),this.activatedRoute.queryParams.subscribe(t=>{this.tabGroup.selectedIndex=t.page,this.breadcrumbsSetup(this.tabGroup.selectedIndex)})},0)}breadcrumbsSetup(t){this.breadcrumbs.setLinks([{route:"/",text:"HOME"},{route:"/main/settings",text:"SETTINGS"},{text:0==t?"personal details":1==t?"notifications":"security"}])}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(M.gz),e.Y36(y.W),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["ng-component"]],viewQuery:function(t,n){if(1&t&&e.Gf(vt,5),2&t){let o;e.iGM(o=e.CRH())&&(n.tabGroup=o.first)}},features:[e._Bn([{provide:e.QbO,useValue:"NoopAnimations"}])],decls:16,vars:2,consts:function(){let i,t,n,o;return i="PERSONAL DETAILS",t="NOTIFICATIONS",n="SECURITY",o="account " + "\ufffd*4:1\ufffd\ufffd#1:1\ufffd" + "" + "\ufffd#2:1\ufffd" + "" + "\ufffd0:1\ufffd" + "" + "\ufffd/#2:1\ufffd" + "" + "\ufffd/#1:1\ufffd\ufffd/*4:1\ufffd" + "",[[1,"my-profile"],[1,"title","flex","margin-top"],[1,"title-text","margin-right","capital-gothic"],o,[4,"ngIf"],[1,"breadcrumbs"],[3,"animationDuration"],["tabs",""],["label",i],["profile",""],["label",t],["label",n]]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e.tHW(3,3),e.YNc(4,$t,3,1,"app-tooltip",4),e.N_p(),e.qZA(),e.TgZ(5,"div",5),e._UZ(6,"wo-breadcrumbs"),e.qZA()(),e.TgZ(7,"mat-tab-group",6,7)(9,"mat-tab",8),e._UZ(10,"app-personal-details-tab",null,9),e.qZA(),e.TgZ(12,"mat-tab",10),e._UZ(13,"app-notifications-tab"),e.qZA(),e.TgZ(14,"mat-tab",11),e._UZ(15,"app-security-tab"),e.qZA()()()),2&t&&(e.xp6(4),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.account),e.xp6(3),e.Q6J("animationDuration","0"))},dependencies:[P.O5,Z.SP,Z.uX,U.K,B.g,Fe,Ze,Ut],styles:[".my-profile[_ngcontent-%COMP%]{padding:0 60px 40px 0;font-family:Arial,Helvetica Neue,sans-serif}.title-text[_ngcontent-%COMP%]{font-size:44px;font-style:normal;font-weight:700;line-height:1;letter-spacing:.44px;text-transform:uppercase;margin-bottom:23px!important}.title-text[_ngcontent-%COMP%]     app-tooltip .right{top:13px}.profile-title[_ngcontent-%COMP%]{font-size:33px;font-weight:700}@media (max-width: 960px){.my-profile[_ngcontent-%COMP%]{padding-right:1rem}}"]}),_})();var G=T(69907);function wt(_,i){if(1&_&&(e.tHW(0,3,1),e.TgZ(1,"app-tooltip"),e._UZ(2,"p"),e.qZA(),e.N_p()),2&_){const t=e.oxw();e.xp6(2),e.pQV(t.tooltipsService.tooltips.settings),e.QtT(0)}}function Zt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",7)(1,"div",8),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.toProfileView(0))}),e.TgZ(2,"p",9),e.SDv(3,10),e.qZA()(),e.TgZ(4,"div",11)(5,"div",12),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.toProfileView(0))}),e.TgZ(6,"p",13),e.SDv(7,14),e.qZA(),e.TgZ(8,"p",15),e.SDv(9,16),e.qZA(),e.TgZ(10,"div",17),e._UZ(11,"div",18),e.qZA()(),e.TgZ(12,"div",19),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.toProfileView(1))}),e.TgZ(13,"p",13),e.SDv(14,20),e.qZA(),e.TgZ(15,"p",15),e.SDv(16,21),e.qZA(),e.TgZ(17,"div",17),e._UZ(18,"div",18),e.qZA()(),e.TgZ(19,"div",22),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.toProfileView(2))}),e.TgZ(20,"p",13),e.SDv(21,23),e.qZA(),e.TgZ(22,"p",15),e.SDv(23,24),e.qZA(),e.TgZ(24,"div",17),e._UZ(25,"div",18),e.qZA()()()()}}function yt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",12),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.toCompanyView(0))}),e.TgZ(1,"p",13),e.SDv(2,29),e.qZA(),e.TgZ(3,"p",15),e.SDv(4,30),e.qZA(),e.TgZ(5,"div",17),e._UZ(6,"div",18),e.qZA()()}}function Bt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",19),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.toCompanyView(1))}),e.TgZ(1,"p",13),e.SDv(2,31),e.qZA(),e.TgZ(3,"p",15),e.SDv(4,32),e.qZA(),e.TgZ(5,"div",17),e._UZ(6,"div",18),e.qZA()()}}function kt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",22),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.toCompanyView(2))}),e.TgZ(1,"p",13),e.SDv(2,33),e.qZA(),e.TgZ(3,"p",15),e.SDv(4,34),e.qZA(),e.TgZ(5,"div",17),e._UZ(6,"div",18),e.qZA()()}}function Yt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",7)(1,"div",8),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.toCompanyView(0))}),e.TgZ(2,"p",9),e.SDv(3,25),e.qZA()(),e.TgZ(4,"div",11),e.YNc(5,yt,7,0,"div",26),e.YNc(6,Bt,7,0,"div",27),e.YNc(7,kt,7,0,"div",28),e.qZA()()}if(2&_){const t=e.oxw();e.xp6(5),e.Q6J("ngIf",t.canAction("view","company_information")),e.xp6(1),e.Q6J("ngIf",t.canAction("view","roles")),e.xp6(1),e.Q6J("ngIf",t.canAction("view","users"))}}let qt=(()=>{class _{constructor(t,n,o,a){this.router=t,this.breadcrumbs=n,this.rolesService=o,this.tooltipsService=a,this.breadcrumbs.set
1Links([{route:"/",text:"Home"},{text:"SETTINGS"}])}toProfileView(t){this.router.navigate(["main/settings/account"],{queryParams:{page:t}})}canAction(t,n){return this.rolesService.canAction(t,n)}toCompanyView(t){this.router.navigate(["main/settings/company-settings"],{queryParams:{page:t}})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(M.F0),e.Y36(y.W),e.Y36(G.f),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-noc"]],decls:9,vars:3,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R;return i="SETTINGS " + "\ufffd*4:1\ufffd\ufffd#1:1\ufffd" + "" + "\ufffd#2:1\ufffd" + "" + "\ufffd0:1\ufffd" + "" + "\ufffd/#2:1\ufffd" + "" + "\ufffd/#1:1\ufffd\ufffd/*4:1\ufffd" + "",t="Account",n="PERSONAL DETAILS",o="Set up your personal information (e.g. name, phone number)",a="NOTIFICATIONS",r="Set up your notification preferences here.",l="SECURITY",p="Changing password, two-factor authentication settings.",S="Company Settings",N="COMPANY INFORMATION",d="Company legal and billing information.",c="ROLES",I="User roles and their permissions.",f="USERS",R="List of company\u2019s users, their roles.",[[1,"support"],[1,"flex"],[1,"text-title","margin-right","capital-gothic"],i,[4,"ngIf"],[1,"breadcrumbs"],["class","links_ticketing-system",4,"ngIf"],[1,"links_ticketing-system"],[1,"ticketing-system","pointer",3,"click"],[1,"ticketing-system_title","capital-gothic"],t,[1,"links"],[1,"faq","link",3,"click"],[1,"link-title"],n,[1,"link-description"],o,[1,"link-arrow-container"],[1,"arrow"],[1,"noc","link",3,"click"],a,r,[1,"escalation-matrix","link",3,"click"],l,p,S,["class","faq link",3,"click",4,"ngIf"],["class","noc link",3,"click",4,"ngIf"],["class","escalation-matrix link",3,"click",4,"ngIf"],N,d,c,I,f,R]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e.tHW(3,3),e.YNc(4,wt,3,1,"app-tooltip",4),e.N_p(),e.qZA(),e.TgZ(5,"div",5),e._UZ(6,"wo-breadcrumbs"),e.qZA()(),e.YNc(7,Zt,26,0,"div",6),e.YNc(8,Yt,8,3,"div",6),e.qZA()),2&t&&(e.xp6(4),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.settings),e.xp6(3),e.Q6J("ngIf",n.canAction("view","account_settings")),e.xp6(1),e.Q6J("ngIf",n.canAction("view","company_information")||n.canAction("view","roles")||n.canAction("view","users")))},dependencies:[P.O5,U.K,B.g],styles:[".links_ticketing-system[_ngcontent-%COMP%]{display:flex;gap:20px;margin-bottom:34px}@media (max-width: 1100px){.links_ticketing-system[_ngcontent-%COMP%]{flex-direction:column}}.links_ticketing-system[_ngcontent-%COMP%]:nth-child(3){flex-direction:row-reverse;justify-content:flex-end}@media (max-width: 1100px){.links_ticketing-system[_ngcontent-%COMP%]:nth-child(3){flex-direction:column}}.links_ticketing-system[_ngcontent-%COMP%]   .ticketing-system[_ngcontent-%COMP%]{display:flex;box-sizing:border-box;flex-direction:column;justify-content:center;background-color:#144a90;padding:50px 16px 54px;min-width:332px}.links_ticketing-system[_ngcontent-%COMP%]   .ticketing-system[_ngcontent-%COMP%]   .ticketing-system_title[_ngcontent-%COMP%]{color:#fff;font-size:30px;font-weight:700;letter-spacing:.3px;padding:0 20px;text-align:center}.links_ticketing-system[_ngcontent-%COMP%]   .pointer[_ngcontent-%COMP%]:hover   .ticketing-system_title[_ngcontent-%COMP%]{color:#d6117f}.links_ticketing-system[_ngcontent-%COMP%]:nth-child(2)   .link-title[_ngcontent-%COMP%]{width:360px}@media (max-width: 1440px){.links_ticketing-system[_ngcontent-%COMP%]:nth-child(2)   .link-title[_ngcontent-%COMP%]{width:280px}}.link[_ngcontent-%COMP%]{display:flex;border-top:1px solid black;height:100px;align-items:center;width:calc(100vw - 700px);max-width:1000px;gap:40px;cursor:pointer}@media (max-width: 1100px){.link[_ngcontent-%COMP%]{width:100%}}.link[_ngcontent-%COMP%]:last-child{border-bottom:1px solid black}.link[_ngcontent-%COMP%]:hover   .link-title[_ngcontent-%COMP%]{color:#d6117f}.link[_ngcontent-%COMP%]:hover   .link-arrow-container[_ngcontent-%COMP%]   .arrow[_ngcontent-%COMP%]{background-color:#d6117f}.link-title[_ngcontent-%COMP%]{width:450px;color:#000;font-size:35px;font-style:normal;font-weight:400;line-height:normal;letter-spacing:.35px;text-transform:uppercase}@media (max-width: 1440px){.link-title[_ngcontent-%COMP%]{width:280px;min-width:270px}}.link-description[_ngcontent-%COMP%]{display:flex;align-items:center;flex:1}.support[_ngcontent-%COMP%]{padding:0 60px 40px 0}@media (max-width: 960px){.support[_ngcontent-%COMP%]{padding-right:1rem}}.link-arrow-container[_ngcontent-%COMP%]{display:flex;width:-moz-fit-content;width:fit-content;margin:10px 0 0 auto}.link-arrow-container[_ngcontent-%COMP%]   .arrow[_ngcontent-%COMP%]{width:39px;height:39px;background-color:#000;-webkit-mask:url(/assets/pic/icons/black-vector.svg) no-repeat center;mask:url(/assets/pic/icons/black-vector.svg) no-repeat center}.useful-links-items[_ngcontent-%COMP%]{display:flex;gap:20px;align-items:center}.useful-links-items[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]{display:flex;gap:20px;flex-direction:column;text-transform:uppercase;color:#144a90;padding-right:20px}.useful-links-items[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{cursor:pointer}.useful-links-items[_ngcontent-%COMP%]   div[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]:hover{color:#d6117f}.text-title[_ngcontent-%COMP%]{font-size:44px;font-style:normal;font-weight:700;margin-top:7px!important;letter-spacing:.44px;margin-bottom:46px!important}.acc-manager[_ngcontent-%COMP%]{display:flex;align-items:flex-start;margin-top:31px}.acc-manager[_ngcontent-%COMP%]   .text[_ngcontent-%COMP%]{margin-right:40px;
1display:flex;flex-direction:column;width:366px;gap:14px}.acc-manager[_ngcontent-%COMP%]   .text[_ngcontent-%COMP%]   .subtitle[_ngcontent-%COMP%]{font-size:30px;font-style:normal;font-weight:700;letter-spacing:.3px}.acc-manager[_ngcontent-%COMP%]   .contact[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:14px;margin-left:24px}.acc-manager[_ngcontent-%COMP%]   .contact[_ngcontent-%COMP%]   .name[_ngcontent-%COMP%]{font-weight:700}"]}),_})();class Xt extends D.I{constructor(){super({}),this.addControl("id",new s.NI("")),this.addControl("legal_name",new s.NI("",s.kI.required)),this.addControl("service_agreement_number",new s.NI("",s.kI.required)),this.addControl("agreement_date",new s.NI("",s.kI.required)),this.addControl("retn_unit",new s.NI("",[s.kI.required,s.kI.pattern($.T.EMAIL_REGEX)])),this.addControl("registration_number",new s.NI("",s.kI.required)),this.addControl("vat_number",new s.NI("",[s.kI.required,s.kI.pattern($.T.PHONE_REGEX)])),this.addControl("legal_address",new s.NI("",s.kI.required)),this.addControl("city",new s.NI("",s.kI.required)),this.addControl("country",new s.NI("",s.kI.required)),this.addControl("post_code",new s.NI("",s.kI.required))}get id(){return this.controls.id}get legal_name(){return this.controls.legal_name}get service_agreement_number(){return this.controls.service_agreement_number}get agreement_date(){return this.controls.agreement_date}get retn_unit(){return this.controls.retn_unit}get registration_number(){return this.controls.registration_number}get vat_number(){return this.controls.vat_number}get legal_address(){return this.controls.legal_address}get city(){return this.controls.city}get country(){return this.controls.country}get post_code(){return this.controls.post_code}}var zt=T(14143);function Jt(_,i){1&_&&(e.ynx(0),e._uU(1,", "),e.BQk())}function Qt(_,i){if(1&_&&(e.TgZ(0,"span"),e._uU(1),e.YNc(2,Jt,2,0,"ng-container",15),e.qZA()),2&_){const t=i.$implicit,n=i.last;e.xp6(1),e.AsE(" ",null==t?null:t.number," (",null==t?null:t.date,") "),e.xp6(1),e.Q6J("ngIf",!n)}}function Ht(_,i){if(1&_&&(e.tHW(0,14,1),e.TgZ(1,"app-tooltip"),e._UZ(2,"p"),e.qZA(),e.N_p()),2&_){const t=e.oxw();e.xp6(2),e.pQV(t.tooltipService.tooltips.address_details),e.QtT(0)}}function Vt(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",20)(1,"div",21),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.newBillingTicket())}),e._UZ(2,"div",22),e.TgZ(3,"p"),e.SDv(4,23),e.qZA()()()}}let Kt=(()=>{class _{constructor(t,n,o,a){this.getCompanyInformationUseCase=t,this.router=n,this.rolesService=o,this.tooltipService=a,this.companyInformationForm=new Xt,this.legalAddress="Registered Address(legal)"}ngOnInit(){this.getCompanyInformationUseCase.execute().subscribe(t=>{this.companyInfo=t,this.companyInformationForm.patchValue(t)})}canAction(t,n){return this.rolesService.canAction(t,n)}newBillingTicket(){this.router.navigate(["/main/support/change-company-information"])}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(zt.p),e.Y36(M.F0),e.Y36(G.f),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-company-information-tab"]],decls:65,vars:14,consts:function(){let i,t,n,o,a,r,l,p,S,N,d;return i="Customer ID " + "\ufffd0\ufffd" + "",t="Legal Name:",n="Registration \u2116:",o="VAT \u2116:",a="RETN Unit:",r="Service Agreement \u2116:",l="City:",p="Country:",S="Post Code:",N="Address Details " + "\ufffd*38:1\ufffd\ufffd#1:1\ufffd" + "" + "\ufffd#2:1\ufffd" + "" + "\ufffd0:1\ufffd" + "" + "\ufffd/#2:1\ufffd" + "" + "\ufffd/#1:1\ufffd\ufffd/*38:1\ufffd" + "",d="CHANGE COMPANY INFORMATION",[[1,"details",3,"formGroup"],[1,"profile-title","margin-top","margin-left-custom","capital-gothic"],i,[1,"pink-divider"],[1,"flex","space-between"],[1,"margin-left-custom","bold"],t,[1,"width-60"],n,o,a,r,[4,"ngFor","ngForOf"],[1,"address"],N,[4,"ngIf"],l,p,S,["class","actions",4,"ngIf"],[1,"actions"],[1,"arrow-container",3,"click"],[1,"arrow"],d]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div")(2,"p",1),e.SDv(3,2),e.qZA(),e._UZ(4,"mat-divider",3),e.TgZ(5,"div",4)(6,"p",5),e.SDv(7,6),e.qZA(),e.TgZ(8,"p",7),e._uU(9),e.qZA()(),e._UZ(10,"mat-divider"),e.TgZ(11,"div",4)(12,"p",5),e.SDv(13,8),e.qZA(),e.TgZ(14,"p",7),e._uU(15),e.qZA()(),e._UZ(16,"mat-divider"),e.TgZ(17,"div",4)(18,"p",5),e.SDv(19,9),e.qZA(),e.TgZ(20,"p",7),e._uU(21),e.qZA()(),e._UZ(22,"mat-divider"),e.TgZ(23,"div",4)(24,"p",5),e.SDv(25,10),e.qZA(),e.TgZ(26,"p",7),e._uU(27),e.qZA()(),e._UZ(28,"mat-divider"),e.TgZ(29,"div",4)(30,"p",5),e.SDv(31,11),e.qZA(),e.TgZ(32,"p",7),e.YNc(33,Qt,3,3,"span",12),e.qZA()(),e._UZ(34,"mat-divider"),e.qZA(),e.TgZ(35,"div",13)(36,"p",1),e.tHW(37,14),e.YNc(38,Ht,3,1,"app-tooltip",15),e.N_p(),e.qZA(),e._UZ(39,"mat-divider",3),e.TgZ(40,"div",4)(41,"p",5),e._uU(42),e.qZA(),e.TgZ(43,"p",7),e._uU(44),e.qZA()(),e._UZ(45,"mat-divider"),e.TgZ(46,"div",4)(47,"p",5),e.SDv(48,16),e.qZA(),e.TgZ(49,"p",7),e._uU(50),e.qZA()(),e._UZ(51,"mat-divider"),e.TgZ(52,"div",4)(53,"p",5),e.SDv(54,17),e.qZA(),e.TgZ(55,"p",7),e._uU(56),e.qZA()(),e._UZ(57,"mat-divider"),e.TgZ(58,"div",4)(59,"p",5),e.SDv(60,18),e.qZA(),e.TgZ(61,"p",7),e._uU(62),e.qZA()(),e._UZ(63,"mat-divider"),e.qZA()(),e.YNc(64,Vt,5,0,"div",19)),2&t&&(e.Q6J("formGroup",n.companyInformationForm),e.xp6(3),e.p
1QV(n.companyInformationForm.id.value),e.QtT(3),e.xp6(6),e.Oqu(null==n.companyInformationForm.legal_name?null:n.companyInformationForm.legal_name.value),e.xp6(6),e.Oqu(null==n.companyInformationForm.registration_number?null:n.companyInformationForm.registration_number.value),e.xp6(6),e.Oqu(null==n.companyInformationForm.vat_number?null:n.companyInformationForm.vat_number.value),e.xp6(6),e.Oqu(null==n.companyInformationForm.retn_unit?null:n.companyInformationForm.retn_unit.value),e.xp6(6),e.Q6J("ngForOf",null==n.companyInfo?null:n.companyInfo.contract_list),e.xp6(5),e.Q6J("ngIf",null==n.tooltipService||null==n.tooltipService.tooltips?null:n.tooltipService.tooltips.address_details),e.xp6(4),e.hij("",n.legalAddress,":"),e.xp6(2),e.Oqu(null==n.companyInformationForm.legal_address?null:n.companyInformationForm.legal_address.value),e.xp6(6),e.Oqu(null==n.companyInformationForm.city?null:n.companyInformationForm.city.value),e.xp6(6),e.Oqu(null==n.companyInformationForm.country?null:n.companyInformationForm.country.value),e.xp6(6),e.Oqu(null==n.companyInformationForm.post_code?null:n.companyInformationForm.post_code.value),e.xp6(2),e.Q6J("ngIf",n.canAction("edit","company_information")))},dependencies:[P.sg,P.O5,s.JL,v.d,s.sg,U.K],styles:[".details[_ngcontent-%COMP%]{min-width:30rem;width:53%;margin-top:54px}.flex[_ngcontent-%COMP%]{min-height:38px;padding-top:10px}.width-60[_ngcontent-%COMP%]{width:65%}@media (max-width: 1440px){.width-60[_ngcontent-%COMP%]{width:55%}}.profile-title[_ngcontent-%COMP%]{font-size:30px;font-weight:700;margin-bottom:18px!important}.pink-divider[_ngcontent-%COMP%]{background-color:#d6117f;height:2px;border:none}mat-divider[_ngcontent-%COMP%]{height:1px;border-top-color:#000}.bold[_ngcontent-%COMP%]{font-weight:700}mat-form-field[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{padding-left:1rem!important}mat-form-field[_ngcontent-%COMP%]     .mat-form-field-label{margin-left:1rem!important}mat-form-field[_ngcontent-%COMP%]   mat-select[_ngcontent-%COMP%]{padding-left:1rem!important;width:96%}mat-form-field[_ngcontent-%COMP%]   mat-label[_ngcontent-%COMP%]{margin-left:1rem!important;font-weight:300;font-size:14px}.margin-left-custom[_ngcontent-%COMP%]{margin-left:24px!important}.absolute[_ngcontent-%COMP%]{position:absolute;top:62px;left:200px}.actions[_ngcontent-%COMP%]{margin-top:54px;padding-left:24px;width:53%;display:flex;justify-content:space-between;box-sizing:border-box}.address[_ngcontent-%COMP%]{margin-top:54px}"]}),_})();var Wt=T(95017),ce=T(61135),Se=T(71884);let jt=(()=>{class _{constructor(t,n){this.data=t,this.matDialogRef=n}ngOnInit(){}negative(){this.matDialogRef.close(!1)}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(F.WI),e.Y36(F.so))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-warning"]],decls:7,vars:1,consts:function(){let i;return i="OK",[[1,"wrapper"],[3,"click"],[1,"text","capital-gothic",3,"innerHTML"],[1,"actions","capital-gothic"],[1,"blue",3,"click"],i]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"mat-icon",1),e.NdJ("click",function(){return n.negative()}),e._uU(2,"close"),e.qZA(),e._UZ(3,"p",2),e.TgZ(4,"div",3)(5,"p",4),e.NdJ("click",function(){return n.negative()}),e.SDv(6,5),e.qZA()()()),2&t&&(e.xp6(3),e.Q6J("innerHTML",n.data.text,e.oJD))},dependencies:[Q.Hw],styles:[".wrapper[_ngcontent-%COMP%]{background-color:#144a90;position:relative;padding:40px 46px;flex-shrink:0;background:var(--blue, #144A90);box-sizing:border-box;border-bottom:12px solid transparent!important;border-image-slice:1;border-image-source:linear-gradient(270deg,#0052A4 -8.17%,#D80A8C 110.33%);width:640px}.wrapper[_ngcontent-%COMP%]   mat-icon[_ngcontent-%COMP%]{position:absolute;top:0;right:0;color:#fff;cursor:pointer}  .general-information-popup .mat-dialog-container{padding:0!important}  .general-information-popup .mat-dialog-container .dedicated-text{color:#4698ff}.text[_ngcontent-%COMP%]{text-align:center;font-size:20px;font-style:normal;font-weight:700;line-height:127.49%;letter-spacing:.5px;color:#fff}.actions[_ngcontent-%COMP%]{display:flex;justify-content:center;gap:125px;margin-top:40px;color:#fff;font-weight:700;line-height:127.49%;letter-spacing:.4px;text-transform:uppercase}.actions[_ngcontent-%COMP%]   .blue[_ngcontent-%COMP%]:hover{color:#4698ff}.actions[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{cursor:pointer;width:-moz-fit-content;width:fit-content}.actions[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]:hover{color:#d80a8c}"]}),_})();var en=T(62825),tn=T(81349),nn=T(28411),_n=T(42675),te=T(56709),w=T(28255),H=T(96308),E=T(30671),pe=T(10879),Ee=T(95184);const on=function(){return["/main/settings/roles/edit/new"]};function an(_,i){1&_&&(e.TgZ(0,"button",37),e.SDv(1,38),e.qZA()),2&_&&e.Q6J("routerLink",e.DdM(1,on))}function sn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(o){e.CHM(t);const a=e.oxw();return a.resetPaginationSettings(),e.KtG(a.onItemsSelect(o,"role_id"))}),e.qZA()}if(2&_){const t=e.oxw();e.Q6J("data",t.role_ids)("label",t.roleIDLabel)}}function rn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(o){e.CHM(t);const a=e.oxw();return a.resetPaginationSettings(),e.KtG(a.onItemsSelect(o,"role"))}),e.qZA()}if(2&_){const t=e.oxw();e.Q6J("data",t.roles)("label",t.roleLabel)}}function ln(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(o){e.CHM(t);const a=e.oxw();return a.resetPaginationSettings(),e.KtG(a.onItemsSelect(o,"role_type"))}),e.qZA()}if(2&_){const t=e.oxw();e.Q6J("data",t.role_types)("label",t.roleTypeLabel)}}function Tn(_,i){1&_&&(e.tHW(0,49,1),e._UZ(1,"span"),e.N_p())}function cn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",48),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.setRoleStatus(null,"active"))}),e.tHW(1,49),e.YNc(2,Tn,2,0,"span",50),e.N_p(),e.qZA()}if(2&_){const t=e.oxw(2);e.xp6(2),e.Q6J("ngIf",(null==t.selectedItems.selected?null:t.selectedItems.selected.length)>1)}}function Sn(_,i){1&_&&(e.tHW(0,51,1),e._UZ(1,"span"),e.N_p())}function pn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",48),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.setRoleStatus(null,"deleted"))}),e.tHW(1,51),e.YNc(2,Sn,2,0,"span",50),e.N_p(),e.qZA()}if(2&_){const t=e.oxw(2);e.xp6(2),e.Q6J("ngIf",(null==t.selectedItems.selected?null:t.selectedItems.selected.length)>1)}}function En(_,i){1&_&&(e.tHW(0,52,1),e._UZ(1,"span"),e.N_p())}function gn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",48),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.setRoleStatus(null,"disabled"))}),e.tHW(1,52),e.YNc(2,En,2,0,"span",50),e.N_p(),e.qZA()}if(2&_){const t=e.oxw(2);e.xp6(2),e.Q6J("ngIf",(null==t.selectedItems.selected?null:t.selectedItems.selected.length)>1)}}function dn(_,i){if(1&_&&(e.TgZ(0,"div",39)(1,"span",40),e.tHW(2,41),e._UZ(3,"span"),e.N_p(),e.qZA(),e.TgZ(4,"span")(5,"b"),e._uU(6,"Actions"),e.qZA()(),e.TgZ(7,"div")(8,"button",42),e.O4$(),e.TgZ(9,"svg",43),e._UZ(10,"path",44),e.qZA()(),e.kcU(),e.TgZ(11,"mat-menu",45,46),e.YNc(13,cn,3,1,"button",47),e.YNc(14,pn,3,1,"button",47),e.YNc(15,gn,3,1,"button",47),e.qZA()()()),2&_){const t=e.MAs(12),n=e.oxw();
1e.xp6(3),e.pQV(n.selectedItems.selected.length),e.QtT(2),e.xp6(5),e.Q6J("matMenuTriggerFor",t),e.xp6(5),e.Q6J("ngIf",n.canAction("edit","roles")),e.xp6(1),e.Q6J("ngIf",n.canAction("delete","roles")),e.xp6(1),e.Q6J("ngIf",n.canAction("edit","roles"))}}function Pn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"th",53)(1,"mat-checkbox",54),e.NdJ("change",function(o){e.CHM(t);const a=e.oxw();return e.KtG(a.onSelectAll(o))}),e.qZA()()}if(2&_){const t=e.oxw();e.xp6(1),e.Q6J("checked",t.allSelected)("indeterminate",t.someSelected())}}function Nn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",55)(1,"mat-checkbox",56),e.NdJ("ngModelChange",function(o){const r=e.CHM(t).$implicit;return e.KtG(r.selected=o)})("ngModelChange",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.updateAllSelected())})("change",function(){const a=e.CHM(t).$implicit,r=e.oxw();return e.KtG(r.onSelect(a.id))}),e.qZA()()}if(2&_){const t=i.$implicit,n=e.oxw();e.xp6(1),e.Q6J("ngModel",t.selected)("checked",n.selectedItems.isSelected(t.id))}}function Cn(_,i){1&_&&(e.TgZ(0,"th",57),e.SDv(1,58),e.qZA())}const ge=function(_){return["../roles/",_]};function un(_,i){if(1&_&&(e.TgZ(0,"td",59)(1,"a",60),e._uU(2),e.qZA()()),2&_){const t=i.$implicit;e.xp6(1),e.Q6J("routerLink",e.VKq(2,ge,t.id)),e.xp6(1),e.hij(" ",t.role_id," ")}}function On(_,i){1&_&&(e.TgZ(0,"th",57),e.SDv(1,61),e.qZA())}function mn(_,i){if(1&_&&(e.TgZ(0,"td",59),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.xp6(1),e.hij(" ",t.role," ")}}function An(_,i){1&_&&(e.TgZ(0,"th",57),e.SDv(1,62),e.qZA())}function Mn(_,i){if(1&_&&(e.TgZ(0,"td",59),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.xp6(1),e.hij(" ",t.role_type," ")}}function In(_,i){1&_&&(e.TgZ(0,"th",57),e.SDv(1,63),e.qZA())}function fn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",59)(1,"mat-select",64)(2,"div",65),e.NdJ("click",function(o){const r=e.CHM(t).$implicit;return e.oxw().setRoleStatus(r,"Active"==r.status?"disabled":"active"),e.KtG(o.stopPropagation())}),e.TgZ(3,"mat-option"),e._uU(4),e.qZA()()()()}if(2&_){const t=i.$implicit,n=e.oxw();e.xp6(1),e.Tol("Active"==t.status?"active":"disabled"),e.Q6J("disabled",!n.canAction("edit","roles"))("placeholder",t.status),e.xp6(3),e.Oqu("Active"==t.status?"DISABLE":"ACTIVATE")}}function Rn(_,i){1&_&&(e.TgZ(0,"th",53),e.SDv(1,66),e.qZA())}function hn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",48),e.NdJ("click",function(){e.CHM(t);const o=e.oxw().$implicit,a=e.oxw();return e.KtG(a.copyRole(o.id))}),e.SDv(1,68),e.qZA()}}function Fn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",48),e.NdJ("click",function(){e.CHM(t);const o=e.oxw().$implicit,a=e.oxw();return e.KtG(a.setRoleStatus(o,"deleted"))}),e.SDv(1,69),e.qZA()}}const Dn=function(_){return["../roles/edit/",_]};function bn(_,i){if(1&_&&(e.TgZ(0,"button",70),e.SDv(1,71),e.qZA()),2&_){const t=e.oxw().$implicit;e.Q6J("routerLink",e.VKq(1,Dn,t.id))}}function Ln(_,i){if(1&_&&(e.TgZ(0,"button",70),e.SDv(1,72),e.qZA()),2&_){const t=e.oxw().$implicit;e.Q6J("routerLink",e.VKq(1,ge,t.id))}}function xn(_,i){if(1&_&&(e.TgZ(0,"td",59)(1,"button",42),e.O4$(),e.TgZ(2,"svg",43),e._UZ(3,"path",44),e.qZA()(),e.kcU(),e.TgZ(4,"mat-menu",45,46),e.YNc(6,hn,2,0,"button",47),e.YNc(7,Fn,2,0,"button",47),e.YNc(8,bn,2,3,"button",67),e.YNc(9,Ln,2,3,"button",67),e.qZA()()),2&_){const t=i.$implicit,n=e.MAs(5),o=e.oxw();e.xp6(1),e.Q6J("matMenuTriggerFor",n),e.xp6(5),e.Q6J("ngIf",o.canAction("create","roles")),e.xp6(1),e.Q6J("ngIf","System"!==t.role_type&&o.canAction("delete","roles")),e.xp6(1),e.Q6J("ngIf","System"!==t.role_type&&o.canAction("edit","roles")),e.xp6(1),e.Q6J("ngIf",o.canAction("view","roles"))}}function Un(_,i){1&_&&e._UZ(0,"tr",73)}function vn(_,i){1&_&&e._UZ(0,"tr",74)}function $n(_,i){1&_&&(e.TgZ(0,"div",75),e.SDv(1,76),e.qZA())}function Gn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"label",77)(1,"input",78),e.NdJ("click",function(){const a=e.CHM(t).index,r=e.oxw();return e.KtG(r.onChangeView(r.pageSizeOptions[a]))}),e.qZA(),e._uU(2),e.qZA()}if(2&_){const t=i.index,n=e.oxw();e.MGl("for","view-",n.pageSizeOptions[t],""),e.xp6(1),e.MGl("id","view-",n.pageSizeOptions[t],""),e.Q6J("checked",n.pageSizeOptions[t]==n.search.pageSize),e.xp6(1),e.Oqu(n.pageSizeOptions[t])}}const wn=function(_){return{"search-input__container_hidden":_}};let Zn=(()=>{class _{constructor(t,n,o,a,r,l,p){this.router=t,this.matDialog=n,this.getRoles=o,this.getRolesFilters=a,this.deleteRole=r,this.changeStatus=l,this.rolesService=p,this.displayedColumns=["id","role_id","role","role_type","status","actions"],this.selectedItems=new Wt.Ov(!0),this.allSelected=!1,this.role_ids=[],this.roles=[],this.role_types=[],this.statuses=["Active","Disabled"],this.roleIDLabel="Role ID",this.roleLabel="Role",this.roleTypeLabel="Role Type",this.statusLabel="Status",this.searchToggled=!1,this.direction="desc",this.search={page:0,pageSize:10,
1common:"",sort_field:"",sort_direction:"",condition:{}},this.filterParamsSubject=new ce.X(this.search.common),this.numberOfRowsAtAll=0,this.currentPage=0,this.pageSizeOptions=[10,30,50],this.numberOfPages=0}canAction(t,n){return this.rolesService.canAction(t,n)}ngOnInit(){this.loadData(),this.filterParamsSubject.pipe((0,ne.b)(800),(0,Se.x)()).subscribe(t=>{this.search.common=t,this.resetPaginationSettings(),this.loadData()})}resetPaginationSettings(){this.search.page=0,this.currentPage=0}loadData(){this.getRoles.execute(this.search).subscribe({next:t=>{this.dataSource=t.rows,this.currentPage=t.pagination.current_page,this.numberOfRowsAtAll=t.pagination.rows_total,this.numberOfPages=t.pagination.last_page,this.dataSource.forEach(n=>{n.selected=!1})}}),this.refreshFilters()}onSearch(){this.loadData()}sortBy(t){t.direction?(this.search.sort_field=t.active,this.search.sort_direction=t.direction,this.direction=t.direction):(this.search.sort_field="",this.search.sort_direction=""),this.loadData()}onChangeView(t){this.search.pageSize=t,this.search.page=0,this.currentPage=0,this.loadData()}onChangePage(t){this.search.pageSize=t,this.search.page=0,this.loadData()}onItemsSelect(t,n){this.search.condition[n]=t,this.loadData()}onSelect(t){this.selectedItems.isSelected(t)?(this.selectedItems.deselect(t),this.dataSource.find(n=>n.id===t).selected=!1):(this.selectedItems.select(t),this.dataSource.find(n=>n.id===t).selected=!0),this.allSelected=!!this.dataSource.every(n=>!0===n.selected)}onSelectAll(t){t.checked?(this.dataSource.map(n=>this.selectedItems.select(n.id)),this.dataSource.map(n=>n.selected=!0),this.allSelected=!0):(this.dataSource.map(n=>this.selectedItems.deselect(n.id)),this.dataSource.map(n=>n.selected=!1),this.allSelected=!1)}someSelected(){return 0!==this.selectedItems.selected.length&&this.dataSource.filter(t=>t.selected).length>0&&!this.allSelected}updateAllSelected(){}setRoleStatus(t,n){let o={ids:null,status:n};o.ids=t?[t.id]:this.dataSource.filter(a=>!0===a.selected).map(a=>a.id),this.changeRoleStatus(o)}changeRoleStatus(t){if("deleted"===t.status){let n={deleted:{description:"Are you sure you want to delete role?"},warning:{description:"You cannot delete this role as it is assigned to the following user(s): "}};this.deleteRole.checkAssignedUsers(t.ids).subscribe({next:o=>{o.assigned_users.length>0?this.matDialog.open(jt,{data:{text:n.warning.description+"<br>"+o.assigned_users.join(", ")}}):this.matDialog.open(b.S,{data:{text:n.deleted.description}}).afterClosed().subscribe(a=>{a&&t.ids.forEach(r=>{this.deleteRole.execute(r).subscribe({next:l=>{l&&this.loadData()}})})})}})}else this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:`Are you sure you want to <span class="dedicated-text">${"active"===t.status?"activate":"deleted"===t.status?"delete":"disable"}</span> this ${t.ids.length<2?"role":"roles"}? ${"disabled"===t.status?"All users who are assigned this role will not be able to use the Portal.":""}`}}).afterClosed().subscribe(n=>{n&&t.ids.forEach(o=>{this.changeStatus.execute({name:o,enabled:"active"===t.status}).subscribe({next:a=>{a&&this.loadData()}})})})}copyRole(t){this.router.navigate(["main/settings/roles/edit/new"],{queryParams:{name:t}})}refreshFilters(){this.getRolesFilters.execute().subscribe(t=>{this.role_ids=t.role_id,this.roles=t.role,this.role_types=t.role_type,this.statuses=t.status})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(M.F0),e.Y36(F.uw),e.Y36(en.V),e.Y36(tn.$),e.Y36(nn.f),e.Y36(_n.v),e.Y36(G.f))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-roles-tab"]],decls:49,vars:24,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R,C;return i="show ",t="New Role ",n="Selected items: " + "\ufffd#3\ufffd" + "" + "\ufffd0\ufffd" + "" + "\ufffd/#3\ufffd" + "",o="Activate " + "\ufffd*2:1\ufffd\ufffd#1:1\ufffd" + "All" + "\ufffd/#1:1\ufffd\ufffd/*2:1\ufffd" + "",a="Delete " + "\ufffd*2:1\ufffd\ufffd#1:1\ufffd" + "All" + "\ufffd/#1:1\ufffd\ufffd/*2:1\ufffd" + "",r="Disable " + "\ufffd*2:1\ufffd\ufffd#1:1\ufffd" + "All" + "\ufffd/#1:1\ufffd\ufffd/*2:1\ufffd" + "",l="Role ID",p="Role",
1S="Role Type",N="Status",d="Actions",c="Copy ",I="Delete ",f="Edit ",R="View Details ",C="No records",[[1,"roles"],["class","btn btn_blue capital-gothic","mat-raised-button","",3,"routerLink",4,"ngIf"],[1,"roles__header"],[1,"roles__filters"],[3,"data","label","selectedItems",4,"ngIf"],[3,"data","label","selectedItems"],["matSuffix","","mat-icon-button","","aria-label","Search",1,"search",3,"disableRipple"],["src","assets/pic/icons/search-icon.svg","alt","Search",3,"click"],[1,"roles__hidden"],[1,"search-input__container",3,"ngClass"],["appearance","fill",1,"search-input"],["matPrefix",""],["src","/en/assets/pic/icons/search-icon.svg","alt","search icon"],["placeholder","Type here","matInput","","type","text",3,"input"],["commonInput",""],["class","multi-actions",4,"ngIf"],[1,"table-wrap"],["mat-table","","matSort","",3,"dataSource","matSortActive","matSortDirection","matSortChange"],["matColumnDef","id"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","","style","max-width: 50px;",4,"matCellDef"],["matColumnDef","role_id"],["mat-header-cell","","mat-sort-header","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","role"],["matColumnDef","role_type"],["matColumnDef","status"],["matColumnDef","actions"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["class","no-records",4,"ngIf"],[1,"table-sort"],[1,"table-view","view"],i,["class","view__label",3,"for",4,"ngFor","ngForOf"],[1,"table__paginator"],[1,"table-paginator",3,"current","last","count","length","limit","pageSizeOptions","changePage"],["mat-raised-button","",1,"btn","btn_blue","capital-gothic",3,"routerLink"],t,[1,"multi-actions"],[1,"multi-actions__label"],n,["mat-button","",1,"dropdown-menu__trigger",3,"matMenuTriggerFor"],["width","21","height","5","viewBox","0 0 21 5","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M2.358 4.288C1.44 4.288 0.72 3.55 0.72 2.614C0.72 1.696 1.44 0.958 2.358 0.958C3.24 0.958 3.96 1.696 3.96 2.614C3.96 3.55 3.24 4.288 2.358 4.288ZM10.3821 4.288C9.46406 4.288 8.74406 3.55 8.74406 2.614C8.74406 1.696 9.46406 0.958 10.3821 0.958C11.2641 0.958 11.9841 1.696 11.9841 2.614C11.9841 3.55 11.2641 4.288 10.3821 4.288ZM18.4061 4.288C17.4881 4.288 16.7681 3.55 16.7681 2.614C16.7681 1.696 17.4881 0.958 18.4061 0.958C19.2881 0.958 20.0081 1.696 20.0081 2.614C20.0081 3.55 19.2881 4.288 18.4061 4.288Z","fill","black"],[1,"dropdown-menu"],["menu","matMenu"],["class","dropdown-menu__item","mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",1,"dropdown-menu__item",3,"click"],o,[4,"ngIf"],a,r,["mat-header-cell",""],[3,"checked","indeterminate","change"],["mat-cell","",2,"max-width","50px"],[3,"ngModel","checked","ngModelChange","change"],["mat-header-cell","","mat-sort-header",""],l,["mat-cell",""],[1,"cell-link","capital-gothic","cell-nowrap",3,"routerLink"],p,S,N,["panelClass","status-select","disableOptionCentering","",3,"disabled","placeholder"],[3,"click"],d,["class","dropdown-menu__item","mat-menu-item","",3,"routerLink",4,"ngIf"],c,I,["mat-menu-item","",1,"dropdown-menu__item",3,"routerLink"],f,R,["mat-header-row",""],["mat-row",""],[1,"no-records"],C,[1,"view__label",3,"for"],["name","view","type","radio",1,"view__input",3,"id","checked","click"]]},template:function(t,n){if(1&t){const o=e.EpF();e.TgZ(0,"div",0),e.YNc(1,an,2,2,"button",1),e.TgZ(2,"div",2)(3,"div",3),e.YNc(4,sn,1,2,"app-custom-search-multiselect",4),e.YNc(5,rn,1,2,"app-custom-search-multiselect",4),e.YNc(6,ln,1,2,"app-custom-search-multiselect",4),e.TgZ(7,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(r){return n.resetPaginationSettings(),n.onItemsSelect(r,"status")}),e.qZA(),e.TgZ(8,"button",6)(9,"mat-icon")(10,"img",7),e.NdJ("click",function(){return n.searchToggled=!n.searchToggled}),e.qZA()()()()(),e.TgZ(11,"div",8)(12,"div",9)(13,"mat-form-field",10)(14,"span",11),e._UZ(15,"img",12),e.qZA(),e.TgZ(16,"input",13,14),e.NdJ("input",function(){e.CHM(o);const r=e.MAs(17);return e.KtG(n.filterParamsSubject.next(r.value))}),e.qZA()()(),e.YNc(18,dn,16,5,"div",15),e.qZA(),e.TgZ(19,"div",16)(20,"table",17),e.NdJ("matSortChange",function(r){return n.sortBy(r)}),e.ynx(21,18),e.YNc(22,Pn,2,2,"th",19),e.YNc(23,Nn,2,2,"td",20),e.BQk(),e.ynx(24,21),e.YNc(25,Cn,2,0,"th",22),e.YNc(26,un,3,4,"td",23),e.BQk(),e.ynx(27,24),e.YNc(28,On,2,0,"th",22),e.YNc(29,mn,2,1,"td",23),e.BQk(),e.ynx(30,25),e.YNc(31,An,2,0,"th",22),e.YNc(32,Mn,2,1,"td",23),e.BQk(),e.ynx(33,26),e.YNc(34,In,2,0,"th",22),e.YNc(35,fn,5,5,"td",23),e.BQk(),e.ynx(36,27),e.YNc(37,Rn,2,0,"th",19),e.YNc(38,xn,10,5,"td",23),e.BQk(),e.YNc(39,Un,1,0,"tr",28),e.YNc(40,vn,1,0,"tr",29),e.qZA(),e.YNc(41,$n,2,0,"div",30),e.qZA(),e.TgZ(42,"div",31)(43,"div",32)(44,"span"),e.SDv(45,33),e.qZA(),e.YNc(46,Gn,3,4,"label",34),e.qZA(),e.TgZ(47,"div",35)(48,"wo-paginator",36),e.NdJ("changePage",function(r){return n.search.page=r.page-1,n.loadData()}),e.qZA()()()()}2&t&&(e.xp6(1),e.Q6J("ngIf",n.canAction("create","roles")),e.xp6(3),e.Q6J("ngIf",(null==n.role_ids?null:n.role_ids.length)>0),e.xp6(1),e.Q6J("ngIf",(null==n.role_ids?null:n.role_ids.length)>0),e.xp6(1),e.Q6J("ngIf",(null==n.role_types?null:n.role_types.length)>0),e.xp6(1),e.Q6J("data",n.statuses)("label",n.statusLabel),e.xp6(1),e.Q6J("disableRipple",!0),e.xp6(4),e.Q6J("ngClass",e.VKq(22,wn,!n.searchToggled)),e.xp6(6),e.Q6J("ngIf",(null==n.selectedItems.selected?null:n.selectedItems.selected.length)>0),e.xp6(2),e.Q6J("dataSource",n.dataSource)("matSortActive",n.search.sort)("matSortDirection",n.direction),e.xp6(19),e.Q6J("matHeaderRowDef",n.displayedColumns),e.xp6(1),e.Q6J("matRowDefColumns",n.displayedColumns),e.xp6(1),e.Q6J("ngIf",0===(null==n.dataSource?null:n.dataSource.length)),e.xp6(
15),e.Q6J("ngForOf",n.pageSizeOptions),e.xp6(2),e.Q6J("current",n.currentPage+1)("last",n.numberOfPages)("count",n.numberOfRowsAtAll)("length",null==n.search?null:n.search.pageSize)("limit",null==n.search?null:n.search.pageSize)("pageSizeOptions",n.pageSizeOptions))},dependencies:[P.mk,P.sg,P.O5,s.JJ,s.On,Y.lW,te.oG,Q.Hw,h.KE,h.qo,h.R9,L.Nt,w.VK,w.OP,w.p6,k.gD,ee.ey,H.YE,H.nU,E.BZ,E.fO,E.as,E.w1,E.Dz,E.nj,E.ge,E.ev,E.XQ,E.Gk,M.rH,M.yS,pe.H,Ee.o],styles:[".roles[_ngcontent-%COMP%]{padding-bottom:40px;position:relative}.roles__header[_ngcontent-%COMP%]{display:flex;column-gap:60px}@media (max-width: 1439px){.roles__header[_ngcontent-%COMP%]{column-gap:20px}}.roles__filters[_ngcontent-%COMP%]{display:flex;column-gap:20px;flex:0 0 80%;flex:1;flex-wrap:wrap}@media (min-width: 1180px){.roles__filters[_ngcontent-%COMP%]{flex-wrap:nowrap}}@media (min-width: 1440px){.roles__filters[_ngcontent-%COMP%]{column-gap:40px;justify-content:flex-start;width:100%}}.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{flex:1;max-width:260px}@media (min-width: 1440px){.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{flex:1;max-width:220px}}@media (min-width: 1600px){.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{flex:1;max-width:260px}}@media (max-width: 1180px){.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{flex:0 0 44%;max-width:unset}}@media (max-width: 940px){.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{flex:0 0 42%;max-width:unset}}.roles__hidden[_ngcontent-%COMP%]{display:flex;flex-direction:row-reverse;justify-content:space-between}.table-wrap[_ngcontent-%COMP%]{overflow-x:auto;white-space:nowrap;padding-bottom:5px;position:relative}table[_ngcontent-%COMP%]{width:100%;table-layout:auto}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%], table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-size:16px;padding:0 10px;text-align:left;border:none;text-overflow:ellipsis;overflow:hidden}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-weight:700;color:#000;border-bottom:1px solid #000}[_nghost-%COMP%]     table.mat-table tbody tr:first-child td{padding-top:18px!important}th.mat-header-cell[_ngcontent-%COMP%]:first-of-type, td.mat-cell[_ngcontent-%COMP%]:first-of-type, td.mat-footer-cell[_ngcontent-%COMP%]:first-of-type{padding-left:10px}[_nghost-%COMP%]     .mat-table tbody tr:nth-child(odd){background:#EAF2FC}[_nghost-%COMP%]     .mat-table .mat-sort-header-content{text-align:left}[_nghost-%COMP%]     .mat-button-ripple.mat-ripple, [_nghost-%COMP%]     .mat-button-focus-overlay{display:none}.cell-link[_ngcontent-%COMP%]{font-size:14px;color:#144a90;text-decoration:none;cursor:pointer}.cell-nowrap[_ngcontent-%COMP%]{white-space:nowrap}.table-sort[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;align-items:center;margin-top:15px;gap:40px}.view__title[_ngcontent-%COMP%]{font-size:1rem;font-weight:300}.view__label[_ngcontent-%COMP%]{position:relative;padding:5px;height:30px;border:1px solid #fff;font-size:1rem;font-weight:300;line-height:24px;transition:all .2s linear;margin-right:3px;
1cursor:pointer}.view__input[_ngcontent-%COMP%]{position:absolute;opacity:0;cursor:pointer}.view[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]:has(input:checked){background:#D9EAFF}[_nghost-%COMP%]     wo-paginator .wo-paginator__link{background:none;border:none;font-size:16px;padding:4px}[_nghost-%COMP%]     wo-paginator .wo-paginator__link:hover{background:none;border:none}[_nghost-%COMP%]     wo-paginator .wo-paginator__item_disabled .wo-paginator__link:hover{background:none;border:none!important}[_nghost-%COMP%]     wo-paginator .wo-paginator__item_active .wo-paginator__link{background:#D9EAFF!important;box-shadow:none!important;color:#000!important}[_nghost-%COMP%]     .search-input__container{display:flex;justify-content:flex-end;height:40px}[_nghost-%COMP%]     .search-input__container.search-input__container_hidden{visibility:hidden;height:40px!important}[_nghost-%COMP%]     .search-input__container .mat-form-field{width:unset!important}[_nghost-%COMP%]     .search-input__container .search-input img{width:20px;height:20px;transform:translateY(2px)}[_nghost-%COMP%]     .search-input__container .search-input .mat-form-field-flex{width:390px;padding:0 13px;border-radius:0;border-bottom:none;background:#F3F3F3}[_nghost-%COMP%]     .search-input__container .search-input .mat-form-field-wrapper{padding-bottom:0}[_nghost-%COMP%]     .search-input__container .search-input .mat-input-element{color:#a6a6a6;font-family:Capital Gothic;font-size:16px;font-style:normal;font-weight:300;line-height:normal;letter-spacing:.16px}[_nghost-%COMP%]     .search-input__container .search-input .mat-form-field-infix{padding:9px;border-top:0}[_nghost-%COMP%]     .search-input__container .search-input .mat-form-field-underline{display:none}[_nghost-%COMP%]     .mat-menu-trigger{padding:0;min-width:unset}.crop-text[_ngcontent-%COMP%]{min-width:5em;max-width:18em;width:100%;text-transform:none!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (min-width: 1800px){.crop-text[_ngcontent-%COMP%]{max-width:35em}}.btn[_ngcontent-%COMP%]{height:50px;margin:30px 0}[_nghost-%COMP%]     table .mat-checkbox-inner-container{height:12px;width:12px}[_nghost-%COMP%]     table .mat-checkbox-ripple{display:none}[_nghost-%COMP%]     table .mat-checkbox-frame{border-radius:0;border:0;background:#DDDDDD}[_nghost-%COMP%]     table .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background, [_nghost-%COMP%]     table .mat-checkbox-checked.mat-accent .mat-checkbox-background{background:#D6117F;border-radius:0}[_nghost-%COMP%]     table .mat-checkbox-checkmark{display:none}[_nghost-%COMP%]     table .mat-select-trigger{padding:5px 10px 5px 5px;color:#fff!important;display:flex;text-align:center;height:20px;width:130px;text-transform:uppercase;font-size:14px}[_nghost-%COMP%]     table .active .mat-select-trigger{background:#144A90}[_nghost-%COMP%]     table .disabled .mat-select-trigger{background:#A8B1C1}[_nghost-%COMP%]     table .mat-select-value{color:#fff!important}[_nghost-%COMP%]     table .mat-select-placeholder{color:#fff}.multi-actions[_ngcontent-%COMP%]{display:flex;gap:15px;align-items:center}.multi-actions__label[_ngcontent-%COMP%]{text-transform:uppercase;font-weight:300}[_nghost-%COMP%]     .mat-form-field{width:100%}[_nghost-%COMP%]     .mat-select-arrow{border-image-source:url(/assets/pic/icons/arrow-white.svg)!important;transform:rotate(180deg)}[_nghost-%COMP%]     mat-select[aria-expanded=true] .mat-select-arrow{transform:rotate(0)}"]}),_})();var _e=T(51432),oe=T(30780),yn=T(9608),Bn=T(42410),kn=T(88670),Yn=T(78524);function qn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",54),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.setUserStatus(null,"active"))}),e.SDv(1,55),e.qZA()}if(2&_){const t=e.oxw(2);e.xp6(1),e.pQV(t.numberOfSelectedUsers>1?"All":""),e.QtT(1)}}function Xn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",54),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.setUserStatus(null,"deleted"))}),e.SDv(1,56),e.qZA()}if(2&_){const t=e.oxw(2);e.xp6(1),e.pQV(t.numberOfSelectedUsers>1?"All":""),e.QtT(1)}}function zn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",54),e.NdJ("click",function(){e.CHM(t);const o=e.oxw(2);return e.KtG(o.setUserStatus(null,"disabled"))}),e.SDv(1,57),e.qZA()}if(2&_){const t=e.oxw(2);e.xp6(1),e.pQV(t.numberOfSelectedUsers>1?"All":""),e.QtT(1)}}function Jn(_,i){if(1&_&&(e.TgZ(0,"div",44)(1,"span",45),e.tHW(2,46),e._UZ(3,"span"),e.N_p(),e.qZA(),e.TgZ(4,"span"),e.tHW(5,47),e._UZ(6,"b"),e.N_p(),e.qZA(),e.TgZ(7,"div")(8,"button",48),e.O4$(),e.TgZ(9,"svg",49),e._UZ(10,"path",50),e.qZA()(),e.kcU(),e.TgZ(11,"mat-menu",51,52),e.YNc(13,qn,2,1,"button",53),e.YNc(14,Xn,2,1,"button",53),e.YNc(15,zn,2,1,"button",53),e.qZA()()()),2&_){const t=e.MAs(12),n=e.oxw();
1e.xp6(3),e.pQV(n.numberOfSelectedUsers),e.QtT(2),e.xp6(5),e.Q6J("matMenuTriggerFor",t),e.xp6(5),e.Q6J("ngIf",n.canAction("edit","users")),e.xp6(1),e.Q6J("ngIf",n.canAction("delete","users")),e.xp6(1),e.Q6J("ngIf",n.canAction("edit","users"))}}function Qn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"th",58)(1,"mat-checkbox",59),e.NdJ("change",function(o){e.CHM(t);const a=e.oxw();return e.KtG(a.onMainCheckboxChange(o))}),e.qZA()()}if(2&_){const t=e.oxw();e.xp6(1),e.Q6J("checked",t.isAllSelected)("indeterminate",t.isSomeSelected)}}function Hn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",60)(1,"mat-checkbox",61),e.NdJ("ngModelChange",function(o){const r=e.CHM(t).$implicit;return e.KtG(r.selected=o)}),e.qZA()()}if(2&_){const t=i.$implicit;e.xp6(1),e.Q6J("ngModel",t.selected)("disabled","1"===t.is_admin)}}function Vn(_,i){1&_&&(e.TgZ(0,"th",62),e.SDv(1,63),e.qZA())}function Kn(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",64)(1,"a",65),e.NdJ("click",function(){const a=e.CHM(t).$implicit,r=e.oxw();return e.KtG(r.viewUserDetails(a.id))}),e._uU(2),e.qZA()()}if(2&_){const t=i.$implicit;e.xp6(2),e.hij(" ",t.name," ")}}function Wn(_,i){1&_&&(e.TgZ(0,"th",62),e.SDv(1,66),e.qZA())}function jn(_,i){if(1&_&&(e.TgZ(0,"td",67),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.xp6(1),e.hij(" ",t.role," ")}}function e_(_,i){1&_&&(e.TgZ(0,"th",62),e.SDv(1,68),e.qZA())}function t_(_,i){if(1&_&&(e.TgZ(0,"td",67),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.xp6(1),e.hij(" ",t.created_at," ")}}function n_(_,i){1&_&&(e.TgZ(0,"th",62),e.SDv(1,69),e.qZA())}function __(_,i){if(1&_&&(e.TgZ(0,"td",67),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.xp6(1),e.hij(" ",t.email," ")}}function o_(_,i){1&_&&(e.TgZ(0,"th",62),e.SDv(1,70),e.qZA())}function i_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",64)(1,"mat-select",71)(2,"div",72),e.NdJ("click",function(o){const r=e.CHM(t).$implicit;return e.oxw().setUserStatus(r,"active"==r.status?"disabled":"active"),e.KtG(o.stopPropagation())}),e.TgZ(3,"mat-option"),e._uU(4),e.qZA()()()()}if(2&_){const t=i.$implicit,n=e.oxw();e.xp6(1),e.Tol("active"==t.status?"active":"disabled"),e.Q6J("disabled",!n.canAction("edit","users"))("placeholder",t.status),e.xp6(3),e.hij("","active"==t.status?"DISABLE":"ACTIVATE"," ")}}function a_(_,i){1&_&&(e.TgZ(0,"th",58),e.SDv(1,73),e.qZA())}function s_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",54),e.NdJ("click",function(){e.CHM(t);const o=e.oxw().$implicit,a=e.oxw();return e.KtG(a.copyUser(o.id))}),e.SDv(1,76),e.qZA()}}function r_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",54),e.NdJ("click",function(){e.CHM(t);const o=e.oxw().$implicit,a=e.oxw();return e.KtG(a.setUserStatus(o,"deleted"))}),e.SDv(1,77),e.qZA()}}function l_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",54),e.NdJ("click",function(){e.CHM(t);const o=e.oxw().$implicit,a=e.oxw();return e.KtG(a.editUser(o.id))}),e.SDv(1,78),e.qZA()}}function T_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",64)(1,"button",48),e.O4$(),e.TgZ(2,"svg",49),e._UZ(3,"path",50),e.qZA()(),e.kcU(),e.TgZ(4,"mat-menu",51,52),e.YNc(6,s_,2,0,"button",53),e.YNc(7,r_,2,0,"button",53),e.YNc(8,l_,2,0,"button",53),e.TgZ(9,"button",74),e.NdJ("click",function(){const a=e.CHM(t).$implicit,r=e.oxw();return e.KtG(r.viewUserDetails(a.id))}),e.SDv(10,75),e.qZA()()()}if(2&_){const t=i.$implicit,n=e.MAs(5),o=e.oxw();e.xp6(1),e.Q6J("matMenuTriggerFor",n),e.xp6(5),e.Q6J("ngIf",o.canAction("create","users")),e.xp6(1),e.Q6J("ngIf",o.canAction("delete","users")&&"1"!==t.is_admin),e.xp6(1),e.Q6J("ngIf",o.canAction("create","users")&&"1"!==t.is_admin),e.xp6(1),e.s9C("routerLink",t.id)}}function c_(_,i){1&_&&e._UZ(0,"tr",79)}function S_(_,i){1&_&&e._UZ(0,"tr",80)}function p_(_,i){1&_&&(e.TgZ(0,"div",81),e.SDv(1,82),e.qZA())}function E_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"label",83)(1,"input",84),e.NdJ("change",function(){const a=e.CHM(t).index,r=e.oxw();return r.filterParams.pageSize=r.pageSizeOptions[a],r.resetPaginationSettings(),e.KtG(r.refreshTable())}),e.qZA(),e._uU(2),e.qZA()}if(2&_){const t=i.index,n=e.oxw();e.MGl("for","view-",n.pageSizeOptions[t],""),e.xp6(1),e.MGl("id","view-",n.pageSizeOptions[t],""),e.Q6J("checked",n.pageSizeOptions[t]==n.filterParams.pageSize),e.xp6(1),e.Oqu(n.pageSizeOptions[t])}}const g_=function(_){return{rotate:_}},d_=function(_){return{"search-input__container_hidden":_}};let P_=(()=>{class _{constructor(t,n,o,a,r,l){this.getAllUsersPaginatedUsecase=t,this.router=n,this.matDialog=o,this.changeUserStatusUsecase=a,this.getFilteringParamsUsecase=r,this.rolesService=l,this.users=[],this.statuses=["active","disabled"],this.menuOpened=!1,this.filterParams={page:0,pageSize:10,
1common:"",sort_field:"",sort_direction:"",condition:{}},this.filterParamsSubject=new ce.X(this.filterParams.common),this.nameLabel="Name",this.roleLabel="Role",this.statusLabel="Status",this.displayedColumns=["selected","name","role","email","created_at","status","actions"],this.searchToggled=!1,this.direction="desc",this.numberOfRowsAtAll=0,this.currentPage=0,this.pageSizeOptions=[10,30,50],this.numberOfPages=0}ngOnInit(){this.refreshFilters(),this.refreshTable(),this.filterParamsSubject.pipe((0,ne.b)(800),(0,Se.x)()).subscribe(t=>{this.filterParams.common=t,this.resetPaginationParams(),this.refreshTable()})}resetPaginationParams(){this.filterParams.page=0,this.currentPage=0}selectAllUsers(){this.users.forEach(t=>{"1"!==t.is_admin&&(t.selected=!0)})}deselectAllUsers(){this.users.forEach(t=>{"1"!==t.is_admin&&(t.selected=!1)})}onMainCheckboxChange(t){t.checked?this.selectAllUsers():this.deselectAllUsers()}get isSomeSelected(){return this.users.some(t=>!0===t.selected)&&!this.isAllSelected}get isAllSelected(){return this.users.every(t=>{})}get numberOfSelectedUsers(){return this.users.filter(t=>!0===t.selected).length}refreshTable(){this.filterParams.condition=_e.g.removeEmptyProperties(this.filterParams.condition),this.getAllUsersPaginatedUsecase.execute(_e.g.removeEmptyProperties(this.filterParams)).subscribe(t=>{this.currentPage=t.pagination.current_page,this.numberOfPages=t.pagination.last_page,this.numberOfRowsAtAll=t.pagination.rows_total,this.users=t.rows,this.users.forEach(n=>{n.selected=!1})})}sort(t){this.filterParams.sort_direction=t.direction,this.filterParams.sort_field=t.direction?t.active:"",this.refreshTable()}setUserStatus(t,n){let o={ids:null,status:n};o.ids=t?[t.id]:this.users.filter(a=>!0===a.selected).map(a=>a.id),this.changeUserStatus(o)}changeUserStatus(t){this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">" + ("active" === t.status ? "activate" : "deleted" === t.status ? "delete" : "disable") + "</span> this " + (t.ids.length < 2 ? "user" : "users") + "?"}}).afterClosed().subscribe(n=>{n&&this.changeUserStatusUsecase.execute(t).subscribe(o=>{"deleted"===t.status&&this.refreshFilters(),this.refreshTable()})})}createNewUser(){this.router.navigate(["main/settings/user/edit/new"])}copyUser(t){this.router.navigate(["main/settings/user/edit/new"],{queryParams:{id:t}})}editUser(t){this.router.navigate(["main/settings/user/edit/"+t])}viewUserDetails(t){this.router.navigate(["main/settings/user/"+t])}get selectDateRangeLabel(){if(this.filterParams.condition.created_at){if(this.filterParams.condition.created_at.from&&this.filterParams.condition.created_at.to)return`${(0,oe.Z)(new Date(this.filterParams.condition.created_at.from),"dd/MM/yyyy")} - ${(0,oe.Z)(new Date(this.filterParams.condition.created_at.to),"dd/MM/yyyy")}`;if(this.filterParams.condition.created_at.from)return`${(0,oe.Z)(new Date(this.filterParams.condition.created_at.from),"dd/MM/yyyy")}`}return""}resetPaginationSettings(){this.filterParams.page=0,this.currentPage=0}refreshFilters(){this.getFilteringParamsUsecase.execute().subscribe(t=>{this.userNames=t.names,this.userEmails=t.emails,this.roles=t.roles})}filterRows(t,n){this.filterParams.condition[n]=t,this.refreshTable()}setDate(t){this.matDateTrigger.closeMenu(),this.filterParams.condition.created_at=_e.g.removeEmptyProperties(t),this.refreshTable()}canAction(t,n){return this.rolesService.canAction(t,n)}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(yn.K),e.Y36(M.F0),e.Y36(F.uw),e.Y36(Bn.z),e.Y36(kn.L),e.Y36(G.f))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-users-tab"]],viewQuery:function(t,n){if(1&t&&e.Gf(w.p6,5),2&t){let o;e.iGM(o=e.CRH())&&(n.matDateTrigger=o.first)}},decls:59,vars:31,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R,C,u,O,m;return i="New User ",t=" Created " + "\ufffd#10\ufffd" + "" + "\ufffd0\ufffd" + "" + "\ufffd/#10\ufffd" + "" + "\ufffd#11\ufffd" + "" + "\ufffd/#11\ufffd" + "",n="show ",o="Selected items: " + "\ufffd#3\ufffd" + "" + "\ufffd0\ufffd" + "" + "\ufffd/#3\ufffd" + "",a="" + "\ufffd#6\ufffd" + "Actions" + "\ufffd/#6\ufffd" + "",r="Activate " + "\ufffd0\ufffd" + " ",l="Delete " + "\ufffd0\ufffd" + " ",p="Disable " + "\ufffd0\ufffd" + " ",S="Name",N="Role",d="Created",c="Email",I="Status",f="Actions",R="View Details ",C="Copy ",u="Delete ",O="Edit ",m="No records",[[1,"roles"],["mat-raised-button","",1,"btn","btn_blue","capital-gothic",3,"click"],i,[1,"roles__header"],[1,"roles__filters"],[3,"data","label","selectedItems"],[1,"search-select",3,"matMenuTriggerFor","menuOpened","menuClosed"],t,[1,"select-arrow",3,"ngClass"],["xPosition","after","yPosition","above",1,"date-menu"],["dateMenu","matMenu"],[3,"dateRangeChanged","click"],["matSuffix","","mat-icon-button","","aria-label","Search",1,"search",3,"disableRipple"],["src","assets/pic/icons/search-icon.svg","alt","Search",3,"click"],[1,"search-input__container",3,"ngClass"],["appearance","fill",1,"search-input"],["matPrefix",""],["src","assets/pic/icons/search-icon.svg","alt","search icon"],["placeholder","Type here","matInput","","type","text",3,"input"],["commonInput",""],[1,"table-wrap"],["class","multi-actions",4,"ngIf"],["mat-table","","matSort","",1,"user-table",3,"dataSource","matSortActive","matSortDirection","matSortChange"],["matColumnDef","selected"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","","style","max-width: 50px;",4,"matCellDef"],["matColumnDef","name"],["mat-header-cell","","mat-sort-header","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","role"],["mat-cell","","class","cell-nowrap",4,"matCellDef"],["matColumnDef","created_at"],["matColumnDef","email"],["matColumnDef","status"],["matColumnDef","actions"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["class","no-records",4,"ngIf"],[1,"table-sort"],[1,"table-view","view"],n,["class","view__label",3,"for",4,"ngFor","ngForOf"],[1,"table__paginator"],[1,"table-paginator",3,"current","last","count","length","limit","pageSizeOptions","changePage"],[1,"multi-actions"],[1,"multi-actions__label"],o,a,["mat-button","",1,"dropdown-menu__trigger",3,"matMenuTriggerFor"],["width","21","height","5","viewBox","0 0 21 5","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M2.358 4.288C1.44 4.288 0.72 3.55 0.72 2.614C0.72 1.696 1.44 0.958 2.358 0.958C3.24 0.958 3.96 1.696 3.96 2.614C3.96 3.55 3.24 4.288 2.358 4.288ZM10.3821 4.288C9.46406 4.288 8.74406 3.55 8.74406 2.614C8.74406 1.696 9.46406 0.958 10.3821 0.958C11.2641 0.958 11.9841 1.696 11.9841 2.614C11.9841 3.55 11.2641 4.288 10.3821 4.288ZM18.4061 4.288C17.4881 4.288 16.7681 3.55 16.7681 2.614C16.7681 1.696 17.4881 0.958 18.4061 0.958C19.2881 0.958 20.0081 1.696 20.0081 2.614C20.0081 3.55 19.2881 4.288 18.4061 4.288Z","fill","black"],[1,"dropdown-menu"],["menu","matMenu"],["class","dropdown-menu__item","mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",1,"dropdown-menu__item",3,"click"],r,l,p,["mat-header-cell",""],[3,"checked","indeterminate","change"],["mat-cell","",2,"max-width","50px"],[3,"ngModel","disabled","ngModelChange"],["mat-header-cell","","mat-sort-header",""],S,["mat-cell",""],[1,"capital-gothic","name_link","pointer",3,"click"],N,["mat-cell","",1,"cell-nowrap"],d,c,I,["panelClass","status-select","disableOptionCentering","",3,"disabled","placeholder"],[3,"click"],f,["mat-menu-item","",1,"dropdown-menu__item",3,"routerLink","click"],R,C,u,O,["mat-header-row",""],["mat-row",""],[1,"no-records"],m,[1,"view__label",3,"for"],["name","view","type","radio",1,"view__input",3,"id","checked","change"]]},template:function(t,n){if(1&t){const o=e.EpF();e.TgZ(0,"div",0)(1,"button",1),e.NdJ("click",function(){return n.createNewUser()}),e.SDv(2,2),e.qZA(),e.TgZ(3,"div",3)(4,"div",4)(5,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(r){return n.resetPaginationSettings(),n.filterRows(r,"name")}),e.qZA(),e.TgZ(6,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(r){return n.resetPaginationSettings(),n.filterRows(r,"role")}),e.qZA(),e.TgZ(7,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(r){return n.resetPaginationSettings(),n.filterRows(r,"email")}),e.qZA(),e.TgZ(8,"div",6),e.NdJ("menuOpened",function(){return n.menuOpened=!0})("menuClosed",function(){return n.menuOpened=!1}),e.tHW(9,7),e._UZ(10,"span")(11,"div",8),e.N_p(),e.qZA(),e.TgZ(12,"mat-menu",9,10)(14,"custom-date-range-picker",11),e.NdJ("dateRangeChanged",function(r){return n.resetPaginationSettings(),n.setDate(r)})("click",function(r){return r.stopPropagation()}),e.qZA()(),e.TgZ(15,"app-custom-search-multiselect",5),e.NdJ("selectedItems",function(r){return n.resetPaginationSettings(),n.filterRows(r,"status")}),e.qZA(),e.TgZ(16,"button",12)(17,"mat-icon")(18,"img",13),e.NdJ("click",function(){return n.searchToggled=!n.searchToggled}),e.qZA()()()()(),e.TgZ(19,"div",14)(20,"mat-form-field",15)(21,"span",16),e._UZ(22,"img",17),e.qZA(),e.TgZ(23,"input",18,19),e.NdJ("input",function(){e.CHM(o);const r=e.MAs(24);return e.KtG(n.filterParamsSubject.next(r.value))}),e.qZA()()(),e.TgZ(25,"div",20),e.YNc(26,Jn,16,5,"div",21),e.TgZ(27,"table",22),e.NdJ("matSortChange",function(r){return n.sort(r)}),e.ynx(28,23),e.YNc(29,Qn,2,2,"th",24),e.YNc(30,Hn,2,2,"td",25),e.BQk(),e.ynx(31,26),e.YNc(32,Vn,2,0,"th",27),e.YNc(33,Kn,3,1,"td",28),e.BQk(),e.ynx(34,29),e.YNc(35,Wn,2,0,"th",27),e.YNc(36,jn,2,1,"td",30),e.BQk(),e.ynx(37,31),e.YNc(38,e_,2,0,"th",27),e.YNc(39,t_,2,1,"td",30),e.BQk(),e.ynx(40,32),e.YNc(41,n_,2,0,"th",27),e.YNc(42,__,2,1,"td",30),e.BQk(),e.ynx(43,33),e.YNc(44,o_,2,0,"th",27),e.YNc(45,i_,5,5,"td",28),e.BQk(),e.ynx(46,34),e.YNc(47,a_,2,0,"th",24),e.YNc(48,T_,11,5,"td",28),e.BQk(),e.YNc(49,c_,1,0,"tr",35),e.YNc(50,S_,1,0,"tr",36),e.qZA(),e.YNc(51,p_,2,0,"div",37),e.qZA(),e.TgZ(52,"div",38)(53,"div",39)(54,"span"),e.SDv(55,40),e.qZA(),e.YNc(56,E_,3,4,"label",41),e.qZA(),e.TgZ(57,"div",42)(58,"wo-paginator",43),e.NdJ("changePage",function(r){return n.filterParams.page=r.page-1,n.refreshTable()}),e.qZA()()()()}if(2&t){const o=e.MAs(13);e.xp6(5),e.Q6J("data",n.userNames)("label",n.nameLabel),e.xp6(1),e.Q6J("data",n.roles)("label",n.roleLabel),e.xp6(1),e.Q6J("data",n.userEmails)("label","Email"),e.xp6(1),e.Q6J("matMenuTriggerFor",o),e.xp6(3),e.Q6J("ngClass",e.VKq(27,g_,!n.menuOpened)),e.pQV(n.selectDateRangeLabel),e.QtT(9),e.xp6(4),e.Q6J("data",n.statuses)("label",n.statusLabel),e.xp6(1),e.Q6J("disableRipple",!0),e.xp6(3),e.Q6J("ngClass",e.VKq(29,d_,!n.searchToggled)),e.xp6(7),e.Q6J("ngIf",n.numberOfSelectedUsers>0),e.xp6(1),e.Q6J("dataSource",n.users)("matSortActive",n.filterParams.sort)("matSortDirection",n.direction),e.xp6(22),e.Q6J("matHeaderRowDef",n.displayedColumns),e.xp6(1),e.Q6J("matRowDefColumns",n.displayedColumns),e.xp6(1),e.Q6J("ngIf",0===n.users.length),e.xp6(
15),e.Q6J("ngForOf",n.pageSizeOptions),e.xp6(2),e.Q6J("current",n.filterParams.page+1)("last",n.numberOfPages)("count",n.numberOfRowsAtAll)("length",n.filterParams.pageSize)("limit",n.filterParams.pageSize)("pageSizeOptions",n.pageSizeOptions)}},dependencies:[P.mk,P.sg,P.O5,s.JJ,s.On,Y.lW,te.oG,Q.Hw,h.KE,h.qo,h.R9,L.Nt,w.VK,w.OP,w.p6,k.gD,ee.ey,H.YE,H.nU,E.BZ,E.fO,E.as,E.w1,E.Dz,E.nj,E.ge,E.ev,E.XQ,E.Gk,M.rH,pe.H,Yn.D,Ee.o],styles:[".table-wrap[_ngcontent-%COMP%]{overflow-x:auto;white-space:nowrap;padding-bottom:5px;margin-top:20px;position:relative;padding-top:20px}table[_ngcontent-%COMP%]{width:100%;table-layout:auto}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%], table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-size:16px;padding:0 10px;text-align:left;border:none;text-overflow:ellipsis;overflow:hidden}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-weight:700;color:#000;border-bottom:1px solid #000}table[_ngcontent-%COMP%]   .align-top[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]   .cell-link[_ngcontent-%COMP%], table[_ngcontent-%COMP%]   .align-top[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]   .multi-cell[_ngcontent-%COMP%]{display:block;margin-bottom:10px;margin-top:10px}table[_ngcontent-%COMP%]   .align-top[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]   .cell-link[_ngcontent-%COMP%]:not(:last-child), table[_ngcontent-%COMP%]   .align-top[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]   .multi-cell[_ngcontent-%COMP%]:not(:last-child){margin-bottom:26px}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]   .note[_ngcontent-%COMP%]{font-size:12px;color:#a6a6a6}[_nghost-%COMP%]     table.mat-table tbody tr:first-child td{padding-top:18px!important}th.mat-header-cell[_ngcontent-%COMP%]:first-of-type, td.mat-cell[_ngcontent-%COMP%]:first-of-type, td.mat-footer-cell[_ngcontent-%COMP%]:first-of-type{padding-left:10px}[_nghost-%COMP%]     .mat-table tbody tr:nth-child(odd){background:#EAF2FC}[_nghost-%COMP%]     .mat-table .mat-sort-header-content{text-align:left}[_nghost-%COMP%]     .mat-button-ripple.mat-ripple, [_nghost-%COMP%]     .mat-button-focus-overlay{display:none}.cell-link[_ngcontent-%COMP%]{font-size:14px;color:#144a90;text-decoration:none;cursor:pointer}.cell-nowrap[_ngcontent-%COMP%]{white-space:nowrap}table[_ngcontent-%COMP%]   td.cell-center[_ngcontent-%COMP%]{text-align:center}.table-sort[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;align-items:center;margin-top:15px;gap:40px}.view__title[_ngcontent-%COMP%]{font-size:1rem;font-weight:300}.view__label[_ngcontent-%COMP%]{position:relative;padding:5px;height:30px;border:1px solid #fff;font-size:1rem;font-weight:300;line-height:24px;transition:all .2s linear;margin-right:3px;
1cursor:pointer}.view__input[_ngcontent-%COMP%]{position:absolute;opacity:0;cursor:pointer}.view[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]:has(input:checked){background:#D9EAFF}[_nghost-%COMP%]     wo-paginator .wo-paginator__link{background:none;border:none;font-size:16px;padding:4px}[_nghost-%COMP%]     wo-paginator .wo-paginator__link:hover{background:none;border:none}[_nghost-%COMP%]     wo-paginator .wo-paginator__item_disabled .wo-paginator__link:hover{background:none;border:none!important}[_nghost-%COMP%]     wo-paginator .wo-paginator__item_active .wo-paginator__link{background:#D9EAFF!important;box-shadow:none!important;color:#000!important}.roles[_ngcontent-%COMP%]{overflow:hidden}.roles__header[_ngcontent-%COMP%]{display:flex;column-gap:20px;width:100%;position:relative}.roles__filters[_ngcontent-%COMP%]{display:flex;column-gap:20px;flex-wrap:wrap!important;width:100%}.roles__filters[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{display:flex;justify-content:flex-end}.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{width:31%;max-width:300px}@media (min-width: 1700px){.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{max-width:260px}}@media (max-width: 1180px){.roles__filters[_ngcontent-%COMP%]   app-custom-search-multiselect[_ngcontent-%COMP%]{flex:0 0 48%;max-width:unset}}.roles__filters[_ngcontent-%COMP%]   .search-select[_ngcontent-%COMP%]{min-width:260px;max-width:300px;padding-left:.75em;padding-right:.75em;background-color:#d9eaff;width:31%;height:42px;display:flex;align-items:center;margin-top:4px!important;box-sizing:border-box;cursor:pointer;margin-bottom:2em}@media (min-width: 1700px){.roles__filters[_ngcontent-%COMP%]   .search-select[_ngcontent-%COMP%]{max-width:260px}}@media (max-width: 1180px){.roles__filters[_ngcontent-%COMP%]   .search-select[_ngcontent-%COMP%]{flex:0 0 48%;max-width:unset}}.roles__filters[_ngcontent-%COMP%]   .search-select[_ngcontent-%COMP%]   span[_ngcontent-%COMP%]{margin-left:auto;color:#d6117f}.roles__filters[_ngcontent-%COMP%]   .search-select[_ngcontent-%COMP%]   .select-arrow[_ngcontent-%COMP%]{height:8px;width:13px;background:url(/en/assets/pic/icons/arrow.svg) no-repeat;margin-left:10px}.roles__filters[_ngcontent-%COMP%]   .search-select[_ngcontent-%COMP%]   .rotate[_ngcontent-%COMP%]{transform:rotate(180deg)}  .search-input__container{display:flex;justify-content:flex-end}  .search-input__container.search-input__container_hidden{visibility:hidden;height:0}  .search-input__container .search-input img{width:20px;height:20px;transform:translateY(2px)}  .search-input__container .search-input .mat-form-field-flex{width:390px;padding:0 13px;border-radius:0;border-bottom:none;background:#F3F3F3}  .search-input__container .search-input .mat-form-field-wrapper{padding-bottom:0}  .search-input__container .search-input .mat-input-element{color:#a6a6a6;font-family:Capital Gothic;font-size:16px;font-style:normal;font-weight:300;line-height:normal;letter-spacing:.16px}  .search-input__container .search-input .mat-form-field-infix{padding:9px;border-top:0}  .search-input__container .search-input .mat-form-field-underline{display:none}[_nghost-%COMP%]     .mat-menu-trigger{padding:0;min-width:unset}.crop-text[_ngcontent-%COMP%]{min-width:5em;max-width:18em;width:100%;text-transform:none!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media (min-width: 1800px){.crop-text[_ngcontent-%COMP%]{max-width:35em}}.btn[_ngcontent-%COMP%]{height:50px;margin:30px 0}[_nghost-%COMP%]     .user-table .mat-checkbox-inner-container{height:12px;width:12px}[_nghost-%COMP%]     .user-table .mat-checkbox-ripple{display:none}[_nghost-%COMP%]     .user-table .mat-checkbox-frame{border-radius:0;border:0;background:#DDDDDD}[_nghost-%COMP%]     .user-table .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background, [_nghost-%COMP%]     .user-table .mat-checkbox-checked.mat-accent .mat-checkbox-background{background:#D6117F;border-radius:0}[_nghost-%COMP%]     .user-table .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background svg, [_nghost-%COMP%]     .user-table .mat-checkbox-checked.mat-accent .mat-checkbox-background svg{display:none}[_nghost-%COMP%]     .user-table .mat-select-trigger{background:#144A90;padding:5px 10px 5px 5px;color:#fff!important;display:flex;text-align:center;height:20px;width:130px;text-transform:uppercase;font-size:14px}[_nghost-%COMP%]     .user-table .active .mat-select-trigger{background:#144A90}[_nghost-%COMP%]     .user-table .disabled .mat-select-trigger{background:#A8B1C1}[_nghost-%COMP%]     .user-table .mat-select-value{color:#fff!important}[_nghost-%COMP%]     .user-table .mat-select-placeholder{color:#fff}[_nghost-%COMP%]     .user-table .name_link{color:#144a90;text-decoration:none;cursor:pointer}.multi-actions[_ngcontent-%COMP%]{display:flex;gap:15px;align-items:center;margin-bottom:10px;position:absolute;top:-10px;z-index:2}.multi-actions__label[_ngcontent-%COMP%]{text-transform:uppercase}[_nghost-%COMP%]     .mat-form-field{width:100%}  .user-table_select{margin-top:23px;background-color:#fff;box-shadow:none;border-radius:0}  .user-table_select .mat-option.mat-active{background:rgba(0,0,0,0)}  .date-menu{width:100%;max-width:100%;padding:10px 20px}  .selector-data{color:#d6117f;margin-left:auto}  .mat-select-panel{border-radius:0!important}[_nghost-%COMP%]     .mat-select-arrow{border-image-source:url(/assets/pic/icons/arrow-white.svg)!important;transform:rotate(180deg)}[_nghost-%COMP%]     mat-select[aria-expanded=true] .mat-select-arrow{transform:rotate(0)}"]}),_})();const N_=["tabs"];function C_(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.company_information)}}function u_(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.roles)}}function O_(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.users)}}function m_(_,i){1&_&&(e.TgZ(0,"mat-tab",10),e._UZ(1,"app-roles-tab"),e.qZA())}function A_(_,i){1&_&&(e.TgZ(0,"mat-tab",11),e._UZ(1,"app-users-tab"),e.qZA())}let M_=(()=>{class _{constructor(t,n,o,a){this.activatedRoute=t,this.breadcrumbs=n,this.rolesService=o,this.tooltipsService=a,this.title="Company"}canAction(t,n){return this.rolesService.canAction(t,n)}ngOnInit(){setTimeout(()=>{this.tabGroup.selectedTabChange.subscribe(t=>{this.breadcrumbsSetup(t.index),this.titleSetup(t.index)}),this.activatedRoute.queryParams.subscribe(t=>{this.tabGroup.selectedIndex=t.page,this.breadcrumbsSetup(this.tabGroup.selectedIndex),this.titleSetup(this.tabGroup.selectedIndex)})},0)}
1breadcrumbsSetup(t){this.breadcrumbs.setLinks([{route:"/",text:"HOME"},{route:"/main/settings",text:"SETTINGS"},{text:0==t?"company information":1==t?"roles":"users"}])}titleSetup(t){this.title=0==t?"Company information":1==t?"Roles":"Users"}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(M.gz),e.Y36(y.W),e.Y36(G.f),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-company"]],viewQuery:function(t,n){if(1&t&&e.Gf(N_,5),2&t){let o;e.iGM(o=e.CRH())&&(n.tabGroup=o.first)}},features:[e._Bn([{provide:e.QbO,useValue:"NoopAnimations"}])],decls:15,vars:7,consts:function(){let i,t,n;return i="COMPANY INFORMATION",t="ROLES",n="USERS",[[1,"company"],[1,"title","flex","margin-top"],[1,"title-text","margin-right","capital-gothic"],[4,"ngIf"],[1,"breadcrumbs"],[1,"group",3,"animationDuration"],["tabs",""],["label",i],["label",t,4,"ngIf"],["label",n,4,"ngIf"],["label",t],["label",n]]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e._uU(3),e.YNc(4,C_,3,1,"app-tooltip",3),e.YNc(5,u_,3,1,"app-tooltip",3),e.YNc(6,O_,3,1,"app-tooltip",3),e.qZA(),e.TgZ(7,"div",4),e._UZ(8,"wo-breadcrumbs"),e.qZA()(),e.TgZ(9,"mat-tab-group",5,6)(11,"mat-tab",7),e._UZ(12,"app-company-information-tab"),e.qZA(),e.YNc(13,m_,2,0,"mat-tab",8),e.YNc(14,A_,2,0,"mat-tab",9),e.qZA()()),2&t&&(e.xp6(3),e.hij("",n.title," "),e.xp6(1),e.Q6J("ngIf",(null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.company_information)&&"Company information"===n.title),e.xp6(1),e.Q6J("ngIf",(null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.roles)&&"Roles"===n.title),e.xp6(1),e.Q6J("ngIf",(null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.users)&&"Users"===n.title),e.xp6(3),e.Q6J("animationDuration","0"),e.xp6(4),e.Q6J("ngIf",n.canAction("view","roles")),e.xp6(1),e.Q6J("ngIf",n.canAction("view","users")))},dependencies:[P.O5,Z.SP,Z.uX,U.K,B.g,Kt,Zn,P_],styles:[".company[_ngcontent-%COMP%]{padding:0 60px 40px 0;font-family:Arial,Helvetica Neue,sans-serif}@media (max-width: 960px){.company[_ngcontent-%COMP%]{padding-right:1rem}}.title-text[_ngcontent-%COMP%]{font-size:44px;font-style:normal;font-weight:700;line-height:1;letter-spacing:.44px;text-transform:uppercase;margin-bottom:23px!important}.title-text[_ngcontent-%COMP%]     app-tooltip .right{top:13px}.profile-title[_ngcontent-%COMP%]{font-size:33px;font-weight:700}[_nghost-%COMP%]     .mat-tab-label{padding:0 10px!important}"]}),_})();var de=T(37542),I_=T(44627),Pe=T(98990),f_=T(72305),R_=T(97726);function h_(_,i){if(1&_&&(e.ynx(0),e._uU(1),e.BQk()),2&_){const t=e.oxw();e.xp6(1),e.Oqu(t.title)}}function F_(_,i){if(1&_&&(e.ynx(0),e._uU(1),e.BQk()),2&_){const t=e.oxw();e.xp6(1),e.Oqu(t.name)}}function D_(_,i){1&_&&(e.ynx(0),e.SDv(1,35),e.BQk()),2&_&&(e.xp6(1),e.pQV("New"),e.QtT(1))}function b_(_,i){1&_&&(e.ynx(0),e.SDv(1,36),e.BQk())}function L_(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.new_role)}}function x_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",8)(1,"p",9),e.SDv(2,37),e.qZA(),e.TgZ(3,"app-custom-search-select",38),e.NdJ("selectedItem",function(o){e.CHM(t);const a=e.oxw();return e.KtG(a.copyRole(o))}),e.qZA()()}if(2&_){const t=e.oxw();let n,o,a;e.xp6(3),e.Q6J("data",t.roles)("label","Select Role")("errors",null==(n=t.formData.get("copy"))?null:n.errors)("touched",null==(o=t.formData.get("copy"))?null:o.touched)("value",null==(a=t.formData.get("copy"))?null:a.value)}}function U_(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,39),e.qZA())}function v_(_,i){1&_&&(e.TgZ(0,"div",8)(1,"p",9),e.SDv(2,40),e.qZA(),e.TgZ(3,"mat-form-field",11),e._UZ(4,"input",41),e.qZA()())}function $_(_,i){1&_&&(e.TgZ(0,"th",42),e.SDv(1,43),e.qZA())}function G_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"td",44)(1,"mat-checkbox",45),e.NdJ("change",function(o){const r=e.CHM(t).$implicit,l=e.oxw();return e.KtG(l.onSelectAllName(o,r.value.name))}),e.qZA(),e.TgZ(2,"span"),e._uU(3),e.qZA()()}if(2&_){const t=i.$implicit,n=e.oxw();e.xp6(1),e.Q6J("checked",!!n.permissionGroup&&n.allNameSelected(t.value.name))("indeterminate",!!n.permissionGroup&&n.someNameSelected(t.value.name)),e.xp6(2),e.Oqu(n.getPermission(t.value.name))}}function w_(_,i){1&_&&(e.ynx(0),e.tHW(1,47),e._UZ(2,"br"),e.N_p(),e.BQk())}function Z_(_,i){1&_&&(e.ynx(0),e.tHW(1,48),e._UZ(2,"br"),e.N_p(),e.BQk())}function y_(_,i){1&_&&(e.ynx(0),e.tHW(1,49),e._UZ(2,"br"),e.N_p(),e.BQk())}function B_(_,i){1&_&&(e.ynx(0),e.tHW(1,50),e._UZ(2,"br"),e.N_p(),e.BQk())}function k_(_,i){1&_&&(e.ynx(0),e.tHW(1,51),e._UZ(2,"br"),e.N_p(),e.BQk())}function Y_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"th",42),e.YNc(1,w_,3,0,"ng-container",3),e.YNc(2,Z_,3,0,"ng-container",3),e.YNc(3,y_,3,0,"ng-container",3),e.YNc(4,B_,3,0,"ng-container",3),e.YNc(5,k_,3,0,"ng-container",3),e.TgZ(6,"mat-checkbox",45),e.NdJ("change",function(o){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw();return e.KtG(r.onSelectAllAction(o,a))}),e.qZA()()}if(2&_){const t=e.oxw().$implicit,n=e.oxw();e.xp6(1),e.Q6J("ngIf","view"===t),e.xp6(1),e.Q6J("ngIf","create"===t),e.xp6(1),e.Q6J("ngIf","edit"===t),e.xp6(1),e.Q6J("ngIf","download"===t),e.xp6(1),e.Q6J("ngIf","delete"===t),e.xp6(1),e.Q6J("checked",!!n.permissionGroup&&n.allActionSelected(t))("indeterminate",!!n.permissionGroup&&n.someActionSelected(t))}}function q_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"mat-checkbox",53),e.NdJ("change",function(o){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw().$implicit,l=e.oxw();return e.KtG(l.toggleChange(o,a.value.name,r))}),e.qZA()}if(2&_){const t=e.oxw().$implicit,n=e.oxw().$implicit,o=e.oxw();e.Q6J("checked",null==o.permissionGroup?null:o.permissionGroup.permissionGroupChildren[t.value.name].actions.includes(n))}}function X_(_,i){if(1&_&&(e.TgZ(0,"td",44),e.YNc(1,q_,1,1,"mat-checkbox",52),e.qZA()),2&_){const t=i.$implicit,n=e.oxw().$implicit,o=e.oxw();e.xp6(1),e.Q6J("ngIf",o.canToggle(t.value.name,n))}}function z_(_,i){1&_&&(e.ynx(0,46),e.YNc(1,Y_,7,7,"th",20),e.YNc(2,X_,2,1,"td",21),e.BQk()),2&_&&e.Q6J("matColumnDef",i.$implicit)}function J_(_,i){1&_&&e._UZ(0,"tr",54)}
1function Q_(_,i){1&_&&e._UZ(0,"tr",55)}function H_(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"button",56),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.onSave())}),e.SDv(1,57),e.qZA()}}function V_(_,i){if(1&_&&(e.TgZ(0,"mat-error"),e._uU(1),e.qZA()),2&_){const t=e.oxw();e.xp6(1),e.Oqu(t.errorMessage)}}const K_=["service","invoice","order","sale_request","account_settings","company_information","roles","users","billing_tickets","trouble_tickets","generatl_requests","portal_requests"],W_=["view","create","edit","delete","download"];let j_=(()=>{class _{constructor(t,n,o,a,r,l,p,S,N){this.breadcrumbs=t,this.route=n,this.router=o,this.getRoleUsecase=a,this.saveRoleUsecase=r,this.loading=l,this.modal=p,this.rolesService=S,this.tooltipsService=N,this.displayedColumns=["name","view","create","edit","delete","download"],this.isEdit=!1,this.saving=!1,this.title="",this.isChanged=!1,this.roles=[],this.defaultPermissions=K_,this.defaultActions=W_,this.permissions=[{name:"account_settings",description:"Account Settings"},{name:"billing_tickets",description:"Billing Tickets"},{name:"company_information",description:"Company Information"},{name:"general_requests",description:"General Requests"},{name:"invoice",description:"Invoices"},{name:"order",description:"Orders"},{name:"portal_requests",description:"Portal Requests"},{name:"roles",description:"Roles"},{name:"sale_request",description:"Sale Requests"},{name:"service",description:"Services"},{name:"trouble_tickets",description:"Trouble Tickets"},{name:"users",description:"Users"}],this.errorMessage="",this.textareaLabel="Describe the role",this.formData=new s.cw({copy:new s.NI(null),title:new s.NI(null,s.kI.required),name:new s.NI({value:null,disabled:!0}),description:new s.NI(null)})}canAction(t,n){return this.rolesService.canAction(t,n)}ngOnInit(){this.route.params.subscribe(t=>{this.isEdit="new"!==t.name,this.name=t.name}),this.route.queryParams.subscribe(t=>{this.dataName=t.name}),this.loadRole("new"!==this.name||"new"===this.name&&this.dataName?"new"===this.name?this.dataName:this.name:null),this.formData.get("title").valueChanges.subscribe(t=>{t&&(this.errorMessage="")})}loadRole(t){this.loading.set(!0),this.getRoleUsecase.execute(t).subscribe({next:n=>{"new"!==t&&this.formData.patchValue(n.permissionGroup),this.defaultPermissionGroups=n.defaultPermissionGroups,null===n.permissionGroup?n.permissionGroup={name:null,description:"",permissionGroupChildren:{},can_edit:!0}:null===n.permissionGroup?.permissionGroupChildren&&(n.permissionGroup.permissionGroupChildren={});for(const o in this.defaultPermissionGroups)if(!(o in n.permissionGroup?.permissionGroupChildren)){const a=this.defaultPermissionGroups[o];n.permissionGroup.permissionGroupChildren[o]={description:a.description,name:a.name,enabled:!0,actions:[],defaultActions:a.actions}}if(this.permissionGroup=n.permissionGroup,this.getDefaultRoles(n.defaultRoles),this.title=this.permissionGroup.title,"new"===this.name&&this.dataName){let o=this.roles.find(a=>a.name===this.dataName);this.formData.get("copy").setValue(o)}},complete:()=>{this.breadcrumbs.setLinks([{route:"/",text:"Home"},{route:"/main/settings",text:"Settings"},{route:"/main/settings/company-settings",params:{page:1},text:"Roles"},{text:this.title?this.title:this.name?"" + this.name + "":"New Role"}]),this.loading.set(!1)}})}onSave(){if(this.formData.markAllAsTouched(),this.formData.invalid)return;let t=!1;if(Object.keys(this.permissionGroup.permissionGroupChildren).forEach(o=>{this.permissionGroup.permissionGroupChildren[o].actions.length>0&&(t=!0)}),!t)return void(this.errorMessage="You must add at least one permission to save the role");let n=this.formData.getRawValue();this.permissionGroup.title=n.title,this.permissionGroup.description=n.description,"new"===this.name&&(this.permissionGroup.name=null),this.saving=!0,this.saveRoleUsecase.execute(this.permissionGroup).subscribe({next:o=>{o?this.name=o:setTimeout(()=>{},100)},error:o=>{o&&(this.errorMessage=o.error.message)},complete:()=>{this.saving=!1,this.router.navigate(["main/settings/roles/"+this.name])}})}toggleChange(t,n,o){this.isChanged=!0,this.errorMessage="";const a=this.permissionGroup.permissionGroupChildren[n].actions,r=a.indexOf(o);!0===t.checked?-1===r&&a.push(o):-1!==r&&a.splice(r,1)}canToggle(t,n){return this.defaultPermissionGroups[t].actions.includes(n)}doCancel(t){this.formData.dirty||this.isChanged?this.modal.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">cancel</span>?<br> Entered data will not be saved."}}).afterClosed().subscribe(n=>{n&&(history.back(),t.preventDefault())}):(history.back(),t.preventDefault())}allActionSelected(t){let[n,o]=this.countActions(t);return n===o}someActionSelected(t){let[n,o]=this.countActions(t);return o>0&&o<n}onSelectAllAction(t,n){t.checked?Object.keys(this.permissionGroup.permissionGroupChildren).forEac
1h(o=>{this.permissionGroup.permissionGroupChildren[o].defaultActions.includes(n)&&(this.permissionGroup.permissionGroupChildren[o].actions.includes(n)||this.permissionGroup.permissionGroupChildren[o].actions.push(n))}):Object.keys(this.permissionGroup.permissionGroupChildren).forEach(o=>{if(this.permissionGroup.permissionGroupChildren[o].actions.includes(n)){let a=this.permissionGroup.permissionGroupChildren[o].actions.indexOf(n);this.permissionGroup.permissionGroupChildren[o].actions.splice(a,1)}})}allNameSelected(t){return this.permissionGroup.permissionGroupChildren[t].actions.length===this.permissionGroup.permissionGroupChildren[t].defaultActions.length}someNameSelected(t){return this.permissionGroup.permissionGroupChildren[t].actions.length!==this.permissionGroup.permissionGroupChildren[t].defaultActions.length&&this.permissionGroup.permissionGroupChildren[t].actions.length>0}onSelectAllName(t,n){this.permissionGroup.permissionGroupChildren[n].defaultActions.forEach(t.checked?o=>{this.permissionGroup.permissionGroupChildren[n].actions.includes(o)||(this.permissionGroup.permissionGroupChildren[n].actions.push(o),this.permissionGroup.permissionGroupChildren[n].enabled=!0)}:o=>{if(this.permissionGroup.permissionGroupChildren[n].actions.includes(o)){let a=this.permissionGroup.permissionGroupChildren[n].actions.indexOf(o);this.permissionGroup.permissionGroupChildren[n].actions.splice(a,1),this.permissionGroup.permissionGroupChildren[n].enabled=!1}})}onSelectAll(){Object.keys(this.permissionGroup.permissionGroupChildren).forEach(t=>{this.permissionGroup.permissionGroupChildren[t].defaultActions.forEach(n=>{this.permissionGroup.permissionGroupChildren[t].actions.includes(n)||this.permissionGroup.permissionGroupChildren[t].actions.push(n)})})}onClearAll(){Object.keys(this.permissionGroup.permissionGroupChildren).forEach(t=>{this.permissionGroup.permissionGroupChildren[t].actions=[]})}countActions(t){let n=0,o=0;return Object.keys(this.permissionGroup?.permissionGroupChildren).forEach(a=>{this.permissionGroup.permissionGroupChildren[a].defaultActions.includes(t)&&(n+=1),this.permissionGroup.permissionGroupChildren[a].actions.includes(t)&&(o+=1)}),[n,o]}getDefaultRoles(t){t.forEach(n=>{n.title?this.roles.push({name:n.name,title:n.title}):!n.title&&n.name&&this.roles.push({name:n.name,title:n.name})})}copyRole(t){this.router.routeReuseStrategy.shouldReuseRoute=()=>!1,this.router.onSameUrlNavigation="reload",this.router.navigate(["main/settings/roles/edit/new"],{queryParams:{name:t}})}get control(){return this.formData.controls.description}getPermission(t){return this.permissions.find(n=>n.name===t).description}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(y.W),e.Y36(M.gz),e.Y36(M.F0),e.Y36(de.M),e.Y36(I_.N),e.Y36(Pe.D),e.Y36(F.uw),e.Y36(G.f),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-role-details"]],features:[e._Bn([{provide:k.PG,useValue:{overlayPanelClass:"select-overlay"}}])],decls:50,vars:19,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R,C,u,O;return i="Role Name *",t="Company",n="Description",o="Select All",a="Clear All",r="Cancel",l="" + "\ufffd0\ufffd" + "",p="New Role",S="Copy From",N="This field is required",d="Role ID",c="PERMISSIONS",I=" View " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",f=" Create " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",R=" Edit " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",C=" Print / Download " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",u=" Cancel / Delete " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",O="Save ",[[1,"role-details"],[1,"title","margin-top"],[1,"title-text","capital-gothic"],[4,"ngIf"],[1,"breadcrumbs"],[3,"formGroup"],[1,"form","editable"],["class","flex align-center space-between",4,"ngIf"],[1,"flex","align-center","space-between"],[1,"label"],i,["floatLabel","never"],["matInput","","placeholder",t,"formControlName","title"],[1,"label",2,"position","relative","bottom","10px"],n,[1,"form-field",2,"position","relative","bottom","-10px"],[3,"control","label"],[1,"table-wrap"],["mat-table","",3,"dataSource"],["matColumnDef","name"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],[3,"matColumnDef",4,"ngFor","ngForOf"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],[1,"selection-control"],[1,"arrow-container",3,"click"],[1,"arrow"],o,a,[1,"actions"],["mat-raised-button","",1,"btn","btn_light",3,"click"],r,["class","btn btn_blue","mat-raised-button","",3,"click",4,"ngIf"],[1,"error"],l,p,S,[3,"data","label","errors","touched","value","selectedItem"],N,d,["matInput","","formControlName","name"],["mat-header-cell",""],c,["mat-cell",""],[3,"checked","indeterminate","change"],[3,"matColumnDef"],I,f,R,C,u,[3,"checked","change",4,"ngIf"],[3,"checked","change"],["mat-header-row",""],["mat-row",""],["mat-raised-button","",1,"btn","btn_blue",3,"click"],O]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e.YNc(3,h_,2,1,"ng-container",3),e.YNc(4,F_,2,1,"ng-container",3),e.YNc(5,D_,2,1,"ng-container",3),e.YNc(6,b_,2,0,"ng-container",3),e.GkF(7),e.YNc(8,L_,3,1,"app-tooltip",3),e.qZA(),e.TgZ(9,"div",4),e._UZ(10,"wo-breadcrumbs"),e.qZA()(),e.TgZ(11,"form",5)(12,"div",6),e.YNc(13,x_,4,5,"div",7),e.TgZ(14,"div",8)(15,"p",9),e.SDv(16,10),e.qZA(),e.TgZ(17,"mat-form-field",11),e._UZ(18,"input",12),e.YNc(19,U_,2,0,"mat-error",3),e.qZA()(),e.YNc(20,v_,5,0,"div",7),e.TgZ(21,"div",8)(22,"p",13),e.SDv(23,14),e.qZA(),e.TgZ(24,"div",15),e._UZ(25,"custom-textarea",16),e.qZA()()(),e.TgZ(26,"div",17)(27,"table",18),e.ALo(28,"keyvalue"),e.ynx(29,19),e.YNc(30,$_,2,0,"th",20),e.YNc(31,G_,4,3,"td",21),e.BQk(),e.YNc(32,z_,3,1,"ng-container",22),e.YNc(33,J_,1,0,"tr",23),e.YNc(34,Q_,1,0,"tr",24),e.qZA()(),e.TgZ(35,"div",25)(36,"div",26),e.NdJ("click",function(){return n.onSelectAll()}),e._UZ(37,"div",27),e.TgZ(38,"p"),e.SDv(39,28),e.qZA()(),e.TgZ(40,"div",26),e.NdJ("click",function(){return n.onClearAll()}),e._UZ(41,"div",27),e.TgZ(42,"p"),e.SDv(43,29),e.qZA()()(),e.TgZ(44,"div",30)(45,"button",31),e.NdJ("click",function(a){return n.doCancel(a)}),e.SDv(46,32),e.qZA(),e.YNc(47,H_,2,0,"button",33),e.qZA(),e.TgZ(48,"div",34),e.YNc(49,V_,2,1,"mat-error",3),e.qZA()()()),2&t&&(e.xp6(3),e.Q6J("ngIf",n.title),e.xp6(1),e.Q6J("ngIf",!n.title&&n.name&&"new"!==n.name),e.xp6(1),e.Q6J("ngIf",!n.title&&"new"===n.name),e.xp6(1),e.Q6J("ngIf",!n.title&&!n.name),e.xp6(2),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.new_role),e.xp6(3),e.Q6J("formGroup",n.formData),e.xp6(2),e.Q6J("ngIf",(null==n.roles?null:n.roles.length)>0),e.xp6(6),e.Q6J("ngIf",n.formData.get("title").hasError("required")),e.xp6(1),e.Q6J("ngIf",n.isEdit),e.xp6(5),e.Q6J("control",n.control)("label",n.textareaLabel),e.xp6(2),e.Q6J("dataSource",e.lcZ(28,17,n.defaultPermissionGroups)),e.xp6(
15),e.Q6J("ngForOf",n.defaultActions),e.xp6(1),e.Q6J("matHeaderRowDef",n.displayedColumns),e.xp6(1),e.Q6J("matRowDefColumns",n.displayedColumns),e.xp6(13),e.Q6J("ngIf",n.canAction(n.isEdit?"edit":"create","roles")),e.xp6(2),e.Q6J("ngIf",n.errorMessage))},dependencies:[P.sg,P.O5,s._Y,s.Fj,s.JJ,s.JL,Y.lW,te.oG,h.TO,h.KE,L.Nt,E.BZ,E.fO,E.as,E.w1,E.Dz,E.nj,E.ge,E.ev,E.XQ,E.Gk,s.sg,s.u,f_.m,U.K,R_.U,B.g,P.Nd],styles:[".role-details[_ngcontent-%COMP%]{padding:0 60px 40px 0}@media (max-width: 960px){.role-details[_ngcontent-%COMP%]{padding-right:1rem}}.table-wrap[_ngcontent-%COMP%]{margin-top:40px;overflow-x:auto;white-space:nowrap}table[_ngcontent-%COMP%]{width:100%;table-layout:auto;min-width:900px;border-bottom:1px solid #000}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%], table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border:none}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:not(:first-child), table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:not(:first-child){text-align:center}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{color:#000;border-bottom:1px solid #000;font:400 14px Capital Gothic,Arial,sans-serif;vertical-align:top;text-transform:uppercase}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:first-child{padding-left:10px}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:not(:first-child){color:#144a90}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]   .mat-checkbox[_ngcontent-%COMP%]{margin-top:8px}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:last-child{padding-right:0}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{width:15%}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:first-child{width:20%;padding-left:10px}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:last-child{padding-right:0}table[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:first-child   span[_ngcontent-%COMP%]{margin-left:30px;position:relative;top:1px;white-space:nowrap}[_nghost-%COMP%]     table.mat-table tbody tr:nth-child(even){background:#EAF2FC}[_nghost-%COMP%]     table .mat-checkbox-inner-container{height:12px;width:12px}[_nghost-%COMP%]     table .mat-checkbox-ripple{display:none}[_nghost-%COMP%]     table .mat-checkbox-frame{border-radius:0;border:0;background:#DDDDDD}[_nghost-%COMP%]     table .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background, [_nghost-%COMP%]     table .mat-checkbox-checked.mat-accent .mat-checkbox-background{background:#D6117F;border-radius:0}[_nghost-%COMP%]     table .mat-checkbox-checkmark{display:none}[_nghost-%COMP%]     table .mat-select-trigger{background:#144A90;padding:5px 10px 5px 5px;color:#fff!important;display:flex;text-align:center;height:20px;width:130px;text-transform:uppercase;font-size:14px}[_nghost-%COMP%]     table .mat-select-value{color:#fff!important}.actions[_ngcontent-%COMP%]{display:flex;margin:70px auto 0;justify-content:center;gap:10%}.selection-control[_ngcontent-%COMP%]{display:flex;margin-top:20px;margin-left:57px;gap:100px}.form[_ngcontent-%COMP%]{width:50%;margin-bottom:70px;max-width:540px}@media (max-width: 1440px){.form[_ngcontent-%COMP%]{width:70%}}@media (max-width: 1180px){.form[_ngcontent-%COMP%]{width:90%}}.form[_ngcontent-%COMP%]   textarea[_ngcontent-%COMP%]{padding:0;border:none;width:100%;box-sizing:border-box}.mat-form-field[_ngcontent-%COMP%]   .arrow[_ngcontent-%COMP%]{width:25px;height:10px;background-color:#959595;-webkit-mask:url(/assets/pic/sidebar/arrow-down.svg) no-repeat;mask:url(/assets/pic/sidebar/arrow-down.svg) no-repeat}  .issue-menu .mat-menu-content{display:flex!important;width:219px!important;height:147px!important;flex-direction:column!important;justify-content:space-between!important;padding:22px 20px 20px!important}  .issue-menu .mat-menu-content p{box-sizing:border-box!important;cursor:pointer!important;border-bottom:1px solid black!important;padding-bottom:10px!important;height:30px!important}  .issue-menu .mat-menu-content p span{visibility:hidden!important;margin-right:10px!important;margin-left:10px!important;display:inline-block;transform:translateY(-3px)!important}  .issue-menu .mat-menu-content p:hover{font-weight:600}  .issue-menu .mat-menu-content p:hover span{visibility:visible!important;color:#d6117f!important;font-size:10px!important}.mat-form-field[_ngcontent-%COMP%]{width:100%}.label[_ngcontent-%COMP%]{min-width:100px;margin-right:10px!important}.editable[_ngcontent-%COMP%]{background-color:#eaf2fc;padding:24px;margin-top:34px;flex:0 0 48%}.editable[_ngcontent-%COMP%]   mat-form-field[_ngcontent-%COMP%]{width:100%}.editable[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{flex:0 0 120px}.editable[_ngcontent-%COMP%]   .form-field[_ngcontent-%COMP%]{flex:1}.editable[_ngcontent-%COMP%]   .flex[_ngcontent-%COMP%]{align-items:baseline;position:relative}[_nghost-%COMP%]     .mat-form-field label, [_nghost-%COMP%]     .mat-select-placeholder{font-size:14px;margin-top:4px;color:#0000008a}app-custom-search-select[_ngcontent-%COMP%]{width:100%}  .form .mat-form-field-appearance-outline .mat-form-field-outline-start,   .form .mat-form-field-appearance-outline .mat-form-field-outline-end{border-bottom:1px solid #000!important}[_nghost-%COMP%]     .mat-form-field-appearance-legacy.mat-form-field-disabled .mat-form-field-underline{background-image:none}.error[_ngcontent-%COMP%]{position:absolute;margin-top:20px;width:100%}mat-error[_ngcontent-%COMP%]{text-align:center;text-transform:uppercase;font-size:14px}[_nghost-%COMP%]     #contentEditableDiv{height:114px!important}[_nghost-%COMP%]     #editableP{max-height:94px!important}"]}),_})();class eo extends D.I{constructor(){super({}),this.addControl("id",new s.NI("")),this.addControl("first_name",new s.NI("",s.kI.required)),this.addControl("last_name",new s.NI("",s.kI.required)),this.addControl("email",new s.NI("",[s.kI.required,s.kI.pattern($.T.EMAIL_REGEX)])),this.addControl("role",new s.NI("",s.kI.required)),this.addControl("role_id",new s.NI("",s.kI.required)),this.addControl("phone",new s.NI("",[s.kI.required,s.kI.pattern($.T.PHONE_REGEX)])),this.addControl("time_zone",new s.NI("",s.kI.required))}get id(){return this.controls.id}get email(){return this.controls.email}get role(){return this.controls.role}get role_id(){return this.controls.role_id}get first_name(){return this.controls.first_name}get last_name(){return this.controls.last_name}get phone(){return this.controls.phone}get time_zone(){return this.controls.time_zone}}var Ne=T(2061),to=T(17875);function no(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.user_details)}}function _o(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",20),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.edit())}),e._UZ(1,"div",21),e.TgZ(2,"p"),e.SDv(3,22),e.qZA()()}}function oo(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",20),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.copy())}),e._UZ(1,"div",21),e.TgZ(2,"p"),e.SDv(3,23),e.qZA()()}}function io(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",20),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.sendResetPasswordRequest())}),e._UZ(1,"div",21),e.TgZ(2,"p"),e.SDv(3,24),e.qZA()()}}function ao(_,i){1&_&&(e.TgZ(0,"p",25),e.SDv(1,26),e.qZA())}let so=(()=>{class _{constructor(t,n,o,a,r,l,p,S){this.getUserDetailsUsecase=t,this.sendResetPasswordRequestUsecase=n,this.activatedRoute=o,this.matDialog=a,this.router=r,this.breadcrumbs=l,this.rolesService=p,this.tooltipsService=S,this.userDetailForm=new eo,this.languageList=Object.values(j.G),this.timeZoneList=Object.values(q.O),this.passwordResetSent=!1,this.getTimeZoneEnumLabel=q.s,this.getLanguageEnumLabel=j.q}canAction(t,n){return this.rolesService.canAction(t,n)}ngOnInit(){this.setUpBreadcrumbLinks(),this.getUserDetailsUsecase.execute(this.userId).subscribe(t=>{this.userDetailForm.patchValue(t),this.is_admin="1"===t.is_admin,this.setUpBreadcrumbLinks((t.first_name+" "+t.last_name).toUpperCase())})}sendResetPasswordRequest(){this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">reset password</span><br> for this user?"}}).afterClosed().subscribe(t=>{t&&this.sendResetPasswordRequestUsecase.execute(this.userId).subscribe(n=>{this.passwordResetSent=!0,setTimeout(()=>{this.passwordResetSent=!1},3e3)})})}copy(){this.router.navigate(["main/settings/user/edit/new"],{queryParams:{id:this.userId}})}edit(){this.router.navigate(["main/settings/user/edit/"+this.userId])}get userId(){return this.activatedRoute.snapshot.params.id}
1setUpBreadcrumbLinks(t=""){this.breadcrumbs.setLinks([{route:"/",text:"HOME"},{route:"/main/settings",text:"SETTINGS"},{route:"/main/settings/company-settings",text:"USERS"},{text:t}])}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(Ne.K),e.Y36(to.k),e.Y36(M.gz),e.Y36(F.uw),e.Y36(M.F0),e.Y36(y.W),e.Y36(G.f),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-user-details"]],decls:51,vars:14,consts:function(){let i,t,n,o,a,r,l,p,S,N,d;return i="Details",t="First Name:",n="Last Name:",o="Email:",a="Phone:",r="Role:",l="Role ID:",p="EDIT",S="COPY",N="RESET PASSWORD",d="RESET PASSWORD EMAIL WAS SUCCESSFULLY SENT TO USER'S EMAIL",[[1,"header"],[1,"profile-title-header","capital-gothic"],[4,"ngIf"],[1,"breadcrumbs"],[1,"details",3,"formGroup"],[1,"profile-title","margin-left-custom","capital-gothic"],i,[1,"pink-divider"],[1,"flex","align-center","space-between"],[1,"margin-left-custom","bold"],t,[1,"width-60"],n,o,a,r,l,[1,"actions"],["class","arrow-container",3,"click",4,"ngIf"],["class","absolute",4,"ngIf"],[1,"arrow-container",3,"click"],[1,"arrow"],p,S,N,[1,"absolute"],d]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"p",1),e._uU(2),e.YNc(3,no,3,1,"app-tooltip",2),e.qZA(),e.TgZ(4,"div",3),e._UZ(5,"wo-breadcrumbs"),e.qZA()(),e.TgZ(6,"div",4)(7,"p",5),e.SDv(8,6),e.qZA(),e._UZ(9,"mat-divider",7),e.TgZ(10,"div",8)(11,"p",9),e.SDv(12,10),e.qZA(),e.TgZ(13,"p",11),e._uU(14),e.qZA()(),e._UZ(15,"mat-divider"),e.TgZ(16,"div",8)(17,"p",9),e.SDv(18,12),e.qZA(),e.TgZ(19,"p",11),e._uU(20),e.qZA()(),e._UZ(21,"mat-divider"),e.TgZ(22,"div",8)(23,"p",9),e.SDv(24,13),e.qZA(),e.TgZ(25,"p",11),e._uU(26),e.qZA()(),e._UZ(27,"mat-divider"),e.TgZ(28,"div",8)(29,"p",9),e.SDv(30,14),e.qZA(),e.TgZ(31,"p",11),e._uU(32),e.qZA()(),e._UZ(33,"mat-divider"),e.TgZ(34,"div",8)(35,"p",9),e.SDv(36,15),e.qZA(),e.TgZ(37,"p",11),e._uU(38),e.qZA()(),e._UZ(39,"mat-divider"),e.TgZ(40,"div",8)(41,"p",9),e.SDv(42,16),e.qZA(),e.TgZ(43,"p",11),e._uU(44),e.qZA()(),e._UZ(45,"mat-divider"),e.qZA(),e.TgZ(46,"div",17),e.YNc(47,_o,4,0,"div",18),e.YNc(48,oo,4,0,"div",18),e.YNc(49,io,4,0,"div",18),e.YNc(50,ao,2,0,"p",19),e.qZA()),2&t&&(e.xp6(2),e.AsE("",null==n.userDetailForm.first_name?null:n.userDetailForm.first_name.value," ",null==n.userDetailForm.last_name?null:n.userDetailForm.last_name.value," "),e.xp6(1),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.user_details),e.xp6(3),e.Q6J("formGroup",n.userDetailForm),e.xp6(8),e.Oqu(null==n.userDetailForm.first_name?null:n.userDetailForm.first_name.value),e.xp6(6),e.Oqu(null==n.userDetailForm.last_name?null:n.userDetailForm.last_name.value),e.xp6(6),e.Oqu(null==n.userDetailForm.email?null:n.userDetailForm.email.value),e.xp6(6),e.Oqu(null==n.userDetailForm.phone?null:n.userDetailForm.phone.value),e.xp6(6),e.Oqu(null==n.userDetailForm.role?null:n.userDetailForm.role.value),e.xp6(6),e.Oqu(null==n.userDetailForm.role_id?null:n.userDetailForm.role_id.value),e.xp6(3),e.Q6J("ngIf",n.canAction("edit","users")&&!n.is_admin),e.xp6(1),e.Q6J("ngIf",n.canAction("delete","users")),e.xp6(1),e.Q6J("ngIf",n.canAction("edit","users")),e.xp6(1),e.Q6J("ngIf",n.passwordResetSent))},dependencies:[P.O5,s.JL,v.d,s.sg,U.K,B.g],styles:[".details[_ngcontent-%COMP%]{min-width:30rem;width:53%}.flex[_ngcontent-%COMP%]{height:3rem}.width-60[_ngcontent-%COMP%]{width:70%}.profile-title[_ngcontent-%COMP%]{margin-top:23px!important;font-size:30px;font-weight:700;margin-bottom:18px!important}.pink-divider[_ngcontent-%COMP%]{background-color:#d6117f;height:2px;border:none}mat-divider[_ngcontent-%COMP%]{height:1px;border-top-color:#000}.bold[_ngcontent-%COMP%]{font-weight:700}mat-form-field[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{padding-left:1rem!important}mat-form-field[_ngcontent-%COMP%]     .mat-form-field-label{margin-left:1rem!important}mat-form-field[_ngcontent-%COMP%]   mat-select[_ngcontent-%COMP%]{padding-left:1rem!important;width:96%}mat-form-field[_ngcontent-%COMP%]   mat-label[_ngcontent-%COMP%]{margin-left:1rem!important;font-weight:300;font-size:14px}.margin-left-custom[_ngcontent-%COMP%]{margin-left:24px!important}.blue-text[_ngcontent-%COMP%]{margin-top:10px!important;color:#144a90;display:flex;justify-content:center}.absolute[_ngcontent-%COMP%]{position:absolute;top:62px;left:200px;color:#d6117f;font-size:14px}.actions[_ngcontent-%COMP%]{position:relative;margin-top:54px;padding-left:24px;width:53%;display:flex;justify-content:space-between;box-sizing:border-box}.profile-title-header[_ngcontent-%COMP%]{font-size:44px;font-style:normal;font-weight:700;line-height:43px;letter-spacing:.44px;text-transform:uppercase}.profile-title-header[_ngcontent-%COMP%]     app-tooltip .right{top:13px}.header[_ngcontent-%COMP%]{display:flex;gap:10px}"]}),_})();class ro extends D.I{constructor(){super({}),this.addControl("id",new s.NI("")),this.addControl("first_name",new s.NI("",s.kI.required)),this.addControl("last_name",new s.NI("",s.kI.required)),this.addControl("email",new s.NI("",[s.kI.required,s.kI.pattern($.T.EMAIL_REGEX)])),this.addControl("role_id",new s.NI("",s.kI.required)),this.addControl("phone",new s.NI("",[s.kI.pattern($.T.PHONE_REGEX)])),this.addControl("timezone",new s.NI(""))}get id(){return this.controls.id}get email(){return this.controls.email}get role_id(){return this.controls.role_id}get first_name(){return this.controls.first_name}get last_name(){return this.controls.last_name}get phone(){return this.controls.phone}get timezone(){return this.controls.timezone}}var lo=T(96828),To=T(56129);function co(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.new_user)}}function So(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,27),e.qZA())}function po(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,28),e.qZA())}function Eo(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,29),e.qZA())}function go(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,30),e.qZA())}function Po(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,31),e.qZA())}function No(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,32),e.qZA())}function Co(_,i){if(1&_&&(e.TgZ(0,"mat-option",33),e._uU(1),e.qZA()),2&_){const t=i.$implicit;e.Q6J("value",t.id),e.xp6(1),e.Oqu(t.name)}}function uo(_,i){1&_&&(e.TgZ(0,"mat-error"),e.SDv(1,34),e.qZA())}function Oo(_,i){if(1&_&&(e.TgZ(0,"mat-option",33),e._uU(1),e.qZA()),2&_){const t=i.$implicit,n=e.oxw();e.Q6J("value",t),e.xp6(1),e.Oqu(n.getTimeZoneEnumLabel(t))}}function mo(_,i){1&_&&(e.TgZ(0,"p",35),e.SDv(1,36),e.qZA())}let Ao=(()=>{class _{constructor(t,n,o,a,r,l,p,S){this.upsertUserDataUsecase=t,this.getUserDetailsUsecase=n,this.activatedRoute=o,this.getUserRolesUsecase=a,this.breadcrumbs=r,this.router=l,this.matDialog=p,this.tooltipsService=S,this.personalDetailsSaved=!1,this.userFirstAndLastName="NEW USER",this.userDetailForm=new ro,this.timeZoneList=Object.values(q.O),this.roles=[],this.getTimeZoneEnumLabel=q.s}ngOnInit(){this.setUpBreadcrumbLinks();const t=this.activatedRoute.snapshot.params.id,n=this.activatedRoute.snapshot.queryParams.id;
1("new"!==t||"new"===t&&n)&&this.getUserDetailsUsecase.execute("new"===t?n:t).subscribe(o=>{"new"!==t&&(this.userFirstAndLastName=o.first_name+" "+o.last_name,this.setUpBreadcrumbLinks(this.userFirstAndLastName.toUpperCase())),this.userDetailForm.patchValue(o)}),"new"===t&&this.userDetailForm.id.disable(),this.getUserRolesUsecase.execute().subscribe(o=>{this.roles=o})}saveUserData(){this.userDetailForm.markAllAsTouched(),this.userDetailForm.valid&&this.upsertUserDataUsecase.execute(this.userDetailForm.value).subscribe(t=>{this.personalDetailsSaved=!0,this.router.navigate(["main/settings/company-settings"],{queryParams:{page:2}}),setTimeout(()=>{this.personalDetailsSaved=!1},8e3)},t=>{this.userDetailForm.email.setErrors({emailExists:!0})})}cancel(){this.userDetailForm.dirty&&this.matDialog.open(b.S,{panelClass:"general-information-popup",data:{text:"Are you sure you want to <span class=\"dedicated-text\">cancel</span><br> changes?"}}).afterClosed().subscribe(t=>{t&&this.goBack()}),!this.userDetailForm.dirty&&this.goBack()}setUpBreadcrumbLinks(t="NEW USER"){this.breadcrumbs.setLinks([{route:"/",text:"HOME"},{route:"/main/settings",text:"SETTINGS"},{route:"/main/settings/company-settings",text:"USERS"},{text:t}])}goBack(){this.router.navigate(["main/settings/company-settings"],{queryParams:{page:2}})}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(lo.F),e.Y36(Ne.K),e.Y36(M.gz),e.Y36(To.B),e.Y36(y.W),e.Y36(M.F0),e.Y36(F.uw),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-user-edit"]],decls:53,vars:13,consts:function(){let i,t,n,o,a,r,l,p,S,N,d,c,I,f,R,C,u,O,m,A,V;return i="First name *",t="First name",n="Last name *",o="Last name",a="Email *",r="Phone",l="Phone",p="Role *",S="Role",N="Time Zone",d="Time Zone",c="CANCEL",I="SAVE",f=" This field is required ",R=" This field is required ",C=" This field is required ",u=" Please enter a valid email address ",O=" This email already exists ",m=" Please enter a valid phone number ",A=" This field is required ",V="YOUR CHANGES WERE SUCCESSFULLY SAVED",[[1,"header"],[1,"profile-title","capital-gothic"],[4,"ngIf"],[1,"breadcrumbs"],[1,"details",3,"formGroup"],[1,"editable"],[1,"flex","align-center"],i,["floatLabel","never"],["matInput","","placeholder",t,"formControlName","first_name"],n,["placeholder",o,"matInput","","formControlName","last_name"],a,["matInput","","placeholder","Email","formControlName","email"],r,["matInput","","placeholder",l,"formControlName","phone"],p,["placeholder",S,"formControlName","role_id"],[3,"value",4,"ngFor","ngForOf"],N,["placeholder",d,"formControlName","timezone"],[1,"actions"],["mat-raised-button","",1,"cancel-button","capital-gothic",3,"click"],c,["mat-raised-button","","color","primary",1,"save-button","capital-gothic",3,"click"],I,["class","blue-text absolute",4,"ngIf"],f,R,C,u,O,m,[3,"value"],A,[1,"blue-text","absolute"],V]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"p",1),e._uU(2),e.YNc(3,co,3,1,"app-tooltip",2),e.qZA(),e.TgZ(4,"div",3),e._UZ(5,"wo-breadcrumbs"),e.qZA()(),e.TgZ(6,"div",4)(7,"div",5)(8,"div",6)(9,"p"),e.SDv(10,7),e.qZA(),e.TgZ(11,"mat-form-field",8),e._UZ(12,"input",9),e.YNc(13,So,2,0,"mat-error",2),e.qZA()(),e.TgZ(14,"div",6)(15,"p"),e.SDv(16,10),e.qZA(),e.TgZ(17,"mat-form-field",8),e._UZ(18,"input",11),e.YNc(19,po,2,0,"mat-error",2),e.qZA()(),e.TgZ(20,"div",6)(21,"p"),e.SDv(22,12),e.qZA(),e.TgZ(23,"mat-form-field",8),e._UZ(24,"input",13),e.YNc(25,Eo,2,0,"mat-error",2),e.YNc(26,go,2,0,"mat-error",2),e.YNc(27,Po,2,0,"mat-error",2),e.qZA()(),e.TgZ(28,"div",6)(29,"p"),e.SDv(30,14),e.qZA(),e.TgZ(31,"mat-form-field",8),e._UZ(32,"input",15),e.YNc(33,No,2,0,"mat-error",2),e.qZA()(),e.TgZ(34,"div",6)(35,"p"),e.SDv(36,16),e.qZA(),e.TgZ(37,"mat-form-field",8)(38,"mat-select",17),e.YNc(39,Co,2,2,"mat-option",18),e.qZA(),e.YNc(40,uo,2,0,"mat-error",2),e.qZA()(),e.TgZ(41,"div",6)(42,"p"),e.SDv(43,19),e.qZA(),e.TgZ(44,"mat-form-field",8)(45,"mat-select",20),e.YNc(46,Oo,2,2,"mat-option",18),e.qZA()()()()(),e.TgZ(47,"div",21)(48,"button",22),e.NdJ("click",function(){return n.cancel()}),e.SDv(49,23),e.qZA(),e.TgZ(50,"button",24),e.NdJ("click",function(){return n.saveUserData()}),e.SDv(51,25),e.qZA(),e.YNc(52,mo,2,0,"p",26),e.qZA()),2&t&&(e.xp6(2),e.hij("",n.userFirstAndLastName," "),e.xp6(1),e.Q6J("ngIf",(null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.new_user)&&"NEW USER"==n.userFirstAndLastName),e.xp6(3),e.Q6J("formGroup",n.userDetailForm),e.xp6(7),e.Q6J("ngIf",n.userDetailForm.first_name.hasError("required")),e.xp6(6),e.Q6J("ngIf",n.userDetailForm.last_name.hasError("required")),e.xp6(6),e.Q6J("ngIf",n.userDetailForm.email.hasError("required")),e.xp6(1),e.Q6J("ngIf",n.userDetailForm.email.hasError("pattern")),e.xp6(1),e.Q6J("ngIf",n.userDetailForm.email.hasError("emailExists")),e.xp6(6),e.Q6J("ngIf",n.userDetailForm.phone.hasError("pattern")),e.xp6(6),e.Q6J("ngForOf",n.roles),e.xp6(1),e.Q6J("ngIf",n.userDetailForm.role_id.hasError("required")),e.xp6(6),e.Q6J("ngForOf",n.timeZoneList),e.xp6(6),e.Q6J("ngIf",n.personalDetailsSaved))},dependencies:[P.sg,P.O5,s.Fj,s.JJ,s.JL,Y.lW,h.TO,h.KE,L.Nt,k.gD,ee.ey,s.sg,s.u,U.K,B.g],styles:[".details[_ngcontent-%COMP%]{min-width:30rem;width:53%}.editable[_ngcontent-%COMP%]{background-color:#eaf2fc;padding:24px;margin-top:23px}.editable[_ngcontent-%COMP%]   mat-form-field[_ngcontent-%COMP%]{width:78%}.flex[_ngcontent-%COMP%]{height:3rem;gap:54px}.flex[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{width:90px}.profile-title[_ngcontent-%COMP%]{font-size:44px;font-style:normal;font-weight:700;line-height:43px;letter-spacing:.44px;text-transform:uppercase}.profile-title[_ngcontent-%COMP%]     app-tooltip .right{top:13px}.actions[_ngcontent-%COMP%]{display:flex;margin:54px auto 40px;justify-content:space-between;width:740px;position:relative}.actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{width:310px;height:50px}.cancel-button[_ngcontent-%COMP%]{background-color:#4698ff;color:#fff}.save-button[_ngcontent-%COMP%]{background-color:#144a90}.bold[_ngcontent-%COMP%]{font-weight:700}mat-form-field[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{padding-left:1rem!important}mat-form-field[_ngcontent-%COMP%]     .mat-form-field-label{margin-left:1rem!important}mat-form-field[_ngcontent-%COMP%]   mat-select[_ngcontent-%COMP%]{padding-left:1rem!important;width:96%}mat-form-field[_ngcontent-%COMP%]   mat-label[_ngcontent-%COMP%]{margin-left:1rem!important;font-weight:300;font-size:14px}.blue-text[_ngcontent-%COMP%]{margin-top:10px!important;color:#144a90;display:flex;justify-content:center}.absolute[_ngcontent-%COMP%]{position:absolute;top:62px;left:200px}.header[_ngcontent-%COMP%]{display:flex;gap:10px}"]}),_})();function Mo(_,i){if(1&_&&(e.TgZ(0,"app-tooltip")(1,"p"),e._uU(2),e.qZA()()),2&_){const t=e.oxw();e.xp6(2),e.Oqu(t.tooltipsService.tooltips.role_details)}}function Io(_,i){1&_&&(e.TgZ(0,"th",22),e.SDv(1,23),e.qZA())}function fo(_,i){if(1&_&&(e.TgZ(0,"td",24)(1,"span"),e._uU(2),e.qZA()()),2&_){const t=i.$implicit,n=e.oxw();e.xp6(2),e.Oqu(n.getPermission(t.value.name))}}function Ro(_,i){1&_&&(e.ynx(0),e.tHW(1,26),e._UZ(2,"br"),e.N_p(),e.BQk())}function ho(_,i){1&_&&(e.ynx(0),e.tHW(1,27),e._UZ(2,"br"),e.N_p(),e.BQk())}function Fo(_,i){1&_&&(e.ynx(0),e.tHW(1,28),e._UZ(2,"br"),e.N_p(),e.BQk())}function Do(_,i){1&_&&(e.ynx(0),e.tHW(1,29),e._UZ(2,"br"),e.N_p(),e.BQk())}function bo(_,i){1&_&&(e.ynx(0),e.tHW(1,30),e._UZ(2,"br"),e.N_p(),e.BQk())}function Lo(_,i){if(1&_&&(e.TgZ(0,"th",22),e.YNc(1,Ro,3,0,"ng-container",3),e.YNc(2,ho,3,0,"ng-container",3),e.YNc(3,Fo,3,0,"ng-container",3),e.YNc(4,Do,3,0,"ng-container",3),e.YNc(5,bo,3,0,"ng-container",3),e.qZA()),2&_){const t=e.oxw().$implicit;e.xp6(1),e.Q6J("ngIf","view"===t),e.xp6(1),e.Q6J("ngIf","create"===t),e.xp6(1),e.Q6J("ngIf","edit"===t),e.xp6(1),e.Q6J("ngIf","download"===t),e.xp6(1),e.Q6J("ngIf","delete"===t)}}function xo(_,i){if(1&_&&(e.ynx(0),e._UZ(1,"span"),e.BQk()),2&_){const t=e.oxw().$implicit,n=e.oxw().$implicit,o=e.oxw();e.xp6(1),e.Tol(o.isChecked(t.value.name,n)?"checked":"not-checked")}}function Uo(_,i){if(1&_&&(e.TgZ(0,"td",24),e.YNc(1,xo,2,3,"ng-container",3),e.qZA()),2&_){const t=i.$implicit,n=e.oxw().$implicit,o=e.oxw();e.xp6(1),e.Q6J("ngIf",o.canToggle(t.value.name,n))}}function vo(_,i){1&_&&(e.ynx(0,25),e.YNc(1,Lo,6,5,"th",15),e.YNc(2,Uo,2,1,"td",16),e.BQk()),2&_&&e.Q6J("matColumnDef",i.$implicit)}function $o(_,i){1&_&&e._UZ(0,"tr",31)}function Go(_,i){1&_&&e._UZ(0,"tr",32)}function wo(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",33),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.onEdit(null==o.permissionGroup?null:o.permissionGroup.name))}),e._UZ(1,"div",34),e.TgZ(2,"p"),e.SDv(3,35),e.qZA()()}}function Zo(_,i){if(1&_){const t=e.EpF();e.TgZ(0,"div",33),e.NdJ("click",function(){e.CHM(t);const o=e.oxw();return e.KtG(o.onCopy(null==o.permissionGroup?null:o.permissionGroup.name))}),e._UZ(1,"div",34),e.TgZ(2,"p"),e.SDv(3,36),e.qZA()()}}const yo=["service","invoice","order","sale_request","account_settings","company_information","roles","users","billing_tickets","trouble_tickets","generatl_requests","portal_requests"],Bo=["view","create","edit","delete","download"];let ko=(()=>{class _{constructor(t,n,o,a,r,l,p){this.breadcrumbs=t,this.activeRoute=n,this.getRoleUsecase=o,this.router=a,this.loading=r,this.rolesService=l,this.tooltipsService=p,this.displayedColumns=["name","view","create","edit","delete","download"],this.defaultPermissions=yo,this.defaultActions=Bo,this.permissions=[{name:"account_settings",description:"Account Settings"},{name:"billing_tickets",description:"Billing Tickets"},{name:"company_information",description:"Company Information"},{name:"general_requests",description:"General Requests"},{name:"invoice",description:"Invoices"},{name:"order",description:"Orders"},{name:"portal_requests",description:"Portal Requests"},{name:"roles",description:"Roles"},{name:"sale_request",description:"Sale Requests"},{name:"service",description:"Services"},{name:"trouble_tickets",description:"Trouble Tickets"},{name:"users",description:"Users"}]}ngOnInit(){this.activeRoute.params.subscribe(t=>{this.loadRole(t.id)})}canAction(t,n){return this.rolesService.canAction(t,n)}loadRole(t){t&&(this.loading.set(!0),this.getRoleUsecase.execute(t).subscribe({next:n=>{this.defaultPermissionGroups=n.defaultPermissionGroups,null===n.permissionGroup&&(n.permissionGroup={name:"",description:"",permissionGroupChildren:{},can_edit:!1});for(const o in this.defaultPermissionGroups)if(null!=n.permissionGroup?.permissionGroupChildren&&!(o in n.permissionGroup?.permissionGroupChildren)){const a=this.defaultPermissionGroups[o];n.permissionGroup.permissionGroupChildren[o]={description:a.description,name:a.name,enabled:!1,actions:[],defaultActions:a.actions}}this.permissionGroup=n.permissionGroup},complete:()=>
1{this.breadcrumbs.setLinks([{route:"/",text:"Home"},{route:"/main/settings",text:"Settings"},{route:"/main/settings/company-settings",params:{page:1},text:"Roles"},{text:this.permissionGroup?.title?this.permissionGroup?.title:this.permissionGroup?.name}]),this.loading.set(!1)}}))}canToggle(t,n){return this.defaultPermissionGroups[t].actions.includes(n)}isChecked(t,n){return null!=this.permissionGroup?.permissionGroupChildren&&this.permissionGroup?.permissionGroupChildren[t]?.actions.includes(n)}onEdit(t){this.router.navigate(["main/settings/roles/edit/"+t])}onCopy(t){this.router.navigate(["main/settings/roles/edit/new"],{queryParams:{name:t}})}getPermission(t){return this.permissions.find(n=>n.name===t).description}}return _.\u0275fac=function(t){return new(t||_)(e.Y36(y.W),e.Y36(M.gz),e.Y36(de.M),e.Y36(M.F0),e.Y36(Pe.D),e.Y36(G.f),e.Y36(x.b))},_.\u0275cmp=e.Xpm({type:_,selectors:[["app-role-view"]],decls:33,vars:12,consts:function(){let i,t,n,o,a,r,l,p,S,N;return i="Role ID:",t="Description:",n="PERMISSIONS",o=" View " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",a=" Create " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",r=" Edit " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",l=" Print / Download " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",p=" Cancel / Delete " + "\ufffd#2\ufffd\ufffd/#2\ufffd" + "",S="EDIT",N="COPY",[[1,"role-details"],[1,"title","margin-top"],[1,"title-text","capital-gothic"],[4,"ngIf"],[1,"breadcrumbs"],[1,"details"],[1,"pink-divider"],[1,"details__field"],[1,"details__label"],i,[1,"details__value"],t,[1,"table-wrap"],["mat-table","",3,"dataSource"],["matColumnDef","name"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],[3,"matColumnDef",4,"ngFor","ngForOf"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],[1,"actions"],["class","arrow-container",3,"click",4,"ngIf"],["mat-header-cell",""],n,["mat-cell",""],[3,"matColumnDef"],o,a,r,l,p,["mat-header-row",""],["mat-row",""],[1,"arrow-container",3,"click"],[1,"arrow"],S,N]},template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"div",1)(2,"p",2),e._uU(3),e.YNc(4,Mo,3,1,"app-tooltip",3),e.qZA(),e.TgZ(5,"div",4),e._UZ(6,"wo-breadcrumbs"),e.qZA()(),e.TgZ(7,"div",5),e._UZ(8,"mat-divider",6),e.TgZ(9,"div",7)(10,"p",8),e.SDv(11,9),e.qZA(),e.TgZ(12,"p",10),e._uU(13),e.qZA()(),e._UZ(14,"mat-divider"),e.TgZ(15,"div",7)(16,"p",8),e.SDv(17,11),e.qZA(),e.TgZ(18,"p",10),e._uU(19),e.qZA()(),e._UZ(20,"mat-divider"),e.qZA(),e.TgZ(21,"div",12)(22,"table",13),e.ALo(23,"keyvalue"),e.ynx(24,14),e.YNc(25,Io,2,0,"th",15),e.YNc(26,fo,3,1,"td",16),e.BQk(),e.YNc(27,vo,3,1,"ng-container",17),e.YNc(28,$o,1,0,"tr",18),e.YNc(29,Go,1,0,"tr",19),e.qZA()(),e.TgZ(30,"div",20),e.YNc(31,wo,4,0,"div",21),e.YNc(32,Zo,4,0,"div",21),e.qZA()()),2&t&&(e.xp6(3),e.hij("",null!=n.permissionGroup&&n.permissionGroup.title?null==n.permissionGroup?null:n.permissionGroup.title:null==n.permissionGroup?null:n.permissionGroup.name," "),e.xp6(1),e.Q6J("ngIf",null==n.tooltipsService||null==n.tooltipsService.tooltips?null:n.tooltipsService.tooltips.role_details),e.xp6(9),e.Oqu(null==n.permissionGroup?null:n.permissionGroup.name),e.xp6(6),e.Oqu(null==n.permissionGroup?null:n.permissionGroup.description),e.xp6(3),e.Q6J("dataSource",e.lcZ(23,10,n.defaultPermissionGroups)),e.xp6(5),e.Q6J("ngForOf",n.defaultActions),e.xp6(1),e.Q6J("matHeaderRowDef",n.displayedColumns),e.xp6(1),e.Q6J("matRowDefColumns",n.displayedColumns),e.xp6(2),e.Q6J("ngIf",(null==n.permissionGroup?null:n.permissionGroup.can_edit)&&n.canAction("edit","roles")),e.xp6(1),e.Q6J("ngIf",n.canAction("create","roles")))},dependencies:[P.sg,P.O5,v.d,E.BZ,E.fO,E.as,E.w1,E.Dz,E.nj,E.ge,E.ev,E.XQ,E.Gk,U.K,B.g,P.Nd],styles:[".role-details[_ngcontent-%COMP%]{padding:0 60px 40px 0}@media (max-width: 960px){.role-details[_ngcontent-%COMP%]{padding-right:1rem}}.table-wrap[_ngcontent-%COMP%]{margin-top:40px;overflow-x:auto;white-space:nowrap}table[_ngcontent-%COMP%]{width:100%;table-layout:auto;min-width:900px;border-bottom:1px solid #000}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%], table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border:none}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:not(:first-child), table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:not(:first-child){text-align:center}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{color:#000;border-bottom:1px solid #000;font:400 14px Capital Gothic,Arial,sans-serif;vertical-align:top;text-transform:uppercase}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:first-child{padding-left:10px}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:not(:first-child){color:#144a90}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]   .mat-checkbox[_ngcontent-%COMP%]{margin-top:8px}table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:last-child{padding-right:0}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{width:15%}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:first-child{width:20%;padding-left:10px}table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:last-child{padding-right:0}[_nghost-%COMP%]     table.mat-table tbody tr:nth-child(odd){background:#EAF2FC}[_nghost-%COMP%]     table .mat-checkbox-inner-container{height:12px;width:12px}[_nghost-%COMP%]     table .mat-checkbox-ripple{display:none}[_nghost-%COMP%]     table .mat-checkbox-frame{border-radius:0;border:0;background:#DDDDDD}[_nghost-%COMP%]     table .mat-checkbox-indeterminate.mat-accent .mat-checkbox-background, [_nghost-%COMP%]     table .mat-checkbox-checked.mat-accent .mat-checkbox-background{background:#D6117F;border-radius:0}[_nghost-%COMP%]     table .mat-checkbox-checkmark{display:none}[_nghost-%COMP%]     table .mat-select-trigger{background:#144A90;padding:5px 10px 5px 5px;color:#fff!important;display:flex;text-align:center;height:20px;width:130px;text-transform:uppercase;font-size:14px}[_nghost-%COMP%]     table .mat-select-value{color:#fff!important}.actions[_ngcontent-%COMP%]{display:flex;margin:40px auto 0;gap:10%}.selection-control[_ngcontent-%COMP%]{display:flex;margin-top:20px;margin-left:57px;gap:100px}.form[_ngcontent-%COMP%]{width:50%;margin-bottom:70px;max-width:540px}@media (max-width: 1440px){.form[_ngcontent-%COMP%]{width:70%}}@media (max-width: 1180px){.form[_ngcontent-%COMP%]{width:90%}}.form[_ngcontent-%COMP%]   textarea[_ngcontent-%COMP%]{padding:10px;width:100%;box-sizing:border-box;border:1px solid #D9D9D9;background:#EAF2FC}.form[_ngcontent-%COMP%]   textarea[_ngcontent-%COMP%]::placeholder{font-size:14px;position:absolute;bottom:10px;left:10px;font-weight:300}.mat-form-field[_ngcontent-%COMP%]   .arrow[_ngcontent-%COMP%]{width:25px;height:10px;background-color:#959595;-webkit-mask:url(/en/assets/pic/sidebar/arrow-down.svg) no-repeat;mask:url(/en/assets/pic/sidebar/arrow-down.svg) no-repeat}  .issue-menu .mat-menu-content{display:flex!important;width:219px!important;height:147px!important;flex-direction:column!important;justify-content:space-between!important;padding:22px 20px 20px!important}  .issue-menu .mat-menu-content p{box-sizing:border-box!important;cursor:pointer!important;border-bottom:1px solid black!important;padding-bottom:10px!important;height:30px!important}  .issue-menu .mat-menu-content p span{visibility:hidden!important;margin-right:10px!important;margin-left:10px!important;display:inline-block;transform:translateY(-3px)!important}  .issue-menu .mat-menu-content p:hover{font-weight:600;border-bottom:2px solid #D6117F!important}  .issue-menu .mat-menu-content p:hover span{visibility:visible!important;color:#d6117f!important;font-size:10px!important}.mat-form-field[_ngcontent-%COMP%]{width:100%}.label[_ngcontent-%COMP%]{min-width:100px;margin-right:10px!important}.editable[_ngcontent-%COMP%]{background-color:#eaf2fc;padding:24px;margin-top:34px;flex:0 0 48%}.editable[_ngcontent-%COMP%]   mat-form-field[_ngcontent-%COMP%]{width:100%}.editable[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{flex:0 0 120px}.editable[_ngcontent-%COMP%]   .form-field[_ngcontent-%COMP%]{flex:1}.editable[_ngcontent-%COMP%]   .flex[_ngcontent-%COMP%]{align-items:baseline;position:relative}[_nghost-%COMP%]     .mat-form-field label, [_nghost-%COMP%]     .mat-select-placeholder{font-size:14px;margin-top:4px;color:#0000008a}app-custom-search-select[_ngcontent-%COMP%]{width:100%}  .form .mat-form-field-appearance-outline .mat-form-field-outline-start,   .form .mat-form-field-appearance-outline .mat-form-field-outline-end{border-bottom:1px solid #000!important}.checked[_ngcontent-%COMP%]{display:inline-block;background:url(/en/assets/pic/icons/checked.svg) center center no-repeat;width:35px;height:35px}.not-checked[_ngcontent-%COMP%]{display:inline-block;background:url(/en/assets/pic/icons/close.svg) center center no-repeat;width:35px;height:35px}.details[_ngcontent-%COMP%]{width:50%;margin-top:40px}.details__field[_ngcontent-%COMP%]{display:grid;grid-template-columns:max-content 1fr;gap:15px;padding:18px 18px 18px 28px}.details__label[_ngcontent-%COMP%]{width:130px;font-weight:700}mat-divider[_ngcontent-%COMP%]{border-top-color:#000}mat-divider.pink-divider[_ngcontent-%COMP%]{border-top-color:#d6117f;border-top-width:2px}"]}),_})();var X=T(82311);const Yo=[{path:"",pathMatch:"full",component:qt},{path:"account",component:Gt,canActivate:[X.p],data:{view:"account_settings",action:"view"}},{path:"company-settings",component:M_,canActivate:[X.p],data:{view:"company_information",action:"view"}},{path:"roles/edit/:name",component:j_,canActivate:[X.p],data:{view:"roles",action:"view"}},{path:"roles/:id",component:ko,canActivate:[X.p],data:{view:"roles",action:"view"}},{path:"user/:id",component:so,canActivate:[X.p],data:{view:"users",action:"view"}},{path:"user/edit/:id",component:Ao,canActivate:[X.p],data:{view:"users",action:"view"}}];let qo=(()=>{class _{}return _.\u0275fac=function(t){return new(t||_)},_.\u0275mod=e.oAB({type:_}),_.\u0275inj=e.cJS({imports:[M.Bz.forChild(Yo),M.Bz]}),_})();var Xo=T(5658),zo=T(17009),Jo=T(10794),Qo=T(7876);let Ho=(()=>{class _{}return _.\u0275fac=function(t){return new(t||_)},_.\u0275mod=e.oAB({type:_}),_.\u0275inj=e.cJS({imports:[P.ez,s.u5,Y.ot,te.p9,F.Is,v.t,z.To,Q.Ps,L.c,w.Tx,Ce.Fk,k.LD,J.rP,zo.ZX,H.JX,E.p0,Z.Nh,s.UX,qo,Qo.G,Xo.M,Jo.C]}),_})()}}]);

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.