54 lines
1.1 KiB
Dart
54 lines
1.1 KiB
Dart
import 'package:json_annotation/json_annotation.dart';
|
|
|
|
import '../config/request_config.dart';
|
|
|
|
part 'app_version.g.dart';
|
|
|
|
@JsonSerializable()
|
|
class AppVersion extends Object {
|
|
// @JsonKey(name: 'id')
|
|
// String id;
|
|
|
|
// @JsonKey(name: 'creatorId')
|
|
// int creatorId;
|
|
|
|
// @JsonKey(name: 'creatorName')
|
|
// String creatorName;
|
|
|
|
// @JsonKey(name: 'creationTime')
|
|
// String creationTime;
|
|
|
|
@JsonKey(name: 'appName')
|
|
String appName;
|
|
|
|
@JsonKey(name: 'version')
|
|
String version;
|
|
|
|
@JsonKey(name: 'ftuType')
|
|
int ftuType;
|
|
|
|
@JsonKey(name: 'downloadUrl')
|
|
String? downloadUrl;
|
|
|
|
@JsonKey(name: 'description')
|
|
String? description;
|
|
|
|
AppVersion(
|
|
// this.id,
|
|
// this.creatorId,
|
|
// this.creatorName,
|
|
// this.creationTime,
|
|
this.appName,
|
|
this.version,
|
|
this.ftuType,
|
|
this.downloadUrl,
|
|
this.description,
|
|
) {
|
|
if (downloadUrl != null) downloadUrl = RequestConfig.imgUrl + downloadUrl!;
|
|
}
|
|
|
|
factory AppVersion.fromJson(Map<String, dynamic> srcJson) => _$AppVersionFromJson(srcJson);
|
|
|
|
Map<String, dynamic> toJson() => _$AppVersionToJson(this);
|
|
}
|