fix:更新调试项目、学习路径图共享文档编辑

This commit is contained in:
wyx
2023-02-16 16:52:43 +08:00
parent 6f19ec452a
commit 44caf13993
2 changed files with 21 additions and 0 deletions

View File

@@ -32,6 +32,9 @@ export const TASK_VOTE_DETAIL = '/stu/task/vote/detail'
export const TASK_WORK_COMMIT = '/workSubmit/submitStudentWorkDetail post'
export const TASK_WORK_DETAIL = '/workSubmit/getWorkDetailByTaskId'
export const TASK_WORK_SUBMIT_LIST = '/workSubmit/queryWorkSubmitDetailById'
// 查询学员端是否导入了作业成绩
export const WhetherImportHomeWorkScore = '/admin/student/whetherImportHomeWorkScore post'
export const VOTE_DETAIL = '/queryVoteSubmitDetailById'
export const TASK_VOTE_LIST = '/queryVoteSubmitDetailListByTaskId'

View File

@@ -442,6 +442,7 @@ import {
TASK_WORK_COMMIT,
TASK_WORK_DETAIL,
TASK_WORK_SUBMIT_LIST,
WhetherImportHomeWorkScore,
WORK_HISTROY,
} from "@/api/api";
import dayjs from "dayjs";
@@ -489,6 +490,18 @@ const { data: submitList } = useRequest(TASK_WORK_SUBMIT_LIST, {
workerId: workId,
});
// 判断是否已经提交过成绩
const submitScore = ref(false);
request(WhetherImportHomeWorkScore,{
"workId": workId
}).then(res=>{
console.log('学员端是否导入过成绩查询', res)
submitScore.value = true;
}).catch(err=>{
console.log(err)
})
const open = () => {
centerDialogVisible.value = true;
};
@@ -498,6 +511,11 @@ const showFileList = computed(() => {
const handleClick = () => {
console.log(fileList.value, uploadRef.value);
if(submitScore.value){
ElMessage.warning("您的作业成绩已出,不能重复上传");
return
}
if (!sbValue.value.content) {
if (fileList.value.length === 0) {
return ElMessage.warning("请输入作业内容");