Updating UserCircle points when completing a chore
This commit is contained in:
parent
13d6cfd7e7
commit
33801b5004
2 changed files with 17 additions and 7 deletions
|
@ -22,13 +22,15 @@ type CircleDetail struct {
|
|||
}
|
||||
|
||||
type UserCircle struct {
|
||||
ID int `json:"id" gorm:"primary_key"` // Unique identifier
|
||||
UserID int `json:"userId" gorm:"column:user_id"` // User ID
|
||||
CircleID int `json:"circleId" gorm:"column:circle_id"` // Circle ID
|
||||
Role string `json:"role" gorm:"column:role"` // Role
|
||||
IsActive bool `json:"isActive" gorm:"column:is_active;default:false"`
|
||||
CreatedAt time.Time `json:"createdAt" gorm:"column:created_at"` // Created at
|
||||
UpdatedAt time.Time `json:"updatedAt" gorm:"column:updated_at"` // Updated at
|
||||
ID int `json:"id" gorm:"primary_key"` // Unique identifier
|
||||
UserID int `json:"userId" gorm:"column:user_id"` // User ID
|
||||
CircleID int `json:"circleId" gorm:"column:circle_id"` // Circle ID
|
||||
Role string `json:"role" gorm:"column:role"` // Role
|
||||
IsActive bool `json:"isActive" gorm:"column:is_active;default:false"`
|
||||
CreatedAt time.Time `json:"createdAt" gorm:"column:created_at"` // Created at
|
||||
UpdatedAt time.Time `json:"updatedAt" gorm:"column:updated_at"` // Updated at
|
||||
Points int `json:"points" gorm:"column:points;default:0;not null"` // Points
|
||||
PointsRedeemed int `json:"pointsRedeemed" gorm:"column:points_redeemed;default:0;not null"` // Points Redeemed
|
||||
}
|
||||
|
||||
type UserCircleDetail struct {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue