feat; 试卷考试排行榜

This commit is contained in:
杨航
2025-08-27 19:07:49 +08:00
parent ef2a95e368
commit 7d477ffcbc
2 changed files with 27 additions and 5 deletions
+9 -1
View File
@@ -63,5 +63,13 @@ export const queryCrsExamScore = (data) => {
};
// 试卷考试 排行榜
export const queryCrsExamScore = (data) => {
return request({
url: base_url + '/traExamPapers/queryPaperExamRankingList',
method: 'post',
toastErrors: true,
data
});
};
+18 -4
View File
@@ -61,25 +61,39 @@
<script>
import { queryTraCrsRankingList } from "@/api/courseDetail.js"
import { queryCrsExamScore } from "@/api/examination.js"
import common from '@/common/common'
export default {
data() {
return {
crsId:'',
crsId: '',
papersId : '',
userList: [],
userRankObj:{}
}
},
onLoad(params){
this.crsId = params.crsId
this.getList()
this.crsId = params.crsId || ''
this.papersId = params.papersId || ''
if(this.crsId){
this.getList()
}else{
this.getExamList()
}
},
methods: {
getList(){
queryTraCrsRankingList({
crsId: this.crsId
}).then(res=>{
console.log(res)
this.userList = res.body.rankingListVos||[]
this.userRankObj = res.body
})
},
getExamList(){
queryCrsExamScore({
papersId : this.papersId
}).then(res=>{
this.userList = res.body.rankingListVos||[]
this.userRankObj = res.body
})