aurcache/frontend/lib/models/build.dart

30 lines
731 B
Dart
Raw Normal View History

2023-12-29 17:13:51 +00:00
class Build {
final int id;
final String pkg_name;
final int pkg_id;
2023-12-29 17:13:51 +00:00
final String version;
final int status;
final int? start_time, end_time;
2023-12-29 17:13:51 +00:00
Build(
{required this.id,
required this.pkg_id,
required this.pkg_name,
required this.version,
required this.start_time,
required this.end_time,
required this.status});
2023-12-29 17:13:51 +00:00
factory Build.fromJson(Map<String, dynamic> json) {
return Build(
id: json["id"] as int,
pkg_id: json["pkg_id"] as int,
2023-12-29 17:13:51 +00:00
status: json["status"] as int,
start_time: json["start_time"] as int?,
end_time: json["end_time"] as int?,
2023-12-29 17:13:51 +00:00
pkg_name: json["pkg_name"] as String,
version: json["version"] as String,
);
}
}