fromJson static method
Implementation
static RegisteredDriver fromJson(Map<String, dynamic> json) {
return RegisteredDriver(
accountCompanyUserId:
json['accountCompanyUserId'] ?? json['driverId'] ?? json['userId'],
name: json['name'],
countryCode: json['countryCode'],
phoneNumber: json['phoneNumber'],
email: json['email'],
companyName: json['companyName'],
averageTripScore: json['averageTripScore'],
totalDistanceTravelled: json['totalDistanceTravelled'],
totalTripCount: json['totalTripCount'],
totalTripDurationInSeconds: json['totalTripDurationInSeconds'],
currentStreak: json['currentStreak'],
longestStreak: json['longestStreak'],
);
}