package commonApi

type CommonStrId struct {
	ID string `json:"id" v:"required#缺失ID"`
}

type CommonIntId struct {
	ID uint `json:"id" v:"required#缺失ID"`
}

type CommonPageReq struct {
	Current  int `json:"current" v:"required#当前页数不能为空" dc:"页数"`
	PageSize int `json:"pageSize" v:"required|in:5,10,15,20,50,100#页码不能为空|页码数量不正确" dc:"页码"`
}

type CommonPageRes[T any] struct {
	Total int `json:"total"`
	CommonDataRes[T]
}

type CommonDataRes[T any] struct {
	List []T `json:"list"`
}

type Author struct {
	Authorization string `p:"Authorization" in:"header" dc:"Bearer {{token}}"`
}
