mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-12 12:26:47 +08:00
fix:添加在线、添加考试、添加案例、添加测评功能完善
This commit is contained in:
@@ -160,7 +160,6 @@ export default {
|
||||
currentPage: 1,
|
||||
tableDataTotal: 0,
|
||||
pageSize: 10,
|
||||
searching:false,
|
||||
selectedRowKeys: [],
|
||||
apiTaskList: [],
|
||||
inputV1: "",
|
||||
@@ -222,23 +221,6 @@ export default {
|
||||
const getTableDate = (tableData) => {
|
||||
let data = tableData;
|
||||
let array = [];
|
||||
if(state.searching){
|
||||
data.map((value, index) => {
|
||||
let obj = {
|
||||
key: index,
|
||||
authorId: value.authorId,
|
||||
authorName: value.authorName,
|
||||
companyId: value.companyId,
|
||||
coverUrl: value.coverUrl,
|
||||
id: value.id,
|
||||
casesId: value.casesId,
|
||||
title: value.title,
|
||||
};
|
||||
if(obj.title == state.inputV1){
|
||||
array.push(obj);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
data.map((value, index) => {
|
||||
let obj = {
|
||||
key: index,
|
||||
@@ -252,7 +234,6 @@ export default {
|
||||
};
|
||||
array.push(obj);
|
||||
});
|
||||
}
|
||||
state.tableData = array;
|
||||
};
|
||||
//获取全部案例信息接口
|
||||
@@ -264,7 +245,7 @@ export default {
|
||||
orderField: "",
|
||||
pageIndex: state.currentPage,
|
||||
pageSize: state.pageSize,
|
||||
top: true,
|
||||
isTop: "",
|
||||
})
|
||||
.then((res) => {
|
||||
if (res.status === 200) {
|
||||
@@ -349,17 +330,14 @@ export default {
|
||||
//搜索案例列表
|
||||
const searchList = ()=> {
|
||||
if(state.inputV1 !== ''){
|
||||
state.searching = true
|
||||
getAllCaseText()
|
||||
}else {
|
||||
state.searching = false
|
||||
resetCase()
|
||||
}
|
||||
}
|
||||
//重置案例信息
|
||||
const resetCase = () => {
|
||||
state.inputV1 = ""
|
||||
state.searching = false
|
||||
state.selectedRowKeys=[]
|
||||
state.currentPage = 1
|
||||
getAllCaseText();
|
||||
|
||||
Reference in New Issue
Block a user