Untitled

mail@pastecode.io avatar
unknown
plain_text
2 years ago
785 B
2
Indexable
Never
function(typeQuestion,questionId,schoolId){
	console.log(typeQuestion)
        input = {
            quizType:typeQuestion,
            quiz:this.getQuizAnswer(typeQuestion),
            rsrQuizId:this.getRsrQuizId(typeQuestion),
            rsrSchoolId:this.schoolId,
        }
        let ew = this
	for(j=0;j<10;j++){
	console.log(j)
        $.ajax({
            url:'/store-point',
            type:'post',
            data:input,
            success: function(response){
		console.log(response)
                if(ew.quizRsrVideos!=typeQuestion && response){
                    ew.store(typeQuestion,-1,parseInt(response));
                    ew.sync();
                }
            },
            error: function(){

            }
        })
}
    }