/home/ivoiecob/email.hirewise-va.com/adminpanel/js/7858.5367f406.js
"use strict";(globalThis["webpackChunkadmin_panel_vue_webclient"]=globalThis["webpackChunkadmin_panel_vue_webclient"]||[]).push([[7858],{57858:(e,s,t)=>{t.r(s),t.d(s,{default:()=>j});var l=t(61758),n=t(58790);const i={class:"q-pa-lg"},a={class:"row q-mb-md"},o={class:"col text-h5"},r={class:"row q-mb-sm"},E={class:"col-2"},L={class:"col-5 text-weight-medium"},c={class:"row q-mb-md"},u={class:"col-2"},d={class:"col-5 text-weight-medium"},T={class:"row q-mb-md"},N={class:"col-2"},I={class:"col-5 text-weight-medium"},h={class:"row q-mb-md"},A={class:"col-2"},_={class:"col-5 text-weight-medium"},S={class:"row q-my-md"},v={class:"col-2 q-my-sm"},C={class:"col-5"},m={class:"row"},b={class:"row q-my-md"},k={class:"col-2 q-my-sm"},R={class:"col-5"},p={class:"row"},g={class:"row q-my-md"},U={class:"row"},w={class:"q-pt-md text-right"};function F(e,s,t,F,V,B){const M=(0,l.g2)("q-input"),q=(0,l.g2)("q-item-label"),O=(0,l.g2)("q-checkbox"),G=(0,l.g2)("q-card-section"),y=(0,l.g2)("q-card"),P=(0,l.g2)("q-btn"),f=(0,l.g2)("q-linear-progress"),$=(0,l.g2)("q-inner-loading"),W=(0,l.g2)("q-scroll-area"),x=(0,l.gN)("t");return(0,l.uX)(),(0,l.Wv)(W,{class:"full-height full-width"},{default:(0,l.k6)((()=>[(0,l.Lk)("div",i,[(0,l.Lk)("div",a,[(0,l.Lk)("div",o,(0,n.v_)(e.$t("ACTIVESERVER.HEADING_SETTINGS_TAB")),1)]),(0,l.bF)(y,{flat:"",bordered:"",class:"card-edit-settings"},{default:(0,l.k6)((()=>[(0,l.bF)(G,null,{default:(0,l.k6)((()=>[(0,l.Lk)("div",r,[(0,l.bo)((0,l.Lk)("div",E,null,512),[[x,"ACTIVESERVER.LABEL_LICENSING_MAX_NUMBER_OF_USERS"]]),(0,l.Lk)("div",L,[(0,l.Lk)("span",null,(0,n.v_)(V.licensedUsersCount),1)])]),(0,l.Lk)("div",c,[(0,l.bo)((0,l.Lk)("div",u,null,512),[[x,"ACTIVESERVER.LABEL_LICENSING_USERS_ALLOCATED"]]),(0,l.Lk)("div",d,[(0,l.Lk)("span",null,(0,n.v_)(V.usersCount),1)])]),(0,l.Lk)("div",T,[(0,l.bo)((0,l.Lk)("div",N,null,512),[[x,"ACTIVESERVER.LABEL_LICENSING_FREE_SLOTS"]]),(0,l.Lk)("div",I,[(0,l.Lk)("span",null,(0,n.v_)(V.usersFreeSlots),1)])]),(0,l.Lk)("div",h,[(0,l.bo)((0,l.Lk)("div",A,null,512),[[x,"ACTIVESERVER.LABEL_LICENSING_TYPE"]]),(0,l.Lk)("div",_,[(0,l.Lk)("span",null,(0,n.v_)(V.licenceType),1)])]),(0,l.Lk)("div",S,[(0,l.bo)((0,l.Lk)("div",v,null,512),[[x,"ACTIVESERVER.LABEL_SERVER_HOST"]]),(0,l.Lk)("div",C,[(0,l.bF)(M,{outlined:"",dense:"","bg-color":"white",modelValue:V.server,"onUpdate:modelValue":s[0]||(s[0]=e=>V.server=e)},null,8,["modelValue"])])]),(0,l.Lk)("div",m,[(0,l.Lk)("div",null,[(0,l.bF)(q,{caption:"",innerHTML:e.$t("ACTIVESERVER.HINT_SERVER_HOST")},null,8,["innerHTML"])])]),(0,l.Lk)("div",b,[(0,l.bo)((0,l.Lk)("div",k,null,512),[[x,"ACTIVESERVER.LABEL_LINK"]]),(0,l.Lk)("div",R,[(0,l.bF)(M,{outlined:"",dense:"","bg-color":"white",modelValue:V.linkToManual,"onUpdate:modelValue":s[1]||(s[1]=e=>V.linkToManual=e)},null,8,["modelValue"])])]),(0,l.Lk)("div",p,[(0,l.Lk)("div",null,[(0,l.bF)(q,{caption:"",innerHTML:e.$t("ACTIVESERVER.HINT_LINK_TO_MANUAL")},null,8,["innerHTML"])])]),(0,l.Lk)("div",g,[(0,l.bF)(O,{dense:"",modelValue:V.enableForNewUsers,"onUpdate:modelValue":s[2]||(s[2]=e=>V.enableForNewUsers=e)},{default:(0,l.k6)((()=>[(0,l.bF)(q,null,{default:(0,l.k6)((()=>[(0,l.eW)((0,n.v_)(e.$t("ACTIVESERVER.ENABLE_FOR_NEW_USERS")),1)])),_:1})])),_:1},8,["modelValue"])]),(0,l.Lk)("div",U,[(0,l.Lk)("div",null,[(0,l.bF)(q,{caption:"",innerHTML:e.$t("ACTIVESERVER.HINT_FOR_NEW_USERS")},null,8,["innerHTML"])])])])),_:1})])),_:1}),(0,l.Lk)("div",w,[(0,l.bF)(P,{unelevated:"","no-caps":"",dense:"",class:"q-px-sm",ripple:!1,color:"primary",onClick:B.save,label:e.$t("COREWEBCLIENT.ACTION_SAVE")},null,8,["onClick","label"])])]),(0,l.bF)($,{style:{"justify-content":"flex-start"},showing:V.saving},{default:(0,l.k6)((()=>[(0,l.bF)(f,{query:""})])),_:1},8,["showing"])])),_:1})}var V=t(36720),B=t(38176),M=t(79134),q=t(34093);const O={name:"ActiveSyncAdminSettings",data(){return{saving:!1,enableModule:!1,enableModuleForUser:!1,enableForNewUsers:!1,usersCount:0,licensedUsersCount:0,usersFreeSlots:0,server:"",linkToManual:"",productName:"",licenceType:""}},mounted(){this.populate(),this.getLicenseInfo(),this.getSettings()},beforeRouteLeave(e,s,t){this.$root.doBeforeRouteLeave(e,s,t)},methods:{hasChanges(){const e=q.A.getActiveServerSettings();return this.enableForNewUsers!==e.enableForNewUsers||this.server!==e.server||this.linkToManual!==e.linkToManual},revertChanges(){this.populate()},save(){if(!this.saving){this.saving=!0;const e={EnableModule:!0,EnableForNewUsers:this.enableForNewUsers,Server:this.server,LinkToManual:this.linkToManual};M.A.sendRequest({moduleName:"ActiveServer",methodName:"UpdateSettings",parameters:e}).then((e=>{this.saving=!1,!0===e?(q.A.saveActiveServerSettings({server:this.server,enableForNewUsers:this.enableForNewUsers,enableModule:this.enableModule,linkToManual:this.linkToManual}),this.populate(),this.getSettings(),B.A.showReport(this.$t("COREWEBCLIENT.REPORT_SETTINGS_UPDATE_SUCCESS"))):B.A.showError(this.$t("COREWEBCLIENT.ERROR_SAVING_SETTINGS_FAILED"))}),(e=>{this.saving=!1,B.A.showError(V.A.getTextFromResponse(e,this.$t("COREWEBCLIENT.ERROR_SAVING_SETTINGS_FAILED")))}))}},getLicenseInfo(){M.A.sendRequest({moduleName:"ActiveServer",methodName:"GetLicenseInfo"}).then((e=>{if(this.licenceType=this.$t("LICENSINGWEBCLIENT.LABEL_TYPE_INVALID"),e)switch(e.Type){case 0:this.licenceType=this.$t("LICENSINGWEBCLIENT.LABEL_TYPE_UNLIM");break;case 1:this.licenceType=this.$tc("LICENSINGWEBCLIENT.LABEL_TYPE_PERMANENT_PLURAL",e.Count,{COUNT:e.Count});break;case 2:this.licenceType=this.$tc("LICENSINGWEBCLIENT.LABEL_TYPE_DOMAINS_PLURAL",e.Count,{COUNT:e.Count});break;case 4:e.ExpiresIn<1&&(this.licenceType=this.$t("LICENSINGWEBCLIENT.LABEL_TYPE_OUTDATED_INFO"));break;case 3:case 10:this.licenceType=3===e.Type?this.$tc("LICENSINGWEBCLIENT.LABEL_TYPE_ANNUAL_PLURAL",e.Count,{COUNT:e.Count}):this.$t("LICENSINGWEBCLIENT.LABEL_TYPE_TRIAL"),"*"!==e.ExpiresIn&&(e.ExpiresIn>0?this.licenceType+=this.$tc("LICENSINGWEBCLIENT.LABEL_TYPE_EXPIRES_IN_PLURAL",e.ExpiresIn,{DAYS:e.ExpiresIn}):this.licenceType+=this.$t("LICENSINGWEBCLIENT.LABEL_TYPE_EXPIRED")+" "+this.$t("LICENSINGWEBCLIENT.LABEL_TYPE_OUTDATED_INFO"));break}}))},getSettings(){M.A.sendRequest({moduleName:"ActiveServer",methodName:"GetSettings"}).then((e=>{this.usersCount=e.UsersCount,this.licensedUsersCount=e.LicensedUsersCount,this.usersFreeSlots=e.UsersFreeSlots}))},populate(){const e=q.A.getActiveServerSettings();this.enableModule=e.enableModule,this.enableModuleForUser=e.enableModuleForUser,this.enableForNewUsers=e.enableForNewUsers,this.server=e.server,this.linkToManual=e.linkToManual,this.productName=e.productName}}};var G=t(12807),y=t(48958),P=t(23316),f=t(44189),$=t(39270),W=t(13796),x=t(37022),D=t(56384),H=t(39035),Y=t(35859),Q=t(98582),X=t.n(Q);const K=(0,G.A)(O,[["render",F]]),j=K;X()(O,"components",{QScrollArea:y.A,QCard:P.A,QCardSection:f.A,QInput:$.A,QItemLabel:W.A,QCheckbox:x.A,QBtn:D.A,QInnerLoading:H.A,QLinearProgress:Y.A})}}]);