mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-13 04:46:44 +08:00
考试接口添加参数
This commit is contained in:
@@ -97,8 +97,8 @@ const studyInfo = function(courseId) {
|
|||||||
* @param {Object} studyId
|
* @param {Object} studyId
|
||||||
* @param {Object} contentId
|
* @param {Object} contentId
|
||||||
*/
|
*/
|
||||||
const getStudyContentItem = function(studyId,contentId) {
|
const getStudyContentItem = function(studyId,contentId,contentTotal) {
|
||||||
return ajax.post('/xboe/school/study/course/study-course-content',{studyId,contentId});
|
return ajax.post('/xboe/school/study/course/study-course-content',{studyId,contentId,contentTotal});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -152,6 +152,10 @@ export default {
|
|||||||
showTest:{
|
showTest:{
|
||||||
type:Boolean,
|
type:Boolean,
|
||||||
default:false
|
default:false
|
||||||
|
},
|
||||||
|
contentTotal:{
|
||||||
|
type:Number,
|
||||||
|
default:0
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
@@ -249,7 +253,7 @@ export default {
|
|||||||
},
|
},
|
||||||
loadStudyItemId(){
|
loadStudyItemId(){
|
||||||
//获取studyItemId;
|
//获取studyItemId;
|
||||||
apiStudy.getStudyContentItem(this.studyId,this.info.contentId).then(rs=>{
|
apiStudy.getStudyContentItem(this.studyId,this.info.contentId,this.contentTotal).then(rs=>{
|
||||||
if(rs.status==200){
|
if(rs.status==200){
|
||||||
this.examScore=rs.result.score;
|
this.examScore=rs.result.score;
|
||||||
this.studyItemId=rs.result.id;
|
this.studyItemId=rs.result.id;
|
||||||
|
|||||||
@@ -102,7 +102,7 @@
|
|||||||
<homework @submit="homeWorkSubmit" v-if="resType == 60 && studyId != ''" :studyId="studyId" :content="contentData"></homework>
|
<homework @submit="homeWorkSubmit" v-if="resType == 60 && studyId != ''" :studyId="studyId" :content="contentData"></homework>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="resType == 61">
|
<div v-if="resType == 61">
|
||||||
<exam @startTest="startTest" v-if="resType == 61 && studyId != '' " :studyId="studyId" :content="contentData"></exam>
|
<exam :contentTotal="totalContent" @startTest="startTest" v-if="resType == 61 && studyId != '' " :studyId="studyId" :content="contentData"></exam>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="resType == 62" style="padding:5px">
|
<div v-if="resType == 62" style="padding:5px">
|
||||||
<assess v-if="resType == 62 && studyId != '' && contentData.id" :studyId="studyId" :content="contentData">
|
<assess v-if="resType == 62 && studyId != '' && contentData.id" :studyId="studyId" :content="contentData">
|
||||||
|
|||||||
Reference in New Issue
Block a user