73 lines
1.9 KiB
Dart
73 lines
1.9 KiB
Dart
|
|
class VersionControlModel {
|
||
|
|
Result? result;
|
||
|
|
String? status;
|
||
|
|
String? message;
|
||
|
|
|
||
|
|
VersionControlModel({this.result, this.status, this.message});
|
||
|
|
|
||
|
|
VersionControlModel.fromJson(Map<String, dynamic> json) {
|
||
|
|
result = json['result'] != null ? Result.fromJson(json['result']) : null;
|
||
|
|
status = json['status'];
|
||
|
|
message = json['message'];
|
||
|
|
}
|
||
|
|
|
||
|
|
Map<String, dynamic> toJson() {
|
||
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
||
|
|
if (result != null) {
|
||
|
|
data['result'] = result!.toJson();
|
||
|
|
}
|
||
|
|
data['status'] = status;
|
||
|
|
data['message'] = message;
|
||
|
|
return data;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
class Result {
|
||
|
|
int? id;
|
||
|
|
int? userId;
|
||
|
|
String? oldVersionAndroid;
|
||
|
|
String? newVersionAndroid;
|
||
|
|
String? oldVersionIos;
|
||
|
|
String? newVersionIos;
|
||
|
|
int? isActive;
|
||
|
|
String? createdAt;
|
||
|
|
String? updatedAt;
|
||
|
|
|
||
|
|
Result(
|
||
|
|
{this.id,
|
||
|
|
this.userId,
|
||
|
|
this.oldVersionAndroid,
|
||
|
|
this.newVersionAndroid,
|
||
|
|
this.oldVersionIos,
|
||
|
|
this.newVersionIos,
|
||
|
|
this.isActive,
|
||
|
|
this.createdAt,
|
||
|
|
this.updatedAt});
|
||
|
|
|
||
|
|
Result.fromJson(Map<String, dynamic> json) {
|
||
|
|
id = json['id'];
|
||
|
|
userId = json['user_id'];
|
||
|
|
oldVersionAndroid = json['old_version_android'];
|
||
|
|
newVersionAndroid = json['new_version_android'];
|
||
|
|
oldVersionIos = json['old_version_ios'];
|
||
|
|
newVersionIos = json['new_version_ios'];
|
||
|
|
isActive = json['is_active'];
|
||
|
|
createdAt = json['created_at'];
|
||
|
|
updatedAt = json['updated_at'];
|
||
|
|
}
|
||
|
|
|
||
|
|
Map<String, dynamic> toJson() {
|
||
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
||
|
|
data['id'] = id;
|
||
|
|
data['user_id'] = userId;
|
||
|
|
data['old_version_android'] = oldVersionAndroid;
|
||
|
|
data['new_version_android'] = newVersionAndroid;
|
||
|
|
data['old_version_ios'] = oldVersionIos;
|
||
|
|
data['new_version_ios'] = newVersionIos;
|
||
|
|
data['is_active'] = isActive;
|
||
|
|
data['created_at'] = createdAt;
|
||
|
|
data['updated_at'] = updatedAt;
|
||
|
|
return data;
|
||
|
|
}
|
||
|
|
}
|