Study/server/model/learning/request/knowledge_point.go

41 lines
1.3 KiB
Go

package request
import (
"github.com/flipped-aurora/gin-vue-admin/server/model/common/request"
"github.com/flipped-aurora/gin-vue-admin/server/model/learning"
)
type KnowledgePointSearch struct {
learning.KnowledgePoint
request.PageInfo
StartCreatedAt *string `json:"startCreatedAt" form:"startCreatedAt"`
EndCreatedAt *string `json:"endCreatedAt" form:"endCreatedAt"`
}
type KnowledgePointCreate struct {
ChapterId uint `json:"chapterId" binding:"required"`
Title string `json:"title" binding:"required"`
Content string `json:"content"`
VideoUrl string `json:"videoUrl"`
Attachments string `json:"attachments"`
Sort int `json:"sort"`
Duration int `json:"duration"`
Status string `json:"status"`
}
type KnowledgePointUpdate struct {
ID uint `json:"id" binding:"required"`
ChapterId uint `json:"chapterId" binding:"required"`
Title string `json:"title" binding:"required"`
Content string `json:"content"`
VideoUrl string `json:"videoUrl"`
Attachments string `json:"attachments"`
Sort int `json:"sort"`
Duration int `json:"duration"`
Status string `json:"status"`
}
type KnowledgePointsByChapterRequest struct {
ChapterId uint `json:"chapterId" form:"chapterId" binding:"required"`
}