芝麻web文件管理V1.00
编辑当前文件:/home/pulsehostuk9/www/cloud.pulsehost.co.uk/adminpanel/js/2447.767572f5.js
"use strict";(globalThis["webpackChunkadmin_panel_vue_webclient"]=globalThis["webpackChunkadmin_panel_vue_webclient"]||[]).push([[2447],{2447:(i,t,o)=>{o.r(t),o.d(t,{default:()=>ti});var e=o(9835),n=o(6970);const s={class:"q-pa-lg"},a={class:"row q-mb-md"},c={class:"col text-h5"},l={class:"row"},u={class:"col-2 q-mt-sm"},r={class:"col-5"},d={class:"row q-my-md"},S={class:""},T={class:"row q-mt-sm"},f={class:"col-2 q-mt-sm"},h={class:"col-5"},m={class:"row q-mt-md"},E={class:"col-2 q-mt-sm"},A={class:"col-5"},p={class:"row q-my-md"},_={key:0,class:"row q-mt-sm"},P={class:"col-2 q-mt-sm"},N={class:"col-5"},R={key:1,class:"row q-mt-md"},L={class:"col-2 q-mt-sm"},I={class:"col-1"},v={class:"col-2 q-ml-sm"},w={key:2,class:"row q-mt-md"},O={class:"col-2 q-mt-sm"},D={class:"col-2"},g={class:"col-2 q-ml-sm"},C={class:"q-pt-md text-right"};function y(i,t,o,y,M,W){const b=(0,e.up)("q-input"),U=(0,e.up)("q-item-label"),q=(0,e.up)("q-select"),V=(0,e.up)("q-checkbox"),k=(0,e.up)("q-card-section"),Z=(0,e.up)("q-card"),B=(0,e.up)("q-btn"),$=(0,e.up)("q-linear-progress"),F=(0,e.up)("q-inner-loading"),H=(0,e.up)("q-scroll-area"),Q=(0,e.Q2)("t");return(0,e.wg)(),(0,e.j4)(H,{class:"full-height full-width"},{default:(0,e.w5)((()=>[(0,e._)("div",s,[(0,e._)("div",a,[(0,e._)("div",c,(0,n.zw)(i.$t("STANDARDRESETPASSWORD.HEADING_SETTINGS_TAB")),1)]),(0,e.Wm)(Z,{flat:"",bordered:"",class:"card-edit-settings"},{default:(0,e.w5)((()=>[(0,e.Wm)(k,null,{default:(0,e.w5)((()=>[(0,e._)("div",l,[(0,e._)("div",u,(0,n.zw)(i.$t("STANDARDRESETPASSWORD.LABEL_RECOVERY_LINK_LIFETIME_MINUTES")),1),(0,e._)("div",r,[(0,e.Wm)(b,{outlined:"",dense:"","bg-color":"white",modelValue:M.recoveryLinkLifetimeMinutes,"onUpdate:modelValue":t[0]||(t[0]=i=>M.recoveryLinkLifetimeMinutes=i)},null,8,["modelValue"])])]),(0,e._)("div",d,[(0,e.Wm)(U,{caption:""},{default:(0,e.w5)((()=>[(0,e.wy)((0,e._)("span",S,null,512),[[Q,"STANDARDRESETPASSWORD.HINT_RECOVERY_LINK_LIFETIME"]])])),_:1})]),(0,e._)("div",T,[(0,e._)("div",f,(0,n.zw)(i.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_EMAIL")),1),(0,e._)("div",h,[(0,e.Wm)(b,{outlined:"",dense:"","bg-color":"white",modelValue:M.notificationEmail,"onUpdate:modelValue":t[1]||(t[1]=i=>M.notificationEmail=i)},null,8,["modelValue"])])]),(0,e._)("div",m,[(0,e._)("div",E,(0,n.zw)(i.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_TYPE")),1),(0,e._)("div",A,[(0,e.Wm)(q,{flat:"",outlined:"",dense:"","bg-color":"white",modelValue:M.notificationType,"onUpdate:modelValue":t[2]||(t[2]=i=>M.notificationType=i),options:M.notificationTypes},null,8,["modelValue","options"])])]),(0,e._)("div",p,[(0,e.Wm)(U,{caption:""},{default:(0,e.w5)((()=>[(0,e._)("span",null,(0,n.zw)(M.inscription),1)])),_:1})]),"smtp"===M.notificationType.value?((0,e.wg)(),(0,e.iD)("div",_,[(0,e._)("div",P,(0,n.zw)(i.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_HOST")),1),(0,e._)("div",N,[(0,e.Wm)(b,{outlined:"",dense:"","bg-color":"white",modelValue:M.notificationHost,"onUpdate:modelValue":t[3]||(t[3]=i=>M.notificationHost=i)},null,8,["modelValue"])])])):(0,e.kq)("",!0),"smtp"===M.notificationType.value?((0,e.wg)(),(0,e.iD)("div",R,[(0,e.wy)((0,e._)("div",L,null,512),[[Q,"STANDARDRESETPASSWORD.LABEL_NOTIFICATION_PORT"]]),(0,e._)("div",I,[(0,e.Wm)(b,{outlined:"",dense:"","bg-color":"white",modelValue:M.notificationPort,"onUpdate:modelValue":t[4]||(t[4]=i=>M.notificationPort=i)},null,8,["modelValue"])]),(0,e._)("div",v,[(0,e.Wm)(q,{outlined:"",dense:"","bg-color":"white",modelValue:M.notificationSMTPSecure,"onUpdate:modelValue":t[5]||(t[5]=i=>M.notificationSMTPSecure=i),"emit-value":"","map-options":"",options:M.SMTPSecureOptions},null,8,["modelValue","options"])])])):(0,e.kq)("",!0),"smtp"===M.notificationType.value?((0,e.wg)(),(0,e.iD)("div",w,[(0,e._)("div",O,[(0,e.Wm)(V,{dense:"",modelValue:M.notificationUseAuth,"onUpdate:modelValue":t[6]||(t[6]=i=>M.notificationUseAuth=i)},{default:(0,e.w5)((()=>[(0,e.Wm)(U,null,{default:(0,e.w5)((()=>[(0,e.Uk)((0,n.zw)(i.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_USE_AUTH")),1)])),_:1})])),_:1},8,["modelValue"])]),(0,e._)("div",D,[(0,e.Wm)(b,{outlined:"",dense:"","bg-color":"white",placeholder:i.$t("COREWEBCLIENT.LABEL_LOGIN"),disable:!M.notificationUseAuth,modelValue:M.notificationLogin,"onUpdate:modelValue":t[7]||(t[7]=i=>M.notificationLogin=i)},null,8,["placeholder","disable","modelValue"])]),(0,e._)("div",g,[(0,e.Wm)(b,{outlined:"",dense:"","bg-color":"white",placeholder:i.$t("COREWEBCLIENT.LABEL_PASSWORD"),type:"password",autocomplete:"new-password",disable:!M.notificationUseAuth,modelValue:M.notificationPassword,"onUpdate:modelValue":t[8]||(t[8]=i=>M.notificationPassword=i)},null,8,["placeholder","disable","modelValue"])])])):(0,e.kq)("",!0)])),_:1})])),_:1}),(0,e._)("div",C,[(0,e.Wm)(B,{unelevated:"","no-caps":"",dense:"",class:"q-px-sm",ripple:!1,color:"primary",label:i.$t("COREWEBCLIENT.ACTION_SAVE"),onClick:W.save},null,8,["label","onClick"])])]),(0,e.Wm)(F,{style:{"justify-content":"flex-start"},showing:M.saving},{default:(0,e.w5)((()=>[(0,e.Wm)($,{query:""})])),_:1},8,["showing"])])),_:1})}var M=o(9336),W=o(1427),b=o(2456),U=o(9985),q=o(2934);const V=" ",k={noSecure:"25",ssl:"465",tls:"587"},Z={name:"PasswordResetSettings",data(){return{saving:!1,notificationTypes:[],notificationType:{},inscription:"",recoveryLinkLifetimeMinutes:0,notificationEmail:"",notificationPort:0,notificationHost:"",SMTPSecureEnum:U.Z.SMTPSecure,SMTPSecureOptions:[{label:this.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_SMTP_NO_SECURE"),value:U.Z.SMTPSecure.noSecure},{label:this.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_SMTP_SSL_SECURE"),value:U.Z.SMTPSecure.ssl},{label:this.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_SMTP_TLS_SECURE"),value:U.Z.SMTPSecure.tls}],notificationSMTPSecure:U.Z.SMTPSecure.noSecure,notificationUseAuth:!1,notificationLogin:"",notificationPassword:V,savedPass:V,hasNotificationPassword:!1}},beforeRouteLeave(i,t,o){this.$root.doBeforeRouteLeave(i,t,o)},mounted(){this.populate()},watch:{"notificationType.value":function(){this.setInscription()},notificationSMTPSecure(i,t){const o=k[Object.keys(this.SMTPSecureEnum).find((i=>this.SMTPSecureEnum[i]===t))],e=k[Object.keys(this.SMTPSecureEnum).find((t=>this.SMTPSecureEnum[t]===i))];this.notificationPort==o&&e&&(this.notificationPort=e)}},methods:{hasChanges(){const i=q.Z.getStandardResetPasswordSettings();return this.recoveryLinkLifetimeMinutes!==i.recoveryLinkLifetimeMinutes||this.notificationEmail!==i.notificationEmail||this.notificationPort!==i.notificationPort||this.notificationHost!==i.notificationHost||this.notificationSMTPSecure!==i.notificationSMTPSecure||this.notificationUseAuth!==i.notificationUseAuth||this.notificationLogin!==i.notificationLogin||this.hasNotificationPassword!==i.hasNotificationPassword||this.notificationType.value!==i.notificationType},revertChanges(){this.populate()},populate(){const i=q.Z.getStandardResetPasswordSettings();this.recoveryLinkLifetimeMinutes=i.recoveryLinkLifetimeMinutes,this.notificationEmail=i.notificationEmail,this.notificationPort=i.notificationPort,this.notificationHost=i.notificationHost,this.notificationSMTPSecure=i.notificationSMTPSecure,this.notificationUseAuth=i.notificationUseAuth,this.notificationLogin=i.notificationLogin,this.hasNotificationPassword=i.hasNotificationPassword;const t=i.notificationType;this.notificationTypes=[{value:"mail",label:this.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_TYPE_MAIL")},{value:"smtp",label:this.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_TYPE_SMTP")},{value:"account",label:this.$t("STANDARDRESETPASSWORD.LABEL_NOTIFICATION_TYPE_ACCOUNT")}],this.notificationType=this.notificationTypes.find((i=>i.value===t)),this.setInscription()},save(){if(!this.saving){this.saving=!0;const i={NotificationEmail:this.notificationEmail,NotificationType:this.notificationType.value,RecoveryLinkLifetimeMinutes:this.recoveryLinkLifetimeMinutes};"smtp"===this.notificationType.value&&(i.NotificationHost=this.notificationHost,i.NotificationPort=this.notificationPort,i.NotificationSMTPSecure=this.notificationSMTPSecure,i.NotificationUseAuth=this.notificationUseAuth,this.notificationUseAuth?(i.NotificationLogin=this.notificationLogin,this.notificationPassword!==V&&(i.NotificationPassword=this.notificationPassword)):i.NotificationUseAuth=this.notificationUseAuth),b.Z.sendRequest({moduleName:"StandardResetPassword",methodName:"UpdateAdminSettings",parameters:i}).then((i=>{this.saving=!1,i?(q.Z.saveStandardResetPasswordSettings({notificationHost:this.notificationHost,notificationPort:this.notificationPort,notificationSMTPSecure:this.notificationSMTPSecure,notificationUseAuth:this.notificationUseAuth,notificationLogin:this.notificationLogin,hasNotificationPassword:""!==this.notificationPassword&&this.notificationUseAuth,notificationEmail:this.notificationEmail,notificationType:this.notificationType.value,recoveryLinkLifetimeMinutes:this.recoveryLinkLifetimeMinutes}),this.savedPass=this.notificationPassword,W.Z.showReport(this.$t("COREWEBCLIENT.REPORT_SETTINGS_UPDATE_SUCCESS")),this.populate()):W.Z.showError(this.$t("COREWEBCLIENT.ERROR_SAVING_SETTINGS_FAILED"))}),(i=>{this.saving=!1,W.Z.showError(M.Z.getTextFromResponse(i,this.$t("COREWEBCLIENT.ERROR_SAVING_SETTINGS_FAILED")))}))}},setInscription(){switch(this.notificationType?.value){case"smtp":this.inscription=this.$t("STANDARDRESETPASSWORD.HINT_NOTIFICATION_TYPE_SMTP");break;case"mail":this.inscription=this.$t("STANDARDRESETPASSWORD.HINT_NOTIFICATION_TYPE_MAIL");break;case"account":this.inscription=this.$t("STANDARDRESETPASSWORD.HINT_NOTIFICATION_TYPE_ACCOUNT");break}}}};var B=o(1639),$=o(6663),F=o(4458),H=o(3190),Q=o(6611),Y=o(3115),G=o(8401),x=o(6937),z=o(8879),j=o(854),K=o(8289),J=o(9984),X=o.n(J);const ii=(0,B.Z)(Z,[["render",y]]),ti=ii;X()(Z,"components",{QScrollArea:$.Z,QCard:F.Z,QCardSection:H.Z,QInput:Q.Z,QItemLabel:Y.Z,QSelect:G.Z,QCheckbox:x.Z,QBtn:z.Z,QInnerLoading:j.Z,QLinearProgress:K.Z})}}]);