learning_material.go 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. // ==========================================================================
  2. // This is auto-generated by gf cli tool. Fill this file as you wish.
  3. // ==========================================================================
  4. package learning
  5. import (
  6. "lims_adapter/model"
  7. "lims_adapter/model/learning/internal"
  8. )
  9. // LearningMaterial is the golang structure for table learning_material.
  10. type LearningMaterial internal.LearningMaterial
  11. // Fill with you ideas below.
  12. type LearningMaterialListReq struct {
  13. Page *model.Page `json:"page"`
  14. OrderBy *model.OrderBy `json:"orderBy"`
  15. SkillId int `json:"skillId"`
  16. Name string `json:"name"`
  17. }
  18. type LearningMaterialGetReq struct {
  19. Id int `json:"id"` // 资料Id
  20. Name string `json:"name"` // 资料名称
  21. }
  22. type LearningMaterialGetRsp struct {
  23. LearningMaterial
  24. File []*LearningMaterialFile `json:"file"`
  25. }
  26. type LearningMaterialAddReqFile struct {
  27. Name string `json:"name"` // 文件名
  28. Url string `json:"url"` // 文件地址
  29. Size string `json:"size"` // 文件大小
  30. Extend string `json:"extend"` // 文件扩展名
  31. }
  32. type LearningMaterialAddReq struct {
  33. SkillId int `json:"skillId" v:"required#请输入技能Id"` // 技能 Id
  34. Name string `json:"name" v:"required#请输入资料名称"` // 资料名称
  35. Type int `json:"type" v:"required#请输入资料类型 in:1,2#请输入正确的资料类型"` // 资料类型 1 资料 2 视频
  36. SortNo int `json:"sortNo"` // 排序
  37. Enable int `json:"enable" v:"in:0,1#请输入正确的启用类型"` // 是否启用
  38. Content string `json:"content"` // 资料内容
  39. File []*LearningMaterialAddReqFile `json:"file"` // 附件
  40. }
  41. type LearningMaterialUpdateReq struct {
  42. Id int `json:"id" v:"required#请输入资料Id"` // Id
  43. SkillId int `json:"skillId"` // 技能 Id
  44. Name string `json:"name"` // 资料名称
  45. Type *int `json:"type" v:"in:1,2#请输入正确的资料类型"` // 资料类型 1 资料 2 视频
  46. SortNo *int `json:"sortNo"` // 排序
  47. Enable *int `json:"enable" v:"in:0,1#请输入正确的启用类型"` // 是否启用
  48. Content string `json:"content"` // 资料内容
  49. File []*LearningMaterialAddReqFile `json:"file"` // 附件
  50. }
  51. type LearningMaterialDeleteReq struct {
  52. Id int `json:"id" v:"required#请输入资料Id"`
  53. }