feat(profile): some fixes, add buttons

This commit is contained in:
mso7nueh
2024-09-04 17:27:46 +03:00
parent d76f535663
commit f9c10047b2
154 changed files with 1249 additions and 296 deletions

View File

@@ -41,17 +41,17 @@ class User with _$User {
@JsonKey(name: "id") required int id,
@JsonKey(name: "name") required String name,
@JsonKey(name: "email") required String email,
@JsonKey(name: "email_verified_at") required DateTime emailVerifiedAt,
@JsonKey(name: "email_verified_at") required dynamic emailVerifiedAt,
@JsonKey(name: "two_factor_confirmed_at") required dynamic twoFactorConfirmedAt,
@JsonKey(name: "current_team_id") required dynamic currentTeamId,
@JsonKey(name: "profile_photo_path") required String profilePhotoPath,
@JsonKey(name: "profile_photo_path") String? profilePhotoPath,
@JsonKey(name: "created_at") required DateTime createdAt,
@JsonKey(name: "updated_at") required DateTime updatedAt,
@JsonKey(name: "is_consultant") required int isConsultant,
@JsonKey(name: "is_public_profile") required int isPublicProfile,
@JsonKey(name: "slug") required String slug,
@JsonKey(name: "user_settings_id") required dynamic userSettingsId,
@JsonKey(name: "profile_photo_url") required String profilePhotoUrl,
@JsonKey(name: "profile_photo_url") String? profilePhotoUrl,
@JsonKey(name: "detailz") required UserDetails detailz,
}) = _User;

View File

@@ -776,13 +776,13 @@ mixin _$User {
@JsonKey(name: "email")
String get email => throw _privateConstructorUsedError;
@JsonKey(name: "email_verified_at")
DateTime get emailVerifiedAt => throw _privateConstructorUsedError;
dynamic get emailVerifiedAt => throw _privateConstructorUsedError;
@JsonKey(name: "two_factor_confirmed_at")
dynamic get twoFactorConfirmedAt => throw _privateConstructorUsedError;
@JsonKey(name: "current_team_id")
dynamic get currentTeamId => throw _privateConstructorUsedError;
@JsonKey(name: "profile_photo_path")
String get profilePhotoPath => throw _privateConstructorUsedError;
String? get profilePhotoPath => throw _privateConstructorUsedError;
@JsonKey(name: "created_at")
DateTime get createdAt => throw _privateConstructorUsedError;
@JsonKey(name: "updated_at")
@@ -796,7 +796,7 @@ mixin _$User {
@JsonKey(name: "user_settings_id")
dynamic get userSettingsId => throw _privateConstructorUsedError;
@JsonKey(name: "profile_photo_url")
String get profilePhotoUrl => throw _privateConstructorUsedError;
String? get profilePhotoUrl => throw _privateConstructorUsedError;
@JsonKey(name: "detailz")
UserDetails get detailz => throw _privateConstructorUsedError;
@@ -814,17 +814,17 @@ abstract class $UserCopyWith<$Res> {
{@JsonKey(name: "id") int id,
@JsonKey(name: "name") String name,
@JsonKey(name: "email") String email,
@JsonKey(name: "email_verified_at") DateTime emailVerifiedAt,
@JsonKey(name: "email_verified_at") dynamic emailVerifiedAt,
@JsonKey(name: "two_factor_confirmed_at") dynamic twoFactorConfirmedAt,
@JsonKey(name: "current_team_id") dynamic currentTeamId,
@JsonKey(name: "profile_photo_path") String profilePhotoPath,
@JsonKey(name: "profile_photo_path") String? profilePhotoPath,
@JsonKey(name: "created_at") DateTime createdAt,
@JsonKey(name: "updated_at") DateTime updatedAt,
@JsonKey(name: "is_consultant") int isConsultant,
@JsonKey(name: "is_public_profile") int isPublicProfile,
@JsonKey(name: "slug") String slug,
@JsonKey(name: "user_settings_id") dynamic userSettingsId,
@JsonKey(name: "profile_photo_url") String profilePhotoUrl,
@JsonKey(name: "profile_photo_url") String? profilePhotoUrl,
@JsonKey(name: "detailz") UserDetails detailz});
$UserDetailsCopyWith<$Res> get detailz;
@@ -846,17 +846,17 @@ class _$UserCopyWithImpl<$Res, $Val extends User>
Object? id = null,
Object? name = null,
Object? email = null,
Object? emailVerifiedAt = null,
Object? emailVerifiedAt = freezed,
Object? twoFactorConfirmedAt = freezed,
Object? currentTeamId = freezed,
Object? profilePhotoPath = null,
Object? profilePhotoPath = freezed,
Object? createdAt = null,
Object? updatedAt = null,
Object? isConsultant = null,
Object? isPublicProfile = null,
Object? slug = null,
Object? userSettingsId = freezed,
Object? profilePhotoUrl = null,
Object? profilePhotoUrl = freezed,
Object? detailz = null,
}) {
return _then(_value.copyWith(
@@ -872,10 +872,10 @@ class _$UserCopyWithImpl<$Res, $Val extends User>
? _value.email
: email // ignore: cast_nullable_to_non_nullable
as String,
emailVerifiedAt: null == emailVerifiedAt
emailVerifiedAt: freezed == emailVerifiedAt
? _value.emailVerifiedAt
: emailVerifiedAt // ignore: cast_nullable_to_non_nullable
as DateTime,
as dynamic,
twoFactorConfirmedAt: freezed == twoFactorConfirmedAt
? _value.twoFactorConfirmedAt
: twoFactorConfirmedAt // ignore: cast_nullable_to_non_nullable
@@ -884,10 +884,10 @@ class _$UserCopyWithImpl<$Res, $Val extends User>
? _value.currentTeamId
: currentTeamId // ignore: cast_nullable_to_non_nullable
as dynamic,
profilePhotoPath: null == profilePhotoPath
profilePhotoPath: freezed == profilePhotoPath
? _value.profilePhotoPath
: profilePhotoPath // ignore: cast_nullable_to_non_nullable
as String,
as String?,
createdAt: null == createdAt
? _value.createdAt
: createdAt // ignore: cast_nullable_to_non_nullable
@@ -912,10 +912,10 @@ class _$UserCopyWithImpl<$Res, $Val extends User>
? _value.userSettingsId
: userSettingsId // ignore: cast_nullable_to_non_nullable
as dynamic,
profilePhotoUrl: null == profilePhotoUrl
profilePhotoUrl: freezed == profilePhotoUrl
? _value.profilePhotoUrl
: profilePhotoUrl // ignore: cast_nullable_to_non_nullable
as String,
as String?,
detailz: null == detailz
? _value.detailz
: detailz // ignore: cast_nullable_to_non_nullable
@@ -943,17 +943,17 @@ abstract class _$$UserImplCopyWith<$Res> implements $UserCopyWith<$Res> {
{@JsonKey(name: "id") int id,
@JsonKey(name: "name") String name,
@JsonKey(name: "email") String email,
@JsonKey(name: "email_verified_at") DateTime emailVerifiedAt,
@JsonKey(name: "email_verified_at") dynamic emailVerifiedAt,
@JsonKey(name: "two_factor_confirmed_at") dynamic twoFactorConfirmedAt,
@JsonKey(name: "current_team_id") dynamic currentTeamId,
@JsonKey(name: "profile_photo_path") String profilePhotoPath,
@JsonKey(name: "profile_photo_path") String? profilePhotoPath,
@JsonKey(name: "created_at") DateTime createdAt,
@JsonKey(name: "updated_at") DateTime updatedAt,
@JsonKey(name: "is_consultant") int isConsultant,
@JsonKey(name: "is_public_profile") int isPublicProfile,
@JsonKey(name: "slug") String slug,
@JsonKey(name: "user_settings_id") dynamic userSettingsId,
@JsonKey(name: "profile_photo_url") String profilePhotoUrl,
@JsonKey(name: "profile_photo_url") String? profilePhotoUrl,
@JsonKey(name: "detailz") UserDetails detailz});
@override
@@ -973,17 +973,17 @@ class __$$UserImplCopyWithImpl<$Res>
Object? id = null,
Object? name = null,
Object? email = null,
Object? emailVerifiedAt = null,
Object? emailVerifiedAt = freezed,
Object? twoFactorConfirmedAt = freezed,
Object? currentTeamId = freezed,
Object? profilePhotoPath = null,
Object? profilePhotoPath = freezed,
Object? createdAt = null,
Object? updatedAt = null,
Object? isConsultant = null,
Object? isPublicProfile = null,
Object? slug = null,
Object? userSettingsId = freezed,
Object? profilePhotoUrl = null,
Object? profilePhotoUrl = freezed,
Object? detailz = null,
}) {
return _then(_$UserImpl(
@@ -999,10 +999,10 @@ class __$$UserImplCopyWithImpl<$Res>
? _value.email
: email // ignore: cast_nullable_to_non_nullable
as String,
emailVerifiedAt: null == emailVerifiedAt
emailVerifiedAt: freezed == emailVerifiedAt
? _value.emailVerifiedAt
: emailVerifiedAt // ignore: cast_nullable_to_non_nullable
as DateTime,
as dynamic,
twoFactorConfirmedAt: freezed == twoFactorConfirmedAt
? _value.twoFactorConfirmedAt
: twoFactorConfirmedAt // ignore: cast_nullable_to_non_nullable
@@ -1011,10 +1011,10 @@ class __$$UserImplCopyWithImpl<$Res>
? _value.currentTeamId
: currentTeamId // ignore: cast_nullable_to_non_nullable
as dynamic,
profilePhotoPath: null == profilePhotoPath
profilePhotoPath: freezed == profilePhotoPath
? _value.profilePhotoPath
: profilePhotoPath // ignore: cast_nullable_to_non_nullable
as String,
as String?,
createdAt: null == createdAt
? _value.createdAt
: createdAt // ignore: cast_nullable_to_non_nullable
@@ -1039,10 +1039,10 @@ class __$$UserImplCopyWithImpl<$Res>
? _value.userSettingsId
: userSettingsId // ignore: cast_nullable_to_non_nullable
as dynamic,
profilePhotoUrl: null == profilePhotoUrl
profilePhotoUrl: freezed == profilePhotoUrl
? _value.profilePhotoUrl
: profilePhotoUrl // ignore: cast_nullable_to_non_nullable
as String,
as String?,
detailz: null == detailz
? _value.detailz
: detailz // ignore: cast_nullable_to_non_nullable
@@ -1062,14 +1062,14 @@ class _$UserImpl implements _User {
@JsonKey(name: "two_factor_confirmed_at")
required this.twoFactorConfirmedAt,
@JsonKey(name: "current_team_id") required this.currentTeamId,
@JsonKey(name: "profile_photo_path") required this.profilePhotoPath,
@JsonKey(name: "profile_photo_path") this.profilePhotoPath,
@JsonKey(name: "created_at") required this.createdAt,
@JsonKey(name: "updated_at") required this.updatedAt,
@JsonKey(name: "is_consultant") required this.isConsultant,
@JsonKey(name: "is_public_profile") required this.isPublicProfile,
@JsonKey(name: "slug") required this.slug,
@JsonKey(name: "user_settings_id") required this.userSettingsId,
@JsonKey(name: "profile_photo_url") required this.profilePhotoUrl,
@JsonKey(name: "profile_photo_url") this.profilePhotoUrl,
@JsonKey(name: "detailz") required this.detailz});
factory _$UserImpl.fromJson(Map<String, dynamic> json) =>
@@ -1086,7 +1086,7 @@ class _$UserImpl implements _User {
final String email;
@override
@JsonKey(name: "email_verified_at")
final DateTime emailVerifiedAt;
final dynamic emailVerifiedAt;
@override
@JsonKey(name: "two_factor_confirmed_at")
final dynamic twoFactorConfirmedAt;
@@ -1095,7 +1095,7 @@ class _$UserImpl implements _User {
final dynamic currentTeamId;
@override
@JsonKey(name: "profile_photo_path")
final String profilePhotoPath;
final String? profilePhotoPath;
@override
@JsonKey(name: "created_at")
final DateTime createdAt;
@@ -1116,7 +1116,7 @@ class _$UserImpl implements _User {
final dynamic userSettingsId;
@override
@JsonKey(name: "profile_photo_url")
final String profilePhotoUrl;
final String? profilePhotoUrl;
@override
@JsonKey(name: "detailz")
final UserDetails detailz;
@@ -1134,8 +1134,8 @@ class _$UserImpl implements _User {
(identical(other.id, id) || other.id == id) &&
(identical(other.name, name) || other.name == name) &&
(identical(other.email, email) || other.email == email) &&
(identical(other.emailVerifiedAt, emailVerifiedAt) ||
other.emailVerifiedAt == emailVerifiedAt) &&
const DeepCollectionEquality()
.equals(other.emailVerifiedAt, emailVerifiedAt) &&
const DeepCollectionEquality()
.equals(other.twoFactorConfirmedAt, twoFactorConfirmedAt) &&
const DeepCollectionEquality()
@@ -1165,7 +1165,7 @@ class _$UserImpl implements _User {
id,
name,
email,
emailVerifiedAt,
const DeepCollectionEquality().hash(emailVerifiedAt),
const DeepCollectionEquality().hash(twoFactorConfirmedAt),
const DeepCollectionEquality().hash(currentTeamId),
profilePhotoPath,
@@ -1198,19 +1198,18 @@ abstract class _User implements User {
@JsonKey(name: "name") required final String name,
@JsonKey(name: "email") required final String email,
@JsonKey(name: "email_verified_at")
required final DateTime emailVerifiedAt,
required final dynamic emailVerifiedAt,
@JsonKey(name: "two_factor_confirmed_at")
required final dynamic twoFactorConfirmedAt,
@JsonKey(name: "current_team_id") required final dynamic currentTeamId,
@JsonKey(name: "profile_photo_path")
required final String profilePhotoPath,
@JsonKey(name: "profile_photo_path") final String? profilePhotoPath,
@JsonKey(name: "created_at") required final DateTime createdAt,
@JsonKey(name: "updated_at") required final DateTime updatedAt,
@JsonKey(name: "is_consultant") required final int isConsultant,
@JsonKey(name: "is_public_profile") required final int isPublicProfile,
@JsonKey(name: "slug") required final String slug,
@JsonKey(name: "user_settings_id") required final dynamic userSettingsId,
@JsonKey(name: "profile_photo_url") required final String profilePhotoUrl,
@JsonKey(name: "profile_photo_url") final String? profilePhotoUrl,
@JsonKey(name: "detailz")
required final UserDetails detailz}) = _$UserImpl;
@@ -1227,7 +1226,7 @@ abstract class _User implements User {
String get email;
@override
@JsonKey(name: "email_verified_at")
DateTime get emailVerifiedAt;
dynamic get emailVerifiedAt;
@override
@JsonKey(name: "two_factor_confirmed_at")
dynamic get twoFactorConfirmedAt;
@@ -1236,7 +1235,7 @@ abstract class _User implements User {
dynamic get currentTeamId;
@override
@JsonKey(name: "profile_photo_path")
String get profilePhotoPath;
String? get profilePhotoPath;
@override
@JsonKey(name: "created_at")
DateTime get createdAt;
@@ -1257,7 +1256,7 @@ abstract class _User implements User {
dynamic get userSettingsId;
@override
@JsonKey(name: "profile_photo_url")
String get profilePhotoUrl;
String? get profilePhotoUrl;
@override
@JsonKey(name: "detailz")
UserDetails get detailz;

View File

@@ -65,17 +65,17 @@ _$UserImpl _$$UserImplFromJson(Map<String, dynamic> json) => _$UserImpl(
id: (json['id'] as num).toInt(),
name: json['name'] as String,
email: json['email'] as String,
emailVerifiedAt: DateTime.parse(json['email_verified_at'] as String),
emailVerifiedAt: json['email_verified_at'],
twoFactorConfirmedAt: json['two_factor_confirmed_at'],
currentTeamId: json['current_team_id'],
profilePhotoPath: json['profile_photo_path'] as String,
profilePhotoPath: json['profile_photo_path'] as String?,
createdAt: DateTime.parse(json['created_at'] as String),
updatedAt: DateTime.parse(json['updated_at'] as String),
isConsultant: (json['is_consultant'] as num).toInt(),
isPublicProfile: (json['is_public_profile'] as num).toInt(),
slug: json['slug'] as String,
userSettingsId: json['user_settings_id'],
profilePhotoUrl: json['profile_photo_url'] as String,
profilePhotoUrl: json['profile_photo_url'] as String?,
detailz: UserDetails.fromJson(json['detailz'] as Map<String, dynamic>),
);
@@ -84,7 +84,7 @@ Map<String, dynamic> _$$UserImplToJson(_$UserImpl instance) =>
'id': instance.id,
'name': instance.name,
'email': instance.email,
'email_verified_at': instance.emailVerifiedAt.toIso8601String(),
'email_verified_at': instance.emailVerifiedAt,
'two_factor_confirmed_at': instance.twoFactorConfirmedAt,
'current_team_id': instance.currentTeamId,
'profile_photo_path': instance.profilePhotoPath,