Commit e78007fc by caoyanzhi

update: 调整应用详情页面

parent a7d4b6e6
......@@ -21,13 +21,13 @@
<el-form-item label="可见范围">
<h4 class="sub-title">管理成员</h4>
<div class="admin-list">
<el-tag type="info" v-for="el in adminRange" :key="el.roleId">{{ el.roleName }}</el-tag>
<span class="no-admin">暂无成员</span>
<el-tag type="info" v-for="el in appData.adminRange" :key="el.roleId">{{ el.roleName }}</el-tag>
<span v-if="appData.adminRange.length == 0" class="no-admin">暂无成员</span>
</div>
<h4 class="sub-title">门店成员</h4>
<div class="admin-list">
<el-tag type="info" v-for="el in storeAdminRange" :key="el.roleId">{{ el.roleName }}</el-tag>
<span class="no-admin">暂无成员</span>
<el-tag type="info" v-for="el in appData.storeAdminRange" :key="el.roleId">{{ el.roleName }}</el-tag>
<span v-if="appData.storeAdminRange.length == 0" class="no-admin">暂无成员</span>
</div>
</el-form-item>
</el-form>
......@@ -65,11 +65,11 @@ export default {
getAppDetail({ applicationId }).then(res => {
const { applicationName, applicationDesc, applicationVersion, overTime, adminRange, storeAdminRange, applicationLogo } = res.result || {};
Object.assign(this.appData, { applicationName, applicationDesc, applicationVersion, overTime, applicationLogo });
if (Array.isArray(adminRange)) {
this.appData.adminRange = adminRange;
if (typeof adminRange == 'string' && adminRange.length > 0) {
this.appData.adminRange = JSON.parse(adminRange);
}
if (Array.isArray(storeAdminRange)) {
this.appData.storeAdminRange = storeAdminRange;
if (typeof storeAdminRange == 'string' && storeAdminRange.length > 0) {
this.appData.storeAdminRange = JSON.parse(storeAdminRange);
}
});
}
......
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