Gold
This commit is contained in:
@@ -9,6 +9,7 @@ import (
|
||||
|
||||
type User struct {
|
||||
ID int `json:"id" gorm:"primary_key"`
|
||||
Gold int `json:"gold"`
|
||||
Name string `json:"name"`
|
||||
Email string `json:"email" gorm:"unique;not null"`
|
||||
Password string `json:"-"`
|
||||
|
@@ -11,6 +11,7 @@ import (
|
||||
|
||||
type Account struct {
|
||||
ID int `json:"id"`
|
||||
Gold int `json:"gold"`
|
||||
Name string `json:"name"`
|
||||
Email string `json:"email"`
|
||||
Admin bool `json:"admin"`
|
||||
@@ -87,6 +88,7 @@ func AccountRead(w http.ResponseWriter, r *http.Request, cb func(account *Accoun
|
||||
|
||||
var account Account
|
||||
account.ID = user.ID
|
||||
account.Gold = user.Gold
|
||||
account.Name = user.Name
|
||||
account.Email = user.Email
|
||||
account.Admin = user.Admin
|
||||
|
Reference in New Issue
Block a user