Write and read language setting from backend
This commit is contained in:
@@ -19,6 +19,7 @@ type User struct {
|
||||
Name string `json:"name"`
|
||||
Vehicles []Vehicle `gorm:"many2many:user_vehicles;" json:"vehicles"`
|
||||
IsDisabled bool `json:"isDisabled"`
|
||||
Language string `json:"language"`
|
||||
}
|
||||
|
||||
func (b *User) MarshalJSON() ([]byte, error) {
|
||||
|
||||
@@ -29,7 +29,7 @@ var migrations = []localMigration{
|
||||
},
|
||||
{
|
||||
Name: "2023_02_26_13_42_AddLanguage",
|
||||
Query: "ALTER TABLE users ADD COLUMN language text default 'English'",
|
||||
Query: "ALTER TABLE users ADD COLUMN language text default 'English 🇬🇧'",
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user