mirror of
https://github.com/immich-app/immich
synced 2025-10-17 18:19:27 +00:00
feat(server): user preferences (#9736)
* refactor(server): user endpoints * feat(server): user preferences * mobile: user preference * wording --------- Co-authored-by: Alex <alex.tran1502@gmail.com>
This commit is contained in:
parent
1f9158c545
commit
0fc6d69824
39 changed files with 1392 additions and 327 deletions
19
mobile/openapi/lib/model/user_admin_create_dto.dart
generated
19
mobile/openapi/lib/model/user_admin_create_dto.dart
generated
|
|
@ -14,7 +14,6 @@ class UserAdminCreateDto {
|
|||
/// Returns a new [UserAdminCreateDto] instance.
|
||||
UserAdminCreateDto({
|
||||
required this.email,
|
||||
this.memoriesEnabled,
|
||||
required this.name,
|
||||
this.notify,
|
||||
required this.password,
|
||||
|
|
@ -25,14 +24,6 @@ class UserAdminCreateDto {
|
|||
|
||||
String email;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
bool? memoriesEnabled;
|
||||
|
||||
String name;
|
||||
|
||||
///
|
||||
|
|
@ -61,7 +52,6 @@ class UserAdminCreateDto {
|
|||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is UserAdminCreateDto &&
|
||||
other.email == email &&
|
||||
other.memoriesEnabled == memoriesEnabled &&
|
||||
other.name == name &&
|
||||
other.notify == notify &&
|
||||
other.password == password &&
|
||||
|
|
@ -73,7 +63,6 @@ class UserAdminCreateDto {
|
|||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(email.hashCode) +
|
||||
(memoriesEnabled == null ? 0 : memoriesEnabled!.hashCode) +
|
||||
(name.hashCode) +
|
||||
(notify == null ? 0 : notify!.hashCode) +
|
||||
(password.hashCode) +
|
||||
|
|
@ -82,16 +71,11 @@ class UserAdminCreateDto {
|
|||
(storageLabel == null ? 0 : storageLabel!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'UserAdminCreateDto[email=$email, memoriesEnabled=$memoriesEnabled, name=$name, notify=$notify, password=$password, quotaSizeInBytes=$quotaSizeInBytes, shouldChangePassword=$shouldChangePassword, storageLabel=$storageLabel]';
|
||||
String toString() => 'UserAdminCreateDto[email=$email, name=$name, notify=$notify, password=$password, quotaSizeInBytes=$quotaSizeInBytes, shouldChangePassword=$shouldChangePassword, storageLabel=$storageLabel]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'email'] = this.email;
|
||||
if (this.memoriesEnabled != null) {
|
||||
json[r'memoriesEnabled'] = this.memoriesEnabled;
|
||||
} else {
|
||||
// json[r'memoriesEnabled'] = null;
|
||||
}
|
||||
json[r'name'] = this.name;
|
||||
if (this.notify != null) {
|
||||
json[r'notify'] = this.notify;
|
||||
|
|
@ -126,7 +110,6 @@ class UserAdminCreateDto {
|
|||
|
||||
return UserAdminCreateDto(
|
||||
email: mapValueOfType<String>(json, r'email')!,
|
||||
memoriesEnabled: mapValueOfType<bool>(json, r'memoriesEnabled'),
|
||||
name: mapValueOfType<String>(json, r'name')!,
|
||||
notify: mapValueOfType<bool>(json, r'notify'),
|
||||
password: mapValueOfType<String>(json, r'password')!,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue