pal管理中心小组管理列表加载和更新小组速度优化

This commit is contained in:
446052889@qq.com 2023-04-06 12:55:27 +08:00
parent d60479f712
commit 75127e0d1d
2 changed files with 39 additions and 2 deletions

View File

@ -1,6 +1,6 @@
module.exports = {
AWSPortalUrl: "http://localhost:8088/portal/",//aws平台启动地址用于开发时获取平台静态资源请求数据等注意最后的/,不要删)
AWSReleasePath: "/Users/sunlh/idea_workspace_aws6/release/", /*C:/work/workspace/release/*/ //aws的平台路径暂时写绝对路径用于build生成的主文件位置注意最后的/,不要删)
AWSReleasePath: "/Users/sunlh/Documents/ideaData/actionsoft/aws6.4.1.1008.yili6/release/", /*C:/work/workspace/release/*/ //aws的平台路径暂时写绝对路径用于build生成的主文件位置注意最后的/,不要删)
moduleTemplateInAWS: "apps/install/com.actionsoft.apps.coe.pal.cooperation/template/page/main.htm", /*apps/install/_bpm.platform/template/page/console.m.dw.design.vue.htm*/ //build后生成到平台的模板位置及名称
outputDir: "apps/install/com.actionsoft.apps.coe.pal.cooperation/web/com.actionsoft.apps.coe.pal.cooperation/main", /*webserver/webapps/portal/apps/_bpm.platform/dw/designer/main*/ //build后js或css生成到平台的位置
publicPath: "../apps/com.actionsoft.apps.coe.pal.cooperation/main", /*../apps/_bpm.platform/dw/designer/main*/ //build到平台后生成到模板中引入js文件的相对平台的位置

View File

@ -72,7 +72,8 @@
label="授权状态"
width="150">
<template slot-scope="scope">
<span v-html="scope.row.permStatus == 0 ? '未设置权限': '已包含' + scope.row.permStatus + '个文件'"></span>
<span v-if="scope.row.permStatus == -1">正在加载...</span>
<span v-else v-html="scope.row.permStatus == 0 ? '未设置权限': '已包含' + scope.row.permStatus + '个文件'"></span>
</template>
</el-table-column>
<el-table-column
@ -134,11 +135,47 @@
awsuiAxios.post(data).then(function (ro) {
if (ro.result == 'ok') {
that.tableData = ro.data;
that.loadTeamPerm();//
}
}).catch(error=>{
console.log(error);
})
},
loadTeamPerm() {
const that = this;
const teamIdArr = [];
for (let i = 0; i < that.tableData.length; i++) {
if (that.tableData[i].permStatus == -1) {
teamIdArr.push(that.tableData[i].teamId);
if (teamIdArr.length >= 5) {// 5
break;
}
}
}
if (teamIdArr.length > 0) {
const data = {
url:'jd',
data:{
cmd: 'com.actionsoft.apps.coe.pal.cooperation_manage_team_info_perm',
teamIdArr: JSON.stringify(teamIdArr)
}
};
awsuiAxios.post(data).then(function (ro) {
if (ro.result == 'ok') {
const result = ro.data
for (let i = 0; i < that.tableData.length; i++) {
if (result[that.tableData[i].teamId] != undefined) {
that.tableData[i].permStatus = result[that.tableData[i].teamId];
}
}
that.loadTeamPerm();//
}
}).catch(error=>{
console.log(error);
})
}
},
updateTeam(teamId) {
this.update.teamId = teamId;
this.update.visible = true;