Commit 81dbd4b3 by 无尘

fix: 更新loading

parent 2920538c
......@@ -4,10 +4,10 @@
* @Author: 无尘
* @Date: 2020-09-08 17:11:02
* @LastEditors: 无尘
* @LastEditTime: 2020-10-27 14:45:14
* @LastEditTime: 2020-12-21 10:28:25
-->
<template>
<div class="app-detail">
<div class="app-detail" v-loading="loading">
<el-form label-width="90px">
<h3 class="model-title">应用信息</h3>
<div class="app-info">
......@@ -70,7 +70,8 @@ export default {
applicationLogo: '',
serverId: ''
},
authInfoList: []
authInfoList: [],
loading: false
};
},
created() {
......@@ -98,19 +99,22 @@ export default {
* @author: 无尘
*/
getAppDetail(menuId, applicationId) {
const that = this;
that.loading = true;
getAppDetail({ menuId, applicationId }).then(res => {
that.loading = false;
const { applicationName, applicationDesc, applicationVersion, overTime, adminRange, storeAdminRange, applicationLogo, serverId } = res.result || {};
this.appData.expirationDate = new Date().getTime() - overTime; // 到期时间
this.appData.expirationDay = overTime - new Date().getTime(); // 剩余到期天数
that.appData.expirationDate = new Date().getTime() - overTime; // 到期时间
that.appData.expirationDay = overTime - new Date().getTime(); // 剩余到期天数
Object.assign(this.appData, { applicationName, applicationDesc, applicationVersion, overTime, applicationLogo, serverId });
Object.assign(that.appData, { applicationName, applicationDesc, applicationVersion, overTime, applicationLogo, serverId });
if (typeof adminRange == 'string' && adminRange.length > 0) {
this.appData.adminRange = JSON.parse(adminRange);
that.appData.adminRange = JSON.parse(adminRange);
}
if (typeof storeAdminRange == 'string' && storeAdminRange.length > 0) {
this.appData.storeAdminRange = JSON.parse(storeAdminRange);
that.appData.storeAdminRange = JSON.parse(storeAdminRange);
}
});
}).finally(() => that.loading = false);;
},
/**
* @description: 获取授权信息
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment