-

+
全部导出
-

+
导出
@@ -281,6 +299,8 @@ export default {
name: "", //名称
selectedRowKeys: [], // 选中的列
option: [],
+ resetOrgId: [],
+ allowClear: true,
});
// 获取tab数据
const getTabData = async () => {
@@ -302,21 +322,20 @@ export default {
state.tableLoading = true;
state.creator = "";
state.name = "";
- getOrgId();
- // getTableData();
+ state.orgId = state.resetOrgId;
+ getTableData();
};
//请求组织接口
const getOrgList = async () => {
const res = await api.userGetUserOrg({});
if (res) {
- const list = res.data?.result?.map((item) => {
- return {
- label: item.orgName,
- value: item.orgId,
- };
- });
- state.option = list;
- getOrgId();
+ state.option = res.data?.result?.list;
+ state.orgId = res.data?.result?.treeNodeList;
+ state.resetOrgId = res.data?.result?.treeNodeList;
+ res.data?.result?.userType === 1
+ ? (state.allowClear = true)
+ : (state.allowClear = false);
+ getTableData();
}
};
// 导出按钮
@@ -407,7 +426,7 @@ export default {
url: "/report/boeu/case/exportAll",
data: {
name: state.name,
- organizationId: state.orgId,
+ organizationId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
},
responseType: "blob",
@@ -423,7 +442,7 @@ export default {
url: "/report/boeu/exam/exportAll",
data: {
name: state.name,
- organizationId: state.orgId,
+ organizationId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
},
responseType: "blob",
@@ -439,7 +458,7 @@ export default {
url: "/report/boeu/course/exportAll",
data: {
name: state.name,
- organizationId: state.orgId,
+ organizationId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
},
responseType: "blob",
@@ -455,7 +474,7 @@ export default {
url: "/report/boeu/teaching/exportAll",
data: {
name: state.name,
- organizationId: state.orgId,
+ organizationId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
},
responseType: "blob",
@@ -471,7 +490,7 @@ export default {
url: "/report/boeu/router/exportAll",
data: {
name: state.name,
- organizationId: state.orgId,
+ organizationId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
},
responseType: "blob",
@@ -485,9 +504,9 @@ export default {
axios({
method: "post",
url: "/report/boeu/project/exportAll",
- data:{
+ data: {
name: state.name,
- organizationId: state.orgId,
+ orgId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
},
responseType: "blob",
@@ -511,7 +530,7 @@ export default {
//考试列表
const res = await api.boeuExamPageList({
creator: state.creator,
- orgId: state.orgId,
+ orgId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
testName: state.name,
page: state.pageNo,
size: state.pageSize,
@@ -531,7 +550,7 @@ export default {
//案例列表
const res = await api.boeuCasePageList({
author: state.creator,
- orgId: state.orgId,
+ orgId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
title: state.name,
page: state.pageNo,
size: state.pageSize,
@@ -552,7 +571,9 @@ export default {
page: state.pageNo,
size: state.pageSize,
name: state.name,
- organizationId: state.orgId,
+ organizationId: state.orgId
+ ? state.orgId[state.orgId.length - 1]
+ : null,
createName: state.creator,
});
const list = res.data.rows.map((item) => {
@@ -569,7 +590,7 @@ export default {
page: state.pageNo,
size: state.pageSize,
teachingName: state.name,
- orgId: state.orgId,
+ orgId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
});
const list = res.data.rows?.map((item) => {
@@ -586,7 +607,7 @@ export default {
page: state.pageNo,
size: state.pageSize,
routerName: state.name,
- orgId: state.orgId,
+ orgId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
});
const list = res.data.rows?.map((item) => {
@@ -602,7 +623,7 @@ export default {
const res = await api.boeuProjectPageList({
page: state.pageNo,
size: state.pageSize,
- orgId: state.orgId,
+ orgId: state.orgId ? state.orgId[state.orgId.length - 1] : null,
createName: state.creator,
projectName: state.name,
});
@@ -1307,14 +1328,7 @@ export default {
}
getTableData();
};
- // 获取登录人员组织
- const getOrgId = async () => {
- const res = await api.userInfo({});
- if (res) {
- state.orgId = res.data.result.departId;
- getTableData();
- }
- };
+
//table 分页事件
const changePagination = (page) => {
state.selectedRowKeys = [];
@@ -1430,10 +1444,15 @@ export default {
.btn2 {
margin-right: 0px !important;
+ background: #4ea6ff;
.search {
width: 16px;
height: 18px;
- background-image: url("../../assets/images/courseManage/reset1.png");
+
+ background-image: url("../../assets/images/courseManage/reset0.png");
+ }
+ .btnText {
+ color: white;
}
}
@@ -1448,18 +1467,29 @@ export default {
color: #ffffff;
}
}
+ .btn2:hover {
+ background: rgba(64, 158, 255, 0.76);
- .btn1:active {
+ .search {
+ background-image: url("../../assets/images/courseManage/reset0.png");
+ }
+
+ .btnText {
+ color: #ffffff;
+ }
+ }
+ .btn1:active,
+ .btn2:active {
background: #0982ff;
}
- .btn2:hover {
- background: rgba(64, 158, 255, 0.1);
- }
+ // .btn2:hover {
+ // background: rgba(64, 158, 255, 0.1);
+ // }
- .btn2:active {
- background: rgba(64, 158, 255, 0.2);
- }
+ // .btn2:active {
+ // background: rgba(64, 158, 255, 0.2);
+ // }
}
.tabBtn {
width: 100%;
@@ -1519,16 +1549,20 @@ export default {
.btn3 {
margin-right: 0px;
+ background: #4ea6ff;
.search {
width: 17px;
height: 18px;
background-image: url("../../assets/images/courseManage/add0.png");
}
+ .btnText {
+ color: #ffffff;
+ }
}
.btn3:hover {
// background: rgba(64, 158, 255, 0.76);
- background: rgba(64, 158, 255, 0.2);
+ background: rgba(64, 158, 255, 0.76);
}
}
}