toJson method

Map<String, dynamic> toJson(
  1. User instance
)

Get Json from model

Implementation

Map<String, dynamic> toJson(User instance) => <String, dynamic>{
      'Id': instance.id,
      'Username': instance.username,
      'Fullname': instance.fullname,
      'Email': instance.email,
      'Password': instance.password,
      'AccessToken': instance.accessToken,
      'RefreshToken': instance.refreshToken,
      'Address': instance.address,
      'Phone': instance.phone,
      'EmailVerified': instance.emailVerified,
      'Role': instance.roles,
      'RoleIds': instance.roleIds,
      'RoleNames': instance.roleNames,
    };