Fix Organization Management dialog type errors

- Fix JSON key mismatch in Flutter models: change 'User' to 'user' in Member and JoinRequest fromJson
- Update backend userInfo to send displayName as *string (null when empty)
- Add json tags to database User struct for consistent lowercase keys
- Handle displayName nullability in backend handlers
This commit is contained in:
Leon Bösche
2026-01-24 02:30:15 +01:00
parent 273976a69e
commit c7e740e732
3 changed files with 25 additions and 15 deletions

View File

@@ -63,13 +63,13 @@ func (sa StringArray) Value() (driver.Value, error) {
}
type User struct {
ID uuid.UUID
Email string
Username string
DisplayName string
PasswordHash *string
CreatedAt time.Time
LastLoginAt *time.Time
ID uuid.UUID `json:"id"`
Email string `json:"email"`
Username string `json:"username"`
DisplayName string `json:"displayName"`
PasswordHash *string `json:"-"`
CreatedAt time.Time `json:"createdAt"`
LastLoginAt *time.Time `json:"lastLoginAt"`
}
type Credential struct {