PageSourceSearch

https://napovednik.com/857.56a14c52f9185ff3.js

js napovednik.com collected 2026-10-02 11:13:48 UTC 115,735 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkNapovednik=self.webpackChunkNapovednik||[]).push([[857],{2975:(re,w,p)=>{p.d(w,{V:()=>L});var T=p(177),o=p(4438),d=p(9417),B=p(5176),b=p(4404),z=p(3887),O=p(5687),N=p(6508),y=p(1413),e=p(1594),t=p(6977),n=p(4372),$=p(5335),i=p(783),M=p(8958),R=p(5312),k=p(1562);let Y=(()=>{class F{constructor(h){this.http=h}firstStepReq(h){return this.http.post(`${R.c.api}/controlpanel/v1/event`,h)}editFirstStepReq(h,G){return this.http.patch(`${R.c.api}/controlpanel/v1/event/${G}/info`,h)}static{this.\u0275fac=function(G){return new(G||F)(o.KVO(k.Qq))}}static{this.\u0275prov=o.jDH({token:F,factory:F.\u0275fac,providedIn:"root"})}}return F})();var ee=p(345),te=p(2219);const K=F=>({"is-invalid":F});function P(F,A){1&F&&o.nrm(0,"event-steps",41),2&F&&o.Y8G("step",1)}function V(F,A){if(1&F&&o.nrm(0,"app-form-error",42),2&F){const h=o.XpG();o.Y8G("validationErrors",h.form.name.errors)}}function X(F,A){if(1&F&&o.nrm(0,"app-form-error",42),2&F){const h=o.XpG();o.Y8G("validationErrors",h.form.nameEn.errors)}}function ne(F,A){if(1&F&&(o.j41(0,"option",43),o.EFF(1),o.nI1(2,"transloco"),o.k0s()),2&F){const h=A.$implicit;o.Y8G("value",h.idCodeListGenre),o.R7$(),o.SpI(" ",o.bMT(2,2,"CodeList.Genre."+h.nameTranslation)," ")}}function oe(F,A){if(1&F&&o.nrm(0,"app-form-error",42),2&F){const h=o.XpG();o.Y8G("validationErrors",h.form.idCodeListGenre.errors)}}function C(F,A){if(1&F&&(o.j41(0,"option",43),o.EFF(1),o.nI1(2,"transloco"),o.k0s()),2&F){const h=A.$implicit;o.Y8G("value",h.idCodeListGenre),o.R7$(),o.SpI(" ",o.bMT(2,2,"CodeList.Sub-genre."+h.nameTranslation)," ")}}function q(F,A){if(1&F&&o.nrm(0,"app-form-error",42),2&F){const h=o.XpG();o.Y8G("validationErrors",h.form.idCodeListSubGenre.errors)}}function _(F,A){if(1&F&&o.nrm(0,"app-form-error",42),2&F){const h=o.XpG(2);o.Y8G("validationErrors",h.form.specialSubGenre.errors)}}function D(F,A){if(1&F&&(o.j41(0,"div",19)(1,"label",44),o.EFF(2),o.nI1(3,"transloco"),o.j41(4,"span",12),o.EFF(5,"*"),o.k0s()(),o.nrm(6,"input",45),o.nI1(7,"transloco"),o.DNE(8,_,1,1,"app-form-error",14),o.k0s()),2&F){const h=o.XpG();o.R7$(2),o.SpI("",o.bMT(3,4,"workscreen.Add-event.Event-description.Form.Label.event-special-genre")," "),o.R7$(4),o.FS9("placeholder",o.bMT(7,6,"workscreen.Add-event.Event-description.Form.Placeholder.event-special-genre")),o.Y8G("ngClass",o.eq3(8,K,h.submitted&&h.form.specialSubGenre.errors)),o.R7$(2),o.Y8G("ngIf",h.submitted)}}function E(F,A){if(1&F&&o.nrm(0,"app-form-error",42),2&F){const h=o.XpG();o.Y8G("validationErrors",h.form.descriptionSl.errors)}}function j(F,A){if(1&F){const h=o.RV6();o.j41(0,"button",46),o.bIt("click",function(){o.eBV(h);const S=o.XpG();return o.Njj(S.toLastStep())}),o.nrm(1,"i",47),o.EFF(2),o.nI1(3,"transloco"),o.k0s()}2&F&&(o.R7$(2),o.SpI("",o.bMT(3,1,"Button.cancel")," "))}let L=(()=>{class F{get form(){return this.eventDescForm.controls}get eventNameCharsLeft(){return this.MAX_LENGTH-this.eventDescForm.controls.name.value.length}get eventNameEnCharsLeft(){return this.MAX_LENGTH-this.eventDescForm.controls.nameEn.value.length}constructor(h,G,S,W,J,ie,ae,se){this.formBuilder=h,this._eventsService=G,this._toastService=S,this._translocoService=W,this._codeListService=J,this._firstStepService=ie,this._sanitizer=ae,this._errorsTranslationService=se,this.MAX_LENGTH=100,this.NEXT_STEP=2,this.FINAL_STEP=5,this.addingEventsInfoUrl=n.kn,this.isEditMode=!1,this.showSpecialGenre=!1,this.toolbar=[["bold","italic","blockquote"],["ordered_list","bullet_list"]],this.genreOptions=[],this.subGenreOptions=[],this.isEdit=!1,this._unsubscribeAll=new y.B,this.eventDescForm=this.formBuilder.group({name:["",[d.k0.required,d.k0.maxLength(this.MAX_LENGTH)]],nameEn:["",[d.k0.maxLength(this.MAX_LENGTH)]],idCodeListGenre:["",[d.k0.required]],idCodeListSubGenre:[""],specialSubGenre:[null],descriptionSl:["",[d.k0.required]],descriptionEn:[""]}),this.eventDescForm.get("idCodeListSubGenre")?.disable(),window.scroll({top:0,left:0})}ngOnInit(){this.editorDescription=new b.KE,this.editorDescriptionEng=new b.KE,this._eventsService.firstStepForm$.pipe((0,e.$)()).subscribe(h=>{h&&(this.isEdit=!0,this.eventDescForm.patchValue(h),h?.idCodeListGenre&&this._getSebGenreOptions(Number(h.idCodeListGenre),Number(h.idCodeListSubGenre)))}),this.editorDescription.view.setProps({handlePaste:(h,G,S)=>{const W=G?.clipboardData?.getData("text/plain")??"",J=h.state.tr.replaceSelectionWith(h.state.schema.text(W));return h.dispatch(J),!0}}),this.editorDescriptionEng.view.setProps({handlePaste:(h,G,S)=>{const W=G?.clipboardData?.getData("text/plain")??"",J=h.state.tr.replaceSelectionWith(h.state.schema.text(W));return h.dispatch(J),!0}}),this._getGenreOptions()}ngAfterViewInit(){this.eventDescForm.get("idCodeListGenre")?.valueChanges.pipe((0,t.Q)(this._unsubscribeAll)).subscribe({next:h=>{h&&(this.showSpecialGenre=!1,this.eventDescForm.get("specialSubGenre")?.setValue(null),this.eventDescForm.get("idCodeListSubGenre")?.setValue(""),this._getSebGenreOptions(Number(h)))}}),this.eventDescForm.get("idCodeListSubGenre")?.valueChanges.pipe((0,t.Q)(this._unsubscribeAll)).subscribe({next:h=>{h&&(this.subGenreOptions.find(S=>S.idCodeListGenre===Number(h))?.nameTranslation?.includes("Other-")?this.showSpecialGenre=!0:(this.eventDescForm.get("specialSubGenre")?.setValue(null),this.showSpecialGenre=!1))}})}ngOnDestroy(){this.editorDescription.destroy(),this.editorDescriptionEng.destroy(),this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}toLastStep(){this._eventsService.selectedStep=this.FINAL_STEP}onSubmit(){this.submitted=!0,this.eventDescForm.valid&&(this.isEdit||this.isEditMode?this._editFirstStepData():this._postFirstStepData())}trackGenreOptions(h,G){return G.idCodeListGenre||h}trackSubGenreOptions(h,G){return G.idCodeSubGenre||h}_postFirstStepData(){this._firstStepService.firstStepReq(this._createFirstStepReq()).pipe((0,t.Q)(this._unsubscribeAll)).subscribe({next:h=>{this._toastService.show(this._translocoService.translate("Toast.Message.save-successful"),{type:"success",class:"success-toast"}),this._eventsService.selectedStep=this.NEXT_STEP,this._eventsService.firstStepForm=this.eventDescForm.value,this._eventsService.eventId=h.data},error:h=>{this._toastService.show(this._errorsTranslationService.translate(h.error?.code??h.error),{type:"error",class:"danger-toast"})}})}_editFirstStepData(){this._firstStepService.editFirstStepReq(this._createFirstStepReq(),this._eventsService.eventId$).pipe((0,t.Q)(this._unsubscribeAll)).subscribe({next:()=>{this._toastService.show(this._translocoService.translate("Toast.Message.save-successful"),{type:"success",class:"success-toast"}),this._eventsService.selectedStep=this.isEditMode?this.FINAL_STEP:this.NEXT_STEP,this._eventsService.firstStepForm=this.eventDescForm.value},error:h=>{this._toastService.show(this._errorsTranslationService.translate(h.error?.code??h.error),{type:"error",class:"danger-toast"})}})}_createFirstStepReq(){return{name:this.eventDescForm.value.name,nameEn:""===this.eventDescForm.value.nameEn?void 0:this.eventDescForm.value.nameEn,idCodeListGenre:Number(this.eventDescForm.value.idCodeListSubGenre),specialSubGenre:this.eventDescForm.value.specialSubGenre,descriptionSl:this._sanitizer.sanitize(o.WPN.HTML,this.eventDescForm.value.descriptionSl)??"",descriptionEn:""===this.eventDescForm.value.descriptionEn||"<p></p>"===this.eventDescForm.value.descriptionEn?void 0:this._sanitizer.sanitize(o.WPN.HTML,this.eventDescForm.value.descriptionEn)??void 0}}_getGenreOptions(){this._codeListService.getGenreOptions().pipe((0,t.Q)(this._unsubscribeAll)).subscribe({next:h=>{this.genreOptions=h},error:h=>{this.genreOptions=[],this._toastService.show(this._errorsTranslationService.translate(h.error?.code??h.error),{type:"error",class:"danger-toast"})}})}_getSebGenreOptions(h,G){this._codeListService.getSubGenreOptions(h).pipe((0,t.Q)(this._unsubscribeAll)).subscribe({next:S=>{this.subGenreOptions=S,this.eventDescForm.get("idCodeListSubGenre")?.enable(),G&&this.subGenreOptions.find(J=>J.idCodeListGenre===Number(G))?.nameTranslation?.includes("Other-")&&(this.showSpecialGenre=!0)},error:S=>{this.subGenreOptions=[],this._toastService.show(this._errorsTranslationService.translate(S.error?.code??S.error),{type:"error",class:"danger-toast"})}})}static{this.\u0275fac=function(G){return new(G||F)(o.rXU(d.ok),o.rXU($.H),o.rXU(i.f),o.rXU(B.JO),o.rXU(M.H),o.rXU(Y),o.rXU(ee.up),o.rXU(te.k))}}static{this.\u0275cmp=o.VBU({type:F,selectors:[["event-step-1"]],inputs:{isEditMode:"isEditMode"},standalone:!0,features:[o.aNF],decls:100,vars:99,consts:[[1,"row","justify-content-center","pb-sm-2"],[1,"col-lg-11","col-xl-10"],[1,"text-center","pb-4"],[1,"h2"],[3,"step",4,"ngIf"],[1,"bg-light","rounded-3","p-4","p-md-5","mb
1-3"],[1,"h4","mb-4"],[1,"fi-info-circle","text-muted","fs-5","mt-n1","me-2"],[3,"formGroup"],[1,"row"],[1,"col-sm-12","mb-4"],["for","event-name",1,"form-label"],[1,"text-danger"],["type","text","id","event-name","formControlName","name","required","",1,"form-control","form-control-lg",3,"placeholder","maxlength","ngClass"],[3,"validationErrors",4,"ngIf"],[1,"form-text","pt-1"],["for","event-name-en",1,"form-label"],["type","text","id","event-name-en","formControlName","nameEn",1,"form-control","form-control-lg",3,"placeholder","maxlength","ngClass"],[1,"row","border-top","pt-4"],[1,"col-sm-6","mb-4"],["for","pr-country",1,"form-label"],["id","pr-country","formControlName","idCodeListGenre","required","",1,"form-select","form-select-lg",3,"ngClass"],["value","","disabled","","selected","","hidden",""],[3,"value",4,"ngFor","ngForOf","ngForTrackBy"],[1,"form-text","pt-sm-4"],["target","_blank","role","button",1,"text-red","text-decoration-none",3,"href"],[1,"col-12","col-sm-6","mb-4"],["for","pr-city",1,"form-label"],["id","pr-city","formControlName","idCodeListSubGenre","required","",1,"form-select","form-select-lg",3,"ngClass"],["class","col-sm-6 mb-4",4,"ngIf"],[1,"border-top","pt-4"],["for","pr-position",1,"form-label"],[1,"ngx-editor"],[3,"editor","toolbar"],["formControlName","descriptionSl",3,"editor","placeholder"],[1,"mt-4"],["formControlName","descriptionEn",3,"editor","placeholder"],[1,"d-flex","flex-column","flex-sm-row","bg-light","rounded-3","p-4","px-md-5"],["class","btn btn-outline-primary btn-lg rounded-pill mb-3 mb-sm-0",3,"click",4,"ngIf"],[1,"btn","btn-primary","btn-lg","rounded-pill","ms-sm-auto",3,"click"],[1,"fi-chevron-right","fs-sm","ms-2"],[3,"step"],[3,"validationErrors"],[3,"value"],["for","special-genre",1,"form-label"],["type","text","id","special-genre","formControlName","specialSubGenre","required","",1,"form-control","form-control-lg",3,"placeholder","ngClass"],[1,"btn","btn-outline-primary","btn-lg","rounded-pill","mb-3","mb-sm-0",3,"click"],[1,"fi-chevron-left","fs-sm","me-2"]],template:function(G,S){1&G&&(o.j41(0,"div",0)(1,"div",1)(2,"div",2)(3,"h1",3),o.EFF(4),o.nI1(5,"transloco"),o.nI1(6,"transloco"),o.k0s()(),o.DNE(7,P,1,1,"event-steps",4),o.j41(8,"div",5)(9,"h2",6),o.nrm(10,"i",7),o.EFF(11),o.nI1(12,"transloco"),o.k0s(),o.j41(13,"form",8)(14,"div",9)(15,"div",10)(16,"label",11),o.EFF(17),o.nI1(18,"transloco"),o.j41(19,"span",12),o.EFF(20,"*"),o.k0s()(),o.nrm(21,"input",13),o.nI1(22,"transloco"),o.DNE(23,V,1,1,"app-form-error",14),o.j41(24,"div",15),o.EFF(25),o.nI1(26,"transloco"),o.k0s()()(),o.j41(27,"div",9)(28,"div",10)(29,"label",16),o.EFF(30),o.nI1(31,"transloco"),o.k0s(),o.nrm(32,"input",17),o.nI1(33,"transloco"),o.DNE(34,X,1,1,"app-form-error",14),o.j41(35,"div",15),o.EFF(36),o.nI1(37,"transloco"),o.k0s()()(),o.j41(38,"div",18)(39,"div",19)(40,"label",20),o.EFF(41),o.nI1(42,"transloco"),o.j41(43,"span",12),o.EFF(44,"*"),o.k0s()(),o.j41(45,"select",21)(46,"option",22),o.EFF(47),o.nI1(48,"transloco"),o.k0s(),o.DNE(49,ne,3,4,"option",23),o.k0s(),o.DNE(50,oe,1,1,"app-form-error",14),o.k0s(),o.j41(51,"div",19)(52,"div",24),o.EFF(53),o.nI1(54,"transloco"),o.j41(55,"a",25),o.EFF(56),o.nI1(57,"transloco"),o.k0s(),o.EFF(58),o.nI1(59,"transloco"),o.k0s()(),o.j41(60,"div",26)(61,"label",27),o.EFF(62),o.nI1(63,"transloco"),o.j41(64,"span",12),o.EFF(65,"*"),o.k0s()(),o.j41(66,"select",28)(67,"option",22),o.EFF(68),o.nI1(69,"transloco"),o.k0s(),o.DNE(70,C,3,4,"option",23),o.k0s(),o.DNE(71,q,1,1,"app-form-error",14),o.k0s(),o.DNE(72,D,9,10,"div",29),o.k0s(),o.j41(73,"div",30)(74,"label",31),o.EFF(75),o.nI1(76,"transloco"),o.j41(77,"span",12),o.EFF(78,"*"),o.k0s()(),o.j41(79,"div",32),o.nrm(80,"ngx-editor-menu",33)(81,"ngx-editor",34),o.k0s(),o.j41(82,"div",15),o.EFF(83),o.nI1(84,"transloco"),o.k0s(),o.DNE(85,E,1,1,"app-form-error",14),o.j41(86,"div",35)(87,"label",31),o.EFF(88),o.nI1(89,"transloco"),o.k0s(),o.j41(90,"div",32),o.nrm(91,"ngx-editor-menu",33)(92,"ngx-editor",36),o.k0s()()()()(),o.j41(93,"div",37),o.DNE(94,j,4,3,"button",38),o.j41(95,"button",39),o.bIt("click",function(){return S.onSubmit()}),o.EFF(96),o.nI1(97,"transloco"),o.nI1(98,"transloco"),o.nrm(99,"i",40),o.k0s()()()()),2&G&&(o.R7$(4),o.SpI(" ",S.isEditMode?o.bMT(5,49,"workscreen.Edit-event.edit-event"):o.bMT(6,51,"workscreen.Add-event.add-event")," "),o.R7$(3),o.Y8G("ngIf",!S.isEditMode),o.R7$(4),o.SpI("",o.bMT(12,53,"workscreen.Add-event.Event-description.event-description")," "),o.R7$(2),o.Y8G("formGroup",S.eventDescForm),o.R7$(4),o.SpI("",o.bMT(18,55,"workscreen.Add-event.Event-description.Form.Label.event-name")," "),o.R7$(4),o.FS9("placeholder",o.bMT(22,57,"workscreen.Add-event.Event-description.Form.Placeholder.event-name")),o.Y8G("maxlength",S.MAX_LENGTH)("ngClass",o.eq3(91,K,S.submitted&&S.form.name.errors)),o.R7$(2),o.Y8G("ngIf",S.submitted),o.R7$(2),o.Lme(" ",o.bMT(26,59,"workscreen.Add-event.Event-description.Form.event-name-helper")," ",S.eventNameCharsLeft," "),o.R7$(5),o.SpI("",o.bMT(31,61,"workscreen.Add-event.Event-description.Form.Label.event-name-english")," "),o.R7$(2),o.FS9("placeholder",o.bMT(33,63,"workscreen.Add-event.Event-description.Form.Placeholder.event-name-english")),o.Y8G("maxlength",S.MAX_LENGTH)("ngClass",o.eq3(93,K,S.submitted&&S.form.nameEn.errors)),o.R7$(2),o.Y8G("ngIf",S.submitted),o.R7$(2),o.Lme(" ",o.bMT(37,65,"workscreen.Add-event.Event-description.Form.event-name-helper")," ",S.eventNameEnCharsLeft," "),o.R7$(5),o.SpI("",o.bMT(42,67,"workscreen.Add-event.Event-description.Form.Label.event-section")," "),o.R7$(4),o.Y8G("ngClass",o.eq3(95,K,S.submitted&&S.form.idCodeListGenre.errors)),o.R7$(2),o.SpI(" ",o.bMT(48,69,"Form.Placeholder.genre")," "),o.R7$(2),o.Y8G("ngForOf",S.genreOptions)("ngForTrackBy",S.trackGenreOptions),o.R7$(),o.Y8G("ngIf",S.submitted),o.R7$(3),o.SpI(" ",o.bMT(54,71,"w
1orkscreen.Add-event.Event-description.Form.event-section-helper-1")," "),o.R7$(2),o.Y8G("href",S.addingEventsInfoUrl,o.B4B),o.R7$(),o.SpI(" ",o.bMT(57,73,"workscreen.Add-event.Event-description.Form.event-section-helper-2"),""),o.R7$(2),o.SpI("",o.bMT(59,75,"workscreen.Add-event.Event-description.Form.event-section-helper-3")," "),o.R7$(4),o.SpI("",o.bMT(63,77,"workscreen.Add-event.Event-description.Form.Label.event-subsection")," "),o.R7$(4),o.Y8G("ngClass",o.eq3(97,K,S.submitted&&S.form.idCodeListSubGenre.errors)),o.R7$(2),o.SpI(" ",o.bMT(69,79,"Form.Placeholder.sub-genre")," "),o.R7$(2),o.Y8G("ngForOf",S.subGenreOptions)("ngForTrackBy",S.trackSubGenreOptions),o.R7$(),o.Y8G("ngIf",S.submitted),o.R7$(),o.Y8G("ngIf",S.showSpecialGenre),o.R7$(3),o.SpI("",o.bMT(76,81,"workscreen.Add-event.Event-description.Form.Label.event-description")," "),o.R7$(5),o.Y8G("editor",S.editorDescription)("toolbar",S.toolbar),o.R7$(),o.Y8G("editor",S.editorDescription)("placeholder",""),o.R7$(2),o.SpI(" ",o.bMT(84,83,"workscreen.Add-event.Event-description.Form.event-description-helper")," "),o.R7$(2),o.Y8G("ngIf",S.submitted),o.R7$(3),o.SpI("",o.bMT(89,85,"workscreen.Add-event.Event-description.Form.Label.event-description-english")," "),o.R7$(3),o.Y8G("editor",S.editorDescriptionEng)("toolbar",S.toolbar),o.R7$(),o.Y8G("editor",S.editorDescriptionEng)("placeholder",""),o.R7$(2),o.Y8G("ngIf",S.isEditMode),o.R7$(2),o.SpI(" ",S.isEditMode?o.bMT(97,87,"Button.save"):o.bMT(98,89,"Button.save-and-continue"),""))},dependencies:[T.MD,T.YU,T.Sq,T.bT,d.YN,d.qT,d.xH,d.y7,d.me,d.wz,d.BC,d.cb,d.YS,d.tU,d.X1,d.j4,d.JD,B.Q8,B.Kj,z.G,O.O,b.VZ,b.Cl,b.Zu,N.h]})}}return F})()},4886:(re,w,p)=>{p.d(w,{S:()=>c});var T=p(177),o=p(9417),d=p(5176),B=p(3887),b=p(5687),z=p(6508),O=p(1413),N=p(1594),y=p(6977),e=p(4011),t=p(4438),n=p(5335),$=p(783),i=p(5312),M=p(1562);let R=(()=>{class s{constructor(r){this.http=r}secondStepReq(r,m){return this.http.patch(`${i.c.api}/controlpanel/v1/event/${m}/time-and-location`,r)}getEventLocationOptions(r){return this.http.get(`${i.c.api}/controlpanel/v1/event/${r}/location`)}static{this.\u0275fac=function(m){return new(m||s)(t.KVO(M.Qq))}}static{this.\u0275prov=t.jDH({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();var k=p(8958),Y=p(7927),ee=p(2219),te=p(4139),K=p(7172);const P=s=>({"is-invalid":s}),V=s=>({"text-muted":s});function X(s,l){1&s&&t.nrm(0,"event-steps",24),2&s&&t.Y8G("step",2)}function ne(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG();t.Y8G("validationErrors",r.form.startDate.errors)}}function oe(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG();t.Y8G("validationErrors",r.form.startTime.errors)}}function C(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG();t.Y8G("validationErrors",r.form.endDate.errors)}}function q(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG();t.Y8G("validationErrors",r.form.endTime.errors)}}function _(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){let r;const m=t.XpG().index,u=t.XpG(2);t.Y8G("validationErrors",null==(r=u.openingHours.at(m).get("openTime"))?null:r.errors)}}function D(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){let r;const m=t.XpG().index,u=t.XpG(2);t.Y8G("validationErrors",null==(r=u.openingHours.at(m).get("closeTime"))?null:r.errors)}}function E(s,l){if(1&s&&(t.j41(0,"div",29)(1,"div",30)(2,"div",31)(3,"div",32),t.nrm(4,"input",33),t.j41(5,"label",34),t.EFF(6),t.k0s()()(),t.j41(7,"div",35),t.nrm(8,"time-flatpicker",36),t.DNE(9,_,1,1,"app-form-error",13),t.k0s(),t.j41(10,"div",35),t.nrm(11,"time-flatpicker",36),t.DNE(12,D,1,1,"app-form-error",13),t.k0s()()()),2&s){let r,m,u,U,Q,Z;const a=l.index,H=t.XpG(2);t.R7$(),t.Y8G("formGroupName",a),t.R7$(3),t.Y8G("id","day-"+a),t.R7$(),t.Y8G("for","day-"+a),t.R7$(),t.JRh(H.getDayTranslation(a)),t.R7$(2),t.Y8G("isRequired",null==(r=H.openingHours.at(a).get("active"))?null:r.value)("isReadOnly",null==(m=H.openingHours.at(a).get("active"))?null:m.value)("isInvalid",H.submitted&&(null==(u=H.openingHours.at(a).get("openTime"))?null:u.errors))("controlForm",H.openingHours.at(a).get("openTime")),t.R7$(),t.Y8G("ngIf",H.submitted),t.R7$(2),t.Y8G("isRequired",null==(U=H.openingHours.at(a).get("active"))?null:U.value)("isReadOnly",null==(Q=H.openingHours.at(a).get("active"))?null:Q.value)("isInvalid",H.submitted&&(null==(Z=H.openingHours.at(a).get("closeTime"))?null:Z.errors))("controlForm",H.openingHours.at(a).get("closeTime")),t.R7$(),t.Y8G("ngIf",H.submitted)}}function j(s,l){if(1&s&&(t.qex(0),t.j41(1,"h2",26),t.nrm(2,"i",27),t.EFF(3),t.nI1(4,"transloco"),t.k0s(),t.DNE(5,E,13,14,"div",28),t.bVm()),2&s){const r=t.XpG();t.R7$(3),t.SpI("",t.bMT(4,2,"workscreen.Add-event.Term-location.opening-time")," "),t.R7$(2),t.Y8G("ngForOf",r.openingHours.controls)}}function L(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.isPhysicalLocation.errors)}}function F(s,l){if(1&s&&(t.j41(0,"option",67),t.EFF(1),t.k0s()),2&s){const r=l.$implicit;t.Y8G("value",r.idDataOrganizationLocation),t.R7$(),t.SpI(" ",r.locationName," ")}}function A(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.eventLocation.errors)}}function h(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.locationName.errors)}}function G(s,l){1&s&&(t.j41(0,"span",11),t.EFF(1,"*"),t.k0s())}function S(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.address.errors)}}function W(s,l){1&s&&(t.j41(0,"span",11),t.EFF(1,"*"),t.k0s())}function J(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.postalCode.errors)}}function ie(s,l){1&s&&(t.j41(0,"span",11),t.EFF(1,"*"),t.k0s())}function ae(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.postalName.errors)}}function se(s,l){1&s&&(t.j41(0,"span",11),t.EFF(1,"*"),t.k0s())}function le(s,l){if(1&s&&(t.j41(0,"option",67),t.EFF(1),t.nI1(2,"transloco"),t.k0s()),2&s){const r=l.$implicit;t.Y8G("value",r.idCodeListRegion),t.R7$(),t.SpI(" ",t.bMT(2,2,"CodeList."+r.nameTranslation)," ")}}function ce(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.idCodeListRegion.errors)}}function pe(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.isPhysicalLocation.errors)}}function me(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.url.errors)}}function f(s,l){if(1&s&&(t.qex(0),t.j41(1,"h2",37),t.nrm(2,"i",38),t.EFF(3),t.nI1(4,"transloco"),t.k0s(),t.j41(5,"div",39),t.EFF(6),t.nI1(7,"transloco"),t.k0s(),t.j41(8,"div",40),t.nrm(9,"input",41),t.j41(10,"label",42),t.EFF(11),t.nI1(12,"transloco"),t.k0s(),t.DNE(13,L,1,1,"app-form-error",13),t.k0s(),t.j41(14,"div",8)(15,"div",43)(16,"label",44),t.EFF(17),t.nI1(18,"transloco"),t.k0s(),t.j41(19,"select",45)(20,"option",46),t.EFF(21),t.nI1(22,"transloco"),t.k0s(),t.DNE(23,F,2,2,"option",47),t.k0s(),t.DNE(24,A,1,1,"app-form-error",13),t.k0s(),t.j41(25,"div",43)(26,"div",16),t.EFF(27),t.nI1(28,"transloco"),t.k0s()()(),t.j41(29,"div",48),t.EFF(30),t.nI1(31,"transloco"),t.k0s(),t.j41(32,"div",49)(33,"label",50),t.EFF(34),t.nI1(35,"transloco"),t.k0s(),t.nrm(36,"input",51),t.nI1(37,"transloco"),t.DNE(38,h,1,1,"app-form-error",13),t.k0s(),t.j41(39,"div",49)(40,"label",52),t.EFF(41),t.nI1(42,"transloco"),t.DNE(43,G,2,0,"span",53),t.k0s(),t.nrm(44,"input",54),t.nI1(45,"transloco"),t.DNE(46,S,1,1,"app-form-error",13),t.k0s(),t.j41(47,"div",8)(48,"div",9)(49,"label",55),t.EFF(50),t.nI1(51,"transloco"),t.DNE(52,W,2,0,"span",53),t.k0s(),t.nrm(53,"input",56),t.nI1(54,"transloco"),t.DNE(55,J,1,1,"app-form-error",13),t.k0s(),t.j41(56,"div",9)(57,"label",57),t.EFF(58),t.nI1(59,"transloco"),t.DNE(60,ie,2,0,"span",53),t.k0s(),t.nrm(61,"input",58),t.nI1(62,"transloco"),t.DNE(63,ae,1,1,"app-form-error",13),t.k0s(),t.j41(64,"div",9)(65,"label",59),t.EFF(66),t.nI1(67,"transloco"),t.DNE(68,se,2,0,"span",53),t.k0s(),t.j41(69,"select",60)(70,"option",61),t.EFF(71),t.nI1(72,"transloco"),t.k0s(),t.DNE(73,le,3,4,"option",47),t.k0s(),t.DNE(74,ce,1,1,"app-form-error",13),t.k0s()(),t.j41(75,"div",62),t.nrm(76,"input",63),t.j41(77,"label",64),t.EFF(78),t.nI1(79,"transloco"),t.k0s(),t.DNE(80,pe,1,1,"app-form-error",13),t.k0s(),t.j41(81,"div",49)(82,"label",65),t.EFF(83),t.nI1(84,"transloco"),t.k0s(),t.nrm(85,"input",66),t.nI1(86,"transloco"),t.DNE(87,me,1,1,"app-form-error",13),t.k0s(),t.bVm()),2&s){const r=t.XpG();t.R7$(3),t.SpI("",t.bMT(4,63,"workscreen.Add-event.Term-location.event-location")," "),t.R7$(3),t.SpI(" ",t.bMT(7,65,"workscreen.Add-event.Term-location.Form.location-helper")," "),t.R7$(3),t.Y8G("ngClass",t.eq3(103,P,r.submitted&&r.form.isPhysicalLocation.errors)),t.R7$(2),t.JRh(t.bMT(12,67,"workscreen.Add-event.Term-location.Form.Label.is-physical-event")),t.R7$(2),t.Y8G("ngIf",r.submitted),t.R7$(3),t.Y8G("ngClass",t.eq3(105,V,!r.form.isPhysicalLocation.value)),t.R7$(),t.SpI("",t.bMT(18,69,"workscreen.Add-event.Term-location.Form.Label.choose-location")," "),t.R7$(2),t.Y8G("ngClass",t.eq3(107,P,r.submitted&&r.form.eventLocation.errors)),t.R7$(),t.Y8G("value",null),t.R7$(),t.SpI(" ",t.bMT(22,71,"workscreen.Add-event.Term-location.Form.Placeholder.location")," "),t.R7$(2),t.Y8G("ngForOf",r.locationOptions)("ngForTrackBy",r.trackLocationOptions),t.R7$(),t.Y8G("ngIf",r.submitted),t.R7$(3),t.SpI(" ",t.bMT(28,73,"workscreen.Add-event.Term-location.Form.choose-location-helper")," "),t.R7$(3),t.SpI(" ",t.bMT(31,75,"workscreen.Add-event.Term-location.add-event-location")," "),t.R7$(3),t.Y8G("ngClass",t.eq3(109,V,!r.form.isPhysicalLocation.value)),t.R7$(),t.SpI("",t.bMT(35,77,"workscreen.Add-event.Term-location.Form.Label.location-name")," "),t.R7$(2),t.FS9("placeholder",t.bMT(37,79,"workscreen.Add-event.Term-location.Form.Placeholder.location-name")),t.Y8G("readOnly",!r.form.isPhysicalLocation.value)("ngClass",t.eq3(111,P,r.submitted&&r.form.locationName.errors)),t.R7$(2),t.Y8G("ngIf",r.submitted),t.R7$(2),t.Y8G("ngClass",t.eq3(113,V,!r.form.isPhysicalLocation.value)),t.R7$(),t.SpI("",t.bMT(42,81,"Form.Label.street-house-nr")," "),t.R7$(2),t.Y8G("ngIf",r.form.isPhysicalLocation.value),t.R7$(),t.FS9("placeholder",t.bMT(45,83,"workscreen.Add-event.Term-location.Form.Placeholder.street-house-nr")),t.Y8G("required",r.form.isPhysicalLocation.value)("readOnly",!r.form.isPhysicalLocation.value)("ngClass",t.eq3(115,P,r.submitted&&r.form.address.errors)),t.R7$(2),t.Y8G("ngIf",r.submitted),t.R7$(3),t.Y8G("ngClass",t.eq3(117,V,!r.form.isPhysicalLocation.value)),t.R7$(),t.SpI("",t.bMT(51,85,"Form.Label.postal-code")," "),t.R7$(2),t.Y8G("ngIf",r.form.isPhysicalLocation.value),t.R7$(),t.FS9("placeholder",t.bMT(54,87,"Form.Placeholder.postal-code")),t.Y8G("required",r.form.isPhysicalLocation.value)("readOnly",!r.form.isPhysicalLocation.value)("ngClass",t.eq3(119,P,r.submitted&&r.form.postalCode.errors)),t.R7$(2),t.Y8G("ngIf",r.submitted),t.R7$(2),t.Y8G("ngClass",t.eq3(121,V,!r.form.isPhysicalLocation.value)),t.R7$(),t.SpI("",t.bMT(59,89,"Form.Label.city")," "),t.R7$(2),t.Y8G("ngIf",r.form.isPhysicalLocation.value),t.R7$(),t.FS9("placeholder",t.bMT(62,91,"Form.Placeholder.city")),t.Y8G("required",r.form.isPhysicalLocation.value)("readOnly",!r.form.isPhysicalLocation.value)("ngClass",t.eq3(123,P,r.submitted&&r.form.postalName.errors)),t.R7$(2),t.Y8G("ngIf",r.submitted),t.R7$(2),t.Y8G("ngClass",t.eq3(125,V,!r.form.isPhysicalLocation.value)),t.R7$(),t.SpI("",t.bMT(67,93,"Form.Label.regi
1on")," "),t.R7$(2),t.Y8G("ngIf",r.form.isPhysicalLocation.value),t.R7$(),t.Y8G("required",r.form.isPhysicalLocation.value)("ngClass",t.eq3(127,P,r.submitted&&r.form.idCodeListRegion.errors)),t.R7$(2),t.SpI(" ",t.bMT(72,95,"Form.Placeholder.region")," "),t.R7$(2),t.Y8G("ngForOf",r.regionDisplayOptions)("ngForTrackBy",r.trackOptions),t.R7$(),t.Y8G("ngIf",r.submitted),t.R7$(2),t.Y8G("ngClass",t.eq3(129,P,r.submitted&&r.form.isPhysicalLocation.errors)),t.R7$(2),t.JRh(t.bMT(79,97,"workscreen.Add-event.Term-location.Form.Label.is-virtual-event")),t.R7$(2),t.Y8G("ngIf",r.submitted),t.R7$(2),t.Y8G("ngClass",t.eq3(131,V,!r.form.isLiveStream.value)),t.R7$(),t.SpI("",t.bMT(84,99,"workscreen.Add-event.Term-location.Form.Label.url-link")," "),t.R7$(2),t.FS9("placeholder",t.bMT(86,101,"workscreen.Add-event.Term-location.Form.Placeholder.url-link")),t.Y8G("readOnly",!r.form.isLiveStream.value)("ngClass",t.eq3(133,P,r.submitted&&r.form.url.errors)),t.R7$(2),t.Y8G("ngIf",r.submitted)}}function x(s,l){if(1&s&&t.nrm(0,"app-form-error",25),2&s){const r=t.XpG(2);t.Y8G("validationErrors",r.form.url.errors)}}function v(s,l){if(1&s&&(t.qex(0),t.j41(1,"h2",26),t.nrm(2,"i",68),t.EFF(3),t.nI1(4,"transloco"),t.k0s(),t.j41(5,"div",49)(6,"label",69),t.EFF(7),t.nI1(8,"transloco"),t.j41(9,"span",11),t.EFF(10,"*"),t.k0s()(),t.nrm(11,"input",70),t.nI1(12,"transloco"),t.DNE(13,x,1,1,"app-form-error",13),t.k0s(),t.bVm()),2&s){const r=t.XpG();t.R7$(3),t.SpI("",t.bMT(4,5,"workscreen.Add-event.Term-location.virtual")," "),t.R7$(4),t.SpI("",t.bMT(8,7,"workscreen.Add-event.Term-location.Form.Label.url-link")," "),t.R7$(4),t.FS9("placeholder",t.bMT(12,9,"workscreen.Add-event.Term-location.Form.Placeholder.url-link")),t.Y8G("ngClass",t.eq3(11,P,r.submitted&&r.form.url.errors)),t.R7$(2),t.Y8G("ngIf",r.submitted)}}function I(s,l){if(1&s){const r=t.RV6();t.j41(0,"button",71),t.bIt("click",function(){t.eBV(r);const u=t.XpG();return t.Njj(u.toPrevStep())}),t.nrm(1,"i",72),t.EFF(2),t.nI1(3,"transloco"),t.k0s()}2&s&&(t.R7$(2),t.SpI("",t.bMT(3,1,"Button.previous-step")," "))}function g(s,l){if(1&s){const r=t.RV6();t.j41(0,"button",71),t.bIt("click",function(){t.eBV(r);const u=t.XpG();return t.Njj(u.toLastStep())}),t.nrm(1,"i",72),t.EFF(2),t.nI1(3,"transloco"),t.k0s()}2&s&&(t.R7$(2),t.JRh(t.bMT(3,1,"Button.cancel")))}let c=(()=>{class s{get form(){return this.eventLocationForm.controls}get eventMinEndDate(){return this.form.endDate.value}get openingHours(){return this.eventLocationForm.get("eventOpeningHours")}constructor(r,m,u,U,Q,Z,a,H){this.formBuilder=r,this._eventsService=m,this._toastService=u,this._translocoService=U,this._secondStepService=Q,this._codeListService=Z,this._userService=a,this._errorsTranslationService=H,this.NEXT_STEP=3,this.PREV_STEP=1,this.FINAL_STEP=5,this.todayMinDate=new Date,this.isEditMode=!1,this.regionOptions=[],this.regionDisplayOptions=[],this.locationOptions=[],this.isExhibition=!1,this.isOnRequest=!1,this.eventMaxDate=new Date,this._unsubscribeAll=new O.B,this.eventLocationForm=this.formBuilder.group({startDate:["",[o.k0.required]],endDate:["",[o.k0.required]],startTime:["",[o.k0.required]],endTime:["",[o.k0.required]],eventOpeningHours:this.formBuilder.array([]),eventLocation:[null],locationName:[""],address:[""],postalCode:[""],postalName:[""],idCodeListRegion:[""],isPhysicalLocation:[!0],isLiveStream:[!1],url:[null,[(0,e.IF)()]]}),this.todayMinDate.setHours(0,0,0,0),this._eventsService.canDeactivate=!0,window.scroll({top:0,left:0})}ngOnInit(){this.user&&(this.eventMaxDate=new Date(this.user.eventRangeDate)),this._eventsService.firstStepForm$.pipe((0,N.$)()).subscribe(r=>{if(r&&r.idCodeListGenre){if(3===Number(r.idCodeListGenre)){this.isExhibition=!0;for(let m=0;m<7;m++)this._addOpeningHours(m)}8===Number(r.idCodeListGenre)&&(this.isOnRequest=!0)}}),this._eventsService.secondStepForm$.pipe((0,N.$)()).subscribe(r=>{r&&(this.eventLocationForm.patchValue(r),r.isPhysicalLocation||(this.eventLocationForm.get("eventLocation")?.disable(),this.eventLocationForm.get("idCodeListRegion")?.disable()))}),this._getRegionOptions(),this._getLocationOptions()}ngAfterViewInit(){this.eventLocationForm.get("eventLocation")?.valueChanges.pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:r=>{if(r){const m=this.locationOptions.find(u=>u.idDataOrganizationLocation===Number(r));this.eventLocationForm.get("locationName")?.setValue(m?.name),this.eventLocationForm.get("address")?.setValue(m?.address),this.eventLocationForm.get("postalCode")?.setValue(m?.postalCode),this.eventLocationForm.get("postalName")?.setValue(m?.postalName),this.eventLocationForm.get("idCodeListRegion")?.setValue(m?.idCodeListRegion)}}}),this.eventLocationForm.get("startDate")?.valueChanges.pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:r=>{r&&this.eventLocationForm.get("endDate")?.setValue(r)}}),this.eventLocationForm.get("isLiveStream")?.valueChanges.pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:r=>{r?(delete this.eventLocationForm.get("isPhysicalLocation")?.errors?.atLeastOneLocation,this.eventLocationForm.get("isPhysicalLocation")?.updateValueAndValidity()):(this.eventLocationForm.get("url")?.setValue(null),this.eventLocationForm.get("isPhysicalLocation")?.value||this.eventLocationForm.get("isPhysicalLocation")?.setErrors({atLeastOneLocation:!0}
1))}}),this.eventLocationForm.get("isPhysicalLocation")?.valueChanges.pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:r=>{r?(this.eventLocationForm.get("eventLocation")?.disabled&&this.eventLocationForm.get("eventLocation")?.enable(),this.eventLocationForm.get("idCodeListRegion")?.enable(),delete this.eventLocationForm.get("isPhysicalLocation")?.errors?.atLeastOneLocation):(this.eventLocationForm.get("eventLocation")?.setValue(null),this.eventLocationForm.get("eventLocation")?.disable(),this.eventLocationForm.get("locationName")?.setValue(""),this.eventLocationForm.get("address")?.setValue(""),this.eventLocationForm.get("postalCode")?.setValue(""),this.eventLocationForm.get("postalName")?.setValue(""),this.eventLocationForm.get("idCodeListRegion")?.setValue(""),this.eventLocationForm.get("idCodeListRegion")?.disable(),this.eventLocationForm.get("isLiveStream")?.value||this.eventLocationForm.get("isPhysicalLocation")?.setErrors({atLeastOneLocation:!0}))}})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}trackOptions(r,m){return m.idCodeListRegion||r}trackLocationOptions(r,m){return m.idDataOrganizationLocation||r}toPrevStep(){this._eventsService.selectedStep=this.PREV_STEP}toLastStep(){this._eventsService.selectedStep=this.FINAL_STEP}onSubmit(){this.submitted=!0,!this.eventLocationForm?.get("isPhysicalLocation")?.value&&!this.eventLocationForm?.get("isLiveStream")?.value&&this.eventLocationForm.get("isPhysicalLocation")?.setErrors({atLeastOneLocation:!0}),this.eventLocationForm.valid&&this._patchSecondStepData()}getDayTranslation(r){return this._translocoService.translate("workscreen.Add-event.Term-location.Form.Label."+["monday","tuesday","wednesday","thurshday","friday","saturday","sunday"][r])}_addOpeningHours(r){const m=this.formBuilder.group({dayOfWeek:[r],openTime:[""],closeTime:[""],active:[!1]});this.openingHours.push(m)}_patchSecondStepData(){this._secondStepService.secondStepReq(this._createSecondStepReq(),this._eventsService.eventId$).pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:()=>{this._toastService.show(this._translocoService.translate("Toast.Message.save-successful"),{type:"success",class:"success-toast"}),this._eventsService.selectedStep=this.isEditMode?this.FINAL_STEP:this.NEXT_STEP,this._eventsService.secondStepForm=this.eventLocationForm.value},error:r=>{this._toastService.show(this._errorsTranslationService.translate(r.error?.code??r.error),{type:"error",class:"danger-toast"})}})}_createSecondStepReq(){const r=this.isExhibition?this.openingHours.value.map(u=>({...u,openTime:""===u.openTime?"00:00:00":u.openTime,closeTime:""===u.closeTime?"00:00:00":u.closeTime})):[];if(this.isOnRequest||!this.eventLocationForm.value.isPhysicalLocation){this.eventLocationForm.get("isLiveStream")?.setValue(!0);const u=this.regionOptions.find(U=>"Region.Web"===U.nameTranslation);this.eventLocationForm.get("idCodeListRegion")?.setValue(u?.idCodeListRegion)}return{IdDataOrganizationLocation:this.eventLocationForm.get("eventLocation")?.value,eventDate:{startDate:this.eventLocationForm.value.startDate,startTime:this.eventLocationForm.value.startTime,endDate:this.eventLocationForm.value.endDate,endTime:this.eventLocationForm.value.endTime},eventLocation:{name:this.eventLocationForm.value.locationName??"",idCodeListRegion:this.eventLocationForm.get("idCodeListRegion")?.value,address:this.eventLocationForm.value.address??"",postalName:this.eventLocationForm.value.postalName??"",postalCode:this.eventLocationForm.value.postalCode??""},isPhysicalLocation:this.eventLocationForm.value.isPhysicalLocation,eventOpeningHours:r,isLiveStream:this.eventLocationForm.value.isLiveStream,url:this.eventLocationForm.value.url}}_getRegionOptions(){this._codeListService.getRegionOptions().pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:r=>{this.regionOptions=r,this.regionDisplayOptions=r.filter(m=>"Region.Web"!==m.nameTranslation)},error:r=>{this.regionOptions=[],this._toastService.show(this._errorsTranslationService.translate(r.error?.code??r.error),{type:"error",class:"danger-toast"})}})}_getLocationOptions(){this._secondStepService.getEventLocationOptions(this._eventsService.eventId$).pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:r=>{this.locationOptions=r},error:r=>{this.locationOptions=[],this._toastService.show(this._errorsTranslationService.translate(r.error?.code??r.error),{type:"error",class:"danger-toast"})}})}static{this.\u0275fac=function(m){return new(m||s)(t.rXU(o.ok),t.rXU(n.H),t.rXU($.f),t.rXU(d.JO),t.rXU(R),t.rXU(k.H),t.rXU(Y.D),t.rXU(ee.k))}}static{this.\u0275cmp=t.VBU({type:s,selectors:[["event-step-2"]],inputs:{isEditMode:"isEditMode",user:"user"},standalone:!0,features:[t.aNF],decls:65,vars:52,consts:[[1,"row","justify-content-center","pb-sm-2"],[1,"col-lg-11","col-xl-10"],[1,"text-center","pb-4"],[1,"h2"],[3,"step",4,"ngIf"],[1,"bg-light","rounded-3","p-4","p-md-5","mb
1-3",3,"formGroup"],[1,"h4","mb-4"],[1,"fi-calendar-alt","text-muted","fs-4","mt-n1","me-2","pe-1"],[1,"row"],[1,"col-sm-4","mb-4"],["for","date-start",1,"form-label"],[1,"text-danger"],[3,"maxDate","isInvalid","controlForm"],[3,"validationErrors",4,"ngIf"],["for","time-start",1,"form-label"],[3,"isInvalid","controlForm"],[1,"form-text","pt-sm-4"],["for","date-end",1,"form-label"],["for","time-end",1,"form-label"],[4,"ngIf"],[1,"d-flex","flex-column","flex-sm-row","bg-light","rounded-3","p-4","px-md-5"],["class","btn btn-outline-primary btn-lg rounded-pill mb-3 mb-sm-0",3,"click",4,"ngIf"],[1,"btn","btn-primary","btn-lg","rounded-pill","ms-sm-auto",3,"click"],[1,"fi-chevron-right","fs-sm","ms-2"],[3,"step"],[3,"validationErrors"],[1,"h4","mb-4","border-top","pt-4"],[1,"fi-clock","text-muted","fs-4","mt-n1","me-2","pe-1"],["formArrayName","eventOpeningHours",4,"ngFor","ngForOf"],["formArrayName","eventOpeningHours"],[1,"row",3,"formGroupName"],[1,"col-sm-3","form-check-container","mb-4","pt-3"],[1,"form-check"],["type","checkbox","formControlName","active",1,"form-check-input",3,"id"],[1,"form-check-label",3,"for"],[1,"col-sm-3","mb-4"],[3,"isRequired","isReadOnly","isInvalid","controlForm"],[1,"h4","mb-2","border-top","pt-4"],[1,"fi-map-pin","text-muted","fs-4","mt-n1","me-2","pe-1"],[1,"form-text","mb-4"],[1,"form-check","mb-4"],["type","checkbox","id","is-physical","formControlName","isPhysicalLocation",1,"form-check-input",3,"ngClass"],["for","is-physical",1,"form-check-label"],[1,"col-sm-6","mb-4"],["for","your-location",1,"form-label",3,"ngClass"],["id","your-location","formControlName","eventLocation",1,"form-select",3,"ngClass"],["disabled","","selected","","hidden","",3,"value"],[3,"value",4,"ngFor","ngForOf","ngForTrackBy"],[1,"form-label","fs-6","pt-2","mb-3"],[1,"mb-4"],["for","location-name",1,"form-label",3,"ngClass"],["type","text","id","location-name","formControlName","locationName",1,"form-control",3,"placeholder","readOnly","ngClass"],["for","address",1,"form-label",3,"ngClass"],["class","text-danger",4,"ngIf"],["type","text","id","address","formControlName","address",1,"form-control",3,"placeholder","required","readOnly","ngClass"],["for","zip",1,"form-label",3,"ngClass"],["type","text","id","zip","formControlName","postalCode",1,"form-control",3,"placeholder","required","readOnly","ngClass"],["for","city",1,"form-label",3,"ngClass"],["type","text","id","city","formControlName","postalName",1,"form-control",3,"placeholder","required","readOnly","ngClass"],["for","district",1,"form-label",3,"ngClass"],["id","district","formControlName","idCodeListRegion",1,"form-select",3,"required","ngClass"],["value","","disabled","","selected","","hidden",""],[1,"form-check","border-top","pt-4","mb-4"],["type","checkbox","id","is-virtual","formControlName","isLiveStream",1,"form-check-input",3,"ngClass"],["for","is-virtual",1,"form-check-label"],["for","url-link",1,"form-label",3,"ngClass"],["type","text","formControlName","url","id","url-link",1,"form-control","form-control-lg",3,"readOnly","placeholder","ngClass"],[3,"value"],[1,"fi-globe","text-muted","fs-4","mt-n1","me-2","pe-1"],["for","url-link",1,"form-label"],["type","text","formControlName","url","required","","id","url-link",1,"form-control","form-control-lg",3,"placeholder","ngClass"],[1,"btn","btn-outline-primary","btn-lg","rounded-pill","mb-3","mb-sm-0",3,"click"],[1,"fi-chevron-left","fs-sm","me-2"]],template:function(m,u){1&m&&(t.j41(0,"div",0)(1,"div",1)(2,"div",2)(3,"h1",3),t.EFF(4),t.nI1(5,"transloco"),t.nI1(6,"transloco"),t.k0s()(),t.DNE(7,X,1,1,"event-steps",4),t.j41(8,"div",5)(9,"h2",6),t.nrm(10,"i",7),t.EFF(11),t.nI1(12,"transloco"),t.k0s(),t.j41(13,"div",8)(14,"div",9)(15,"label",10),t.EFF(16),t.nI1(17,"transloco"),t.j41(18,"span",11),t.EFF(19,"*"),t.k0s()(),t.nrm(20,"date-flatpicker",12),t.DNE(21,ne,1,1,"app-form-error",13),t.k0s(),t.j41(22,"div",9)(23,"label",14),t.EFF(24),t.nI1(25,"transloco"),t.j41(26,"span",11),t.EFF(27,"*"),t.k0s()(),t.nrm(28,"time-flatpicker",15),t.DNE(29,oe,1,1,"app-form-error",13),t.k0s(),t.j41(30,"div",9)(31,"div",16),t.EFF(32),t.nI1(33,"transloco"),t.k0s()(),t.j41(34,"div",9)(35,"label",17),t.EFF(36),t.nI1(37,"transloco"),t.j41(38,"span",11),t.EFF(39,"*"),t.k0s()(),t.nrm(40,"date-flatpicker",12),t.DNE(41,C,1,1,"app-form-error",13),t.k0s(),t.j41(42,"div",9)(43,"label",18),t.EFF(44),t.nI1(45,"transloco"),t.j41(46,"span",11),t.EFF(47,"*"),t.k0s()(),t.nrm(48,"time-flatpicker",15),t.DNE(49,q,1,1,"app-form-error",13),t.k0s(),t.j41(50,"div",9)(51,"div",16),t.EFF(52),t.nI1(53,"transloco"),t.k0s()()(),t.DNE(54,j,6,4,"ng-container",19)(55,f,88,135,"ng-container",19)(56,v,14,13,"ng-container",19),t.k0s(),t.j41(57,"div",20),t.DNE(58,I,4,3,"button",21)(59,g,4,3,"button",21),t.j41(60,"button",22),t.bIt("click",function(){return u.onSubmit()}),t.EFF(61),t.nI1(62,"transloco"),t.nI1(63,"transloco"),t.nrm(64,"i",23),t.k0s()()()()),2&m&&(t.R7$(4),t.SpI(" ",u.isEditMode?t.bMT(5,30,"workscreen.Edit-event.edit-event"):t.bMT(6,32,"workscreen.Add-event.add-event")," "),t.R7$(3),t.Y8G("ngIf",!u.isEditMode),t.R7$(),t.Y8G("formGroup",u.eventLocationForm),t.R7$(3),t.SpI("",t.bMT(12,34,"workscreen.Add-event.Term-location.event-term")," "),t.R7$(5),t.SpI("",t.bMT(17,36,"workscreen.Add-event.Term-location.Form.Label.date-start")," "),t.R7$(4),t.Y8G("maxDate",u.eventMaxDate)("isInvalid",u.submitted&&u.form.startDate.errors)("controlForm",u.form.startDate),t.R7$(),t.Y8G("ngIf",u.submitted),t.R7$(3),t.SpI("",t.bMT(25,38,"workscreen.Add-event.Term-location.Form.Label.time-start")," "),t.R7$(4),t.Y8G("isInvalid",u.submitted&&u.form.startTime.errors)("controlForm",u.form.startTime),t.R7$(),t.Y8G("ngIf",u.submitted),t.R7$(3),t.SpI(" ",t.bMT(33,40,"workscreen.Add-event.Term-location.Form.start-time-helper")," "),t.R7$(4),t.SpI("",t.bMT(37,42,"workscreen.Add-event.Term-location.Form.Label.date-end")," "),t.R7$(4),t.Y8G("maxDate",u.eventMaxDate)("isInvalid",u.submitted&&u.form.endDate.errors)("controlForm",u.form.endDate),t.R7$(),t.Y8G("ngIf",u.submitted),t.R7$(3),t.SpI("",t.bMT(45,44,"workscreen.Add-event.Term-location.Form.Label.time-end")," "),t.R7$(4),t.Y8G("isInvalid",u.submitted&&u.form.endTime.errors)("controlForm",u.form.endTime),t.R7$(),t.Y8G("ngIf",u.submitted),t.R7$(3),t.SpI(" ",t.bMT(53,46,"workscreen.Add-event.Term-location.Form.end-time-helper")," "),t.R7$(2),t.Y8G("ngIf",u.isExhibition),t.R7$(),t.Y8G("ngIf",!u.isOnRequest),t.R7$(),t.Y8G("ngIf",u.isOnRequest),t.R7$(2),t.Y8G("ngIf",!u.isEditMode),t.R7$(),t.Y8G("ngIf",u.isEditMode),t.R7$(2),t.SpI(" ",u.isEditMode?t.bMT(62,48,"Button.save"):t.bMT(63,50,"Button.save-and-continue"),""))},dependencies:[T.MD,T.YU,T.Sq,T.bT,o.YN,o.xH,o.y7,o.me,o.Zm,o.wz,o.BC,o.cb,o.YS,o.X1,o.j4,o.JD,o.$R,o.v8,d.Q8,d.Kj,B.G,te.X,K.g,b.O,z.h]})}}return s})()},7519:(re,w,p)=>{p.d(w,{f:()=>oe});var T=p(177),o=p(9417),d=p(5176),B=p(3887),b=p(5687),z=p(6508),O=p(9386),N=p(1413),y=p(1594),e=p(6977),t=p(4372),n=p(5312),$=p(4011),i=p(4438),M=p(5335),R=p(783),k=p(1562);let Y=(()=>{class C{constructor(_){this.http=_}thirdStepReq(_,D){return this.http.patch(`${n.c.api}/controlpanel/v1/event/${D}/event-assets`,_)}static{this.\u0275fac=function(D){return new(D||C)(i.KVO(k.Qq))}}
1static{this.\u0275prov=i.jDH({token:C,factory:C.\u0275fac,providedIn:"root"})}}return C})();var ee=p(4324),te=p(2219);const K=C=>({"is-invalid":C});function P(C,q){1&C&&i.nrm(0,"event-steps",26),2&C&&i.Y8G("step",3)}function V(C,q){if(1&C&&i.nrm(0,"app-form-error",27),2&C){const _=i.XpG();i.Y8G("validationErrors",_.form.videoLink.errors)}}function X(C,q){if(1&C){const _=i.RV6();i.j41(0,"button",28),i.bIt("click",function(){i.eBV(_);const E=i.XpG();return i.Njj(E.toPrevStep())}),i.nrm(1,"i",29),i.EFF(2),i.nI1(3,"transloco"),i.k0s()}2&C&&(i.R7$(2),i.SpI("",i.bMT(3,1,"Button.previous-step")," "))}function ne(C,q){if(1&C){const _=i.RV6();i.j41(0,"button",28),i.bIt("click",function(){i.eBV(_);const E=i.XpG();return i.Njj(E.toLastStep())}),i.nrm(1,"i",29),i.EFF(2),i.nI1(3,"transloco"),i.k0s()}2&C&&(i.R7$(2),i.JRh(i.bMT(3,1,"Button.cancel")))}let oe=(()=>{class C{get form(){return this.eventFilesForm.controls}get eventImages(){return this.eventFilesForm.get("eventImages")}get eventImageFolder(){return n.c.assetsSrc+"event/"}get coverImageFolder(){return n.c.assetsSrc+"cover/"}constructor(_,D,E,j,L,F,A){this.formBuilder=_,this._translocoService=D,this._eventsService=E,this._toastService=j,this._thirdStepService=L,this._authService=F,this._errorsTranslationService=A,this.NEXT_STEP=4,this.PREV_STEP=2,this.FINAL_STEP=5,this.isEditMode=!1,this.dropCoverDisabled=!1,this._unsubscribeAll=new N.B,this._thumbnailImages=[],this._thumbnailCoverImage=null,this.eventFilesForm=this.formBuilder.group({coverImage:[""],eventImages:this.formBuilder.array([]),videoLink:[null,[(0,$._2)()]]}),this.dropconfig={url:t.vw,headers:{Authorization:"Bearer "+this._authService.accessToken},maxFilesize:5,acceptedFiles:".jpeg,.jpg,.png,.webp",clickable:!0,maxFiles:10,addRemoveLinks:!0,dictRemoveFile:this._translocoService.translate("Form.File.remove-file"),dictMaxFilesExceeded:this._translocoService.translate("Form.File.max-file-exceeded-ten"),dictFileTooBig:this._translocoService.translate("Form.File.file-too-big"),dictInvalidFileType:this._translocoService.translate("Form.File.invalid-file-type"),dictCancelUpload:this._translocoService.translate("Form.File.cancel-upload")},this.dropConfigCoverImage={url:t.vw,headers:{Authorization:"Bearer "+this._authService.accessToken},maxFilesize:5,acceptedFiles:".jpeg,.jpg,.png,.webp",clickable:!0,maxFiles:1,uploadMultiple:!1,addRemoveLinks:!0,dictRemoveFile:this._translocoService.translate("Form.File.remove-file"),dictMaxFilesExceeded:this._translocoService.translate("Form.File.max-file-exceeded-one-only"),dictFileTooBig:this._translocoService.translate("Form.File.file-too-big"),dictInvalidFileType:this._translocoService.translate("Form.File.invalid-file-type"),dictCancelUpload:this._translocoService.translate("Form.File.cancel-upload")},this._eventsService.canDeactivate=!0,window.scroll({top:0,left:0})}ngOnInit(){this._eventsService.thirdStepForm$.pipe((0,y.$)()).subscribe(_=>{_&&(this.eventFilesForm.patchValue(_),this._thumbnailCoverImage=_.coverImage,_.eventImages&&_.eventImages.length>0&&_.eventImages.forEach(D=>{this._thumbnailImages?.push(D),this.eventImages.push(this.formBuilder.control(D))}))})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}onCoverImageInit(_){if(_&&this._thumbnailCoverImage){_.displayExistingFile({name:this._thumbnailCoverImage,size:12345},this.coverImageFolder+this._thumbnailCoverImage,null,null,!1),this.dropCoverDisabled=!0;const E=_.element.querySelector(".dz-preview"),j=_.element.querySelector(".dz-image");this.setDZPreviewStyle(j,E)}}onCoverImageThumbnail(_){if(_){const D=_[0].previewElement,E=_[0].previewElement.querySelector(".dz-image");this.setDZPreviewStyle(E,D)}}onCoverImageRemoveFile(_){_&&(this.dropCoverDisabled=!1,this._thumbnailCoverImage=null)}onCoverImageUploadError(_){if(_){let D=this._translocoService.translate("Toast.Message.file-upload-error");_[1]&&(D=_[1]),this._toastService.show(D,{type:"error",class:"danger-toast"})}}onCoverImageUploadSuccess(_){_&&(this.dropCoverDisabled=!0,this._thumbnailCoverImage=_[1]?.fileName)}onInit(_){if(_&&this._thumbnailImages&&this._thumbnailImages.length>0){const D=this._thumbnailImages;Array.isArray(D)&&D.length>0&&D.forEach(L=>{_.displayExistingFile({name:L,size:12345}
1,this.eventImageFolder+L,null,null,!1)});const E=_.element.querySelector(".dz-preview"),j=_.element.querySelector(".dz-image");this.setDZPreviewStyle(j,E)}}onRemoveFile(_){if(this._thumbnailImages){const D=this._thumbnailImages.findIndex(E=>E.includes(_.name));this._thumbnailImages?.splice(D,1)}}onUploadError(_){let D=this._translocoService.translate("Toast.Message.file-upload-error");_[1]&&(D=_[1]),this._toastService.show(D,{type:"error",class:"danger-toast"})}onUploadSuccess(_){const D=_[1]?.fileName;this._thumbnailImages?.push(D)}toPrevStep(){this._eventsService.selectedStep=this.PREV_STEP}toLastStep(){this._eventsService.selectedStep=this.FINAL_STEP}onSubmit(){this.submitted=!0,this.eventFilesForm.valid&&this._patchThirdStepData()}setDZPreviewStyle(_,D){_.style.width="120px",_.style.height="120px",_.style.borderRadius="20px",D.style.width="auto"}_patchThirdStepData(){this._thirdStepService.thirdStepReq(this._thirdStepReq(),this._eventsService.eventId$).pipe((0,e.Q)(this._unsubscribeAll)).subscribe({next:_=>{this._toastService.show(this._translocoService.translate("Toast.Message.save-successful"),{type:"success",class:"success-toast"}),_.images&&_.images.length>0&&(this.eventImages.clear(),_.images.forEach(D=>{this.eventImages.push(this.formBuilder.control(D.fileName))})),_.coverImage&&this.form.coverImage.setValue(_.coverImage.fileName),this._eventsService.selectedStep=this.isEditMode?this.FINAL_STEP:this.NEXT_STEP,this._eventsService.thirdStepForm=this.eventFilesForm.value},error:_=>{this._toastService.show(this._errorsTranslationService.translate(_.error?.code??_.error),{type:"error",class:"danger-toast"})}})}_thirdStepReq(){const _=this._thumbnailCoverImage?{imageName:this._thumbnailCoverImage,resizeList:["small","medium","large"]}:void 0,D=this._thumbnailImages?.map(j=>({imageName:j,resizeList:["large"]}));return{announcementVideoLink:this.eventFilesForm.value.videoLink,coverImage:_,eventImages:D}}static{this.\u0275fac=function(D){return new(D||C)(i.rXU(o.ok),i.rXU(d.JO),i.rXU(M.H),i.rXU(R.f),i.rXU(Y),i.rXU(ee.u),i.rXU(te.k))}}static{this.\u0275cmp=i.VBU({type:C,selectors:[["event-step-3"]],inputs:{isEditMode:"isEditMode"},standalone:!0,features:[i.aNF],decls:56,vars:54,consts:[[1,"row","justify-content-center","pb-sm-2"],[1,"col-lg-11","col-xl-10"],[1,"text-center","pb-4"],[1,"h2"],[3,"step",4,"ngIf"],[1,"bg-light","rounded-3","p-4","p-md-5","mb-3",3,"formGroup"],[1,"h4","mb-3"],[1,"bi","bi-images","text-muted","fs-4","mt-n1","me-2","pe-1"],["role","alert",1,"alert","alert-dropzone","mb-4"],[1,"d-flex"],[1,"fi-alert-circle","me-2","me-sm-3"],[1,"fs-sm","mb-1"],[1,"file-uploader","file-uploader-grid","bg-faded-light","border-light","dropzone_sec",3,"init","thumbnail","removedFile","error","success","config","disabled","message"],[1,"h4","mb-3","pt-4"],[1,"file-uploader","file-uploader-grid","bg-faded-light","border-light","dropzone_sec",3,"init","removedFile","error","success","config","message"],[1,"h4","mb-2","border-top","pt-4"],[1,"fi-youtube","text-muted","fs-4","mt-n1","me-2","pe-1"],[1,"form-text","mb-4"],[1,"mb-4"],["for","url-link",1,"form-label"],["type","text","formControlName","videoLink","id","url-link",1,"form-control","form-control-lg",3,"placeholder","ngClass"],[3,"validationErrors",4,"ngIf"],[1,"d-flex","flex-column","flex-sm-row","bg-light","rounded-3","p-4","px-md-5"],["class","btn btn-outline-primary btn-lg rounded-pill mb-3 mb-sm-0",3,"click",4,"ngIf"],[1,"btn","btn-primary","btn-lg","rounded-pill","ms-sm-auto",3,"click"],[1,"fi-chevron-right","fs-sm","ms-2"],[3,"step"],[3,"validationErrors"],[1,"btn","btn-outline-primary","btn-lg","rounded-pill","mb-3","mb-sm-0",3,"click"],[1,"fi-chevron-left","fs-sm","me-2"]],template:function(D,E){1&D&&(i.j41(0,"div",0)(1,"div",1)(2,"div",2)(3,"h1",3),i.EFF(4),i.nI1(5,"transloco"),i.nI1(6,"transloco"),i.k0s()(),i.DNE(7,P,1,1,"event-steps",4),i.j41(8,"div",5)(9,"h2",6),i.nrm(10,"i",7),i.EFF(11),i.nI1(12,"transloco"),i.k0s(),i.j41(13,"div",8)(14,"div",9),i.nrm(15,"i",10),i.j41(16,"p",11),i.EFF(17),i.nI1(18,"transloco"),i.k0s()()(),i.j41(19,"dropzone",12),i.nI1(20,"transloco"),i.bIt("init",function(L){return E.onCoverImageInit(L)})("thumbnail",function(L){return E.onCoverImageThumbnail(L)})("removedFile",function(L){return E.onCoverImageRemoveFile(L)})("error",function(L){return E.onCoverImageUploadError(L)})("success",function(L){return E.onCoverImageUploadSuccess(L)}),i.k0s(),i.j41(21,"h2",13),i.nrm(22,"i",7),i.EFF(23),i.nI1(24,"transloco"),i.k0s(),i.j41(25,"div",8)(26,"div",9),i.nrm(27,"i",10),i.j41(28,"p",11),i.EFF(29),i.nI1(30,"transloco"),i.nI1(31,"transloco"),i.k0s()()(),i.j41(32,"dropzone",14),i.nI1(33,"transloco"),i.bIt("init",function(L){return E.onInit(L)})("removedFile",function(L){return E.onRemoveFile(L)})("error",function(L){return E.onUploadError(L)})("success",function(L){return E.onUploadSuccess(L)}),i.k0s(),i.j41(34,"h2",15),i.nrm(35,"i",16),i.EFF(36),i.nI1(37,"transloco"),i.k0s(),i.j41(38,"div",17),i.EFF(39),i.nI1(40,"transloco"),i.k0s(),i.j41(4
11,"div",18)(42,"label",19),i.EFF(43),i.nI1(44,"transloco"),i.k0s(),i.nrm(45,"input",20),i.nI1(46,"transloco"),i.DNE(47,V,1,1,"app-form-error",21),i.k0s()(),i.j41(48,"div",22),i.DNE(49,X,4,3,"button",23)(50,ne,4,3,"button",23),i.j41(51,"button",24),i.bIt("click",function(){return E.onSubmit()}),i.EFF(52),i.nI1(53,"transloco"),i.nI1(54,"transloco"),i.nrm(55,"i",25),i.k0s()()()()),2&D&&(i.R7$(4),i.SpI(" ",E.isEditMode?i.bMT(5,22,"workscreen.Edit-event.edit-event"):i.bMT(6,24,"workscreen.Add-event.add-event")," "),i.R7$(3),i.Y8G("ngIf",!E.isEditMode),i.R7$(),i.Y8G("formGroup",E.eventFilesForm),i.R7$(3),i.SpI("",i.bMT(12,26,"workscreen.Add-event.Photo-video.event-cover-photo")," "),i.R7$(6),i.SpI(" ",i.bMT(18,28,"Form.File.max-file-description")," "),i.R7$(2),i.FS9("message",i.bMT(20,30,"Form.File.drag-drop-description")),i.Y8G("config",E.dropConfigCoverImage)("disabled",E.dropCoverDisabled),i.R7$(4),i.SpI("",i.bMT(24,32,"workscreen.Add-event.Photo-video.add-photos")," "),i.R7$(6),i.Lme(" ",i.bMT(30,34,"Form.File.max-file-description")," ",i.bMT(31,36,"Form.File.max-10-files")," "),i.R7$(3),i.FS9("message",i.bMT(33,38,"Form.File.drag-drop-description")),i.Y8G("config",E.dropconfig),i.R7$(4),i.SpI("",i.bMT(37,40,"workscreen.Add-event.Photo-video.add-video")," "),i.R7$(3),i.SpI(" ",i.bMT(40,42,"workscreen.Add-event.Photo-video.add-video-helper")," "),i.R7$(4),i.SpI("",i.bMT(44,44,"workscreen.Add-event.Photo-video.Form.Label.youtube-link")," "),i.R7$(2),i.FS9("placeholder",i.bMT(46,46,"workscreen.Add-event.Photo-video.Form.Placeholder.youtube-link")),i.Y8G("ngClass",i.eq3(52,K,E.submitted&&E.form.videoLink.errors)),i.R7$(2),i.Y8G("ngIf",E.submitted),i.R7$(2),i.Y8G("ngIf",!E.isEditMode),i.R7$(),i.Y8G("ngIf",E.isEditMode),i.R7$(2),i.SpI(" ",E.isEditMode?i.bMT(53,48,"Button.save"):i.bMT(54,50,"Button.save-and-continue"),""))},dependencies:[T.MD,T.YU,T.bT,o.YN,o.me,o.BC,o.cb,o.X1,o.j4,o.JD,d.Q8,d.Kj,B.G,b.O,z.h,O._L,O.HF]})}}return C})()},128:(re,w,p)=>{p.d(w,{Q:()=>me});var T=p(177),o=p(9417),d=p(2791),B=p(5176),b=p(3887),z=p(5687),O=p(6508),N=p(1413),y=p(6977),e=p(1594),t=p(4011),n=p(4438),$=p(5335),i=p(783),M=p(5312),R=p(1562);let k=(()=>{class f{constructor(v){this.http=v}fourthStepReq(v,I){return this.http.patch(`${M.c.api}/controlpanel/v1/event/${I}/other-info`,v)}getSponsorOptions(v){return this.http.get(`${M.c.api}/controlpanel/v1/event/${v}/sponsor`)}static{this.\u0275fac=function(I){return new(I||f)(n.KVO(R.Qq))}}static{this.\u0275prov=n.jDH({token:f,factory:f.\u0275fac,providedIn:"root"})}}return f})();var Y=p(8777),ee=p(2219),te=p(7927),K=p(4139),P=p(7172);const V=f=>({"text-muted":f}),X=f=>({"is-invalid":f});function ne(f,x){1&f&&n.nrm(0,"event-steps",43),2&f&&n.Y8G("step",4)}function oe(f,x){1&f&&(n.j41(0,"span",44),n.EFF(1,"*"),n.k0s())}function C(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG();n.Y8G("validationErrors",v.form.ticketPrice.errors)}}function q(f,x){1&f&&(n.j41(0,"div",14)(1,"div",46),n.nrm(2,"input",47),n.j41(3,"label",48),n.EFF(4),n.nI1(5,"transloco"),n.k0s()()()),2&f&&(n.R7$(4),n.JRh(n.bMT(5,1,"workscreen.Add-event.Information.Form.Label.free-event")))}function _(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG(3);n.Y8G("validationErrors",v.form.priorRegistrationDate.errors)}}function D(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG(3);n.Y8G("validationErrors",v.form.priorRegistrationTime.errors)}}function E(f,x){if(1&f&&(n.j41(0,"div",8)(1,"div",53)(2,"label",54),n.EFF(3),n.nI1(4,"transloco"),n.k0s(),n.nrm(5,"date-flatpicker",55),n.DNE(6,_,1,1,"app-form-error",13),n.k0s(),n.j41(7,"div",53)(8,"label",56),n.EFF(9),n.nI1(10,"transloco"),n.k0s(),n.nrm(11,"time-flatpicker",55),n.DNE(12,D,1,1,"app-form-error",13),n.k0s()()),2&f){const v=n.XpG(2);n.R7$(3),n.SpI("",n.bMT(4,8,"workscreen.Add-event.Information.Form.Label.registration-end-date")," "),n.R7$(2),n.Y8G("isInvalid",v.submitted&&v.form.priorRegistrationDate.errors)("controlForm",v.form.priorRegistrationDate),n.R7$(),n.Y8G("ngIf",v.submitted),n.R7$(3),n.SpI("",n.bMT(10,10,"workscreen.Add-event.Information.Form.Label.time")," "),n.R7$(2),n.Y8G("isInvalid",v.submitted&&v.form.priorRegistrationTime.errors)("controlForm",v.form.priorRegistrationTime),n.R7$(),n.Y8G("ngIf",v.submitted)}}function j(f,x){if(1&f&&(n.j41(0,"div",49),n.nrm(1,"input",50),n.j41(2,"label",51),n.EFF(3),n.nI1(4,"transloco"),n.k0s()(),n.DNE(5,E,13,12,"div",52)),2&f){const v=n.XpG();n.R7$(3),n.JRh(n.bMT(4,2,"workscreen.Add-event.Information.Form.Label.registration-required")),n.R7$(2),n.Y8G("ngIf",v.form.priorRegistration.value)}}function L(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG(2);n.Y8G("validationErrors",v.form.socializingDesc.errors)}}function F(f,x){if(1&f&&(n.j41(0,"div",28)(1,"label",57),n.EFF(2),n.nI1(3,"transloco"),n.k0s(),n.nrm(4,"textarea",58),n.DNE(5,L,1,1,"app-form-error",13),n.k0s()),2&f){const v=n.XpG();n.R7$(2),n.SpI("",n.bMT(3,3,"workscreen.Add-event.Information.Form.Label.socializing-description")," "),n.R7$(2),n.Y8G("ngClass",n.eq3(5,X,v.submitted&&v.form.socializingDesc.errors)),n.R7$(),n.Y8G("ngIf",v.submitted)}}function A(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG();n.Y8G("validationErrors",v.form.contactEmail.errors)}}function h(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG();n.Y8G("validationErrors",v.form.contactNumber.errors)}}function G(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){const v=n.XpG();n.Y8G("validationErrors",v.form.ticketUrl.errors)}}function S(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){let v;const I=n.XpG().index,g=n.XpG();n.Y8G("validationErrors",null==(v=g.externalLinks.at(I).get("urlName"))?null:v.errors)}}function W(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){let v;const I=n.XpG().index,g=n.XpG();n.Y8G("validationErrors",null==(v=g.externalLinks.at(I).get("urlLink"))?null:v.errors)}}function J(f,x){if(1&f&&(n.j41(0,"div",59)(1,"div",60)(2,"div",22)(3,"label",61),n.EFF(4),n.nI1(5,"transloco"),n.k0s(),n.nrm(6,"input",62),n.nI1(7,"transloco"),n.DNE(8,S,1,1,"app-form-error",13),n.k0s(),n.j41(9,"div",22)(10,"label",63),n.EFF(11),n.nI1(12,"transloco"),n.k0s(),n.nrm(13,"input",64),n.nI1(14,"transloco"),n.DNE(15,W,1,1,"app-form-error",13),n.k0s()()()),2&f){let v,I;const g=x.index,c=n.XpG();n.R7$(),n.Y8G("formGroupName",g),n.R7$(3),n.SpI("",n.bMT(5,9,"Form.Label.title")," "),n.R7$(2),n.FS9("placeholder",n.bMT(7,11,"workscreen.Add-event.Information.Form.Placeholder.title")),n.Y8G("ngClass",n.eq3(1
17,X,c.submitted&&(null==(v=c.externalLinks.at(g).get("urlName"))?null:v.errors))),n.R7$(2),n.Y8G("ngIf",c.submitted),n.R7$(3),n.SpI("",n.bMT(12,13,"workscreen.Add-event.Information.Form.Label.url")," "),n.R7$(2),n.FS9("placeholder",n.bMT(14,15,"workscreen.Add-event.Information.Form.Placeholder.url")),n.Y8G("ngClass",n.eq3(19,X,c.submitted&&(null==(I=c.externalLinks.at(g).get("urlLink"))?null:I.errors))),n.R7$(2),n.Y8G("ngIf",c.submitted)}}function ie(f,x){if(1&f&&(n.j41(0,"option",71),n.EFF(1),n.k0s()),2&f){const v=x.$implicit,I=n.XpG(2);n.Y8G("hidden",!!I.hiddenSponsorIds.includes(v.idDataEventSponsor)||null)("value",v.idDataEventSponsor),n.R7$(),n.SpI(" ",v.name," ")}}function ae(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){let v;const I=n.XpG().index,g=n.XpG();n.Y8G("validationErrors",null==(v=g.eventSponsors.at(I).get("idDataOrganizationSponsor"))?null:v.errors)}}function se(f,x){if(1&f&&n.nrm(0,"app-form-error",45),2&f){let v;const I=n.XpG().index,g=n.XpG();n.Y8G("validationErrors",null==(v=g.eventSponsors.at(I).get("customRole"))?null:v.errors)}}function le(f,x){if(1&f&&(n.j41(0,"div",65)(1,"div",60)(2,"div",22)(3,"label",61),n.EFF(4),n.nI1(5,"transloco"),n.k0s(),n.j41(6,"select",66)(7,"option",67),n.EFF(8),n.nI1(9,"transloco"),n.k0s(),n.DNE(10,ie,2,3,"option",68),n.k0s(),n.DNE(11,ae,1,1,"app-form-error",13),n.k0s(),n.j41(12,"div",22)(13,"label",69),n.EFF(14),n.nI1(15,"transloco"),n.k0s(),n.nrm(16,"input",70),n.nI1(17,"transloco"),n.DNE(18,se,1,1,"app-form-error",13),n.k0s()()()),2&f){let v,I;const g=x.index,c=n.XpG();n.R7$(),n.Y8G("formGroupName",g),n.R7$(3),n.Lme("",g+1,". ",n.bMT(5,13,"workscreen.Add-event.Information.Form.Label.sponsor")," "),n.R7$(2),n.Y8G("ngClass",n.eq3(21,X,c.submitted&&(null==(v=c.eventSponsors.at(g).get("idDataOrganizationSponsor"))?null:v.errors))),n.R7$(),n.Y8G("value",null),n.R7$(),n.SpI(" ",n.bMT(9,15,"workscreen.Add-event.Information.Form.Placeholder.sponsor")," "),n.R7$(2),n.Y8G("ngForOf",c.sponsorOptions)("ngForTrackBy",c.trackSponsorOptions),n.R7$(),n.Y8G("ngIf",c.submitted),n.R7$(3),n.SpI("",n.bMT(15,17,"workscreen.Add-event.Information.Form.Label.sponsor-role")," "),n.R7$(2),n.FS9("placeholder",n.bMT(17,19,"workscreen.Add-event.Information.Form.Placeholder.sponsor-role")),n.Y8G("ngClass",n.eq3(23,X,c.submitted&&(null==(I=c.eventSponsors.at(g).get("customRole"))?null:I.errors))),n.R7$(2),n.Y8G("ngIf",c.submitted)}}function ce(f,x){if(1&f){const v=n.RV6();n.j41(0,"button",72),n.bIt("click",function(){n.eBV(v);const g=n.XpG();return n.Njj(g.toPrevStep())}),n.nrm(1,"i",73),n.EFF(2),n.nI1(3,"transloco"),n.k0s()}2&f&&(n.R7$(2),n.SpI("",n.bMT(3,1,"Button.previous-step")," "))}function pe(f,x){if(1&f){const v=n.RV6();n.j41(0,"button",72),n.bIt("click",function(){n.eBV(v);const g=n.XpG();return n.Njj(g.toLastStep())}),n.nrm(1,"i",73),n.EFF(2),n.nI1(3,"transloco"),n.k0s()}2&f&&(n.R7$(2),n.SpI("",n.bMT(3,1,"Button.cancel")," "))}let me=(()=>{class f{get form(){return this.eventInfoForm.controls}get externalLinks(){return this.eventInfoForm.get("externalLinks")}get eventSponsors(){return this.eventInfoForm.get("eventSponsors")}constructor(v,I,g,c,s,l,r,m){this.formBuilder=v,this._eventsService=I,this._toastService=g,this._translocoService=c,this._fourthStepService=s,this._profileService=l,this._errorsTranslationService=r,this._userService=m,this.NEXT_STEP=5,this.PREV_STEP=3,this.isEditMode=!1,this.sponsorOptions=[],this.hiddenSponsorIds=[],this.isOnRequest=!1,this._unsubscribeAll=new N.B,this.eventInfoForm=this.formBuilder.group({ticketPrice:[null],isFree:[!1],priorRegistration:[!1],priorRegistrationDate:[null],priorRegistrationTime:[null],socializing:[!1],socializingDesc:[null],contactEmail:[null,[o.k0.email]],contactNumber:[null,(0,t.bb)()],ticketUrl:[null],externalLinks:this.formBuilder.array([this.formBuilder.group({urlName:[null],urlLink:[null]},{validators:t.Ne.fieldsEmptyOrRequired("urlName","urlLink")})]),eventSponsors:this.formBuilder.array([this.formBuilder.group({idDataOrganizationSponsor:[null],customRole:[null]},{validators:t.Ne.fieldsEmptyOrRequired("idDataOrganizationSponsor","customRole")})])}),this._userService.user$.pipe((0,y.Q)(this._unsubscribeAll)).subscribe(u=>{this.user=u}),this._eventsService.canDeactivate=!0,window.scroll({top:0,left:0})}ngOnInit(){this._eventsService.firstStepForm$.pipe((0,e.$)()).subscribe(v=>{v&&v.idCodeListGenre&&8===Number(v.idCodeListGenre)&&(this.isOnRequest=!0)}),this._eventsService.fourthStepForm$.pipe((0,e.$)()).subscribe(v=>{if(v){if(v.externalLinks&&v.externalLinks.length>1){const I=v.externalLinks.length;for(let g=1;g<I;g++)this.addExternalLink()}if(v.eventSponsors&&v.eventSponsors.length>1){const I=v.eventSponsors.length;for(let g=1;g<I;g++)this.addSponsor()}this.eventInfoForm.patchValue(v)}else this._getProfileData()}),this._getSponsorOptions()}ngAfterViewInit(){this.eventInfoForm.get("isFree")?.valueChanges.pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:v=>{v&&this.eventInfoForm.get("ticketPrice")?.setValue(null)}}),this.eventSponsors?.valueChanges.pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:v=>{if(v){const I=v.map(g=>g.idDataOrganizationSponsor).map(g=>Number(g));this.hiddenSponsorIds=I}}})}ngOnDestroy(){this._unsubscribeAll.next(!0),this._unsubscribeAll.complete()}addExternalLink(){const v=this.formBuilder.group({urlName:[null],urlLink:[null]},{validators:t.Ne.fieldsEmptyOrRequired("urlName","urlLink")});this.externalLinks.push(v)}addSponsor(){const v=this.formBuilder.group({idDataOrganizationSponsor:[null],customRole:[null]},{validators:t.Ne.fieldsEmptyOrRequired("idDataOrganizationSponsor","customRole")});this.eventSponsors.push(v)}toPrevStep(){this._eventsService.selectedStep=this.PREV_STEP}toLastStep(){this._eventsService.selectedStep=this.NEXT_STEP}trackSponsorOptions(v,I){return I.idDataEventSponsor||v}onSubmit(){this.submitted=!0,this.eventInfoForm.valid&&this._patchFourthStepData()}_patchFourthStepData(){this._fourthStepService.fourthStepReq(this._createFourthStepReq(),this._eventsService.eventId$).pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:()=>{this._toastService.show(this._translocoService.translate("Toast.Message.save-successful"),{type:"success",class:"success-toast"}),this._eventsService.selectedStep=this.NEXT_STEP,this._eventsService.fourthStepForm=this.eventInfoForm.value},error:v=>{this._toastService.show(this._errorsTranslationService.translate(v.error?.code??v.error),{type:"error",class:"danger-toast"})}})}_getSponsorOptions(){this._fourthStepService.getSponsorOptions(this._eventsService.eventId$).pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:v=>{this.sponsorOptions=v},error:v=>{this.sponsorOptions=[],this._toastService.show(this._errorsTranslationService.translate(v.error?.code??v.error),{type:"error",class:"danger-toast"})}})}_createFourthStepReq(){return{ticketPrice:this.eventInfoForm.value.ticketPrice,isFree:this.eventInfoForm.value.isFree,priorRegistration:this.eventInfoForm.value.priorRegistration,priorRegistrationDate:""===this.eventInfoForm.value.priorRegistrationDate?null:this.eventInfoForm.value.priorRegistrationDate,priorRegistrationTime:""===this.eventInfoForm.value.priorRegistrationTime?null:this.eventInfoForm.value.priorRegistrationTime,socializing:this.eventInfoForm.value.socializing,socializingDesc:this.eventInfoForm.value.socializingDesc,contactInformation:{contactEmail:this.eventInfoForm.value.contactEmail,contactNumber:this.eventInfoForm.value.contactNumber},ticketUrl:this.eventInfoForm.value.ticketUrl,externalLinks:this._removeEmptyObjects(this.externalLinks.value),eventSponsors:this._removeEmptyObjects(this.eventSponsors.value)}}_removeEmptyObjects(v){return v.filter(I=>Object.values(I).every(g=>null!==g&&""!==g))}_getProfileData(){this._profileService.getProfileData().pipe((0,y.Q)(this._unsubscribeAll)).subscribe({next:v=>{this.eventInfoForm.patchValue({contactEmail:v.contactEmail,contactNumber:v.contactPhone})},error:v=>{this._toastService.show(this._errorsTranslationService.translate(v.error?.code??v.error),{type:"error",class:"danger-toast"})}})}static{this.\u0275fac=function(I){return new(I||f)(n.rXU(o.ok),n.rXU($.H),n.rXU(i.f),n.rXU(B.JO),n.rXU(k),n.rXU(Y.p),n.rXU(ee.k),n.rXU(te.D))}}static{this.\u0275cmp=n.VBU({type:f,selectors:[["event-step-4"]],inputs:{isEditMode:"isEditMode"},standalone:!0,features:[n.aNF],decls:102,vars:104,consts:[[1,"row","justify-content-center","pb-sm-2"],[1,"col-lg-11","col-xl-10"],[1,"text-center","pb-4"],[1,"h2"],[3,"step",4,"ngIf"],[1,"bg-light","rounded-3","p-4","p-md-5","mb
1-3",3,"formGroup"],[1,"h4","mb-4"],[1,"fi-info-circle","text-muted","fs-4","mt-n1","me-2","pe-1"],[1,"row"],[1,"col-sm-8","mb-4"],["for","price",1,"form-label",3,"ngClass"],["class","text-danger",4,"ngIf"],["type","text","id","price","formControlName","ticketPrice",1,"form-control","form-control-lg",3,"placeholder","required","readOnly","ngClass"],[3,"validationErrors",4,"ngIf"],[1,"col-sm-4","mb-4","form-check-container"],[1,"mb-4","form-check"],["type","checkbox","id","socializing","formControlName","socializing",1,"form-check-input"],["for","socializing",1,"form-check-label"],["class","mb-4",4,"ngIf"],[1,"h4","mb-2","border-top","pt-4"],[1,"fi-send","text-muted","fs-4","mt-n1","me-2","pe-1"],[1,"form-text","mb-4"],[1,"col-sm-6","mb-4"],["for","email",1,"form-label"],["type","text","formControlName","contactEmail","id","email",1,"form-control","form-control-lg",3,"ngClass","placeholder"],["for","phone",1,"form-label"],["type","text","formControlName","contactNumber","id","phone",1,"form-control","form-control-lg",3,"ngClass","placeholder"],[1,"fi-ticket","text-muted","fs-4","mt-n1","me-2","pe-1"],[1,"mb-4"],["for","ticket-url",1,"form-label"],["type","text","formControlName","ticketUrl","id","ticket-url",1,"form-control","form-control-lg",3,"ngClass","placeholder"],[1,"fi-link","text-muted","fs-4","mt-n1","me-2","pe-1"],["formArrayName","externalLinks",4,"ngFor","ngForOf"],[1,"btn","btn-outline-primary","btn-sm","rounded-pill","mb-4","align-items-center","d-flex",3,"click"],[1,"fi-plus-circle","fs-sm","me-2","pt-1"],[1,"fi-flag","text-muted","fs-4","mt-n1","me-2","pe-1"],["routerLink","/delovni-zaslon/sponzorji","target","_blank"],["formArrayName","eventSponsors",4,"ngFor","ngForOf"],[1,"btn","btn-outline-primary","btn-sm","rounded-pill","align-items-center","d-flex",3,"click"],[1,"d-flex","flex-column","flex-sm-row","bg-light","rounded-3","p-4","px-md-5"],["class","btn btn-outline-primary btn-lg rounded-pill mb-3 mb-sm-0",3,"click",4,"ngIf"],[1,"btn","btn-primary","btn-lg","rounded-pill","ms-sm-auto",3,"click"],[1,"fi-chevron-right","fs-sm","ms-2"],[3,"step"],[1,"text-danger"],[3,"validationErrors"],[1,"form-check"],["type","checkbox","id","free-event","formControlName","isFree",1,"form-check-input"],["for","free-event",1,"form-check-label"],[1,"mb-4","form-check","border-top","pt-4"],["type","checkbox","id","registration-required","formControlName","priorRegistration",1,"form-check-input"],["for","registration-required",1,"form-check-label"],["class","row",4,"ngIf"],[1,"col-sm-5","mb-4"],["for","registration-end",1,"form-label"],[3,"isInvalid","controlForm"],["for","time",1,"form-label"],["for","socializing-description",1,"form-label"],["id","socializing-description","formControlName","socializingDesc","rows","5",1,"form-control",3,"ngClass"],["formArrayName","externalLinks"],[1,"row",3,"formGroupName"],["for","url-title",1,"form-label"],["type","text","formControlName","urlName","id","url-title",1,"form-control","form-control-lg",3,"placeholder","ngClass"],["for","url-link",1,"form-label"],["type","text","formControlName","urlLink","id","url-link",1,"form-control","form-control-lg",3,"placeholder","ngClass"],["formArrayName","eventSponsors"],["id","sponsor","formControlName","idDataOrganizationSponsor",1,"form-select","form-select-lg",3,"ngClass"],["disabled","","selected","","hidden","",3,"value"],[3,"hidden","value",4,"ngFor","ngForOf","ngForTrackBy"],["for","sponsor-role",1,"form-label"],["type","text","formControlName","customRole","id","url-title",1,"form-control","form-control-lg",3,"placeholder","ngClass"],[3,"hidden","value"],[1,"btn","btn-outline-primary","btn-lg","rounded-pill","mb-3","mb-sm-0",3,"click"],[1,"fi-chevron-left","fs-sm","me-2"]],template:function(I,g){1&I&&(n.j41(0,"div",0)(1,"div",1)(2,"div",2)(3,"h1",3),n.EFF(4),n.nI1(5,"transloco"),n.nI1(6,"transloco"),n.k0s()(),n.DNE(7,ne,1,1,"event-steps",4),n.j41(8,"div",5)(9,"h2",6),n.nrm(10,"i",7),n.EFF(11),n.nI1(12,"transloco"),n.k0s(),n.j41(13,"div",8)(14,"div",9)(15,"label",10),n.EFF(16),n.nI1(17,"transloco"),n.DNE(18,oe,2,0,"span",11),n.k0s(),n.nrm(19,"input",12),n.nI1(20,"transloco"),n.DNE(21,C,1,1,"app-form-error",13),n.k0s(),n.DNE(22,q,6,3,"div",14),n.k0s(),n.DNE(23,j,6,4),n.j41(24,"div",15),n.nrm(25,"input",16),n.j41(26,"label",17),n.EFF(27),n.n
1I1(28,"transloco"),n.k0s()(),n.DNE(29,F,6,7,"div",18),n.j41(30,"h2",19),n.nrm(31,"i",20),n.EFF(32),n.nI1(33,"transloco"),n.k0s(),n.j41(34,"div",21),n.EFF(35),n.nI1(36,"transloco"),n.k0s(),n.j41(37,"div",8)(38,"div",22)(39,"label",23),n.EFF(40),n.nI1(41,"transloco"),n.k0s(),n.nrm(42,"input",24),n.nI1(43,"transloco"),n.DNE(44,A,1,1,"app-form-error",13),n.k0s(),n.j41(45,"div",22)(46,"label",25),n.EFF(47),n.nI1(48,"transloco"),n.k0s(),n.nrm(49,"input",26),n.nI1(50,"transloco"),n.DNE(51,h,1,1,"app-form-error",13),n.k0s()(),n.j41(52,"h2",19),n.nrm(53,"i",27),n.EFF(54),n.nI1(55,"transloco"),n.k0s(),n.j41(56,"div",21),n.EFF(57),n.nI1(58,"transloco"),n.k0s(),n.j41(59,"div",28)(60,"label",29),n.EFF(61),n.nI1(62,"transloco"),n.k0s(),n.nrm(63,"input",30),n.nI1(64,"transloco"),n.DNE(65,G,1,1,"app-form-error",13),n.k0s(),n.j41(66,"h2",19),n.nrm(67,"i",31),n.EFF(68),n.nI1(69,"transloco"),n.k0s(),n.j41(70,"div",21),n.EFF(71),n.nI1(72,"transloco"),n.k0s(),n.DNE(73,J,16,21,"div",32),n.j41(74,"button",33),n.bIt("click",function(){return g.addExternalLink()}),n.nrm(75,"i",34),n.EFF(76),n.nI1(77,"transloco"),n.k0s(),n.j41(78,"h2",19),n.nrm(79,"i",35),n.EFF(80),n.nI1(81,"transloco"),n.k0s(),n.j41(82,"div",21),n.EFF(83),n.nI1(84,"transloco"),n.j41(85,"a",36),n.EFF(86),n.nI1(87,"transloco"),n.k0s(),n.EFF(88,". "),n.k0s(),n.DNE(89,le,19,25,"div",37),n.j41(90,"button",38),n.bIt("click",function(){return g.addSponsor()}),n.nrm(91,"i",34),n.EFF(92),n.nI1(93,"transloco"),n.k0s()(),n.j41(94,"div",39),n.DNE(95,ce,4,3,"button",40)(96,pe,4,3,"button",40),n.j41(97,"button",41),n.bIt("click",function(){return g.onSubmit()}),n.EFF(98),n.nI1(99,"transloco"),n.nI1(100,"transloco"),n.nrm(101,"i",42),n.k0s()()()()),2&I&&(n.R7$(4),n.SpI(" ",g.isEditMode?n.bMT(5,44,"workscreen.Edit-event.edit-event"):n.bMT(6,46,"workscreen.Add-event.add-event")," "),n.R7$(3),n.Y8G("ngIf",!g.isEditMode),n.R7$(),n.Y8G("formGroup",g.eventInfoForm),n.R7$(3),n.SpI("",n.bMT(12,48,"workscreen.Add-event.Information.other-info")," "),n.R7$(4),n.Y8G("ngClass",n.eq3(94,V,g.form.isFree.value)),n.R7$(),n.SpI("",n.bMT(17,50,"workscreen.Add-event.Information.Form.Label.price")," "),n.R7$(2),n.Y8G("ngIf",g.isOnRequest),n.R7$(),n.FS9("placeholder",n.bMT(20,52,"workscreen.Add-event.Information.Form.Placeholder.price")),n.Y8G("required",g.isOnRequest)("readOnly",g.form.isFree.value)("ngClass",n.eq3(96,X,g.submitted&&g.form.ticketPrice.errors)),n.R7$(2),n.Y8G("ngIf",g.submitted),n.R7$(),n.vxM(g.isOnRequest?-1:22),n.R7$(),n.vxM("S"!==(null==g.user?null:g.user.packageShortName)?23:-1),n.R7$(4),n.JRh(n.bMT(28,54,"workscreen.Add-event.Information.Form.Label.socializing-after-event")),n.R7$(2),n.Y8G("ngIf",g.form.socializing.value),n.R7$(3),n.SpI("",n.bMT(33,56,"workscreen.Add-event.Information.contact-info")," "),n.R7$(3),n.SpI(" ",n.bMT(36,58,"workscreen.Add-event.Information.Form.contacts-info-helper")," "),n.R7$(5),n.SpI("",n.bMT(41,60,"Form.Label.email")," "),n.R7$(2),n.FS9("placeholder",n.bMT(43,62,"Form.Placeholder.email")),n.Y8G("ngClass",n.eq3(98,X,g.submitted&&g.form.contactEmail.errors)),n.R7$(2),n.Y8G("ngIf",g.submitted),n.R7$(3),n.SpI("",n.bMT(48,64,"Form.Label.phone")," "),n.R7$(2),n.FS9("placeholder",n.bMT(50,66,"Form.Placeholder.phone")),n.Y8G("ngClass",n.eq3(100,X,g.submitted&&g.form.contactNumber.errors)),n.R7$(2),n.Y8G("ngIf",g.submitted),n.R7$(3),n.SpI("",n.bMT(55,68,"workscreen.Add-event.Information.tickets-link")," "),n.R7$(3),n.SpI(" ",n.bMT(58,70,"workscreen.Add-event.Information.Form.tickets-link-helper")," "),n.R7$(4),n.SpI("",n.bMT(62,72,"workscreen.Add-event.Information.Form.Label.url")," "),n.R7$(2),n.FS9("placeholder",n.bMT(64,74,"workscreen.Add-event.Information.Form.Placeholder.url")),n.Y8G("ngClass",n.eq3(102,X,g.submitted&&g.form.ticketUrl.errors)),n.R7$(2),n.Y8G("ngIf",g.submitted),n.R7$(3),n.SpI("",n.bMT(69,76,"workscreen.Add-event.Information.external-links")," "),n.R7$(3),n.SpI(" ",n.bMT(72,78,"workscreen.Add-event.Information.Form.external-links-helper")," "),n.R7$(2),n.Y8G("ngForOf",g.externalLinks.controls),n.R7$(3),n.SpI("",n.bMT(77,80,"Button.add")," "),n.R7$(4),n.SpI("",n.bMT(81,82,"workscreen.Add-event.Information.sponsors")," "),n.R7$(3),n.SpI(" ",n.bMT(84,84,"workscreen.Add-event.Information.Form.sponsors-helper-1")," "),n.R7$(3),n.JRh(n.bMT(87,86,"workscreen.Add-event.Information.Form.sponsors-helper-2")),n.R7$(3),n.Y8G("ngForOf",g.eventSponsors.controls),n.R7$(3),n.SpI("",n.bMT(93,88,"Button.add")," "),n.R7$(3),n.Y8G("ngIf",!g.isEditMode),n.R7$(),n.Y8G("ngIf",g.isEditMode),n.R7$(2),n.SpI(" ",g.isEditMode?n.bMT(99,90,"Button.save"):n.bMT(100,92,"Button.save-and-continue"),""))},dependencies:[T.MD,T.YU,T.Sq,T.bT,o.YN,o.xH,o.y7,o.me,o.Zm,o.wz,o.BC,o.cb,o.YS,o.X1,o.j4,o.JD,o.$R,o.v8,d.Wk,B.Q8,B.Kj,b.G,K.X,P.g,z.O,O.h]})}}return f})()},5651:(re,w,p)=>{p.d(w,{z:()=>g});var T=p(177),o=p(5176),d=p(6508),B=p(9386),b=p(1413),z=p(6977),O=p(5312),N=p(4623),y=p(8229),e=p(4438),t=p(5335),n=p(783),$=p(1562);let i=(()=>{class c{constructor(l){this.http=l}getEventData(l){return this.http.get(`${O.c.api}/controlpanel/v1/event/${l}`)}publishEvent(l){return this.http.patch(`${O.c.api}/controlpanel/v1/event/${l}/publish`,null)}static{this.\u0275fac=function(r){return new(r||c)(e.KVO($.Qq))}}static{this.\u0275prov=e.jDH({token:c,factory:c.\u0275fac,providedIn:"root"})}}return c})();var M=p(2791),R=p(2219);const k=c=>({"pb-5":c});function Y(c,s){1&c&&e.nrm(0,"event-steps",10),2&c&&e.Y8G("step",5)}function ee(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" (",e.bMT(1,1,"workscreen.Add-event.Review.in-draft"),") ")}function te(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" (",e.bMT(1,1,"workscreen.Add-event.Review.published"),") ")}
1function K(c,s){if(1&c){const l=e.RV6();e.j41(0,"div",11)(1,"h2",12),e.nrm(2,"i",13),e.EFF(3),e.nI1(4,"transloco"),e.k0s(),e.j41(5,"button",14),e.bIt("click",function(){let m;e.eBV(l);const u=e.XpG();return e.Njj(u.navigateToEvent(null!==(m=null==u.eventData||null==u.eventData.eventBaseData?null:u.eventData.eventBaseData.codeListParentGenre)&&void 0!==m?m:"",null!==(m=null==u.eventData||null==u.eventData.eventBaseData?null:u.eventData.eventBaseData.codeListGenre)&&void 0!==m?m:"",null!==(m=null==u.eventData||null==u.eventData.eventBaseData?null:u.eventData.eventBaseData.name)&&void 0!==m?m:"",null!==(m=null==u.eventData||null==u.eventData.eventBaseData?null:u.eventData.eventBaseData.idDataEvent)&&void 0!==m?m:-1))}),e.EFF(6),e.nI1(7,"transloco"),e.DNE(8,ee,2,3)(9,te,2,3),e.k0s()()}if(2&c){const l=e.XpG();e.R7$(3),e.SpI("",e.bMT(4,3,"workscreen.Add-event.Review.review-and-post")," "),e.R7$(3),e.SpI(" ",e.bMT(7,5,"workscreen.Add-event.Review.preview")," "),e.R7$(2),e.vxM(0===(null==l.eventData||null==l.eventData.eventBaseData?null:l.eventData.eventBaseData.status)?8:9)}}function P(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.True")," ")}function V(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.False")," ")}function X(c,s){1&c&&e.EFF(0),2&c&&e.SpI(" ","/"," ")}function ne(c,s){1&c&&(e.j41(0,"span"),e.EFF(1," /"),e.k0s())}function oe(c,s){if(1&c&&(e.j41(0,"div",27)(1,"div",31),e.nrm(2,"img",32),e.k0s()()),2&c){const l=e.XpG(2);e.R7$(2),e.Y8G("src",l.eventImagesFolder+l.coverImageLink,e.B4B)}}function C(c,s){1&c&&(e.j41(0,"span"),e.EFF(1," /"),e.k0s())}function q(c,s){if(1&c&&(e.qex(0),e.j41(1,"div",31),e.nrm(2,"img",33),e.k0s(),e.bVm()),2&c){const l=s.$implicit,r=e.XpG(2);e.R7$(2),e.Y8G("src",r.eventImagesFolder+l.link,e.B4B)}}function _(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.False")," ")}function D(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.True")," ")}function E(c,s){1&c&&e.EFF(0),2&c&&e.SpI(" ","/"," ")}function j(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.True")," ")}function L(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.False")," ")}function F(c,s){if(1&c&&(e.j41(0,"li")(1,"span",21),e.EFF(2),e.nI1(3,"transloco"),e.k0s(),e.EFF(4),e.nI1(5,"date"),e.k0s()),2&c){const l=e.XpG(2);e.R7$(2),e.SpI("",e.bMT(3,2,"workscreen.Add-event.Review.prior-registration-date"),":"),e.R7$(2),e.SpI(" ",e.i5U(5,4,null==l.eventData||null==l.eventData.eventBaseData?null:l.eventData.eventBaseData.priorRegistrationDate,"dd.MM.yyyy")," ")}}function A(c,s){if(1&c&&(e.j41(0,"li")(1,"span",21),e.EFF(2),e.nI1(3,"transloco"),e.k0s(),e.EFF(4),e.nI1(5,"dateOnlyOrTimeOnlyFormat"),e.k0s()),2&c){const l=e.XpG(2);e.R7$(2),e.SpI(" ",e.bMT(3,2,"workscreen.Add-event.Review.prior-registration-time"),":"),e.R7$(2),e.SpI(" ",e.bMT(5,4,null==l.eventData||null==l.eventData.eventBaseData?null:l.eventData.eventBaseData.priorRegistrationDate)," ")}}function h(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.True")," ")}function G(c,s){1&c&&(e.EFF(0),e.nI1(1,"transloco")),2&c&&e.SpI(" ",e.bMT(1,1,"CodeList.Bool.False")," ")}function S(c,s){1&c&&e.EFF(0),2&c&&e.SpI(" ","/"," ")}function W(c,s){if(1&c&&(e.j41(0,"li")(1,"span",21),e.EFF(2),e.nI1(3,"transloco"),e.k0s(),e.EFF(4),e.k0s()),2&c){let l;const r=e.XpG(2);e.R7$(2),e.SpI("",e.bMT(3,2,"workscreen.Add-event.Review.socializing-description"),":"),e.R7$(2),e.SpI(" ",null!==(l=null==r.eventData||null==r.eventData.eventBaseData?null:r.eventData.eventBaseData.socializing)&&void 0!==l?l:"/"," ")}}function J(c,s){if(1&c){const l=e.RV6();e.j41(0,"a",34),e.bIt("click",function(){e.eBV(l);const m=e.XpG(2);return e.Njj(m.goToLink(null==m.eventData||null==m.eventData.eventBaseData?null:m.eventData.eventBaseData.ticketUrl))})("auxclick",function(){e.eBV(l);const m=e.XpG(2);return e.Njj(m.goToLink(null==m.eventData||null==m.eventData.eventBaseData?null:m.eventData.eventBaseData.ticketUrl))}),e.EFF(1),e.k0s()}if(2&c){const l=e.XpG(2);e.R7$(),e.JRh(null==l.eventData||null==l.eventData.eventBaseData?null:l.eventData.eventBaseData.ticketUrl)}}function ie(c,s){1&c&&e.EFF(0),2&c&&e.SpI(" ","/"," ")}function ae(c,s){1&c&&(e.j41(0,"li")(1,"span",21),e.EFF(2),e.nI1(3,"transloco"),e.k0s(),e.EFF(4," / "),e.k0s()),2&c&&(e.R7$(2),e.SpI("",e.bMT(3,1,"workscreen.Add-event.Review.external-url"),":"))}function se(c,s){if(1&c){const l=e.RV6();e.qex(0),e.j41(1,"li")(2,"span",21),e.EFF(3),e.nI1(4,"transloco"),e.k0s(),e.j41(5,"a",34),e.bIt("click",function(){const m=e.eBV(l).$implicit,u=e.XpG(2);return e.Njj(u.goToLink(m.urlLink))})("auxclick",function(){const m=e.eBV(l).$implicit,u=e.XpG(2);return e.Njj(u.goToLink(m.urlLink))}),e.EFF(6),e.k0s()(),e.bVm()}if(2&c){const l=s.$implicit,r=s.index;e.R7$(3),e.Lme(" ",e.bMT(4,3,"workscreen.Add-event.Review.external-url")," ",r+1,": "),e.R7$(3),e.JRh(l.urlName)}}function le(c,s){1&c&&(e.j41(0,"li")(1,"span",21),e.EFF(2),e.nI1(3,"transloco"),e.k0s(),e.EFF(4," / "),e.k0s()),2&c&&(e.R7$(2),e.SpI("",e.bMT(3,1,"workscreen.Add-event.Review.sponsors"),":"))}function ce(c,s){if(1&c&&(e.qex(0),e.j41(1,"li")(2,"span",21),e.EFF(3),e.nI1(4,"transloco"),e.k0s(),e.EFF(5),e.k0s(),e.bVm()),2&c){const l=s.$implicit,r=s.index;e.R7$(3),e.Lme(" ",e.bMT(4,4,"workscreen.Add-event.Information.Form.Label.sponsor")," ",r+1,":"),e.R7$(2),e.Lme(" ",l.name," - ",l.customRole," ")}}function pe(c,s){if(1&c){const l=e.RV6();e.j41(0,"div",15)(1,"div",16)(2,"div",17)(3,"div",18)(4,"h4",19),e.EFF(5),e.nI1(6,"transloco"),e.k0s(),e.j41(7,"ul",20)(8,"li")(9,"span",21),e.EFF(10),e.nI1(11,"transloco"),e.k0s(),e.EFF(12),e.k0s(),e.j41(13,"li")(14,"span",21),e.EFF(15),e.nI1(16,"transloco"),e.k0s(),e.EFF(17),e.k0s(),e.j41(18,"li")(19,"span",21),e.EFF(20),e.nI1(21,"transloco"),e.k0s(),e.EFF(22),e.nI1(23,"transloco"),e.k0s(),e.j41(24,"li")(25,"span",21),e.EFF(26),e.nI1(27,"transloco"),e.k0s(),e.EFF(28),e.nI1(29,"transloco"),e.k0s(),e.j41(30,"li")(31,"span",21),e.EFF(32),e.nI1(33,"transloco"),e.k0s(),e.nrm(34,"span",22),e.k0s(),e.j41(35,"li")(36,"span",21),e.EFF(37),e.nI1(38,"transloco"),e.k0s(),e.nrm(39,"span",22),e.k0s()(),e.j41(40,"a",23),e.bIt("click",function(){e.eBV(l);const m=e.XpG();return e.Njj(m.toStep(m.FIRST_STEP))}),e.nrm(41,"i",24),e.EFF(42),e.nI1(43,"transloco"),e.k0s()()(),e.j41(44,"div",25)(45,"h4",19),e.EFF(46),e.nI1(47,"transloco"),e.k0s(),e.j41(48,"ul",20)(49,"li")(50,"span",21),e.EFF(51),e.nI1(52,"transloco"),e.k0s(),e.EFF(53),e.nI1(54,"date"),e.k0s(),e.j41(55,"li")(56,"span",21),e.EFF(57),e.nI1(58,"transloco"),e.k0s(),e.EFF(59),e.nI1(60,"dateOnlyOrTimeOnlyFormat"),e.k0s(),e.j41(61,"li")(62,"span",21),e.EFF(63),e.nI1(64,"transloco"),e.k0s(),e.EFF(65),e.nI1(66,"date"),e.k0s(),e.j41(67,"li")(68,"span",21),e.EFF(69),e.nI1(70,"transloco"),e.k0s(),e.EFF(71),e.nI1(72,"dateOnlyOrTimeOnlyFormat"),e.k0s(),e.j41(73,"li")(74,"span",21),e.EFF(75),e.nI1(76,"transloco"),e.k0s(),e.EFF(77),e.k0s(),e.j41(78,"li")(79,"span",21),e.EFF(80),e.nI1(81,"transloco"),e.k0s(),e.EFF(82),e.k0s(),e.j41(83,"li")(84,"span",21),e.EFF(85),e.nI1(86,"transloco"),e.k0s(),e.EFF(87),e.k0s(),e.j41(88,"li")(89,"
1span",21),e.EFF(90),e.nI1(91,"transloco"),e.k0s(),e.EFF(92),e.k0s(),e.j41(93,"li")(94,"span",21),e.EFF(95),e.nI1(96,"transloco"),e.k0s(),e.EFF(97),e.nI1(98,"transloco"),e.k0s(),e.j41(99,"li")(100,"span",21),e.EFF(101),e.nI1(102,"transloco"),e.k0s(),e.DNE(103,P,2,3)(104,V,2,3)(105,X,1,1),e.k0s(),e.j41(106,"li")(107,"span",21),e.EFF(108),e.nI1(109,"transloco"),e.k0s(),e.EFF(110),e.k0s()(),e.j41(111,"a",23),e.bIt("click",function(){e.eBV(l);const m=e.XpG();return e.Njj(m.toStep(m.SECOND_STEP))}),e.nrm(112,"i",24),e.EFF(113),e.nI1(114,"transloco"),e.k0s()(),e.j41(115,"div",25)(116,"h4",19),e.EFF(117),e.nI1(118,"transloco"),e.k0s(),e.j41(119,"ul",20)(120,"li")(121,"span",21),e.EFF(122),e.nI1(123,"transloco"),e.k0s(),e.DNE(124,ne,2,0,"span",8)(125,oe,3,1,"div",26),e.k0s(),e.j41(126,"li")(127,"span",21),e.EFF(128),e.nI1(129,"transloco"),e.k0s(),e.DNE(130,C,2,0,"span",8),e.j41(131,"div",27),e.DNE(132,q,3,1,"ng-container",28),e.k0s()(),e.j41(133,"li")(134,"span",21),e.EFF(135),e.nI1(136,"transloco"),e.k0s(),e.EFF(137),e.k0s()(),e.j41(138,"a",23),e.bIt("click",function(){e.eBV(l);const m=e.XpG();return e.Njj(m.toStep(m.THIRD_STEP))}),e.nrm(139,"i",24),e.EFF(140),e.nI1(141,"transloco"),e.k0s()(),e.j41(142,"div",29)(143,"h4",19),e.EFF(144),e.nI1(145,"transloco"),e.k0s(),e.j41(146,"ul",20)(147,"li")(148,"span",21),e.EFF(149),e.nI1(150,"transloco"),e.k0s(),e.EFF(151),e.k0s(),e.j41(152,"li")(153,"span",21),e.EFF(154),e.nI1(155,"transloco"),e.k0s(),e.DNE(156,_,2,3)(157,D,2,3)(158,E,1,1),e.k0s(),e.j41(159,"li")(160,"span",21),e.EFF(161),e.nI1(162,"transloco"),e.k0s(),e.DNE(163,j,2,3)(164,L,2,3),e.k0s(),e.DNE(165,F,6,7,"li",8)(166,A,6,6,"li",8),e.j41(167,"li")(168,"span",21),e.EFF(169),e.nI1(170,"transloco"),e.k0s(),e.DNE(171,h,2,3)(172,G,2,3)(173,S,1,1),e.k0s(),e.DNE(174,W,5,4,"li",8),e.j41(175,"li")(176,"span",21),e.EFF(177),e.nI1(178,"transloco"),e.k0s(),e.EFF(179),e.k0s(),e.j41(180,"li")(181,"span",21),e.EFF(182),e.nI1(183,"transloco"),e.k0s(),e.EFF(184),e.k0s(),e.j41(185,"li")(186,"span",21),e.EFF(187),e.nI1(188,"transloco"),e.k0s(),e.DNE(189,J,2,1,"a",30)(190,ie,1,1),e.k0s(),e.DNE(191,ae,5,3,"li",8)(192,se,7,5,"ng-container",28)(193,le,5,3,"li",8)(194,ce,6,6,"ng-container",28),e.k0s(),e.j41(195,"a",23),e.bIt("click",function(){e.eBV(l);const m=e.XpG();return e.Njj(m.toStep(m.FOURTH_STEP))}),e.nrm(196,"i",24),e.EFF(197),e.nI1(198,"transloco"),e.k0s()()()()}if(2&c){let l,r,m,u,U,Q,Z;const a=e.XpG();e.R7$(5),e.SpI(" ",e.bMT(6,78,"workscreen.Add-event.Review.event-description")," "),e.R7$(5),e.SpI("",e.bMT(11,80,"workscreen.Add-event.Event-description.Form.Label.event-name"),":"),e.R7$(2),e.SpI(" ",null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.name," "),e.R7$(3),e.SpI("",e.bMT(16,82,"workscreen.Add-event.Event-description.Form.Label.event-name-english"),":"),e.R7$(2),e.SpI(" ",null!==(l=null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.nameEn)&&void 0!==l?l:"/"," "),e.R7$(3),e.SpI("",e.bMT(21,84,"workscreen.Add-event.Event-description.Form.Label.event-section"),":"),e.R7$(2),e.SpI(" ",e.bMT(23,86,null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.codeListParentGenre)," "),e.R7$(4),e.SpI("",e.bMT(27,88,"workscreen.Add-event.Event-description.Form.Label.event-subsection"),":"),e.R7$(2),e.SpI(" ",e.bMT(29,90,null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.codeListGenre)," "),e.R7$(4),e.SpI("",e.bMT(33,92,"workscreen.Add-event.Event-description.Form.Label.event-description"),": "),e.R7$(2),e.Y8G("innerHTML",null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.descriptionSl,e.npT),e.R7$(3),e.SpI("",e.bMT(38,94,"workscreen.Add-event.Event-description.Form.Label.event-description-english"),": "),e.R7$(2),e.Y8G("innerHTML",null!==(r=null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.descriptionEn)&&void 0!==r?r:"/",e.npT),e.R7$(3),e.SpI("",e.bMT(43,96,"Button.edit")," "),e.R7$(4),e.SpI(" ",e.bMT(47,98,"workscreen.Add-event.Review.term-and-location")," "),e.R7$(5),e.SpI("",e.bMT(52,100,"workscreen.Add-event.Term-location.Form.Label.date-start"),":"),e.R7$(2),e.SpI(" ",null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.startDate?e.i5U(54,102,null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.startDate,"dd.MM.yyyy"):"/"," "),e.R7$(4),e.SpI("",e.bMT(58,105,"workscreen.Add-event.Term-location.Form.Label.time-start"),":"),e.R7$(2),e.SpI(" ",null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.startDate?e.bMT(60,107,null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.startDate):"/"," "),e.R7$(4),e.SpI("",e.bMT(64,109,"workscreen.Add-event.Term-location.Form.Label.date-end"),":"),e.R7$(2),e.SpI(" ",null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.endDate?e.i5U(66,111,null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.endDate,"dd.MM.yyyy"):"/"," "),e.R7$(4),e.SpI("",e.bMT(70,114,"workscreen.Add-event.Term-location.Form.Label.time-end"),":"),e.R7$(2),e.SpI(" ",null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.endDate?e.bMT(72,116,null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.endDate):"/"," "),e.R7$(4),e.SpI("",e.bMT(76,118,"workscreen.Add-event.Term-location.Form.Label.location-name"),":"),e.R7$(2),e.SpI(" ",(null==a.eventData||null==a.eventData.eventLocationData?null:a.eventData.eventLocationData.locationName)||"/"," "),e.R7$(3),e.SpI("",e.bMT(81,120,"Form.Label.street-house-nr"),":"),e.R7$(2),e.SpI(" ",(null==a.eventData||null==a.eventData.eventLocationData?null:a.eventData.eventLocationData.address)||"/"," "),e.R7$(3),e.SpI("",e.bMT(86,122,"Form.Label.postal-code"),":"),e.R7$(2),e.SpI(" ",(null==a.eventData||null==a.eventData.eventLocationData?null:a.eventData.eventLocationData.postalCode)||"/"," "),e.R7$(3),e.SpI("",e.bMT(91,124,"Form.Label.city"),":"),e.R7$(2),e.SpI(" ",(null==a.eventData||null==a.eventData.eventLocationData?null:a.eventData.eventLocationData.postalName)||"/"," "),e.R7$(3),e.SpI("",e.bMT(96,126,"Form.Label.regi
1on"),":"),e.R7$(2),e.SpI(" ",null!=a.eventData&&null!=a.eventData.eventLocationData&&a.eventData.eventLocationData.nameTranslation?e.bMT(98,128,null==a.eventData||null==a.eventData.eventLocationData?null:a.eventData.eventLocationData.nameTranslation):"/"," "),e.R7$(4),e.SpI("",e.bMT(102,130,"workscreen.Add-event.Term-location.event-virtual"),":"),e.R7$(2),e.vxM(null!==(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.urlVirtualLocation)&&null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.urlVirtualLocation?103:-1),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.urlVirtualLocation)||null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.urlVirtualLocation?-1:104),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.urlVirtualLocation)?105:-1),e.R7$(3),e.SpI("",e.bMT(109,132,"workscreen.Add-event.Review.online-link"),":"),e.R7$(2),e.SpI(" ",null!==(m=null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.urlVirtualLocation)&&void 0!==m?m:"/"," "),e.R7$(3),e.SpI("",e.bMT(114,134,"Button.edit")," "),e.R7$(4),e.SpI(" ",e.bMT(118,136,"workscreen.Add-event.Review.photo-and-video")," "),e.R7$(5),e.SpI("",e.bMT(123,138,"workscreen.Add-event.Photo-video.event-cover-photo"),":"),e.R7$(2),e.Y8G("ngIf",!a.coverImageLink),e.R7$(),e.Y8G("ngIf",a.coverImageLink),e.R7$(3),e.SpI("",e.bMT(129,140,"workscreen.Add-event.Photo-video.event-photos"),":"),e.R7$(2),e.Y8G("ngIf",!(null!=a.eventData&&a.eventData.eventImageData)||0===(null==(u=a.excludeCoverImage(null==a.eventData?null:a.eventData.eventImageData))?null:u.length)),e.R7$(2),e.Y8G("ngForOf",a.excludeCoverImage(null==a.eventData?null:a.eventData.eventImageData)),e.R7$(3),e.SpI("",e.bMT(136,142,"workscreen.Add-event.Review.link"),":"),e.R7$(2),e.SpI(" ",null!==(U=null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.urlAnnouncementVideo)&&void 0!==U?U:"/"," "),e.R7$(3),e.SpI("",e.bMT(141,144,"Button.edit")," "),e.R7$(4),e.SpI(" ",e.bMT(145,146,"workscreen.Add-event.Review.other-info")," "),e.R7$(5),e.SpI("",e.bMT(150,148,"workscreen.Add-event.Information.Form.Label.price"),":"),e.R7$(2),e.SpI(" ",(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.ticketPrice)||"/"," "),e.R7$(3),e.SpI("",e.bMT(155,150,"workscreen.Add-event.Information.Form.Label.free-event"),":"),e.R7$(2),e.vxM(null!==(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasTicketPrice)&&null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.hasTicketPrice?156:-1),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasTicketPrice)||null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.hasTicketPrice?-1:157),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasTicketPrice)?158:-1),e.R7$(3),e.SpI("",e.bMT(162,152,"workscreen.Add-event.Information.Form.Label.registration-required"),":"),e.R7$(2),e.vxM(null!==(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.priorRegistrationRequired)&&null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.priorRegistrationRequired?163:-1),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.priorRegistrationRequired)||null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.priorRegistrationRequired?-1:164),e.R7$(),e.Y8G("ngIf",null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.priorRegistrationDate),e.R7$(),e.Y8G("ngIf",null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.priorRegistrationDate),e.R7$(3),e.SpI("",e.bMT(170,154,"workscreen.Add-event.Information.Form.Label.socializing-after-event"),":"),e.R7$(2),e.vxM(null!==(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasSocializing)&&null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.hasSocializing?171:-1),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasSocializing)||null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.hasSocializing?-1:172),e.R7$(),e.vxM(null===(null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasSocializing)?173:-1),e.R7$(),e.Y8G("ngIf",null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.hasSocializing),e.R7$(3),e.SpI("",e.bMT(178,156,"Form.Label.email"),":"),e.R7$(2),e.SpI(" ",null!==(Q=null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.contactEmail)&&void 0!==Q?Q:"/"," "),e.R7$(3),e.SpI("",e.bMT(183,158,"Form.Label.phone"),":"),e.R7$(2),e.SpI(" ",null!==(Z=null==a.eventData||null==a.eventData.eventBaseData?null:a.eventData.eventBaseData.contactNumber)&&void 0!==Z?Z:"/"," "),e.R7$(3),e.SpI("",e.bMT(188,160,"workscreen.Add-event.Information.tickets-link"),": "),e.R7$(2),e.vxM(null!=a.eventData&&null!=a.eventData.eventBaseData&&a.eventData.eventBaseData.ticketUrl?189:190),e.R7$(2),e.Y8G("ngIf",!(null!=a.eventData&&a.eventData.eventExternalLinkData)||0===(null==a.eventData||null==a.eventData.eventExternalLinkData?null:a.eventData.eventExternalLinkData.length)),e.R7$(),e.Y8G("ngForOf",null==a.eventData?null:a.eventData.eventExternalLinkData),e.R7$(),e.Y8G("ngIf",!(null!=a.eventData&&a.eventData.eventSponsorData)||0===(null==a.eventData||null==a.eventData.eventSponsorData?null:a.eventData.eventSponsorData.length)),e.R7$(),e.Y8G("ngForOf",null==a.eventData?null:a.eventData.eventSponsorData),e.R7$(3),e.SpI("",e.bMT(198,162,"Button.edit")," ")}}function me(c,s){1&c&&e.nrm(0,"app-spinner")}function f(c,s){if(1&c){const l=e.RV6();e.j41(0,"div",35)(1,"button",36),e.bIt("click",function(){e.eBV(l);const m=e.XpG();return e.Njj(m.toPrevStep())}),e.nrm(2,"i",37),e.EFF(3),e.nI1(4,"transloco"),e.k0s(),e.j41(5,"button",38),e.bIt("click",function(){e.eBV(l);const m=e.XpG();return e.Njj(m.publishEvent())}),e.EFF(6),e.nI1(7,"transloco"),e.k0s()()}2&c&&(e.R7$(3),e.SpI("",e.bMT(4,2,"Button.previous-step")," "),e.R7$(3),e.SpI(" ",e.bMT(7,4,"workscreen.Add-event.Review.publish-event")," "))}
1function x(c,s){if(1&c){const l=e.RV6();e.j41(0,"button",38),e.bIt("click",function(){e.eBV(l);const m=e.XpG(2);return e.Njj(m.publishEvent())}),e.EFF(1),e.nI1(2,"transloco"),e.k0s()}2&c&&(e.R7$(),e.SpI(" ",e.bMT(2,1,"workscreen.Add-event.Review.publish-event")," "))}function v(c,s){if(1&c){const l=e.RV6();e.j41(0,"button",38),e.bIt("click",function(){e.eBV(l);const m=e.XpG(2);return e.Njj(m.saveAndExitEvent(null==m.eventData||null==m.eventData.eventBaseData?null:m.eventData.eventBaseData.isMyEvent))}),e.EFF(1),e.nI1(2,"transloco"),e.k0s()}2&c&&(e.R7$(),e.SpI(" ",e.bMT(2,1,"Button.exit")," "))}function I(c,s){if(1&c&&(e.j41(0,"div",35),e.DNE(1,x,3,3,"button",39)(2,v,3,3,"button",39),e.k0s()),2&c){const l=e.XpG();e.R7$(),e.vxM(l.showEventPublishOption()?1:2)}}let g=(()=>{class c{get eventImagesFolder(){return O.c.assetsSrc}constructor(l,r,m,u,U,Q,Z){this._eventsService=l,this._toastService=r,this._fifthStepService=m,this._datePipe=u,this._router=U,this._translocoService=Q,this._errorsTranslationService=Z,this.FIRST_STEP=1,this.SECOND_STEP=2,this.THIRD_STEP=3,this.FOURTH_STEP=4,this.PREV_STEP=4,this.isEditMode=!1,this.isAdmin=!1,this.isDataLoaded=!1,this._unsubscribeAll=new b.B,this._getEventData(),this._eventsService.canDeactivate=!0}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}toStep(l){this._eventsService.selectedStep=l}toPrevStep(){this._eventsService.selectedStep=this.PREV_STEP}excludeCoverImage(l){return l?.filter(r=>!r.isCover)}saveAndExitEvent(l){this._router.navigateByUrl(this.isAdmin&&!l?"/nadzorna-plosca/dogodki":"/delovni-zaslon/moji-dogodki")}showEventPublishOption(){if(!this.eventData||!this.eventData?.eventBaseData)return!1;const l=new Date(this.eventData.eventBaseData.startDate),r=new Date(this.eventData.eventBaseData.endDate);return 0===this.eventData.eventBaseData.status&&null!==this.eventData.eventBaseData.startDate&&l.getTime()<r.getTime()&&null!==this.eventData.eventBaseData.endDate&&null!==this.eventData.eventLocationData&&this.eventData.eventLocationData.idCodeListRegion>0&&(!!this.eventData.eventLocationData.address&&!!this.eventData.eventLocationData.postalCode&&!!this.eventData.eventLocationData.postalName||!!this.eventData?.eventBaseData?.urlVirtualLocation||8===Number(this.eventData.eventBaseData.idCodeListParentGenre))}publishEvent(){this._fifthStepService.publishEvent(this._eventsService.eventId$).pipe((0,z.Q)(this._unsubscribeAll)).subscribe({next:l=>{this._toastService.show(this._translocoService.translate("Toast.Message.event-published"),{type:"success",class:"success-toast"}),this._router.navigateByUrl("/delovni-zaslon/moji-dogodki")},error:l=>{this._toastService.show(this._errorsTranslationService.translate(l.error?.code??l.error),{type:"error",class:"danger-toast"})}})}_getEventData(){this._fifthStepService.getEventData(this._eventsService.eventId$).pipe((0,z.Q)(this._unsubscribeAll)).subscribe({next:l=>{this.eventData=l,this.isEditMode?this._setStepsFormsData():this.coverImageLink=this.eventData?.eventImageData?.find(r=>r.isCover)?.link,this.isDataLoaded=!0},error:l=>{this.eventData=void 0,this._toastService.show(this._errorsTranslationService.translate(l.error?.code??l.error),{type:"error",class:"danger-toast"})}})}goToLink(l){l&&-1===l.indexOf("http")&&(l=`//${l}`),window.open(l,"_blank")}navigateToEvent(l,r,m,u){u<0||this._eventsService.navigateToEventByUrl(l.split("Genre.")[1],r.split("Sub-genre.")[1],m,u)}_setStepsFormsData(){this._setFirstStepFormData(),this._setSecondStepFormData(),this._setThirdStepFormData(),this._setFourthStepFormData()}_setFirstStepFormData(){this._eventsService.firstStepForm={name:this.eventData?.eventBaseData?.name??"",nameEn:this.eventData?.eventBaseData?.nameEn??"",idCodeListGenre:this.eventData?.eventBaseData?.idCodeListParentGenre??-1,idCodeListSubGenre:this.eventData?.eventBaseData?.idCodeListGenre,specialSubGenre:this.eventData?.eventBaseData?.specialSubGenre,descriptionSl:this.eventData?.eventBaseData?.descriptionSl??"",descriptionEn:this.eventData?.eventBaseData?.descriptionEn??""}}_setSecondStepFormData(){const l={startDate:this._datePipe.transform(this.eventData?.eventBaseData?.startDate,"yyyy-MM-dd")??"",startTime:this._formatTime(this.eventData?.eventBaseData?.startDate),endDate:this._datePipe.transform(this.eventData?.eventBaseData?.endDate,"yyyy-MM-dd")??"",endTime:this._formatTime(this.eventData?.eventBaseData?.endDate),eventOpeningHours:this.eventData?.eventOpeningHourData,eventLocation:this.eventData?.eventLocationData?.idDataOrganizationLocation??void 0,locationName:this.eventData?.eventLocationData?.locationName??"",idCodeListRegion:this.eventData?.eventLocationData?.idCodeListRegion??"",address:this.eventData?.eventLocationData?.address??"",postalName:this.eventData?.eventLocationData?.postalName??"",postalCode:this.eventData?.eventLocationData?.postalCode??"",isPhysicalLocation:!!this.eventData?.eventLocationData?.address,isLiveStream:!!this.eventData?.eventBaseData.urlVirtualLocation,url:this.eventData?.eventBaseData?.urlVirtualLocation??""};
1this._eventsService.secondStepForm=l}_setThirdStepFormData(){const l=this.eventData?.eventImageData?.filter(u=>!u.isCover)?.map(u=>u.name),r=this.eventData?.eventImageData?.find(u=>u.isCover);this.coverImageLink=r?.link,this._eventsService.thirdStepForm={videoLink:this.eventData?.eventBaseData?.urlAnnouncementVideo??"",eventImages:l,coverImage:r?.name}}_setFourthStepFormData(){const l=this.eventData?.eventSponsorData?.map(u=>{const{idOrganizationSponsor:U,customRole:Q}=u;return{idDataOrganizationSponsor:U,customRole:Q}}),r=this.eventData?.eventBaseData?.idCodeListParentGenre??-1,m={ticketPrice:this.eventData?.eventBaseData?.ticketPrice,isFree:!(!0===this.eventData?.eventBaseData?.hasTicketPrice||8===r),priorRegistration:!!this.eventData?.eventBaseData?.priorRegistrationDate,priorRegistrationDate:this._datePipe.transform(this.eventData?.eventBaseData?.priorRegistrationDate,"yyyy-MM-dd")??"",priorRegistrationTime:this._formatTime(this.eventData?.eventBaseData?.priorRegistrationDate),socializing:this.eventData?.eventBaseData?.hasSocializing??!1,socializingDesc:this.eventData?.eventBaseData?.socializing,contactEmail:this.eventData?.eventBaseData?.contactEmail,contactNumber:this.eventData?.eventBaseData?.contactNumber,ticketUrl:this.eventData?.eventBaseData?.ticketUrl,externalLinks:this.eventData?.eventExternalLinkData,eventSponsors:l};this._eventsService.fourthStepForm=m}_formatTime(l){if(!l)return"";const r=new Date(l);if(isNaN(r.getTime()))return"";const[m,u,U]=[r.getHours(),r.getMinutes(),r.getSeconds()].map(Q=>Q.toString().padStart(2,"0"));return`${m}:${u}:${U}`}static{this.\u0275fac=function(r){return new(r||c)(e.rXU(t.H),e.rXU(n.f),e.rXU(i),e.rXU(T.vh),e.rXU(M.Ix),e.rXU(o.JO),e.rXU(R.k))}}static{this.\u0275cmp=e.VBU({type:c,selectors:[["event-step-5"]],inputs:{isEditMode:"isEditMode",isAdmin:"isAdmin"},standalone:!0,features:[e.Jv_([T.vh]),e.aNF],decls:14,vars:14,consts:[[1,"row","justify-content-center","pb-sm-2"],[1,"col-lg-11","col-xl-10"],[1,"text-center","pb-4"],[1,"h2"],[3,"step",4,"ngIf"],[1,"bg-light","rounded-3","pt-4","pb-0","px-4","p-md-5","mb-3",3,"ngClass"],["class","d-md-flex align-items-center justify-content-between mb-4 pb-md-2",4,"ngIf"],["class","card shadow-sm p-md-2 mx-n4 mx-md-0",4,"ngIf"],[4,"ngIf"],["class","d-flex flex-column flex-sm-row bg-light rounded-3 p-4 px-md-5",4,"ngIf"],[3,"step"],[1,"d-md-flex","align-items-center","justify-content-between","mb-4","pb-md-2"],[1,"h4","mb-md-0"],[1,"fi-eye-on","text-muted","fs-5","mt-n1","me-2","pe-1"],["aria-hidden","true",1,"btn","btn-outline-primary","ms-sm-auto",3,"click"],[1,"card","shadow-sm","p-md-2","mx-n4","mx-md-0"],[1,"card-body","p-4"],[1,"d-sm-flex","justify-content-between","align-items-start","pb-4"],[1,"order-sm-1"],[1,"h5"],[1,"list-unstyled","text-nav"],[1,"text-muted"],[1,"event-description",3,"innerHTML"],["href","javascript:void(0);",1,"d-inline-block","fw-bold","text-decoration-none","py-1",3,"click"],[1,"fi-edit","mt-n1","me-2"],[1,"border-top","py-4"],["class","row",4,"ngIf"],[1,"row"],[4,"ngFor","ngForOf"],[1,"border-top","pt-4"],["href","javascript:void(0);",1,"text-red"],[1,"col-xxl-3","col-md-3","col-sm-4","mb-3"],["alt","Event cover photo",1,"d-block","rounded-3","w-100","mx-auto",2,"max-width","12rem",3,"src"],["alt","Event photo",1,"d-block","rounded-3","w-100","mx-auto",2,"max-width","12rem",3,"src"],["href","javascript:void(0);",1,"text-red",3,"click","auxclick"],[1,"d-flex","flex-column","flex-sm-row","bg-light","rounded-3","p-4","px-md-5"],[1,"btn","btn-outline-primary","btn-lg","rounded-pill","mb-3","mb-sm-0",3,"click"],[1,"fi-chevron-left","fs-sm","me-2"],["type","button",1,"btn","btn-primary","btn-lg","rounded-pill","ms-sm-auto",3,"click"],["type","button",1,"btn","btn-primary","btn-lg","rounded-pill","ms-sm-auto"]],template:function(r,m){1&r&&(e.j41(0,"div",0)(1,"div",1)(2,"div",2)(3,"h1",3),e.EFF(4),e.nI1(5,"transloco"),e.nI1(6,"transloco"),e.k0s()(),e.DNE(7,Y,1,1,"event-steps",4),e.j41(8,"div",5),e.DNE(9,K,10,7,"div",6)(10,pe,199,164,"div",7)(11,me,1,0,"app-spinner",8),e.k0s(),e.DNE(12,f,8,6,"div",9)(13,I,3,1,"div",9),e.k0s()()),2&r&&(e.R7$(4),e.SpI(" ",m.isEditMode?e.bMT(5,8,"workscreen.Edit-event.edit-event"):e.bMT(6,10,"workscreen.Add-event.add-event")," "),e.R7$(3),e.Y8G("ngIf",!m.isEditMode),e.R7$(),e.Y8G("ngClass",e.eq3(12,k,!m.isDataLoaded)),e.R7$(),e.Y8G("ngIf",m.isDataLoaded),e.R7$(),e.Y8G("ngIf",m.isDataLoaded),e.R7$(),e.Y8G("ngIf",!m.isDataLoaded),e.R7$(),e.Y8G("ngIf",!m.isEditMode),e.R7$(),e.Y8G("ngIf",m.isEditMode))},dependencies:[T.MD,T.YU,T.Sq,T.bT,T.vh,o.Q8,o.Kj,d.h,y.q,B._L,N.t],styles:[".event-description p{margin-bottom:0}"]})}}return c})()},6508:(re,w,p)=>{p.d(w,{h:()=>$});var T=p(177),o=p(5176),d=p(4438);const B=()=>[1,2,3,4,5],b=i=>({active:i});function z(i,M){1&i&&(d.j41(0,"div"),d.EFF(1),d.nI1(2,"transloco"),d.k0s()),2&i&&(d.R7$(),d.SpI(" ",d.bMT(2,1,"workscreen.Add-event.Stepper.event-description")," "))}function O(i,M){1&i&&(d.j41(0,"div"),d.EFF(1),d.nI1(2,"transloco"),d.k0s()),2&i&&(d.R7$(),d.SpI(" ",d.bMT(2,1,"workscreen.Add-event.Stepper.date-location")," "))}function N(i,M){1&i&&(d.j41(0,"div"),d.EFF(1),d.nI1(2,"transloco"),d.k0s()),2&i&&(d.R7$(),d.SpI(" ",d.bMT(2,1,"workscreen.Add-event.Stepper.photo-video")," "))}function y(i,M){1&i&&(d.j41(0,"div"),d.EFF(1),d.nI1(2,"transloco"),d.k0s()),2&i&&(d.R7$(),d.SpI(" ",d.bMT(2,1,"workscreen.Add-event.Stepper.other-info")," "))}function e(i,M){1&i&&(d.j41(0,"div"),d.EFF(1),d.nI1(2,"transloco"),d.k0s()),2&i&&(d.R7$(),d.SpI(" ",d.bMT(2,1,"workscreen.Add-event.Stepper.review")," "))}function t(i,M){1&i&&d.nrm(0,"div")}function n(i,M){if(1&i&&(d.j41(0,"div",3)(1,"div",4),d.nrm(2,"span",5)(3,"span",6),d.j41(4,"span",7),d.EFF(5),d.k0s()(),d.j41(6,"div",8),d.qex(7,9),d.DNE(8,z,3,3,"div",10)(9,O,3,3,"div",10)(10,N,3,3,"div",10)(11,y,3,3,"div",10)(12,e,3,3,"div",10)(13,t,1,0,"div",11),d.bVm(),d.k0s()()),2&i){const R=M.$implicit,k=d.XpG();d.Y8G("ngClass",d.eq3(8,b,k.step>=R)),d.R7$(5),d.JRh(R),d.R7$(2),d.Y8G("ngSwitch",R),d.R7$(),d.Y8G("ngSwitchCase",1),d.R7$(),d.Y8G("ngSwitchCase",2),d.R7$(),d.Y8G("ngSwitchCase",3),d.R7$(),d.Y8G("ngSwitchCase",4),d.R7$(),d.Y8G("ngSwitchCase",5)}}let $=(()=>
1{class i{static{this.\u0275fac=function(k){return new(k||i)}}static{this.\u0275cmp=d.VBU({type:i,selectors:[["event-steps"]],inputs:{step:"step"},standalone:!0,features:[d.aNF],decls:3,vars:2,consts:[[1,"bg-light","rounded-3","py-4","px-md-4","mb-3"],[1,"steps","pt-4","pb-1"],["class","step",3,"ngClass",4,"ngFor","ngForOf"],[1,"step",3,"ngClass"],[1,"step-progress"],[1,"step-progress-start"],[1,"step-progress-end"],[1,"step-number"],[1,"step-label"],[3,"ngSwitch"],[4,"ngSwitchCase"],[4,"ngSwitchDefault"]],template:function(k,Y){1&k&&(d.j41(0,"div",0)(1,"div",1),d.DNE(2,n,14,10,"div",2),d.k0s()()),2&k&&(d.R7$(2),d.Y8G("ngForOf",d.lJ4(1,B)))},dependencies:[T.MD,T.YU,T.Sq,T.ux,T.e1,T.fG,o.Q8,o.Kj],changeDetection:0})}}return i})()},2844:(re,w,p)=>{p.d(w,{V:()=>T});const T={weekdays:{shorthand:["Ned","Pon","Tor","Sre","\u010cet","Pet","Sob"],longhand:["Nedelja","Ponedeljek","Torek","Sreda","\u010cetrtek","Petek","Sobota"]},months:{shorthand:["Jan","Feb","Mar","Apr","Maj","Jun","Jul","Avg","Sep","Okt","Nov","Dec"],longhand:["Januar","Februar","Marec","April","Maj","Junij","Julij","Avgust","September","Oktober","November","December"]},firstDayOfWeek:1,rangeSeparator:" do ",time_24hr:!0,ordinal:function(){return"."}}},4139:(re,w,p)=>{p.d(w,{X:()=>n});var T=p(2844),o=p(1413),d=p(6977),B=p(1022),b=p(4438),z=p(3318),O=p(177),N=p(9417),y=p(5176);const e=($,i)=>({"input-group-lg":$,"is-invalid":i}),t=($,i)=>({"me-5":$,"me-3":i});let n=(()=>{class ${constructor(M){this._languageService=M,this.locale="",this.maxDate="",this.minDate="",this.useInputGroupMD=!1,this.placeholder="Form.Placeholder.date",this._unsubscribeAll=new o.B,this._languageService.activeLanguage$.pipe((0,d.Q)(this._unsubscribeAll)).subscribe(R=>{this.locale="sl"===R?T.V:"en"})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}openFlatpickr(){this.flatpicker?.instance?.open()}static{this.\u0275fac=function(R){return new(R||$)(b.rXU(z.g))}}static{this.\u0275cmp=b.VBU({type:$,selectors:[["date-flatpicker"]],viewQuery:function(R,k){if(1&R&&b.GBs(B.kL,5),2&R){let Y;b.mGM(Y=b.lsd())&&(k.flatpicker=Y.first)}},inputs:{controlForm:"controlForm",isInvalid:"isInvalid",maxDate:"maxDate",minDate:"minDate",useInputGroupMD:"useInputGroupMD",placeholder:"placeholder"},decls:4,vars:17,consts:[[1,"input-group","flatpicker",3,"ngClass"],["type","text","id","date-picker","altFormat","d.m.Y","dateFormat","Y-m-d","mwlFlatpickr","",1,"form-control","rounded","pe-5","flatpickr-input",3,"placeholder","maxDate","minDate","locale","formControl","altInput","convertModelValue"],["aria-hidden","true",1,"fi-calendar","text-muted","position-absolute","top-50","end-0","translate-middle-y","cursor-pointer",3,"click","ngClass"]],template:function(R,k){1&R&&(b.j41(0,"div",0),b.nrm(1,"input",1),b.nI1(2,"transloco"),b.j41(3,"i",2),b.bIt("click",function(){return k.openFlatpickr()}),b.k0s()()),2&R&&(b.Y8G("ngClass",b.l_i(11,e,!k.useInputGroupMD,k.isInvalid)),b.R7$(),b.FS9("placeholder",b.bMT(2,9,k.placeholder)),b.Y8G("maxDate",k.maxDate)("minDate",k.minDate)("locale",k.locale)("formControl",k.controlForm)("altInput",!0)("convertModelValue",!1),b.R7$(2),b.Y8G("ngClass",b.l_i(14,t,k.isInvalid,!k.isInvalid)))},dependencies:[O.YU,N.me,N.BC,N.l_,B.kL,y.Kj],styles:[".flatpicker.is-invalid .form-control{border-color:var(--fi-form-invalid-border-color);padding-right:calc(1.5em + 1.15rem);background-repeat:no-repeat;background-position:right calc(.375em + .2875rem) center;background-size:calc(.75em + .575rem) calc(.75em + .575rem);background-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='%23f23c49' fill-rule='evenodd'%3e%3cpath d='M9 3a6 6 0 1 0 0 12A6 6 0 1 0 9 3zM1.5 9a7.5 7.5 0 1 1 15 0 7.5 7.5 0 1 1-15 0zM9 5.25a.75.75 0 0 1 .75.75v3a.75.75 0 1 1-1.5 0V6A.75.75 0 0 1 9 5.25zM8.25 12a.75.75 0 0 1 .75-.75h.008a.75.75 0 1 1 0 1.5H9a.75.75 0 0 1-.75-.75z'/%3e%3c/svg%3e\")}"]})}}return $})()},7172:(re,w,p)=>{p.d(w,{g:()=>n});var T=p(2844),o=p(1413),d=p(6977),B=p(1022),b=p(4438),z=p(3318),O=p(177),N=p(9417),y=p(5176);const e=$=>({"is-invalid":$}),t=($,i)=>({"me-5":$,"me-3":i});let n=(()=>{class ${constructor(M){this._languageService=M,this.locale="",this._unsubscribeAll=new o.B,this._languageService.activeLanguage$.pipe((0,d.Q)(this._unsubscribeAll)).subscribe(R=>{this.locale="sl"===R?T.V:"en"})}ngOnDestroy(){this._unsubscribeAll.next(null),this._unsubscribeAll.complete()}openFlatpickr(){this.flatpicker?.instance?.open()}static{this.\u0275fac=function(R){return new(R||$)(b.rXU(z.g))}}static{this.\u0275cmp=b.VBU({type:$,selectors:[["time-flatpicker"]],viewQuery:function(R,k){if(1&R&&b.GBs(B.kL,5),2&R){let Y;b.mGM(Y=b.lsd())&&(k.flatpicker=Y.first)}},inputs:{controlForm:"controlForm",isInvalid:"isInvalid",isRequired:"isRequired",isReadOnly:"isReadOnly"},decls:4,vars:21,consts:[[1,"input-group","input-group-lg","flatpicker",3,"ngClass"],["type","text","id","date-picker","mwlFlatpickr","","altFormat","H:i",1,"form-control","rounded","pe-5","flatpickr-input",3,"placeholder","locale","formControl","dateFormat","required","readOnly","clickOpens","altInput","time24hr","noCalendar","enableTime","convertModelValue"],["aria-hidden","true",1,"fi-clock","text-muted","position-absolute","top-50","end-0","translate-middle-y","cursor-pointer",3,"click","ngClass"]],template:function(R,k){1&R&&(b.j41(0,"div",0),b.nrm(1,"input",1),b.nI1(2,"transloco"),b.j41(3,"i",2),b.bIt("click",function(){return k.openFlatpickr()}),b.k0s()()),2&R&&(b.Y8G("ngClass",b.eq3(16,e,k.isInvalid)),b.R7$(),b.FS9("placeholder",b.bMT(2,14,"Form.Placeholder.time")),b.Y8G("locale",k.locale)("formControl",k.controlForm)("dateFormat","H:i:ss")("required",k.isRequired)("readOnly",k.isReadOnly)("clickOpens",k.isReadOnly)("altInput",!0)("time24hr",!0)("noCalendar",!0)("enableTime",!0)("convertModelValue",!1),b.R7$(2),b.Y8G("ngClass",b.l_i(18,t,k.isInvalid,!k.isInvalid)))},dependencies:[O.YU,N.me,N.BC,N.YS,N.l_,B.kL,y.Kj],styles:[".flatpicker.is-invalid .form-control{border-color:var(--fi-form-invalid-border-color);padding-right:calc(1.5em + 1.15rem);background-repeat:no-repeat;background-position:right calc(.375em + .2875rem) center;background-size:calc(.75em + .575rem) calc(.75em + .575rem);background-image:url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='%23f23c49' fill-rule='evenodd'%3e%3cpath d='M9 3a6 6 0 1 0 0 12A6 6 0 1 0 9 3zM1.5 9a7.5 7.5 0 1 1 15 0 7.5 7.5 0 1 1-15 0zM9 5.25a.75.75 0 0 1 .75.75v3a.75.75 0 1 1-1.5 0V6A.75.75 0 0 1 9 5.25zM8.25 12a.75.75 0 0 1 .75-.75h.008a.75.75 0 1 1 0 1.5H9a.75.75 0 0 1-.75-.75z'/%3e%3c/svg%3e\")}"]})}}return $})()}}]);

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.