|
@@ -7,14 +7,14 @@ import (
|
|
|
)
|
|
|
|
|
|
type ExeamLog struct {
|
|
|
- Id primitive.ObjectID `bson:"_id,omitempty" json:"_id"`
|
|
|
- Cid string `bson:"cid,omitempty" json:"cid"` // 分类id
|
|
|
- Uid string `bson:"uid,omitempty" json:"uid"` // 用户id
|
|
|
- Type string `bson:"type,omitempty" json:"type"` // 考核类型: 理论/实操
|
|
|
- Correct *int `bson:"correct,omitempty" json:"correct"` // 正确题目数
|
|
|
- Error *int `bson:"error,omitempty" json:"error"` // 错误题目数
|
|
|
- TotalScore *int `bson:"totalScore,omitempty" json:"totalScore"` // 总分
|
|
|
- ExeamRecord []*Record `bson:"exeamRecord,omitempty" json:"exeamRecord"` // 答题记录
|
|
|
+ Id primitive.ObjectID `bson:"_id,omitempty" json:"_id"`
|
|
|
+ Cid string `bson:"cid,omitempty" json:"cid"` // 分类id
|
|
|
+ Uid string `bson:"uid,omitempty" json:"uid"` // 用户id
|
|
|
+ Type string `bson:"type,omitempty" json:"type"` // 考核类型: 理论/实操
|
|
|
+ Correct *int `bson:"correct,omitempty" json:"correct"` // 正确题目数
|
|
|
+ Error *int `bson:"error,omitempty" json:"error"` // 错误题目数
|
|
|
+ TotalScore *int `bson:"totalScore,omitempty" json:"totalScore"` // 总分
|
|
|
+ ExeamResult map[string][]*TestRecord `bson:"exeamResult,omitempty" json:"exeamResult"` // 考核结果/ choiceQuestion:[{}] judgeQuestion:[{}]
|
|
|
// 成绩
|
|
|
Score *int `bson:"socre,omitempty" json:"socre"` // 分数
|
|
|
CompleteRate *int `bson:"completeRate,omitempty" json:"completeRate"` // 完成进度
|
|
@@ -22,7 +22,7 @@ type ExeamLog struct {
|
|
|
UpdateTime time.Time `bson:"updateTime,omitempty" json:"updateTime"`
|
|
|
}
|
|
|
|
|
|
-type Record struct {
|
|
|
- QuestionId string `bson:"questionId,omitempty" json:"questionId"` // 题目id
|
|
|
- Answer string `bson:"answer,omitempty" json:"answer"` // 答案
|
|
|
+type TestRecord struct {
|
|
|
+ Test
|
|
|
+ ExeamAnswer string `bson:"exeamAnswer,omitempty" json:"exeamAnswer"` // 答案
|
|
|
}
|