You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.1 KiB
39 lines
1.1 KiB
class UserAuth {
|
|
String username;
|
|
String password;
|
|
String accountType;
|
|
String status;
|
|
String deviceToken;
|
|
String referralCode;
|
|
UserAuth({
|
|
this.username,
|
|
this.password,
|
|
this.accountType,
|
|
this.status,
|
|
this.deviceToken,
|
|
this.referralCode,
|
|
});
|
|
UserAuth.fromJSON(Map<String, dynamic> json)
|
|
: username = json['username'],
|
|
password = json['password'],
|
|
accountType = json['accountType'],
|
|
status = json['status'],
|
|
referralCode = json['referral'],
|
|
deviceToken = json['deviceToken'];
|
|
|
|
Map<String, dynamic> toJson() {
|
|
final Map<String, dynamic> data = Map<String, dynamic>();
|
|
data['username'] = this.username;
|
|
data['password'] = this.password;
|
|
data['accountType'] = this.accountType;
|
|
data['status'] = this.status;
|
|
data['deviceToken'] = this.deviceToken;
|
|
data['referral'] = this.referralCode;
|
|
return data;
|
|
}
|
|
|
|
@override
|
|
String toString() {
|
|
return '{"username": "$username", "password": "$password","accountType": "$accountType", "status": "$status","deviceToken": "$deviceToken"}';
|
|
}
|
|
}
|
|
|