feat: implement wish list and wish features including creation, retrieval, and updates;
fix: modify ban logic to respect expiration timestamps and pardon flags; refactor: change boolean fields to non-nullable in models and use COALESCE for optional updates in SQL
This commit is contained in:
@@ -15,7 +15,7 @@ type BannedUser struct {
|
||||
Reason *string
|
||||
ExpiresAt pgtype.Timestamp
|
||||
BannedBy *string
|
||||
Pardoned *bool
|
||||
Pardoned bool
|
||||
PardonedBy *string
|
||||
}
|
||||
|
||||
@@ -25,8 +25,8 @@ type ConfirmationCode struct {
|
||||
CodeType int32
|
||||
CodeHash string
|
||||
ExpiresAt pgtype.Timestamp
|
||||
Used *bool
|
||||
Deleted *bool
|
||||
Used bool
|
||||
Deleted bool
|
||||
}
|
||||
|
||||
type LoginInformation struct {
|
||||
@@ -78,8 +78,34 @@ type Session struct {
|
||||
type User struct {
|
||||
ID int64
|
||||
Username string
|
||||
Verified *bool
|
||||
Verified bool
|
||||
RegistrationDate pgtype.Timestamp
|
||||
Role int32
|
||||
Deleted *bool
|
||||
}
|
||||
|
||||
type Wish struct {
|
||||
ID int64
|
||||
Guid pgtype.UUID
|
||||
WishListID int64
|
||||
Name string
|
||||
Description string
|
||||
PictureUrl string
|
||||
Stars int16
|
||||
CreationDate pgtype.Timestamp
|
||||
Fulfilled bool
|
||||
FulfilledDate pgtype.Timestamp
|
||||
Deleted bool
|
||||
}
|
||||
|
||||
type WishList struct {
|
||||
ID int64
|
||||
Guid pgtype.UUID
|
||||
ProfileID int64
|
||||
Hidden bool
|
||||
Name string
|
||||
IconName *string
|
||||
Color *string
|
||||
ColorGrad *string
|
||||
Deleted bool
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user