Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Memo ¶
type Memo struct { Id string `json:"Id" binding:"" bson:"_id"` Subject string `json:"Subject" binding:"required"` Description string `json:"Description" binding:""` UserId string `json:"UserId" binding:"required"` MonthDay int `json:"MonthDay" binding:"required"` StartYear int `json:"StartYear" binding:""` Lunar bool `json:"Lunar" binding:""` //user care about chinese Lunar only if checked CreateTime string `json:"CreateTime,omitempty"` LastModifiedTime string `json:"LastModifiedTime,omitempty"` }
func (*Memo) ToResponse ¶
func (memo *Memo) ToResponse(now *time.Time) *MemoResponse
type MemoRequest ¶
type MemoResponse ¶
type MemoResponse struct { Id string `json:"Id" binding:""` UserId string `json:"UserId" binding:"required"` Subject string `json:"Subject" binding:"required"` Description string `json:"Description" binding:""` MonthDay int `json:"MonthDay" binding:"required"` StartYear int `json:"StartYear" binding:""` Lunar bool `json:"Lunar" binding:""` Distance []int `json:"Distance" binding:"required"` CreateTime string `json:"CreateTime,omitempty"` // - TODO convert to formated datetime LastModifiedTime string `json:"LastModifiedTime,omitempty"` // - TODO convert to formated datetime }
Click to show internal directories.
Click to hide internal directories.