1"use strict";(self.webpackChunksuivo_web=self.webpackChunksuivo_web||[]).push([[2608],{11971:(M,y,s)=>{function t(u){return u&&u.value?new RegExp(/^[A-HJ-NP-Z0-9]{13}$/).test(u.value.toUpperCase())?null:{invalid:{message:"checkinAtWork.sites.error.registrationNr.invalid"}}:null}s.d(y,{B:()=>t})},18169:(M,y,s)=>{s.r(y),s.d(y,{CreateEditTypeComponent:()=>Ct});var t=s(73664),u=s(27208),a=s(2615),F=s(17705),_=s(70246),h=s(72200),E=s(57515),g=s(60516),T=s(13803);class d{constructor(){this.id=null,this.group=null,this.description=null,this.translations=null,this.parent=null,this.costPerDay=null,this.rszCode=null}}var p=s(9728),v=s(11971),r=s(89417),l=s(73807),b=s(48926),I=s(86806),G=s(43626),j=s(58863),S=s(77120);function V(n,c){1&n&&(t.EFF(0),t.nI1(1,"translate")),2&n&&t.SpI(" ",t.bMT(1,1,"settings.entityTypes.edit")," ")}function B(n,c){if(1&n&&(t.EFF(0),t.nI1(1,"translate")),2&n){const e=t.XpG();t.SpI(" ",t.bMT(1,1,e.type&&e.parentId?"settings.entityTypes.add":"settings.entityTypes.new")," ")}}function L(n,c){if(1&n&&t.EFF(0),2&n){const e=t.XpG();t.SpI(" - ",e.parentDescription," ")}}function w(n,c){if(1&n&&(t.j41(0,"div",2)(1,"div",3)(2,"label"),t.EFF(3),t.nI1(4,"translate"),t.k0s(),t.nrm(5,"input",12)(6,"show-errors",5),t.k0s()()),2&n){const e=t.XpG();t.R7$(3),t.JRh(t.bMT(4,3,"settings.vehicleAdmin.dayCost")),t.R7$(2),t.Y8G("allowDecimals",!0),t.R7$(),t.Y8G("control",e.dayCost)}}function N(n,c){if(1&n&&(t.j41(0,"div",2)(1,"div",3)(2,"label"),t.EFF(3),t.nI1(4,"translate"),t.k0s(),t.nrm(5,"input",13)(6,"show-errors",5),t.k0s()()),2&n){const e=t.XpG();t.R7$(3),t.JRh(t.bMT(4,2,"checkinandout.workplaces.rsz")),t.R7$(3),t.Y8G("control",e.rszCode)}}let $=(()=>{class n{set data(e){this.parentId=e.parentId,this.id=e.id,this.parentDescription=e.parentDescription,this.group=e.groupType,this.setupType()}set serverErrors(e){if(this.resetValidation(),e)for(let o in e)this.typeForm.get(o).setErrors({server:{message:e[o]}})}constructor(e,o,i,m){this.fb=e,this.typesService=o,this.changeDetector=i,this.permissionService=m,this.groupType=u.MH,this.typesFormSubmitted=!1,this.typesFormSuccess=!1,this.saveButtonDisabled=!1,this.onFormSubmit=new t.bkB,this.onEdit=new t.bkB}ngOnInit(){this.groupTypes={UNIT:"permission.PAGE_VEHICLES",PERSON:"permission.PAGE_PERSONS",LOCATION:"permission.PAGE_LOCATIONS",COST_LOCATION:"permission.PAGE_COST_LOCATIONS",STOCK_LOCATION:"permission.PAGE_STOCK_LOCATIONS",CONSUMABLE:"permission.PAGE_CONSUMABLES",SITE:"allReports.site",SURCHARGE:"permission.ITEM_SURCHARGES",ABSENCE:"permission.ITEM_ABSENCES",TASK_CONFIG:"settings.account.planning.taskConfiguration",SKILL_CATEGORY:"settings.account.planning.skills.categories"},this.typeForm=this.fb.group({description:[null,[(0,T.Nj)()]],dayCost:[null],rszCode:[null,v.B],externalReference:[null]}),this.setupFormValues(),"true"===this.permissionService.getPreference("block_edit_external_reference")&&this.externalReference.disable({emitEvent:!1})}ngOnDestroy(){this.formSubscription&&this.formSubscription.unsubscribe()}submitTypeForm(){if(this.typesFormSubmitted=!0,this.typeForm.valid){this.saveButtonDisabled=!0,this.failed=!1;let e=this.typeForm.get("description").value,o=new d;o.id=this.id,o.group=this.group,o.description=e.label,o.translations=e.translations,o.parent=this.parentId,o.costPerDay=this.dayCost.value,o.rszCode=this.rszCode.value,o.externalReference=this.externalReference.value,this.typesService.saveEntityType(o).subscribe(i=>{this.serverErrors=i.errors,(0,g.b0)(i.errors)||null==i.errors||""==i.errors?(this.typesFormSubmitted=!1,this.typesFormSuccess=!0,this.saveButtonDisabled=!1,this.onFormSubmit.emit(i.entityType),this.onEdit.emit(!1),setTimeout(()=>{this.typesFormSuccess=!1,this.changeDetector.markForCheck()},3e3)):this.failed=!0})}}get description(){return this.typeForm.get("description")}resetValidation(){this.saveButtonDisabled=!1;for(let e in this.typeForm.controls)this.typeForm.get(e).setErrors(null)}setupType(){let e=!(0,g.b0)(this.id)&&this.id?this.id:this.parentId;e?this.typesService.getEntityType(e).subscribe(o=>{if(this.parentId){let i=new d;i.group=o.group,i.parent=o.id,this.type=i}else this.type=o;this.setupFormValues()}):(this.type=new d,this.setupFormValues())}
1setupFormValues(){this.typeForm&&(this.typeForm.reset({description:this.getDescriptionValue(),dayCost:(0,g.hX)(this.type)?null:this.type.costPerDay,rszCode:(0,g.hX)(this.type)?null:this.type.rszCode,externalReference:(0,g.hX)(this.type)?null:this.type.externalReference},{onlySelf:!0,emitEvent:!1}),this.description.markAsPristine(),this.onEdit.emit(!1),this.formSubscription=this.typeForm.valueChanges.subscribe(e=>{this.onEdit.emit(!0)}))}canSubmit(){return this.typeForm.dirty&&this.typeForm.valid&&!this.saveButtonDisabled}getDescriptionValue(){let e=new p.G;return this.type&&(e.label=this.type.description,e.translations=Object.assign({},this.type.translations)),e}get dayCost(){return this.typeForm.get("dayCost")}get rszCode(){return this.typeForm.get("rszCode")}get externalReference(){return this.typeForm.get("externalReference")}static{this.\u0275fac=function(o){return new(o||n)(t.rXU(r.ze),t.rXU(_.V),t.rXU(F.gRc),t.rXU(l.n))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["types-form"]],inputs:{data:"data"},outputs:{onFormSubmit:"onFormSubmit",onEdit:"onEdit"},standalone:!1,decls:31,vars:26,consts:[[2,"margin","0 0 20px 0"],[3,"formGroup"],[1,"row","form-group"],[1,"col-12"],["formControlName","description",3,"collapsible","hasValueError"],[3,"control"],[1,"row"],[1,"col-md-12"],["type","text","formControlName","externalReference",1,"form-control","form-control-sm"],[1,"col-md-12",3,"control"],["type","button",1,"btn","btn-sm","float-start",3,"click"],[3,"onButtonClick","success","failed","buttonDisabled","alignRight"],["type","text","formControlName","dayCost","numbersOnly","","smartFloat","",1,"form-control",3,"allowDecimals"],["type","text","formControlName","rszCode",1,"form-control"]],template:function(o,i){1&o&&(t.j41(0,"h3",0),t.nVh(1,V,2,3),t.nVh(2,B,2,3),t.EFF(3),t.nI1(4,"translate"),t.nVh(5,L,1,1),t.EFF(6,")\n"),t.k0s(),t.j41(7,"form",1)(8,"label"),t.EFF(9),t.nI1(10,"translate"),t.k0s(),t.j41(11,"div",2)(12,"div",3),t.nrm(13,"translatable-field",4),t.k0s(),t.j41(14,"div",3),t.nrm(15,"show-errors",5),t.k0s()(),t.nVh(16,w,7,5,"div",2),t.nVh(17,N,7,4,"div",2),t.j41(18,"div",6)(19,"label",7),t.EFF(20),t.nI1(21,"translate"),t.k0s(),t.j41(22,"div",7),t.nrm(23,"input",8),t.k0s(),t.nrm(24,"show-errors",9),t.k0s(),t.j41(25,"div",6)(26,"div",3)(27,"button",10),t.bIt("click",function(){return i.setupFormValues()}),t.EFF(28),t.nI1(29,"translate"),t.k0s(),t.j41(30,"success-submit-button",11),t.bIt("onButtonClick",function(){return i.submitTypeForm()}
1),t.k0s()()()()),2&o&&(t.R7$(),t.vxM(i.type&&i.type.id?1:-1),t.R7$(),t.vxM(i.type&&i.type.id?-1:2),t.R7$(),t.SpI(" (",t.bMT(4,18,i.groupTypes[i.groupType[i.group]])),t.R7$(2),t.vxM(i.parentId?5:-1),t.R7$(2),t.Y8G("formGroup",i.typeForm),t.R7$(2),t.JRh(t.bMT(10,20,"allpages.description")),t.R7$(4),t.Y8G("collapsible",!1)("hasValueError",i.typesFormSubmitted&&!i.description.valid),t.R7$(2),t.Y8G("control",i.description),t.R7$(),t.vxM(i.group!=i.groupType.SITE&&i.group!=i.groupType.ABSENCE&&i.group!=i.groupType.SURCHARGE&&i.group!=i.groupType.TASK_CONFIG&&i.group!=i.groupType.SKILL_CATEGORY?16:-1),t.R7$(),t.vxM(i.group==i.groupType.SITE?17:-1),t.R7$(3),t.JRh(t.bMT(21,22,"allpages.externalReference")),t.R7$(4),t.Y8G("control",i.externalReference),t.R7$(4),t.SpI(" ",t.bMT(29,24,"allpages.button.reset")," "),t.R7$(2),t.Y8G("success",i.typesFormSuccess)("failed",i.failed)("buttonDisabled",!i.canSubmit())("alignRight",!0))},dependencies:[r.qT,r.me,r.BC,r.cb,r.j4,r.JD,b.w,I.l,p.b,G.t,j.a,S.D],styles:[".alert-success[_ngcontent-%COMP%]{padding-top:3px;padding-bottom:3px;margin-top:8px}.groupType[_ngcontent-%COMP%]{margin-top:5px;display:inline-block}"],changeDetection:0})}}return n})();var U=s(41233),P=s(87531),X=s(21270),Y=s(75081),z=s(6017);const H=n=>({fullHeight:n}),K=(n,c)=>({"fa-chevron-down":n,"fa-chevron-right":c}),W=n=>({"padding-left":n});function J(n,c){if(1&n){const e=t.RV6();t.j41(0,"attributes-config-list",5),t.bIt("onAttributeAction",function(i){a.eBV(e);const m=t.XpG(2);return a.Njj(m.onAttributeAction.emit(i))}),t.k0s()}if(2&n){const e=t.XpG(2);t.Y8G("attributes",e.currentEntityType.attributes)("selectedAttribute",e.selectedAttribute)}}function Z(n,c){if(1&n&&(t.j41(0,"li")(1,"div",10),t.EFF(2),t.k0s()()),2&n){const e=c.$implicit;t.R7$(2),t.SpI(" ",e.name," ")}}function Q(n,c){if(1&n&&(t.j41(0,"ul"),t.Z7z(1,Z,3,1,"li",null,t.fX1),t.k0s()),2&n){const e=t.XpG().$implicit;t.R7$(),t.Dyx(e.attributes)}}function q(n,c){if(1&n&&(t.j41(0,"li",9)(1,"b"),t.EFF(2),t.k0s(),t.nVh(3,Q,3,0,"ul"),t.k0s()),2&n){const e=c.$implicit;t.Y8G("ngStyle",t.eq3(3,W,e.level?10*e.level+"px":0)),t.R7$(2),t.JRh(e.description),t.R7$(),t.vxM(e.attributes&&0!=e.attributes.length?3:-1)}}function tt(n,c){if(1&n&&(t.j41(0,"div",8)(1,"ul"),t.Z7z(2,q,4,5,"li",9,t.fX1),t.k0s()()),2&n){const e=t.XpG(3);t.R7$(2),t.Dyx(e.relatedEntityTypes)}}function et(n,c){if(1&n){const e=t.RV6();t.j41(0,"div",1)(1,"h3",6),t.bIt("click",function(){a.eBV(e);const i=t.XpG(2);return a.Njj(i.relatedAttributesVisible=!i.relatedAttributesVisible)}),t.EFF(2),t.nI1(3,"translate"),t.nrm(4,"i",7),t.k0s()(),t.nVh(5,tt,4,0,"div",8)}if(2&n){const e=t.XpG(2);t.R7$(2),t.SpI(" ",t.bMT(3,3,"settings.customFields.inherited")," "),t.R7$(2),t.Y8G("ngClass",t.l_i(5,K,e.relatedAttributesVisible&&!e.shrink,!e.relatedAttributesVisible||e.shrink)),t.R7$(),t.vxM(e.relatedAttributesVisible&&!e.shrink?5:-1)}}function nt(n,c){if(1&n&&(t.j41(0,"div",0)(1,"div",1)(2,"h3",2),t.EFF(3),t.nI1(4,"translate"),t.k0s()(),t.j41(5,"div",3),t.nVh(6,J,1,2,"attributes-config-list",4),t.nVh(7,et,6,8),t.k0s()()),2&n){const e=t.XpG();t.Y8G("ngClass",t.eq3(7,H,!e.shrink&&e.relatedAttributesVisible)),t.R7$(3),t.Lme(" ",t.bMT(4,5,"allpages.type"),": ",e.currentEntityType.description," "),t.R7$(3),t.vxM(e.currentEntityType?6:-1),t.R7$(),t.vxM(e.relatedEntityTypes&&0!=e.relatedEntityTypes.length?7:-1)}}let it=(()=>{class n{set selectedAttribute(e){this._selectedAttribute=e,this.relatedAttributesVisible=!1}get selectedAttribute(){return this._selectedAttribute}set config(e){e&&this.getRelevantAttributes(e.items,e.entityTypes)}constructor(e,o){this.permissionService=e,this.translation=o,this.permissions=new Map,this.relatedAttributesVisible=!0,this.editable=!1,this.onAttributeAction=new t.bkB}ngOnInit(){this.permissions=new Map([["CUSTOM_FIELD_DEFINITION_CREATE",1==this.permissionService.get("CUSTOM_FIELD_DEFINITION_CREATE")],["CUSTOM_FIELD_DEFINITION_UPDATE",1==this.permissionService.get("CUSTOM_FIELD_DEFINITION_UPDATE")],["CUSTOM_FIELD_DEFINITION_DELETE",1==this.permissionService.get("CUSTOM_FIELD_DEFINITION_DELETE")]])}getRelevantAttributes(e,o){let i=this;this.relatedEntityTypes=[],function k(C,R,A){for(let f of R)f.id==C?(i.currentEntityType=f,i.currentEntityType.attributes=O(f.i
1d,e)):x(C,f)&&(f.attributes=O(f.id,e),f.level=A,i.relatedEntityTypes.push(f),f.subTypes&&0!=f.subTypes.length&&k(C,f.subTypes,A+1))}(this.selectedType,o,0);let m=O(null,e);if(m){let C=new u.ck;C.description=this.translation.get("permission.ITEM_GENERAL"),C.attributes=m,this.relatedEntityTypes.push(C)}function O(C,R){let A=[];for(let f of R)(null==C&&!f.entityType||f.entityType==C)&&A.push(f);return 0!=A.length?A:null}function x(C,R){return!(!R.subTypes||0==R.subTypes.length)&&R.subTypes.find(A=>A.id==C||x(C,A))}this.currentEntityType&&!this.currentEntityType.attributes&&(this.currentEntityType.attributes=[])}static{this.\u0275fac=function(o){return new(o||n)(t.rXU(l.n),t.rXU(P.L))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["types-attributes-list"]],inputs:{shrink:"shrink",selectedAttribute:"selectedAttribute",editable:"editable",selectedType:"selectedType",config:"config"},outputs:{onAttributeAction:"onAttributeAction"},standalone:!1,decls:1,vars:1,consts:[[1,"card","attributesList",3,"ngClass"],[1,"card-header"],[1,"card-title"],[1,"listContent"],[3,"attributes","selectedAttribute"],[3,"onAttributeAction","attributes","selectedAttribute"],[1,"card-title","action",3,"click"],[1,"fas","float-end",3,"ngClass"],[1,"card-body"],[3,"ngStyle"],[1,"col-12"]],template:function(o,i){1&o&&t.nVh(0,nt,8,9,"div",0),2&o&&t.vxM(i.currentEntityType?0:-1)},dependencies:[h.YU,h.B3,z.$,S.D],styles:["[_nghost-%COMP%] .attributesList[_ngcontent-%COMP%] .listContent[_ngcontent-%COMP%]{overflow-y:auto;margin-top:-1px}[_nghost-%COMP%] .attributesList.fullHeight[_ngcontent-%COMP%]{height:calc(100% - 90px)}[_nghost-%COMP%] .attributesList.fullHeight[_ngcontent-%COMP%] .listContent[_ngcontent-%COMP%]{height:calc(100% - 34px)}[_nghost-%COMP%] .attributesList[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{border:1px solid var(--colors-general-soft-grey);background-color:var(--colors-general-background-grey)}[_nghost-%COMP%] .attributesList[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%]{border:1px solid var(--colors-general-soft-grey);padding-top:5px;padding-bottom:5px}"]})}}return n})();function ot(n,c){if(1&n){const e=t.RV6();t.j41(0,"button",7),t.bIt("click",function(){a.eBV(e);const i=t.XpG(2);return a.Njj(i.dispatchAttributeAction({action:"create"}))}),t.nrm(1,"i",8),t.EFF(2),t.nI1(3,"translate"),t.k0s()}2&n&&(t.R7$(2),t.SpI("\xa0",t.bMT(3,1,"settings.customFields.new")," "))}function st(n,c){if(1&n&&(t.j41(0,"div",1)(1,"div",5),t.nVh(2,ot,4,3,"button",6),t.k0s()()),2&n){const e=t.XpG();t.R7$(2),t.vxM(e.permissions.CUSTOM_FIELD_DEFINITION_CREATE?2:-1)}}function rt(n,c){if(1&n){const e=t.RV6();t.j41(0,"div",3)(1,"div",9)(2,"h3",10),t.EFF(3),t.nI1(4,"translate"),t.j41(5,"i",11),t.bIt("click",function(){a.eBV(e);const i=t.XpG();return a.Njj(i.cancelAttributeForm())}),t.k0s()()(),t.j41(6,"div",12)(7,"attributes-config-form",13),t.bIt("onFormSubmit",function(i){a.eBV(e);const m=t.XpG();return a.Njj(m.formSubmitted(i))}),t.k0s()()()}if(2&n){const e=t.XpG();t.R7$(3),t.SpI(" ",t.bMT(4,5,e.selectedAttribute?"settings.customFields.edit":"settings.customFields.new")," "),t.R7$(4),t.Y8G("config",e.config)("groupType",e.groupType)("entityType",e.entityType)("attributeId",e.selectedAttribute)}}function at(n,c){if(1&n){const e=t.RV6();t.j41(0,"list-delete-popup",14),t.bIt("onConfirmDelete",function(){a.eBV(e);const i=t.XpG();return a.Njj(i.deleteAttribute())})("closePopup",function(){a.eBV(e);const i=t.XpG();return a.Njj(i.deletePopup.visible=!1)}),t.k0s()}if(2&n){const e=t.XpG();t.Y8G("requestCode",!0)("confirmationMessage",e.deletePopup.confirmationMessage)}}let lt=(()=>{class n{set groupType(e){this._groupType=e,(0,g.hX)(e)||this.attributesService.getConfig(e,!0).subscribe(o=>{this.config=o,this.changeDetection.markForCheck()})}get groupType(){return this._groupType}ngOnInit(){}constructor(e,o,i,m){this.attributesService=e,this.permissionService=o,this.translation=i,this.changeDetection=m,this.showAttributeForm=!1,this.deletePopup={visible:!1},this.permissions={CUSTOM_FIELD_DEFINITION_CREATE:1==this.permissionService.get("CUSTOM_FIELD_DEFINITION_CREATE")}}formSubmitted(e){this.config=e,setTimeout(()=>{this.showAttributeForm=!1,this.selectedAttribute=null,this.changeDetection.markForCheck()},3e3)}cancelAttributeForm(){this.showAttributeForm=!1,this.selectedAttribute=null}deleteAttribute(){this.attributesService.deleteConfig(this.deletePopup.attribute.group,this.deletePopup.attribute.id,!0).subscribe(e=>{this.config=e,delete this.deletePopup.confirmationMessage,delete this.deletePopup.attribute,this.deletePopup.visible=!1,this.changeDetection.markForCheck()})}dispatchAttributeAction(e){if("delete"===e.action){let o="";e.config.used&&(o=this.translation.get("settings.vehicleAdmin.warning.title").toUpperCase()+": "+this.translation.get("settings.customFields.config.used."+e.config.group+".confirmDelete")),o+=this.translation.get("settings.customFields.config.confirmDelete"),this.deletePopup.confirmationMessage=o,this.deletePopup.attribute=e.config,this.deletePopup.visible=!0}else"edit"===e.action?(this.showAttributeForm=!0,this.selectedAttribute=e.id):"create"===e.action&&(this.showAttributeForm=!0,this.selectedAttribute=null)}static{this.\u0275fac=function(o){return new(o||n)(t.rXU(U.x),t.rXU(l.n),t.rXU(P.L),t.rXU(F.gRc))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["attributes-config"]],inputs:{groupType:"groupType",entityType:"entityType"},standalone:!1,decls:7,vars:10,consts:[[2,"margin","0 0 10px 0"],[1,"row"],[3,"onAttributeAction","config","selectedType","selectedAttribute","shrink"],[1,"card","newAttribute"],[3,"requestCode","confirmationMessage"],[1,"col-12"],["type","button",1,"btn","btn-sm","createButton","float-end"],["type","button",1,"btn","btn-sm","createButton","float-end",3,"click"],[1,"fas","fa-plus"],[1,"card-header"],[1,"card-title"],[1,"float-end","fas","fa-times","action",3,"click"],[1,"card-body"],[3,"onFormSubmit","config","groupType","entityType","attributeId"],[3,"onConfirmDelete","closePopup","requestCode","confirmationMessage"]],template:function(o,i){1&o&&(t.j41(0,"h3",0),t.EFF(1),t.nI1(2,"translate"),t.k0s(),t.nVh(3,st,3,1,"div",1),t.j41(4,"types-attributes-list",2),t.bIt("onAttributeAction",function(O){return i.dispatchAttributeAction(O)}),t.k0s(),t.nVh(5,rt,8,7,"div",3),t.nVh(6,at,1,2,"list-delete-popup",4)),2&o&&(t.R
17$(),t.JRh(t.bMT(2,8,"settings.customFields.config.title")),t.R7$(2),t.vxM(i.showAttributeForm?-1:3),t.R7$(),t.Y8G("config",i.config)("selectedType",i.entityType)("selectedAttribute",i.selectedAttribute)("shrink",i.showAttributeForm),t.R7$(),t.vxM(i.showAttributeForm?5:-1),t.R7$(),t.vxM(null!=i.deletePopup&&i.deletePopup.visible?6:-1))},dependencies:[X.h,Y.T,it,S.D],styles:[".card[_ngcontent-%COMP%]{margin-top:15px}.createButton[_ngcontent-%COMP%]{margin-top:0;margin-bottom:10px}.newAttribute[_ngcontent-%COMP%]{border:1px solid var(--colors-general-soft-grey)!important}"],changeDetection:0})}}return n})();const ct=n=>({active:n});function pt(n,c){if(1&n&&(t.qex(0),t.EFF(1),t.bVm()),2&n){const e=t.XpG(3);t.R7$(),t.JRh(e.data.description)}}function ut(n,c){if(1&n){const e=t.RV6();t.j41(0,"i",12),t.bIt("click",function(){a.eBV(e);const i=t.XpG(3);return a.Njj(i.cancelFunction.emit())}),t.k0s()}}function dt(n,c){if(1&n&&(t.j41(0,"h2"),t.DNE(1,pt,2,1,"ng-container",0)(2,ut,1,0,"i",11),t.k0s()),2&n){const e=t.XpG(2);t.R7$(),t.Y8G("ngIf",(null==e.data?null:e.data.description)&&e.data.id&&!e.data.parentId),t.R7$(),t.Y8G("ngIf",!e.hideCloseButton)}}function mt(n,c){if(1&n){const e=t.RV6();t.j41(0,"li",13),t.bIt("click",function(){const i=a.eBV(e).$implicit,m=t.XpG(2);return a.Njj(m.setActiveFlow(m.getFlow(i.action)))}),t.j41(1,"a"),t.EFF(2),t.nI1(3,"translate"),t.k0s()()}if(2&n){const e=c.$implicit,o=t.XpG(2);t.Y8G("ngClass",t.eq3(4,ct,o.activeFlow.action==e.action)),t.R7$(2),t.JRh(t.bMT(3,2,e.title))}}function _t(n,c){if(1&n&&(t.j41(0,"li",14)(1,"a"),t.nrm(2,"i",15),t.k0s(),t.j41(3,"div",16),t.EFF(4),t.nI1(5,"translate"),t.k0s()()),2&n){const e=t.XpG(2);t.R7$(4),t.JRh(t.bMT(5,1,e.activeFlow.info))}}function ht(n,c){if(1&n){const e=t.RV6();t.j41(0,"types-form",17),t.bIt("onFormSubmit",function(i){a.eBV(e);const m=t.XpG(2);return a.Njj(m.formSubmitted(i))})("onEdit",function(i){a.eBV(e);const m=t.XpG(2);return a.Njj(m.setHasEdit(i))}),t.k0s()}if(2&n){const e=t.XpG(2);t.Y8G("data",e.data)}}function ft(n,c){if(1&n&&t.nrm(0,"attributes-config",18),2&n){const e=t.XpG(2);t.Y8G("groupType",e.data.groupType)("entityType",e.data.id)}}function gt(n,c){if(1&n){const e=t.RV6();t.j41(0,"avatar-settings",19),t.bIt("onAvatarSave",function(){a.eBV(e);const i=t.XpG(2);return a.Njj(i.refreshFunction.emit(!0))}),t.k0s()}if(2&n){const e=t.XpG(2);t.Y8G("typeId",e.data.id)("groupId",e.groupType[e.data.groupType])}}function bt(n,c){if(1&n&&(t.qex(0),t.j41(1,"div",1)(2,"div",2),t.DNE(3,dt,3,2,"h2",0),t.j41(4,"ul",3),t.DNE(5,mt,4,6,"li",4)(6,_t,6,3,"li",5),t.k0s()()(),t.j41(7,"collapsible-panel-content",6)(8,"div",7),t.DNE(9,ht,1,1,"types-form",8)(10,ft,1,2,"attributes-config",9)(11,gt,1,2,"avatar-settings",10),t.k0s()(),t.bVm()),2&n){const e=t.XpG();t.R7$(3),t.Y8G("ngIf",(null==e.data?null:e.data.description)||!e.hideCloseButton),t.R7$(2),t.Y8G("ngForOf",e.availableActions),t.R7$(),t.Y8G("ngIf",e.activeFlow.info&&""!=e.activeFlow.info),t.R7$(),t.Y8G("row",!0)("flow",e.activeFlow.action)("ngSwitch",e.activeFlow.action),t.R7$(2),t.Y8G("ngSwitchCase","general"),t.R7$(),t.Y8G("ngSwitchCase","customFields"),t.R7$(),t.Y8G("ngSwitchCase","avatar")}}let Ct=(()=>{class n{set activeFlow(e){this._activeFlow=e,e&&(this.availableActions=this.typesService.getTypesActions(!this.data||!this.data.id,this.data))}get activeFlow(){return this._activeFlow}constructor(e,o){this.typesService=e,this.changeDetector=o,this.changeAlertFunction=new t.bkB,this.refreshFunction=new t.bkB,this.cancelFunction=new t.bkB,this.hasEditFunction=new t.bkB,this.groupType=u.MH}ngOnInit(){this.activeFlow||(this.availableActions=this.typesService.getTypesActions(!0),this.setActiveFlow(this.getFlow("general")))}setHasEdit(e){this.hasEdit=e,this.hasEditFunction.emit(e)}formSubmitted(e){if(e){let o=e;o.parentId=null,o.groupType="string"==typeof e.group?u.MH[e.group]:e.group,o.editable=!0,this.data=o,this.availableActions=this.typesService.getTypesActions(!1,this.data),this.setActiveFlow(this.activeFlow)}this.refreshFunction.emit(e)}setShowAlert(e){this.showAlert=e,this.changeAlertFunction.emit(e)}getFlow(e){return this.availableActions.find(function(o){return o.action===e})}setActiveFlow(e){this.setShowAlert(!1),this.data&&(e.type=this.data),this.activeFlow=Object.assign({},e),this.changeDetector.markForCheck()}static{this.\u0275fac=function(o){return new(o||n)(t.rXU(_.V),t.rXU(F.gRc))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["create-edit-type"]],inputs:{data:"data",activeFlow:"activeFlow",hideCloseButton:"hideCloseButton"},outputs:{changeAlertFunction:"changeAlertFunction",refreshFunction:"refreshFunction",cancelFunction:"cancelFunction",hasEditFunction:"hasEditFunction"},standalone:!1,decls:1,vars:1,consts:[[4,"ngIf"],[1,"row",2,"min-height","75px"],[1,"col-12"],[1,"nav","nav-pills"],["role","presentation",3,"ngClass","click",4,"ngFor","ngForOf"],["class","float-end help",4,"ngIf"],["toggle-alert","showAlert",3,"row","flow","ngSwitch"],[1,"container-fluid"],[3,"data","onFormSubmit","onEdit",4,"ngSwitchCase"],[3,"groupType","entityType",4,"ngSwitchCase"],[3,"typeId","groupId","onAvatarSave",4,"ngSwitchCase"],["class","fas fa-times action float-end",3,"click",4,"ngIf"],[1,"fas","fa-times","action","float-end",3,"click"],["role","presentation",3,"click","ngClass"],[1,"float-end","help"],[1,"fas","fa-info-circle"],[1,"helpdiv","left"],[3,"onFormSubmit","onEdit","data"],[3,"groupType","entityType"],[3,"onAvatarSave","typeId","groupId"]],template:function(o,i){1&o&&t.DNE(0,bt,12,9,"ng-container",0),2&o&&t.Y8G("ngIf",i.activeFlow)},dependencies:[h.YU,h.Sq,h.bT,h.ux,h.e1,E.W,$,lt,S.D],styles:["[_nghost-%COMP%]{display:flex;height:100%;flex-direction:column}.container-fluid[_ngcontent-%COMP%]{height:100%}collapsible-panel-content[_ngcontent-%COMP%]{overflow-y:auto}"],changeDetection:0})}}return n})()},21270:(M,y,s)=>{s.d(y,{h:()=>T});var t=s(73664),u=s(2615),a=s(86806),F=s(28110),_=s(77120);function h(d,D){if(1&d&&(t.j41(0,"span"),t.EFF(1),t.nI1(2,"translate"),t.k0s()),2&d){const p=t.XpG();t.R7$(),t.JRh(t.i5U(2,1,"allpages.list.view.delete.selectedItems",p.numberOfItems+""))}}function E(d,D){1&d&&(t.j41(0,"span"),t.EFF(1),t.nI1(2,"translate"),t.k0s()),2&d&&(t.R
17$(),t.JRh(t.bMT(2,1,"allpages.button.delete")))}function g(d,D){if(1&d){const p=t.RV6();t.j41(0,"confirmation-code-input",10),t.bIt("onConfirmation",function(r){u.eBV(p);const l=t.XpG();return u.Njj(l.confirmed=r)}),t.k0s()}}let T=(()=>{class d{constructor(){this.closePopup=new t.bkB,this.onConfirmDelete=new t.bkB}confirmDelete(){this.buttonDisabled=!0,(!this.requestCode||this.confirmed)&&this.onConfirmDelete.emit()}static{this.\u0275fac=function(v){return new(v||d)}}static{this.\u0275cmp=t.VBU({type:d,selectors:[["list-delete-popup"]],inputs:{numberOfItems:"numberOfItems",requestCode:"requestCode",confirmationMessage:"confirmationMessage",errors:"errors"},outputs:{closePopup:"closePopup",onConfirmDelete:"onConfirmDelete"},standalone:!1,decls:19,vars:13,consts:[[1,"popupBackgroundOverlay"],[1,"optionsPopup","checkinSitesPopup"],[1,"popupContent","empty","full-height"],[1,"optionForm","full-height"],["type","button",1,"btn-close","float-end",3,"click"],[1,"full-height"],[1,"row"],[1,"col-12"],["type","button",1,"btn","float-start","nomargin",3,"click"],[3,"onButtonClick","buttonClass","buttonText","alignRight","buttonDisabled"],[3,"onConfirmation"]],template:function(v,r){1&v&&(t.j41(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"button",4),t.bIt("click",function(){return r.closePopup.emit()}),t.k0s(),t.j41(5,"h1"),t.nVh(6,h,3,4,"span"),t.nVh(7,E,3,3,"span"),t.k0s(),t.j41(8,"div",5),t.EFF(9),t.nI1(10,"translate"),t.nVh(11,g,1,0,"confirmation-code-input"),t.nrm(12,"hr"),t.j41(13,"div",6)(14,"div",7)(15,"button",8),t.bIt("click",function(){return r.closePopup.emit()}),t.EFF(16),t.nI1(17,"translate"),t.k0s(),t.j41(18,"success-submit-button",9),t.bIt("onButtonClick",function(){return r.confirmDelete()}),t.k0s()()()()()()()()),2&v&&(t.R7$(6),t.vxM(r.numberOfItems?6:-1),t.R7$(),t.vxM(r.numberOfItems?-1:7),t.R7$(2),t.SpI(" ",r.confirmationMessage?r.confirmationMessage:t.bMT(10,9,"allpages.list.confirmdelete")," "),t.R7$(2),t.vxM(r.requestCode?11:-1),t.R7$(5),t.SpI(" ",t.bMT(17,11,"allpages.button.cancel")," "),t.R7$(2),t.Y8G("buttonClass","nomargin")("buttonText","allpages.button.confirm")("alignRight",!0)("buttonDisabled",r.requestCode&&!r.confirmed||r.buttonDisabled))},dependencies:[a.l,F.M,_.D],styles:[".optionsPopup[_ngcontent-%COMP%]{width:400px;left:calc((100% - 400px)/2)!important;bottom:auto!important}"],changeDetection:0})}}return d})()},28110:(M,y,s)=>{s.d(y,{M:()=>D});var t=s(73664),u=s(89417),a=s(2615),F=s(72200),_=s(6369),h=s(58863),E=s(77120);const g=p=>({index:p});function T(p,v){if(1&p&&t.eu8(0,5),2&p){const r=v.$implicit;t.XpG();const l=t.sdS(8);t.Y8G("ngTemplateOutlet",l)("ngTemplateOutletContext",t.eq3(2,g,r))}}function d(p,v){if(1&p){const r=t.RV6();t.j41(0,"input",6),t.bIt("focus",function(){const b=a.eBV(r).index,I=t.XpG();return a.Njj(I.codeFocus=b)}),t.k0s()}if(2&p){const r=v.index,l=t.XpG();t.Y8G("formControlName",t.VkB("code",r))("inputFocus",l.codeFocus==r)}}let D=(()=>{class p{static{this.codeLength=6}constructor(r){this.fb=r,this.codeArray=Array(p.codeLength).fill(0).map((l,b)=>b+1),this.codeFocus=1,this.onConfirmation=new t.bkB,this.confirmationCode=p.generateCode(),this.codeForm=this.fb.group({})}ngOnInit(){this.codeArray=Array(p.codeLength).fill(0).map((r,l)=>(this.codeForm.addControl("code"+(l+1),new u.hs(null,u.k0.required)),l+1)),this.codeForm.setValidators(this.isValidCode(this.confirmationCode)),this.formSubscription=this.codeForm.valueChanges.subscribe(r=>{this.codeFocus=this.codeFocus<p.codeLength?this.codeFocus+1:null,this.co
1deForm.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),this.onConfirmation.emit(this.codeForm.valid)}),this.visibleConfirmationCode=this.confirmationCode.substr(0,3)+" "+this.confirmationCode.substr(3,6)}static generateCode(){let r=[],l=0;for(;l<p.codeLength;)r.push(Math.floor(10*Math.random())),l++;return r.join("")}isValidCode(r){return l=>{if(!l||!l.value)return null;let b="",I=0;for(;I<p.codeLength;)b+=l.get("code"+(I+1)).value,I++;return b!=r?{invalid:{value:b,message:"allpages.error.invalidValue"}}:null}}static{this.\u0275fac=function(l){return new(l||p)(t.rXU(u.ze))}}static{this.\u0275cmp=t.VBU({type:p,selectors:[["confirmation-code-input"]],outputs:{onConfirmation:"onConfirmation"},standalone:!1,decls:9,vars:5,consts:[["CODE_INPUT",""],[3,"formGroup"],[1,"container-fluid","mainCodeContainer","form-control"],[3,"innerHTML"],[1,"codeContainer"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],["type","text","numbersOnly","",1,"form-control","input-md","codeInput","float-start",3,"focus","formControlName","inputFocus"]],template:function(l,b){1&l&&(t.j41(0,"form",1)(1,"div",2),t.nrm(2,"label",3),t.nI1(3,"translate"),t.j41(4,"div",4),t.Z7z(5,T,1,4,"ng-container",5,t.fX1),t.DNE(7,d,1,3,"ng-template",null,0,t.C5r),t.k0s()()()),2&l&&(t.Y8G("formGroup",b.codeForm),t.R7$(2),t.Y8G("innerHTML",t.i5U(3,2,"allpages.list.view.delete.confirm.code","<b class=confirmationCode>"+b.visibleConfirmationCode+"</b>"),t.npT),t.R7$(3),t.Dyx(b.codeArray))},dependencies:[F.T3,u.qT,u.me,u.BC,u.cb,u.j4,u.JD,_.i,h.a,E.D],styles:[".mainCodeContainer[_ngcontent-%COMP%]{text-align:center;margin-top:15px;padding:10px;height:auto}.mainCodeContainer[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{font-size:12px}.mainCodeContainer[_ngcontent-%COMP%] .codeContainer[_ngcontent-%COMP%]{display:inline-block;margin-top:10px}.mainCodeContainer[_ngcontent-%COMP%] .codeContainer[_ngcontent-%COMP%] .codeInput[_ngcontent-%COMP%]{width:30px;margin:0 3px;padding:3px;text-align:center;font-size:15px}[_nghost-%COMP%] .confirmationCode{letter-spacing:.03em;font-size:13px}"],changeDetection:0})}}return p})()},43626:(M,y,s)=>{s.d(y,{t:()=>u});var t=s(73664);let u=(()=>{class a{constructor(_){this.elementRef=_,this.smartFloat=new t.bkB,this.element=this.elementRef.nativeElement}onFocus(_){-1!=_.indexOf(",")&&(this.element.value=_.replace(",","."),this.smartFloat.emit(this.element.value))}onBlur(_){-1!=_.indexOf(",")&&(this.element.value=_.replace(",","."),this.smartFloat.emit(this.element.value))}static{this.\u0275fac=function(h){return new(h||a)(t.rXU(t.aKT))}}static{this.\u0275dir=t.FsC({type:a,selectors:[["","smartFloat",""]],hostBindings:function(h,E){1&h&&t.bIt("keyup",function(T){return E.onFocus(T.target.value)})("blur",function(T){return E.onBlur(T.target.value)})},outputs:{smartFloat:"smartFloat"},standalone:!1})}}return a})()},79624:(M,y,s)=>{s.d(y,{C:()=>t});class t{constructor(F,_,h,E,g,T,d){this.action=F,this.title=_,this.info=h,this.shortInfo=E,this.icon=g,this.faIcon=T,this.section=d}}}}]);
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.