User.fromJson constructor

User.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory User.fromJson(Map<String, dynamic> json) {
  return User(
    disabledDate: timeStampFromJson(json['DisabledDate']),
    displayName: json['DisplayName'] as String?,
    email: json['Email'] as String?,
    enabledDate: timeStampFromJson(json['EnabledDate']),
    id: json['Id'] as String?,
    name: json['Name'] as String?,
    state: (json['State'] as String?)?.toEntityState(),
    userRole: (json['UserRole'] as String?)?.toUserRole(),
  );
}