(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-3de4f040"],{
/***/"161d":
/***/function(e,t,s){"use strict";
/* harmony import */s("86f5");
/* harmony import */},
/***/"86f5":
/***/function(e,t,s){
// extracted by mini-css-extract-plugin
/***/},
/***/d0e7:
/***/function(e,t,s){"use strict";
// ESM COMPAT FLAG
s.r(t);
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"411544a2-vue-loader-template"}!./node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/pages/Setting/SystemAuth.vue?vue&type=template&id=5e1fc8d3&scoped=true
var a=s("5530"),o=(s("b0c0"),s("1d40")),r=s("2f62"),i=s("7424"),n=(s("3dd1"),s("2345"),{name:"SystemParams",i18n:s("89fe"),data:function(){return{currentVersionDes:"",RemoteVersionDes:"",remoteVersion:"",localUpgradeUrl:i.AUTHUPLOAD,remoteDate:"",remoteVersionLog:"",remoteIsBete:!1,messageShowLoad:!1}},components:{},created:function(){this.currentVersionDes=this.$t("SystemUpgrade.Version")+":"+this.systemVersion+"  ("+(this.versionBete?this.$t("SystemUpgrade.BeteVersion"):this.$t("SystemUpgrade.RCVersion"))+")    "+this.$t("SystemUpgrade.VersionDate")+":"+this.versionDate+"    (x64)",this.OnlineUpgrade()},computed:Object(a.a)(Object(a.a)({},Object(r.e)("setting",["isMobile","theme","layout","footerLinks","systemName","copyright","fixedHeader","fixedSideBar","fixedTabs","versionDate","versionBete","systemVersion"])),{},{systemLogo:function(){return this.$store.state.setting.SystemLogo},IsLicense:function(){return this.$store.state.setting.IsOEM}}),methods:{beforeUpload:function(){this.$message.loading({content:this.$t("dataModel.opcuaModel.ImportNodeIDLoading"),duration:0})},BeginUpgrade:function(){var e=this;this.$confirm({title:this.$t("SystemUpgrade.UpgradeConfirm"),content:this.$t("SystemUpgrade.UpgradeContent"),okText:this.$t("SystemUpgrade.ConfirmUpgrade"),cancelText:this.$t("SystemUpgrade.ConfirmCancel"),onOk:function(){e.$message.loading(e.$t("SystemUpgrade.BeginUpgradeLoading"),0),Object(o.a)().then((function(t){e.$message.destroy(),0==t.data.code?(e.remoteVersion=t.data.Result.currentVersion,e.remoteIsBete=t.data.Result.IsBete,e.remoteDate=t.data.Result.versionData,e.remoteVersionLog=t.data.Result.currentVersionDescribeCH,e.RemoteVersionDes=e.$t("SystemUpgrade.RemoteVersion")+":"+e.remoteVersion+"  ("+(e.remoteIsBete?e.$t("SystemUpgrade.BeteVersion"):e.$t("SystemUpgrade.RCVersion"))+")    "+e.$t("SystemUpgrade.VersionDate")+":"+e.remoteDate+"    (x64)"):4006==t.data.code?e.$message.error(e.$t("SystemUpgrade.OnlineCheckNoAuth")):e.$message.error(e.$t("SystemUpgrade.OnlineCheckError")),setTimeout((function(){e.$message.destroy()}),5e3),e.messageShowLoad=!1})).catch((function(t){e.messageShowLoad=!1,e.$message.success(e.$t("SystemUpgrade.BeginUpgradeLoading")),setTimeout((function(){location.reload()}),1e4)}))}})},OnlineUpgrade:function(){var e=this,t={DebugEnable:this.DebugEnable};this.messageShowLoad=!0,Object(o.s)(t).then((function(t){0==t.data.code?(e.remoteVersion=t.data.Result.currentVersion,e.remoteIsBete=t.data.Result.IsBete,e.remoteDate=t.data.Result.versionData,e.remoteVersionLog=t.data.Result.currentVersionDescribeCH):e.$message.error(e.$t("SystemUpgrade.OnlineCheckError")),e.messageShowLoad=!1})).catch((function(t){e.messageShowLoad=!1,e.$message.error(e.$t("loginPage.serverError"),3)}))},localUpgradeCharge:function(e){this.dataSource=[];if(this.messageShowLoad=!0,"done"===e.file.status){var t=e.file.response;this.$message.destroy(),0==t.Code?(this.$message.success("".concat(e.file.name," ")+this.$t("SystemUpgrade.AuthUploadLoading")),this.$store.state.setting.IsOEM=t.Oem,
// 刷新页面
window.location.reload()):-2==t.Code?this.$message.error("".concat(e.file.name," ")+this.$t("SystemUpgrade.UpgradeFileError")):this.$message.error("".concat(e.file.name," ")+this.$t("SystemUpgrade.UpgradeFileSaveError"))}else if("uploading"===e.file.status);else if("error"===e.file.status){this.$message.loading(this.$t("SystemUpgrade.BeginUpgradeLoading"),0),setTimeout((function(){location.reload()}),1e4)}this.messageShowLoad=!1}}}),d=(s("161d"),s("2877")),m=Object(d.a)(n,(function(){var e=this,t=e._self._c;return t("a-card",{attrs:{title:e.$t("SystemUpgrade.about"),headStyle:{"font-size":"20px","font-weight":600}}},[t("a-list",{attrs:{"item-layout":"horizontal"}},[t("a-list-item",[t("a-list-item-meta",{attrs:{description:e.currentVersionDes}},[t("a",{attrs:{slot:"title"},slot:"title"},[e._v(e._s(e.systemName))]),t("a-avatar",{attrs:{slot:"avatar",src:e.systemLogo},slot:"avatar"})],1)],1)],1),t("a-spin",{attrs:{spinning:e.messageShowLoad}},[t("a-card",[e.remoteVersion!=e.systemVersion?t("div",{staticStyle:{"white-space":"pre-wrap"}},[e._v(" "+e._s(e.remoteVersionLog)+" ")]):e._e(),t("p",{staticStyle:{"margin-top":"20px"}},[t("a-upload",{attrs:{name:"file",multiple:!1,action:e.localUpgradeUrl,showUploadList:!1,beforeUpload:e.beforeUpload},on:{change:e.localUpgradeCharge}},[t("a-button",{attrs:{type:"default"}},[t("a-icon",{attrs:{type:"upload"}}),e._v(" "+e._s(e.$t("SystemUpgrade.AuthUpload"))+" ")],1)],1)],1)])],1)],1)}),[],!1,null,"5e1fc8d3",null)
/* harmony default export */;t.default=m.exports}}]);