mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-07 01:46:43 +08:00
Merge branch 'zcwy_0712_bug' into master-0705
This commit is contained in:
@@ -374,7 +374,9 @@ export function usePage(_url, params, init = true,listing = false) {
|
||||
state.totalPage = r.data.total/10 || 1;
|
||||
state.total = r.data.total;
|
||||
state.loading = false;
|
||||
});
|
||||
}).catch(err => {
|
||||
state.loading = false;
|
||||
})
|
||||
}
|
||||
|
||||
init && fetch();
|
||||
@@ -498,6 +500,9 @@ export async function request(_url, params) {
|
||||
if (res.code === 0 || res.code === 200) {
|
||||
return res;
|
||||
}
|
||||
if (res.code === 4 ){
|
||||
return Promise.reject(res);
|
||||
}
|
||||
if (res.code === 1000 || res.code === 1002) {
|
||||
window.location.href = process.env.VUE_APP_LOGIN_URL + encodeURIComponent(window.location.protocol + process.env.VUE_APP_BOE_API_URL + process.env.VUE_APP_BASE + router.currentRoute.value.fullPath)
|
||||
localStorage.removeItem('refreshPage')
|
||||
|
||||
@@ -487,18 +487,20 @@ const columns = ref([
|
||||
key: "teacher",
|
||||
width: "20%",
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
customRender: ({ record }) => {
|
||||
const teachers = record.offteachers;
|
||||
return teachers.map((teacher, index) => {
|
||||
// 如果需要显示为列表形式
|
||||
return (
|
||||
<div key={index}>
|
||||
{teacher.teacherName}
|
||||
{index !== teachers.length - 1 && ', '}
|
||||
</div>
|
||||
);
|
||||
});
|
||||
},
|
||||
// const teachers = record.offteachers;
|
||||
// return teachers.map((teacher, index) => {
|
||||
// // 如果需要显示为列表形式
|
||||
// return (
|
||||
// <div key={index}>
|
||||
// {teacher.teacherName}
|
||||
// {index !== teachers.length - 1 && ', '}
|
||||
// </div>
|
||||
// );
|
||||
// });
|
||||
return record.offteachers.map(item=>item.teacherName).join(',')
|
||||
},
|
||||
|
||||
},
|
||||
{
|
||||
|
||||
@@ -189,7 +189,7 @@ export default {
|
||||
pageSize: 10,
|
||||
currentPage: 1,
|
||||
tableDataTotal: 0,
|
||||
projectName: undefined,
|
||||
projectName: null,
|
||||
projectNameListNot: [
|
||||
{
|
||||
id: 1,
|
||||
@@ -377,7 +377,7 @@ export default {
|
||||
ctx.emit("update:Tvisible", false);
|
||||
state.currentPage = 1;
|
||||
state.name = "";
|
||||
state.projectName = undefined;
|
||||
state.projectName = null;
|
||||
state.tabledata = [];
|
||||
};
|
||||
const afterVisibleChange = (bol) => {
|
||||
@@ -389,6 +389,9 @@ export default {
|
||||
};
|
||||
const selectProjectName = (value) => {
|
||||
state.projectName = value;
|
||||
if(value === undefined){
|
||||
state.projectName = null;
|
||||
}
|
||||
};
|
||||
//催促
|
||||
const godie = () => {
|
||||
@@ -515,7 +518,7 @@ export default {
|
||||
state.tableDataTotalLoading = true;
|
||||
state.currentPage = 1;
|
||||
state.name = "";
|
||||
state.projectName = "";
|
||||
state.projectName = null;
|
||||
getData();
|
||||
}
|
||||
|
||||
|
||||
@@ -192,7 +192,7 @@ export default {
|
||||
pageSize: 10,
|
||||
currentPage: 1,
|
||||
tableDataTotal: 0,
|
||||
projectName: undefined,
|
||||
projectName: null,
|
||||
projectNameListNot: [
|
||||
{
|
||||
id: 1,
|
||||
@@ -384,7 +384,7 @@ export default {
|
||||
ctx.emit("update:CommonModelVisible", false);
|
||||
state.currentPage = 1;
|
||||
state.name = "";
|
||||
state.projectName = undefined;
|
||||
state.projectName = null;
|
||||
state.tabledata = [];
|
||||
};
|
||||
const afterVisibleChange = (bol) => {
|
||||
@@ -396,6 +396,9 @@ export default {
|
||||
};
|
||||
const selectProjectName = (value) => {
|
||||
state.projectName = value;
|
||||
if(value === undefined){
|
||||
state.projectName = null;
|
||||
}
|
||||
};
|
||||
//催促
|
||||
const godie = () => {
|
||||
@@ -523,7 +526,7 @@ export default {
|
||||
state.tableDataTotalLoading = true;
|
||||
state.currentPage = 1;
|
||||
state.name = "";
|
||||
state.projectName = undefined;
|
||||
state.projectName = null;
|
||||
getData();
|
||||
}
|
||||
|
||||
|
||||
@@ -442,6 +442,10 @@ export default {
|
||||
|
||||
{/* 导出数据 */ }
|
||||
function exportData() {
|
||||
if(state.tabledata.length==0){
|
||||
message.error("没有数据可以导出");
|
||||
return
|
||||
}
|
||||
// window.open(`${process.env.VUE_APP_BASE_API}/admin/exam/manage/exportExam?chapterId=${props.datasource.chapterId}&targetId=${props.datasource.routerId}&taskId=${props.datasource.courseId}&type=${1}`)
|
||||
window.open(`${process.env.VUE_APP_BASE_API}/admin/exam/manage/exportExam?currentStageId=${props.datasource.chapterId}&type=${1}&pid=${props.datasource.routerId}&targetId=${props.datasource.routerId}&taskId=${props.datasource.courseId}&taskType=${props.datasource.type}`)
|
||||
|
||||
|
||||
@@ -1993,16 +1993,17 @@ const columns6 = [
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
customRender: ({ record }) => {
|
||||
const teachers = record.offteachers;
|
||||
return teachers.map((teacher, index) => {
|
||||
// 如果需要显示为列表形式
|
||||
return (
|
||||
<div key={index}>
|
||||
{teacher.teacherName}
|
||||
{index !== teachers.length - 1 && ', '}
|
||||
</div>
|
||||
);
|
||||
});
|
||||
// const teachers = record.offteachers;
|
||||
// return teachers.map((teacher, index) => {
|
||||
// // 如果需要显示为列表形式
|
||||
// return (
|
||||
// <div key={index}>
|
||||
// {teacher.teacherName}
|
||||
// {index !== teachers.length - 1 && ', '}
|
||||
// </div>
|
||||
// );
|
||||
// });
|
||||
return record.offteachers.map(item=>item.teacherName).join(',')
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user