|
|
@@ -26,17 +26,19 @@ type LearningQuestionDao struct {
|
|
|
|
|
|
// LearningQuestionColumns defines and stores column names for table learning_question.
|
|
|
type learningQuestionColumns struct {
|
|
|
- Id string // Id
|
|
|
- SkillId string // 技能 Id
|
|
|
- Name string // 题目名称
|
|
|
- Type string // 题型 1 单选 2 多选 3 判断
|
|
|
- Enable string // 是否启用
|
|
|
- Content string // 题目内容
|
|
|
- Explanation string // 题目解析
|
|
|
- OperateBy string // 操作人
|
|
|
- CreatedAt string // 创建时间
|
|
|
- UpdatedAt string // 更新时间
|
|
|
- DeletedAt string // 删除时间
|
|
|
+ Id string // Id
|
|
|
+ SkillId string // 技能 Id
|
|
|
+ Name string // 题目
|
|
|
+ NameImage string // 题目图片
|
|
|
+ Type string // 题型 1 单选 2 多选 3 判断
|
|
|
+ Enable string // 是否启用
|
|
|
+ Content string // 题目内容
|
|
|
+ Explanation string // 题目解析
|
|
|
+ ExplanationImage string // 题目解析图片
|
|
|
+ OperateBy string // 操作人
|
|
|
+ CreatedAt string // 创建时间
|
|
|
+ UpdatedAt string // 更新时间
|
|
|
+ DeletedAt string // 删除时间
|
|
|
}
|
|
|
|
|
|
var (
|
|
|
@@ -46,17 +48,19 @@ var (
|
|
|
DB: g.DB("default"),
|
|
|
Table: "learning_question",
|
|
|
Columns: learningQuestionColumns{
|
|
|
- Id: "Id",
|
|
|
- SkillId: "SkillId",
|
|
|
- Name: "Name",
|
|
|
- Type: "Type",
|
|
|
- Enable: "Enable",
|
|
|
- Content: "Content",
|
|
|
- Explanation: "Explanation",
|
|
|
- OperateBy: "OperateBy",
|
|
|
- CreatedAt: "CreatedAt",
|
|
|
- UpdatedAt: "UpdatedAt",
|
|
|
- DeletedAt: "DeletedAt",
|
|
|
+ Id: "Id",
|
|
|
+ SkillId: "SkillId",
|
|
|
+ Name: "Name",
|
|
|
+ NameImage: "NameImage",
|
|
|
+ Type: "Type",
|
|
|
+ Enable: "Enable",
|
|
|
+ Content: "Content",
|
|
|
+ Explanation: "Explanation",
|
|
|
+ ExplanationImage: "ExplanationImage",
|
|
|
+ OperateBy: "OperateBy",
|
|
|
+ CreatedAt: "CreatedAt",
|
|
|
+ UpdatedAt: "UpdatedAt",
|
|
|
+ DeletedAt: "DeletedAt",
|
|
|
},
|
|
|
}
|
|
|
)
|
|
|
@@ -68,17 +72,19 @@ func NewLearningQuestionDao(tenant string) LearningQuestionDao {
|
|
|
DB: g.DB(tenant),
|
|
|
Table: "learning_question",
|
|
|
Columns: learningQuestionColumns{
|
|
|
- Id: "Id",
|
|
|
- SkillId: "SkillId",
|
|
|
- Name: "Name",
|
|
|
- Type: "Type",
|
|
|
- Enable: "Enable",
|
|
|
- Content: "Content",
|
|
|
- Explanation: "Explanation",
|
|
|
- OperateBy: "OperateBy",
|
|
|
- CreatedAt: "CreatedAt",
|
|
|
- UpdatedAt: "UpdatedAt",
|
|
|
- DeletedAt: "DeletedAt",
|
|
|
+ Id: "Id",
|
|
|
+ SkillId: "SkillId",
|
|
|
+ Name: "Name",
|
|
|
+ NameImage: "NameImage",
|
|
|
+ Type: "Type",
|
|
|
+ Enable: "Enable",
|
|
|
+ Content: "Content",
|
|
|
+ Explanation: "Explanation",
|
|
|
+ ExplanationImage: "ExplanationImage",
|
|
|
+ OperateBy: "OperateBy",
|
|
|
+ CreatedAt: "CreatedAt",
|
|
|
+ UpdatedAt: "UpdatedAt",
|
|
|
+ DeletedAt: "DeletedAt",
|
|
|
},
|
|
|
}
|
|
|
return dao
|