bugfix
This commit is contained in:
parent
36d9572bea
commit
9964ab1ca0
@ -13,7 +13,54 @@ bricks.QAFrame = class extends bricks.VBox {
|
||||
timeout:
|
||||
}
|
||||
timeout:0 no timeout, number in seconds
|
||||
|
||||
"accept data type"
|
||||
1:
|
||||
type:courseware:
|
||||
data:{
|
||||
type:
|
||||
url:
|
||||
}
|
||||
2:
|
||||
type:ask_ready
|
||||
data:{
|
||||
total_q
|
||||
cur_q
|
||||
}
|
||||
3:
|
||||
type:question
|
||||
data: {
|
||||
q_desc:
|
||||
total_q:
|
||||
cur_q
|
||||
}
|
||||
4:
|
||||
type:result
|
||||
data: {
|
||||
total_q:
|
||||
correct_cnt:
|
||||
error_cnt
|
||||
}
|
||||
5:
|
||||
type:error_list,
|
||||
data: {
|
||||
error_cnt,
|
||||
rows:[
|
||||
{
|
||||
pos:
|
||||
q_desc:
|
||||
your_a:
|
||||
corrent_a:
|
||||
error_desc:
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
send message:
|
||||
1:
|
||||
type: qa_start
|
||||
data:null
|
||||
|
||||
2:
|
||||
}
|
||||
*/
|
||||
constructor(opts){
|
||||
@ -38,6 +85,9 @@ bricks.QAFrame = class extends bricks.VBox {
|
||||
this.ws.bind('onopen', this.start_question_answer.bind(this));
|
||||
this.ws.bind('onquestion', this.show_question.bind(this));
|
||||
this.ws.bind('oncourseware', this.show_courseware.bind(this));
|
||||
this.ws.bind('onask_start', this.show_courseware.bind(this));
|
||||
this.ws.bind('oncourseware', this.show_courseware.bind(this));
|
||||
this.ws.bind('oncourseware', this.show_courseware.bind(this));
|
||||
if (this.courseware){
|
||||
this.play_course();
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user