diff options
Diffstat (limited to 'api/internal/models')
-rw-r--r-- | api/internal/models/auth.go | 2 | ||||
-rw-r--r-- | api/internal/models/preferences.go | 8 | ||||
-rw-r--r-- | api/internal/models/statistics.go | 2 | ||||
-rw-r--r-- | api/internal/models/user.go | 2 |
4 files changed, 7 insertions, 7 deletions
diff --git a/api/internal/models/auth.go b/api/internal/models/auth.go index 41344d5..fa7dbe4 100644 --- a/api/internal/models/auth.go +++ b/api/internal/models/auth.go | |||
@@ -3,7 +3,7 @@ package models | |||
3 | import "time" | 3 | import "time" |
4 | 4 | ||
5 | type Token struct { | 5 | type Token struct { |
6 | ID int64 `json:"-"` | 6 | ID int64 `json:"id"` |
7 | UserID int64 `json:"user_id"` | 7 | UserID int64 `json:"user_id"` |
8 | Token string `json:"token"` | 8 | Token string `json:"token"` |
9 | CreatedAt time.Time `json:"created_at"` | 9 | CreatedAt time.Time `json:"created_at"` |
diff --git a/api/internal/models/preferences.go b/api/internal/models/preferences.go index cbbd47c..8022099 100644 --- a/api/internal/models/preferences.go +++ b/api/internal/models/preferences.go | |||
@@ -1,14 +1,14 @@ | |||
1 | package models | 1 | package models |
2 | 2 | ||
3 | type Preference struct { | 3 | type Preference struct { |
4 | ID int64 `json:"-"` | 4 | ID int64 `json:"id"` |
5 | Color string `json:"color"` | 5 | Color string `json:"color"` |
6 | UserID int64 `json:"-"` | 6 | UserID int64 `json:"user_id"` |
7 | Size Size `json:"size"` | 7 | SizeID int64 `json:"size_id"` |
8 | } | 8 | } |
9 | 9 | ||
10 | type Size struct { | 10 | type Size struct { |
11 | ID int64 `json:"-"` | 11 | ID int64 `json:"id"` |
12 | Size int64 `json:"size"` | 12 | Size int64 `json:"size"` |
13 | Unit string `json:"unit"` | 13 | Unit string `json:"unit"` |
14 | } | 14 | } |
diff --git a/api/internal/models/statistics.go b/api/internal/models/statistics.go index 457e6a0..7dceb3a 100644 --- a/api/internal/models/statistics.go +++ b/api/internal/models/statistics.go | |||
@@ -3,7 +3,7 @@ package models | |||
3 | import "time" | 3 | import "time" |
4 | 4 | ||
5 | type Statistic struct { | 5 | type Statistic struct { |
6 | ID int64 `json:"-"` | 6 | ID int64 `json:"id"` |
7 | Date time.Time `json:"date"` | 7 | Date time.Time `json:"date"` |
8 | User User `json:"user"` | 8 | User User `json:"user"` |
9 | Quantity int `json:"quantity"` | 9 | Quantity int `json:"quantity"` |
diff --git a/api/internal/models/user.go b/api/internal/models/user.go index 2a3e6fd..ca5daa4 100644 --- a/api/internal/models/user.go +++ b/api/internal/models/user.go | |||
@@ -3,7 +3,7 @@ package models | |||
3 | import "github.com/google/uuid" | 3 | import "github.com/google/uuid" |
4 | 4 | ||
5 | type User struct { | 5 | type User struct { |
6 | ID int64 `json:"-"` | 6 | ID int64 `json:"id"` |
7 | Name string `json:"name"` | 7 | Name string `json:"name"` |
8 | UUID uuid.UUID `json:"uuid"` | 8 | UUID uuid.UUID `json:"uuid"` |
9 | Password string `json:"-"` | 9 | Password string `json:"-"` |