Commit 900be442 authored by 徐一鸣's avatar 徐一鸣

Merge branch 'xym' into dev

parents fcd35b80 b5b45013
......@@ -4,12 +4,12 @@
<i class="el-icon-close"></i>
</a>
<div class="app_card-icon">
<el-avatar shape="square" :size="56" fit="cover" :src="data.img" />
<el-avatar shape="square" :size="56" fit="cover" :src="data.logo" />
</div>
<div class="app_card-info">
<p
class="app_card-name text_clip"
v-text="data.name"
v-text="data.app_name"
@click="intoDetail"
></p>
<p class="app_card-version text_clip" v-text="data.version"></p>
......@@ -24,7 +24,7 @@
<i class="el-icon-time"></i>
<span>上线时间:</span>
</span>
<span class="text_clip" v-text="data.time"></span>
<span class="text_clip" v-text="data.created"></span>
</p>
</div>
</template>
......@@ -53,7 +53,7 @@ export default {
this.$emit("delete-action", this.data);
},
intoDetail() {
this.$router.push(`${this.detailsUrl}${this.data.id}`);
this.$router.push(`${this.detailsUrl}${this.data.up_userid}`);
},
},
};
......
......@@ -60,12 +60,12 @@ export default {
<style scoped>
.app_list {
margin: 20px -25px 0;
margin: 0 -20px;
padding: 30px 0 0;
border-top: 1px solid #e3e5ef;
display: flex;
flex-wrap: wrap;
justify-content: flex-start;
align-items: flex-start;
align-content: flex-start;
}
</style>
......@@ -39,7 +39,7 @@ export default {
listHeader: [],
listData: [],
filterList: [],
roleFilter: [],
otherFilter: [],
dialogInfo: {
title: "",
msg: "",
......@@ -73,20 +73,24 @@ export default {
Promise.all([
this.$http.get("/apaas/service/v3/service/manager/servtype"),
this.$http.get("/apaas/service/v3/service/manager/servarea"),
]).then((response) => {
let data = response.map((item) => {
return {
name: item.body.data[0].type_name,
prop: item.body.data[0].type_code,
data: item.body.data.map((v) => ({
name: v.name,
value: v.id,
})),
};
});
])
.then((response) => {
let data = response.map((item) => {
return {
name: item.body.data[0].type_name,
prop: item.body.data[0].type_code,
data: item.body.data.map((v) => ({
name: v.name,
value: v.id,
})),
};
});
this.filterList = [...data, ...this.roleFilter];
});
this.filterList = [...data, ...this.otherFilter];
})
.catch((error) => {
console.log(error);
});
},
initHeader() {
let _self = this;
......@@ -163,7 +167,7 @@ export default {
],
},
];
this.roleFilter = [
this.otherFilter = [
{
name: "开放程度",
prop: "openness",
......@@ -267,7 +271,7 @@ export default {
],
},
];
this.roleFilter = [
this.otherFilter = [
{
name: "开放程度",
prop: "openness",
......@@ -419,7 +423,7 @@ export default {
align: "center",
},
];
this.roleFilter = [
this.otherFilter = [
{
name: "开放程度",
prop: "openness",
......@@ -532,7 +536,7 @@ export default {
],
},
];
this.roleFilter = [
this.otherFilter = [
{
name: "开放程度",
prop: "openness",
......@@ -696,7 +700,7 @@ export default {
],
},
];
this.roleFilter = [
this.otherFilter = [
{
name: "开放程度",
prop: "openness",
......@@ -795,7 +799,7 @@ export default {
],
},
];
this.roleFilter = [
this.otherFilter = [
{
name: "开放程度",
prop: "openness",
......
<template>
<div class="list_container">
<div class="apass_breadcrumb">
<div class="app_management_list">
<apass-list
ref="list"
search-placeholder="请输入关键字"
:list-total="listTotal"
:list-filter="filterList"
:list-header="listHeader"
:list-data="listData"
:list-padding-left="35"
@list-action="initDatas"
>
<el-breadcrumb separator="/">
<el-breadcrumb-item>我的应用</el-breadcrumb-item>
<el-breadcrumb-item>{{ pathName }}</el-breadcrumb-item>
</el-breadcrumb>
</div>
<div class="main_container card" v-if="listType == 'card'">
<div class="filter_contaner">
<div class="filter_action">
<el-button
v-if="filterList && filterList.length"
@click="showFliterList = !showFliterList"
>
{{ showFliterList ? "收起" : "筛选" }}
<i
class="el-icon--right"
:class="
showFliterList ? 'el-icon-caret-bottom' : 'el-icon-caret-top'
"
></i>
</el-button>
<el-input
v-model="search"
prefix-icon="el-icon-search"
placeholder="请输入应用名称"
style="width:180px;"
@input="searchAction"
class="ces_toolbar_inp"
></el-input>
</div>
<table-filter
:show="showFliterList"
:filter-list="filterList"
@filter-change="filterChange"
style="margin-top: 5px;"
></table-filter>
</div>
<app-list
:data="appList"
v-if="listType"
slot="list"
:data="listData"
:card-type="cardType"
@deployment-action="deploymentAction"
@delete-action="deleteAction"
:details-url="detailsUrl"
></app-list>
<div class="flex_grow"></div>
<comments-pagination
:total="100"
:page-sizes="pageSizes"
:page-size="pageSize"
:current-page="currentPage"
@size-change="changePageSize"
@current-change="changeCurrentPage"
></comments-pagination>
</div>
<div class="main_container" v-if="listType == 'table'">
<ces-table
class="r_yhgl_table"
size="mini"
url="tableData"
input-placeholder="请输入应用名称"
empty-text="暂时没数据"
:detailsUrl="detailsUrl"
:border="false"
:headers="headers"
:searchShow="true"
:autoAdd="false"
:stripe="true"
:pageSizeShow="true"
:filterList="filterList"
:isIndex="false"
@action-approval="approvalItem"
@action-delete="deleteItem"
@action-edit="editItem"
@off-line="offLine"
@goods-shelf="goodsShelf"
style="margin-top: 50px;"
></ces-table>
</div>
<dialog-action
ref="myConfirm"
:confirm-options="confirmOptions"
></dialog-action>
</apass-list>
<apass-dialog
ref="dialog"
:title="dialogInfo.title"
:msg="dialogInfo.msg"
:submit="dialogInfo.submit"
></apass-dialog>
</div>
</template>
<script>
import tableFilter from "@/components/table/table-filter";
import appList from "@/components/app-list/app-list";
import cesTable from "@/components/table/table-um";
import dialogAction from "@/components/dialog-action";
import commentsPagination from "@/components/comments-pagination";
import apassList from "@/components/apass-list";
import apassDialog from "@/components/apass-dialog";
import { mapState } from "vuex";
export default {
components: {
tableFilter,
appList,
cesTable,
dialogAction,
commentsPagination,
apassList,
apassDialog,
},
data: () => ({
level: 0, // 用户等级
type: 0, // 访问的页面
listType: "",
cardType: "",
showFliterList: false,
filterList: [
{
name: "在线状态",
prop: "zxzt",
data: ["平台应用", "开发者应用", "未上架"],
},
{
name: "应用类型",
prop: "yylx",
data: ["基础工具", "通用工具", "业务应用"],
},
{
name: "业务领域",
prop: "ywly",
data: [
"公安应用",
"应急应用",
"政务服务应用",
"金融应用",
"交通应用",
"旅游应用",
],
},
{
name: "是否支持开发",
prop: "sfzckf",
data: ["全部", "支持开发", "不支持开发"],
},
],
appList: [
{
id: 1000001,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "mapvideos",
version: "V2.0",
time: "2019-04-11 12:50:30",
},
{
id: 1000002,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "语音识别",
version: "V2.0",
time: "2019-04-11 12:50:30",
},
{
id: 1000003,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.0",
time: "2019-04-11 12:50:30",
},
{
id: 1000004,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.1",
time: "2019-04-11 12:50:30",
},
{
id: 1000005,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.2",
time: "2019-04-11 12:50:30",
},
{
id: 1000006,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.3",
time: "2019-04-11 12:50:30",
},
{
id: 1000007,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.4",
time: "2019-04-11 12:50:30",
},
{
id: 100000,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.5",
time: "2019-04-11 12:50:30",
},
{
id: 1000009,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.6",
time: "2019-04-11 12:50:30",
},
{
id: 1000010,
img:
"https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg",
name: "轨迹绘制",
version: "V2.7",
time: "2019-04-11 12:50:30",
},
],
search: "",
pageSizes: [10, 50, 100],
pageSize: 10,
currentPage: 1,
confirmOptions: {
listTotal: 0,
filterList: [],
listHeader: [],
listData: [],
dialogInfo: {
title: "",
message: "",
btnCancelText: "",
btnSubmitText: "",
item: null,
},
otherFilter1: [],
otherFilter2: [],
tempFliter: null,
}),
computed: {
...mapState({
......@@ -252,39 +89,525 @@ export default {
},
},
methods: {
searchAction(value) {
console.log(value);
initHeader() {
let level = this.level;
let type = this.type;
// 普通用户 --- 应用仓库 card列表形式
if (level === 0 && type === 0) {
this.listType = "card";
this.cardType = 0;
this.otherFilter1 = [
{
name: "在线状态",
prop: "online_state",
data: [
{
name: "平台应用",
value: 1,
},
{
name: "开发者应用",
value: 2,
},
{
name: "未上架",
value: 0,
},
],
},
];
this.otherFilter2 = [
{
name: "是否支持开发",
prop: "developable",
data: [
{
name: "支持开发",
value: 1,
},
{
name: "不支持开发",
value: 0,
},
],
},
{
name: "应用来源",
prop: "appSource",
data: [
{
name: "创建的应用",
value: 0,
},
{
name: "申请的应用",
value: 1,
},
],
},
];
}
// 普通用户 --- 我部署的应用
else if (level === 0 && type === 1) {
this.listType = "card";
this.cardType = 1;
this.otherFilter1 = [
{
name: "部署来源",
prop: "online_state",
data: [
{
name: "应用商店",
value: 0,
},
{
name: "开发者应用",
value: 1,
},
],
},
];
this.otherFilter2 = [
{
name: "是否支持开发",
prop: "developable",
data: [
{
name: "支持开发",
value: 1,
},
{
name: "不支持开发",
value: 0,
},
],
},
{
name: "应用来源",
prop: "appSource",
data: [
{
name: "创建的应用",
value: 0,
},
{
name: "申请的应用",
value: 1,
},
],
},
];
}
// 普通用户 --- 申请的应用 card列表形式
else if (level === 0 && type === 2) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "申请时间", prop: "address", type: "", align: "center" },
{ label: "申请状态", prop: "address", type: "", align: "center" },
];
this.otherFilter1 = [
{
name: "在线区域",
prop: "online_state",
data: [
{
name: "平台应用",
value: 1,
},
{
name: "开发者应用",
value: 2,
},
],
},
];
this.otherFilter2 = [
{
name: "申请类型",
prop: "apply_type",
data: [
{
name: "申请部署",
value: 1,
},
{
name: "申请开发",
value: 2,
},
],
},
{
name: "申请状态",
prop: "apply_state",
data: [
{
name: "审批中",
value: 1,
},
{
name: "审批通过",
value: 2,
},
{
name: "审批未通过",
value: 2,
},
],
},
{
name: "应用来源",
prop: "appSource",
data: [
{
name: "创建的应用",
value: 0,
},
{
name: "申请的应用",
value: 1,
},
],
},
];
}
/* // 普通用户 --- 审批的应用
else if (level === 0 && type === 3) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "审批时间", prop: "address", type: "", align: "center" },
{ label: "审批状态", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "action-approval",
label: "审批",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
} */
// 组织管理员 --- 应用仓库管理
else if (level === 1 && type === 0) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线状态", prop: "address", type: "", align: "center" },
{ label: "创建时间", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "goods-shelf",
},
],
},
];
}
// 组织管理员 --- 部署的应用
else if (level === 1 && type === 1) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "上架区域", prop: "address", type: "", align: "center" },
{ label: "部署时间", prop: "address", type: "", align: "center" },
{ label: "部署区域", prop: "address", type: "", align: "center" },
];
}
// 组织管理员 --- 应用审批管理
else if (level === 1 && type === 2) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "审批时间", prop: "address", type: "", align: "center" },
{ label: "申请状态", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "action-approval",
label: "审批",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// 超级管理员 --- 平台应用管理
else if (level === 2 && type === 0) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线状态", prop: "address", type: "", align: "center" },
{ label: "所属组织", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 240,
btnList: [
{
type: "action-edit",
label: "编辑",
line: "|",
},
{
type: "off-line",
label: "下线",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// 超级管理员 --- 应用部署管理
else if (level === 2 && type === 1) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "上架区域", prop: "address", type: "", align: "center" },
{ label: "所属组织", prop: "address", type: "", align: "center" },
{ label: "部署时间", prop: "address", type: "", align: "center" },
{ label: "部署区域", prop: "address", type: "", align: "center" },
];
}
// 超级管理员 --- 应用审批管理
else if (level === 2 && type === 2) {
this.listType = "table";
this.listHeader = [
{ label: "应用名称", prop: "name", type: "", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "审批时间", prop: "address", type: "", align: "center" },
{ label: "申请状态", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "action-approval",
label: "审批",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// Error
else {
throw Error("The page doesn't exist");
}
},
filterChange(filter) {
console.log(filter);
initFilter() {
let level = this.level;
let type = this.type;
let urls = [
{
path: "/apaas/hubApi/market/appTypes",
callback(response) {
let datas = [];
datas = response.body.data.map((v) => ({
name: v.name,
value: v.id,
}));
return {
name: "应用类型",
prop: "appTypes",
data: datas,
};
},
},
{
path: "/apaas/hubApi/market/businessAreas",
callback(response) {
let datas = [];
datas = response.body.data.map((v) => ({
name: v.name,
value: v.id,
}));
return {
name: "业务领域",
prop: "businessArea",
data: datas,
};
},
},
];
Promise.all(urls.map((url) => this.$http.get(url.path)))
.then((responses) => {
let filterList = responses.map((response, index) => {
return urls[index].callback(response);
});
this.filterList = [
...this.otherFilter1,
...filterList,
...this.otherFilter2,
];
})
.catch((error) => {
console.log(error);
});
},
initDatas(filter) {
let listUrl = [
"/apaas/hubApi/market/list",
"/apaas/hubApi/market/deployList",
"/apaas/hubApi/market/deployList",
];
let params = {};
if (filter.online_state) {
params.online_state = filter.online_state
.map((item) => {
return item.value;
})
.join(",");
} // 在线状态
if (filter.appTypes) {
params.appTypes = filter.appTypes
.map((item) => {
return item.value;
})
.join(",");
} // 应用类型
if (filter.businessArea) {
params.businessArea = filter.businessArea
.map((item) => {
return item.value;
})
.join(",");
} // 业务领域
if (filter.developable) {
params.developable = filter.developable
.map((item) => {
return item.value;
})
.join(",");
} // 是否支持开发
if (filter.appSource) {
params.appSource = filter.appSource
.map((item) => {
return item.value;
})
.join(",");
} // 应用来源
this.tempFliter = filter;
this.$http
.get(listUrl[this.type], {
params: {
...params,
search: filter.keyword,
page: filter.page,
limit: filter.size,
},
})
.then(({ data }) => {
this.listTotal = data.total;
this.listData = data.data || [];
})
.catch((error) => {
console.log(error);
});
},
deploymentAction(item) {
console.log("deployment " + item.name);
},
deleteAction(item) {
if (this.cardType === 0) {
this.confirmOptions.title = "删除提示";
this.confirmOptions.message =
/* if (this.cardType === 0) {
this.dialogInfo.title = "删除提示";
this.dialogInfo.msg =
"您需要先进行应用商店下架申请,应用处于下架状态时才能进行删除操作。";
this.confirmOptions.btnCancelText = "";
this.confirmOptions.btnSubmitText = "";
this.confirmOptions.confirmSubmit = () => {
this.dialogInfo.btnCancelText = "";
this.dialogInfo.btnSubmitText = "";
this.dialogInfo.confirmSubmit = () => {
console.log("deleteItem - " + item.name);
this.$refs.myConfirm.hideModel();
};
} else if (this.cardType === 1) {
this.confirmOptions.title = "是否删除部署的应用";
this.confirmOptions.message =
this.dialogInfo.title = "是否删除部署的应用";
this.dialogInfo.msg =
"该操作会导致正在调用该应用的用户被迫终止对应用的调用,删除前需向正在调用该应用的用户发送通知,自通知发送之日起,2日后应用将被删除。";
this.confirmOptions.btnCancelText = "";
this.confirmOptions.btnSubmitText = "发送通知";
this.confirmOptions.confirmSubmit = () => {
this.dialogInfo.btnCancelText = "";
this.dialogInfo.btnSubmitText = "发送通知";
this.dialogInfo.confirmSubmit = () => {
console.log("deleteItem - " + item.name);
this.$refs.myConfirm.hideModel();
};
}
this.$refs.myConfirm.showModel();
this.$refs.myConfirm.showModel(); */
},
changePageSize(value) {
this.pageSize = value;
......@@ -312,249 +635,14 @@ export default {
created() {
this.level = parseInt(this.$route.params.level);
this.type = parseInt(this.$route.params.type);
let level = this.level;
let type = this.type;
// 普通用户 --- 应用仓库 card列表形式
if (level === 0 && type === 0) {
this.listType = "card";
this.cardType = 0;
}
// 普通用户 --- 我部署的应用
else if (level === 0 && type === 1) {
this.listType = "card";
this.cardType = 1;
}
// 普通用户 --- 申请的应用 card列表形式
else if (level === 0 && type === 2) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "申请时间", prop: "address", type: "", align: "center" },
{ label: "申请状态", prop: "address", type: "", align: "center" },
];
}
// 普通用户 --- 审批的应用
else if (level === 0 && type === 3) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "审批时间", prop: "address", type: "", align: "center" },
{ label: "审批状态", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "action-approval",
label: "审批",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// 组织管理员 --- 应用仓库管理
else if (level === 1 && type === 0) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线状态", prop: "address", type: "", align: "center" },
{ label: "创建时间", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "goods-shelf",
},
],
},
];
}
// 组织管理员 --- 部署的应用
else if (level === 1 && type === 1) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "上架区域", prop: "address", type: "", align: "center" },
{ label: "部署时间", prop: "address", type: "", align: "center" },
{ label: "部署区域", prop: "address", type: "", align: "center" },
];
}
// 组织管理员 --- 应用审批管理
else if (level === 1 && type === 2) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "审批时间", prop: "address", type: "", align: "center" },
{ label: "申请状态", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "action-approval",
label: "审批",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// 超级管理员 --- 平台应用管理
else if (level === 2 && type === 0) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线状态", prop: "address", type: "", align: "center" },
{ label: "所属组织", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 240,
btnList: [
{
type: "action-edit",
label: "编辑",
line: "|",
},
{
type: "off-line",
label: "下线",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// 超级管理员 --- 应用部署管理
else if (level === 2 && type === 1) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "href", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "上架区域", prop: "address", type: "", align: "center" },
{ label: "所属组织", prop: "address", type: "", align: "center" },
{ label: "部署时间", prop: "address", type: "", align: "center" },
{ label: "部署区域", prop: "address", type: "", align: "center" },
];
}
// 超级管理员 --- 应用审批管理
else if (level === 2 && type === 2) {
this.listType = "table";
this.headers = [
{ label: "应用名称", prop: "name", type: "", align: "left" },
{ label: "应用版本", prop: "date", type: "", align: "center" },
{ label: "应用类型", prop: "address", type: "", align: "center" },
{ label: "业务领域", prop: "address", type: "", align: "center" },
{ label: "在线区域", prop: "address", type: "", align: "center" },
{ label: "申请类型", prop: "address", type: "", align: "center" },
{ label: "审批时间", prop: "address", type: "", align: "center" },
{ label: "申请状态", prop: "address", type: "", align: "center" },
{
label: "操作",
type: "Button",
align: "center",
width: 160,
btnList: [
{
type: "action-approval",
label: "审批",
line: "|",
},
{
type: "action-delete",
label: "删除",
},
],
},
];
}
// Error
else {
throw Error("The page doesn't exist");
}
this.initHeader();
this.initFilter();
},
};
</script>
<style scoped>
.list_container {
.app_management_list {
height: 100%;
padding: 0 20px;
overflow: auto;
}
.main_container {
min-height: calc(100% - 84px);
padding: 15px 20px;
border-radius: 10px;
overflow: hidden;
background-color: #fff;
margin-bottom: 42px;
}
.main_container.card {
display: flex;
flex-direction: column;
justify-content: flex-start;
align-items: stretch;
}
.flex_grow {
flex-grow: 1;
}
.filter_action {
display: flex;
justify-content: space-between;
align-items: center;
}
</style>
......@@ -12,7 +12,7 @@ const store = new Vuex.Store({
["平台服务管理", "服务审批管理" /* , "云资源管理" */], // 超级管理员
], // 服务管理列表,onlyRead
yyglNav: [
["应用仓库", "我部署的应用", "申请的应用", "审批的应用"], // 普通用户
["应用仓库", "我部署的应用", "申请的应用" /* "审批的应用" */], // 普通用户
["应用仓库管理", "部署的应用", "应用审批管理"], // 组织管理员
["平台应用管理", "应用部署管理", "应用审批管理"], // 超级管理员
], // 应用管理列表,onlyRead
......
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