| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- import 'package:json_annotation/json_annotation.dart';
- part 'upload_info.g.dart';
- /// 上传信息
- @JsonSerializable()
- class UploadInfo {
- /// 唯一id
- @JsonKey(name: "id")
- String? id;
- /// 文件名称
- @JsonKey(name: "fileName")
- String? fileName;
- /// 文件的绝对路径
- @JsonKey(name: "filePath")
- String? filePath;
- /// 文件场景类型
- @JsonKey(name: "uploadSceneType")
- String? uploadSceneType;
- /// 上传状态
- @JsonKey(name: "uploadState")
- String? uploadState;
- /// 文件的远程访问Url,上传成功后赋值
- @JsonKey(name: "fileUrl")
- String? fileUrl;
- /// 文件的cdn前缀,上传成功后赋值
- @JsonKey(name: "fileUrlCdnPrefix")
- String? fileUrlCdnPrefix;
- UploadInfo({
- this.id,
- this.fileName,
- this.filePath,
- this.uploadSceneType,
- this.uploadState,
- });
- Map<String, dynamic> toJson() => _$UploadInfoToJson(this);
- factory UploadInfo.fromJson(Map<String, dynamic> json) =>
- _$UploadInfoFromJson(json);
- }
|