修改接口方法为post

This commit is contained in:
chensg
2025-06-13 17:19:36 +08:00
parent 2e1d7d7a51
commit 1b737e4a7a

View File

@@ -397,45 +397,58 @@
data.tableLoading = true;
if(props.reportType=='project' && props.secondReportType=='student'){
const res = await api.projectStudentReportList({page: data.pageNo,size: data.pageSize,projectId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='project' && props.secondReportType=='task'){
const res = await api.projectTaskReportList({page: data.pageNo,size: data.pageSize,projectId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='router' && props.secondReportType=='chapter'){
const res = await api.routerChapterReportList({page: data.pageNo,size: data.pageSize,routerId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='router' && props.secondReportType=='student'){
const res = await api.routerStudentReportList({page: data.pageNo,size: data.pageSize,routerId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='router' && props.secondReportType=='task'){
const res = await api.routerTaskReportList({page: data.pageNo,size: data.pageSize,routerId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='offcourse' && props.secondReportType=='teacher'){
const res = await api.offCourseTeacherReportList({page: data.pageNo,size: data.pageSize,offCourseId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='offcourse' && props.secondReportType=='student'){
const res = await api.offCourseStudentReportList({page: data.pageNo,size: data.pageSize,offCourseId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='online' && props.secondReportType=='content'){
const res = await api.onlineCourseContentReportList({page: data.pageNo,size: data.pageSize,courseId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='online' && props.secondReportType=='student'){
const res = await api.onlineCourseStudentReportList({page: data.pageNo,size: data.pageSize,courseId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='exam' && props.secondReportType=='student'){
const res = await api.examTestStudentReportList({page: data.pageNo,size: data.pageSize,testId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='case' && props.secondReportType=='author'){
const res = await api.caseAuthorReportList({page: data.pageNo,size: data.pageSize,caseId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='professional' && props.secondReportType=='task'){
const res = await api.professionalTaskReportList({page: data.pageNo,size: data.pageSize,growthId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}else if(props.reportType=='professional' && props.secondReportType=='student'){
const res = await api.professionalStudentReportList({page: data.pageNo,size: data.pageSize,growthId: props.currentId});
data.dataSource = res.data.result.rows || [];
data.dataSource = res.data.records || [];
data.total = res.data.total;
}
state.tableLoading = false;
data.tableLoading = false;
};
const emit = defineEmits({})
@@ -445,6 +458,7 @@
// 监听弹出层分页变化方法
const modelChangePagination = (page) =>{
data.pageNo = page;
console.log(data.pageNo)
getTableData();
}
</script>