|
@@ -543,17 +543,17 @@ class Stream extends MarshalByRefObject{
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-class DownloadFileResult {
|
|
|
+class DownloadFileResult2 {
|
|
|
Stream? merageFileStream;
|
|
|
int fileSize;
|
|
|
|
|
|
- DownloadFileResult({
|
|
|
+ DownloadFileResult2({
|
|
|
this.merageFileStream,
|
|
|
this.fileSize = 0,
|
|
|
});
|
|
|
|
|
|
- factory DownloadFileResult.fromJson(Map<String, dynamic> map) {
|
|
|
- return DownloadFileResult(
|
|
|
+ factory DownloadFileResult2.fromJson(Map<String, dynamic> map) {
|
|
|
+ return DownloadFileResult2(
|
|
|
merageFileStream: map['MerageFileStream'] != null ? Stream.fromJson(map['MerageFileStream']) : null,
|
|
|
fileSize: map['FileSize'],
|
|
|
);
|
|
@@ -8359,6 +8359,14 @@ enum BusinessModuleEnum {
|
|
|
RemoteControl,
|
|
|
}
|
|
|
|
|
|
+enum ChannelDescriptionEnum {
|
|
|
+ DeskChannel,
|
|
|
+ TerminalChannel,
|
|
|
+ CameraChannel,
|
|
|
+ TerminalTestChannel,
|
|
|
+ NoneChannel,
|
|
|
+}
|
|
|
+
|
|
|
enum QueryCMSTemplateStatusTypeEnum {
|
|
|
UnPublished,
|
|
|
Published,
|
|
@@ -8391,6 +8399,14 @@ enum QueryStatisticsBannerTypeEnum {
|
|
|
Download,
|
|
|
}
|
|
|
|
|
|
+enum CourseAvailabilityEnum {
|
|
|
+ Public,
|
|
|
+ Limited,
|
|
|
+ Fee,
|
|
|
+ Invitation,
|
|
|
+ Meeting,
|
|
|
+}
|
|
|
+
|
|
|
enum LogEventLevel {
|
|
|
Verbose,
|
|
|
Debug,
|
|
@@ -8453,6 +8469,12 @@ enum AIThyroidLabelEnum {
|
|
|
DiffuseDisease,
|
|
|
}
|
|
|
|
|
|
+enum DiseaseConclusion {
|
|
|
+ NoConclusion,
|
|
|
+ Positive,
|
|
|
+ Negative,
|
|
|
+}
|
|
|
+
|
|
|
enum FollowUpVisitStatusEnum {
|
|
|
Unknown,
|
|
|
PendingVisit,
|
|
@@ -9528,6 +9550,20 @@ enum AnimalGenderEnum {
|
|
|
AnimalInfoFemale,
|
|
|
}
|
|
|
|
|
|
+enum QualifiedState {
|
|
|
+ UnSet,
|
|
|
+ Qualified,
|
|
|
+ UnQualified,
|
|
|
+}
|
|
|
+
|
|
|
+enum QualityType {
|
|
|
+ None,
|
|
|
+ Qualified,
|
|
|
+ InformationUnCompleted,
|
|
|
+ ImageNotClear,
|
|
|
+ PositiveSiteNotClear,
|
|
|
+}
|
|
|
+
|
|
|
enum RegionGradeEnum {
|
|
|
Country,
|
|
|
Province,
|
|
@@ -16183,6 +16219,1724 @@ class CommandResultPageSettingInfoDTO extends ListPageSettingInfoDTO{
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+class AdminView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+
|
|
|
+ AdminView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory AdminView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return AdminView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class CaseLabelView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+
|
|
|
+ CaseLabelView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory CaseLabelView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return CaseLabelView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ChannelDataView {
|
|
|
+ String? channelId;
|
|
|
+ String? downLoadUrl;
|
|
|
+ String? upLoadUrl;
|
|
|
+ ChannelDescriptionEnum description;
|
|
|
+ String? httpUrl;
|
|
|
+ String? hlsUrl;
|
|
|
+
|
|
|
+ ChannelDataView({
|
|
|
+ this.channelId,
|
|
|
+ this.downLoadUrl,
|
|
|
+ this.upLoadUrl,
|
|
|
+ this.description = ChannelDescriptionEnum.DeskChannel,
|
|
|
+ this.httpUrl,
|
|
|
+ this.hlsUrl,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ChannelDataView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ChannelDataView(
|
|
|
+ channelId: map['ChannelId'],
|
|
|
+ downLoadUrl: map['DownLoadUrl'],
|
|
|
+ upLoadUrl: map['UpLoadUrl'],
|
|
|
+ description: ChannelDescriptionEnum.values.firstWhere((e) => e.index == map['Description']),
|
|
|
+ httpUrl: map['HttpUrl'],
|
|
|
+ hlsUrl: map['HlsUrl'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(channelId != null)
|
|
|
+ map['ChannelId'] = channelId;
|
|
|
+ if(downLoadUrl != null)
|
|
|
+ map['DownLoadUrl'] = downLoadUrl;
|
|
|
+ if(upLoadUrl != null)
|
|
|
+ map['UpLoadUrl'] = upLoadUrl;
|
|
|
+ map['Description'] = description.index;
|
|
|
+ if(httpUrl != null)
|
|
|
+ map['HttpUrl'] = httpUrl;
|
|
|
+ if(hlsUrl != null)
|
|
|
+ map['HlsUrl'] = hlsUrl;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class CommentView {
|
|
|
+ String? userCode;
|
|
|
+ String? userName;
|
|
|
+ double score;
|
|
|
+ String? description;
|
|
|
+
|
|
|
+ CommentView({
|
|
|
+ this.userCode,
|
|
|
+ this.userName,
|
|
|
+ this.score = 0,
|
|
|
+ this.description,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory CommentView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return CommentView(
|
|
|
+ userCode: map['UserCode'],
|
|
|
+ userName: map['UserName'],
|
|
|
+ score: double.parse(map['Score'].toString()),
|
|
|
+ description: map['Description'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(userCode != null)
|
|
|
+ map['UserCode'] = userCode;
|
|
|
+ if(userName != null)
|
|
|
+ map['UserName'] = userName;
|
|
|
+ map['Score'] = score;
|
|
|
+ if(description != null)
|
|
|
+ map['Description'] = description;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class UserView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? organizationCode;
|
|
|
+ String? organizationName;
|
|
|
+
|
|
|
+ UserView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.organizationCode,
|
|
|
+ this.organizationName,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory UserView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return UserView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ organizationCode: map['OrganizationCode'],
|
|
|
+ organizationName: map['OrganizationName'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(organizationCode != null)
|
|
|
+ map['OrganizationCode'] = organizationCode;
|
|
|
+ if(organizationName != null)
|
|
|
+ map['OrganizationName'] = organizationName;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class StudentView extends UserView{
|
|
|
+ bool isNoSpeaking;
|
|
|
+ bool isAssistant;
|
|
|
+ List<int>? smallHeadImage;
|
|
|
+ bool isPay;
|
|
|
+ StudentCourseStatusEnum signCourseStatus;
|
|
|
+
|
|
|
+ StudentView({
|
|
|
+ this.isNoSpeaking = false,
|
|
|
+ this.isAssistant = false,
|
|
|
+ this.smallHeadImage,
|
|
|
+ this.isPay = false,
|
|
|
+ this.signCourseStatus = StudentCourseStatusEnum.All,
|
|
|
+ String? code,
|
|
|
+ String? name,
|
|
|
+ String? organizationCode,
|
|
|
+ String? organizationName,
|
|
|
+ }) : super(
|
|
|
+ code: code,
|
|
|
+ name: name,
|
|
|
+ organizationCode: organizationCode,
|
|
|
+ organizationName: organizationName,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory StudentView.fromJson(Map<String, dynamic> map) {
|
|
|
+ final smallHeadImageData = map['SmallHeadImage'];
|
|
|
+ return StudentView(
|
|
|
+ isNoSpeaking: map['IsNoSpeaking'],
|
|
|
+ isAssistant: map['IsAssistant'],
|
|
|
+ smallHeadImage: smallHeadImageData != null ? (smallHeadImageData as List).map((e) => e as int).toList(): null,
|
|
|
+ isPay: map['IsPay'],
|
|
|
+ signCourseStatus: StudentCourseStatusEnum.values.firstWhere((e) => e.index == map['SignCourseStatus']),
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ organizationCode: map['OrganizationCode'],
|
|
|
+ organizationName: map['OrganizationName'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ map['IsNoSpeaking'] = isNoSpeaking;
|
|
|
+ map['IsAssistant'] = isAssistant;
|
|
|
+ if(smallHeadImage != null)
|
|
|
+ map['SmallHeadImage'] = smallHeadImage;
|
|
|
+ map['IsPay'] = isPay;
|
|
|
+ map['SignCourseStatus'] = signCourseStatus.index;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class CourseAlbumView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? teacherCode;
|
|
|
+ String? teacherName;
|
|
|
+ String? cover;
|
|
|
+ String? introduction;
|
|
|
+ List<String >? courseLabelCodes;
|
|
|
+ CourseViewRangeEnum viewRange;
|
|
|
+ double price;
|
|
|
+ List<StudentView >? students;
|
|
|
+ int sort;
|
|
|
+ bool isStick;
|
|
|
+
|
|
|
+ CourseAlbumView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.teacherCode,
|
|
|
+ this.teacherName,
|
|
|
+ this.cover,
|
|
|
+ this.introduction,
|
|
|
+ this.courseLabelCodes,
|
|
|
+ this.viewRange = CourseViewRangeEnum.All,
|
|
|
+ this.price = 0,
|
|
|
+ this.students,
|
|
|
+ this.sort = 0,
|
|
|
+ this.isStick = false,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory CourseAlbumView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return CourseAlbumView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ teacherCode: map['TeacherCode'],
|
|
|
+ teacherName: map['TeacherName'],
|
|
|
+ cover: map['Cover'],
|
|
|
+ introduction: map['Introduction'],
|
|
|
+ courseLabelCodes: map['CourseLabelCodes'] != null ? map['CourseLabelCodes'].cast<String>().toList() : null,
|
|
|
+ viewRange: CourseViewRangeEnum.values.firstWhere((e) => e.index == map['ViewRange']),
|
|
|
+ price: double.parse(map['Price'].toString()),
|
|
|
+ students: map['Students'] != null ? (map['Students'] as List).map((e)=>StudentView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ sort: map['Sort'],
|
|
|
+ isStick: map['IsStick'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(teacherCode != null)
|
|
|
+ map['TeacherCode'] = teacherCode;
|
|
|
+ if(teacherName != null)
|
|
|
+ map['TeacherName'] = teacherName;
|
|
|
+ if(cover != null)
|
|
|
+ map['Cover'] = cover;
|
|
|
+ if(introduction != null)
|
|
|
+ map['Introduction'] = introduction;
|
|
|
+ if(courseLabelCodes != null)
|
|
|
+ map['CourseLabelCodes'] = courseLabelCodes;
|
|
|
+ map['ViewRange'] = viewRange.index;
|
|
|
+ map['Price'] = price;
|
|
|
+ if(students != null)
|
|
|
+ map['Students'] = students;
|
|
|
+ map['Sort'] = sort;
|
|
|
+ map['IsStick'] = isStick;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class CustomerLabelView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+
|
|
|
+ CustomerLabelView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory CustomerLabelView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return CustomerLabelView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class DeviceView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? description;
|
|
|
+ String? uniqueCode;
|
|
|
+ String? organizationCode;
|
|
|
+ String? organizationName;
|
|
|
+ String? deviceType;
|
|
|
+ String? deviceModel;
|
|
|
+
|
|
|
+ DeviceView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.description,
|
|
|
+ this.uniqueCode,
|
|
|
+ this.organizationCode,
|
|
|
+ this.organizationName,
|
|
|
+ this.deviceType,
|
|
|
+ this.deviceModel,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory DeviceView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return DeviceView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ description: map['Description'],
|
|
|
+ uniqueCode: map['UniqueCode'],
|
|
|
+ organizationCode: map['OrganizationCode'],
|
|
|
+ organizationName: map['OrganizationName'],
|
|
|
+ deviceType: map['DeviceType'],
|
|
|
+ deviceModel: map['DeviceModel'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(description != null)
|
|
|
+ map['Description'] = description;
|
|
|
+ if(uniqueCode != null)
|
|
|
+ map['UniqueCode'] = uniqueCode;
|
|
|
+ if(organizationCode != null)
|
|
|
+ map['OrganizationCode'] = organizationCode;
|
|
|
+ if(organizationName != null)
|
|
|
+ map['OrganizationName'] = organizationName;
|
|
|
+ if(deviceType != null)
|
|
|
+ map['DeviceType'] = deviceType;
|
|
|
+ if(deviceModel != null)
|
|
|
+ map['DeviceModel'] = deviceModel;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class DiagnosisView {
|
|
|
+ DiagnosisOrganEnum organ;
|
|
|
+ DiagnosisConclusionEnum diagnosisStatus;
|
|
|
+
|
|
|
+ DiagnosisView({
|
|
|
+ this.organ = DiagnosisOrganEnum.Null,
|
|
|
+ this.diagnosisStatus = DiagnosisConclusionEnum.NotRequired,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory DiagnosisView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return DiagnosisView(
|
|
|
+ organ: DiagnosisOrganEnum.values.firstWhere((e) => e.index == map['Organ']),
|
|
|
+ diagnosisStatus: DiagnosisConclusionEnum.values.firstWhere((e) => e.index == map['DiagnosisStatus']),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ map['Organ'] = organ.index;
|
|
|
+ map['DiagnosisStatus'] = diagnosisStatus.index;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class FileView {
|
|
|
+ RemedicalFileDataTypeEnum dataType;
|
|
|
+ String? originalUrl;
|
|
|
+ String? cdnUrl;
|
|
|
+ int fileSize;
|
|
|
+ String? fileName;
|
|
|
+ String? previewUrl;
|
|
|
+ String? converUrl;
|
|
|
+
|
|
|
+ FileView({
|
|
|
+ this.dataType = RemedicalFileDataTypeEnum.VinnoVidSingle,
|
|
|
+ this.originalUrl,
|
|
|
+ this.cdnUrl,
|
|
|
+ this.fileSize = 0,
|
|
|
+ this.fileName,
|
|
|
+ this.previewUrl,
|
|
|
+ this.converUrl,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory FileView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return FileView(
|
|
|
+ dataType: RemedicalFileDataTypeEnum.values.firstWhere((e) => e.index == map['DataType']),
|
|
|
+ originalUrl: map['OriginalUrl'],
|
|
|
+ cdnUrl: map['CdnUrl'],
|
|
|
+ fileSize: map['FileSize'],
|
|
|
+ fileName: map['FileName'],
|
|
|
+ previewUrl: map['PreviewUrl'],
|
|
|
+ converUrl: map['ConverUrl'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ map['DataType'] = dataType.index;
|
|
|
+ if(originalUrl != null)
|
|
|
+ map['OriginalUrl'] = originalUrl;
|
|
|
+ if(cdnUrl != null)
|
|
|
+ map['CdnUrl'] = cdnUrl;
|
|
|
+ map['FileSize'] = fileSize;
|
|
|
+ if(fileName != null)
|
|
|
+ map['FileName'] = fileName;
|
|
|
+ if(previewUrl != null)
|
|
|
+ map['PreviewUrl'] = previewUrl;
|
|
|
+ if(converUrl != null)
|
|
|
+ map['ConverUrl'] = converUrl;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ImageLocationView {
|
|
|
+ String? group;
|
|
|
+ String? position;
|
|
|
+ String? quadrant;
|
|
|
+
|
|
|
+ ImageLocationView({
|
|
|
+ this.group,
|
|
|
+ this.position,
|
|
|
+ this.quadrant,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ImageLocationView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ImageLocationView(
|
|
|
+ group: map['Group'],
|
|
|
+ position: map['Position'],
|
|
|
+ quadrant: map['Quadrant'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(group != null)
|
|
|
+ map['Group'] = group;
|
|
|
+ if(position != null)
|
|
|
+ map['Position'] = position;
|
|
|
+ if(quadrant != null)
|
|
|
+ map['Quadrant'] = quadrant;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class RemoteDiagnosisFileView extends FileView{
|
|
|
+ String? code;
|
|
|
+ String? application;
|
|
|
+ ImageLocationView? imageLocationInfo;
|
|
|
+ List<CommentView >? commentInfos;
|
|
|
+
|
|
|
+ RemoteDiagnosisFileView({
|
|
|
+ this.code,
|
|
|
+ this.application,
|
|
|
+ this.imageLocationInfo,
|
|
|
+ this.commentInfos,
|
|
|
+ RemedicalFileDataTypeEnum dataType = RemedicalFileDataTypeEnum.VinnoVidSingle,
|
|
|
+ String? originalUrl,
|
|
|
+ String? cdnUrl,
|
|
|
+ int fileSize = 0,
|
|
|
+ String? fileName,
|
|
|
+ String? previewUrl,
|
|
|
+ String? converUrl,
|
|
|
+ }) : super(
|
|
|
+ dataType: dataType,
|
|
|
+ originalUrl: originalUrl,
|
|
|
+ cdnUrl: cdnUrl,
|
|
|
+ fileSize: fileSize,
|
|
|
+ fileName: fileName,
|
|
|
+ previewUrl: previewUrl,
|
|
|
+ converUrl: converUrl,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory RemoteDiagnosisFileView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return RemoteDiagnosisFileView(
|
|
|
+ code: map['Code'],
|
|
|
+ application: map['Application'],
|
|
|
+ imageLocationInfo: map['ImageLocationInfo'] != null ? ImageLocationView.fromJson(map['ImageLocationInfo']) : null,
|
|
|
+ commentInfos: map['CommentInfos'] != null ? (map['CommentInfos'] as List).map((e)=>CommentView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ dataType: RemedicalFileDataTypeEnum.values.firstWhere((e) => e.index == map['DataType']),
|
|
|
+ originalUrl: map['OriginalUrl'],
|
|
|
+ cdnUrl: map['CdnUrl'],
|
|
|
+ fileSize: map['FileSize'],
|
|
|
+ fileName: map['FileName'],
|
|
|
+ previewUrl: map['PreviewUrl'],
|
|
|
+ converUrl: map['ConverUrl'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(application != null)
|
|
|
+ map['Application'] = application;
|
|
|
+ if(imageLocationInfo != null)
|
|
|
+ map['ImageLocationInfo'] = imageLocationInfo;
|
|
|
+ if(commentInfos != null)
|
|
|
+ map['CommentInfos'] = commentInfos;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class LiveConsultationFileView extends FileView{
|
|
|
+ String? userCode;
|
|
|
+ String? userName;
|
|
|
+ String? type;
|
|
|
+ ConsultationFileTypeEnum consultationFileType;
|
|
|
+ String? remedicalCode;
|
|
|
+ String? remedicalMeasureCode;
|
|
|
+
|
|
|
+ LiveConsultationFileView({
|
|
|
+ this.userCode,
|
|
|
+ this.userName,
|
|
|
+ this.type,
|
|
|
+ this.consultationFileType = ConsultationFileTypeEnum.Screenshot,
|
|
|
+ this.remedicalCode,
|
|
|
+ this.remedicalMeasureCode,
|
|
|
+ RemedicalFileDataTypeEnum dataType = RemedicalFileDataTypeEnum.VinnoVidSingle,
|
|
|
+ String? originalUrl,
|
|
|
+ String? cdnUrl,
|
|
|
+ int fileSize = 0,
|
|
|
+ String? fileName,
|
|
|
+ String? previewUrl,
|
|
|
+ String? converUrl,
|
|
|
+ }) : super(
|
|
|
+ dataType: dataType,
|
|
|
+ originalUrl: originalUrl,
|
|
|
+ cdnUrl: cdnUrl,
|
|
|
+ fileSize: fileSize,
|
|
|
+ fileName: fileName,
|
|
|
+ previewUrl: previewUrl,
|
|
|
+ converUrl: converUrl,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory LiveConsultationFileView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return LiveConsultationFileView(
|
|
|
+ userCode: map['UserCode'],
|
|
|
+ userName: map['UserName'],
|
|
|
+ type: map['Type'],
|
|
|
+ consultationFileType: ConsultationFileTypeEnum.values.firstWhere((e) => e.index == map['ConsultationFileType']),
|
|
|
+ remedicalCode: map['RemedicalCode'],
|
|
|
+ remedicalMeasureCode: map['RemedicalMeasureCode'],
|
|
|
+ dataType: RemedicalFileDataTypeEnum.values.firstWhere((e) => e.index == map['DataType']),
|
|
|
+ originalUrl: map['OriginalUrl'],
|
|
|
+ cdnUrl: map['CdnUrl'],
|
|
|
+ fileSize: map['FileSize'],
|
|
|
+ fileName: map['FileName'],
|
|
|
+ previewUrl: map['PreviewUrl'],
|
|
|
+ converUrl: map['ConverUrl'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(userCode != null)
|
|
|
+ map['UserCode'] = userCode;
|
|
|
+ if(userName != null)
|
|
|
+ map['UserName'] = userName;
|
|
|
+ if(type != null)
|
|
|
+ map['Type'] = type;
|
|
|
+ map['ConsultationFileType'] = consultationFileType.index;
|
|
|
+ if(remedicalCode != null)
|
|
|
+ map['RemedicalCode'] = remedicalCode;
|
|
|
+ if(remedicalMeasureCode != null)
|
|
|
+ map['RemedicalMeasureCode'] = remedicalMeasureCode;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class GroupView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+
|
|
|
+ GroupView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory GroupView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return GroupView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class PatientView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? identityCardId;
|
|
|
+ String? mobile;
|
|
|
+ String? gender;
|
|
|
+ String? age;
|
|
|
+
|
|
|
+ PatientView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.identityCardId,
|
|
|
+ this.mobile,
|
|
|
+ this.gender,
|
|
|
+ this.age,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory PatientView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return PatientView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ identityCardId: map['IdentityCardId'],
|
|
|
+ mobile: map['Mobile'],
|
|
|
+ gender: map['Gender'],
|
|
|
+ age: map['Age'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(identityCardId != null)
|
|
|
+ map['IdentityCardId'] = identityCardId;
|
|
|
+ if(mobile != null)
|
|
|
+ map['Mobile'] = mobile;
|
|
|
+ if(gender != null)
|
|
|
+ map['Gender'] = gender;
|
|
|
+ if(age != null)
|
|
|
+ map['Age'] = age;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class OrganizationView {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? departmentCode;
|
|
|
+ String? departmentName;
|
|
|
+ String? description;
|
|
|
+ String? logoUrl;
|
|
|
+ String? countryCode;
|
|
|
+ String? countryName;
|
|
|
+ String? provinceCode;
|
|
|
+ String? provinceName;
|
|
|
+ String? cityCode;
|
|
|
+ String? cityName;
|
|
|
+
|
|
|
+ OrganizationView({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.departmentCode,
|
|
|
+ this.departmentName,
|
|
|
+ this.description,
|
|
|
+ this.logoUrl,
|
|
|
+ this.countryCode,
|
|
|
+ this.countryName,
|
|
|
+ this.provinceCode,
|
|
|
+ this.provinceName,
|
|
|
+ this.cityCode,
|
|
|
+ this.cityName,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory OrganizationView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return OrganizationView(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ departmentCode: map['DepartmentCode'],
|
|
|
+ departmentName: map['DepartmentName'],
|
|
|
+ description: map['Description'],
|
|
|
+ logoUrl: map['LogoUrl'],
|
|
|
+ countryCode: map['CountryCode'],
|
|
|
+ countryName: map['CountryName'],
|
|
|
+ provinceCode: map['ProvinceCode'],
|
|
|
+ provinceName: map['ProvinceName'],
|
|
|
+ cityCode: map['CityCode'],
|
|
|
+ cityName: map['CityName'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(departmentCode != null)
|
|
|
+ map['DepartmentCode'] = departmentCode;
|
|
|
+ if(departmentName != null)
|
|
|
+ map['DepartmentName'] = departmentName;
|
|
|
+ if(description != null)
|
|
|
+ map['Description'] = description;
|
|
|
+ if(logoUrl != null)
|
|
|
+ map['LogoUrl'] = logoUrl;
|
|
|
+ if(countryCode != null)
|
|
|
+ map['CountryCode'] = countryCode;
|
|
|
+ if(countryName != null)
|
|
|
+ map['CountryName'] = countryName;
|
|
|
+ if(provinceCode != null)
|
|
|
+ map['ProvinceCode'] = provinceCode;
|
|
|
+ if(provinceName != null)
|
|
|
+ map['ProvinceName'] = provinceName;
|
|
|
+ if(cityCode != null)
|
|
|
+ map['CityCode'] = cityCode;
|
|
|
+ if(cityName != null)
|
|
|
+ map['CityName'] = cityName;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ICollection<T> {
|
|
|
+ int count;
|
|
|
+ bool isReadOnly;
|
|
|
+
|
|
|
+ ICollection({
|
|
|
+ this.count = 0,
|
|
|
+ this.isReadOnly = false,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ICollection.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ICollection(
|
|
|
+ count: map['Count'],
|
|
|
+ isReadOnly: map['IsReadOnly'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ map['Count'] = count;
|
|
|
+ map['IsReadOnly'] = isReadOnly;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportConclusionView {
|
|
|
+ String? reportId;
|
|
|
+ String? diseaseName;
|
|
|
+ DiseaseConclusion diseaseConclusion;
|
|
|
+
|
|
|
+ ReportConclusionView({
|
|
|
+ this.reportId,
|
|
|
+ this.diseaseName,
|
|
|
+ this.diseaseConclusion = DiseaseConclusion.NoConclusion,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportConclusionView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportConclusionView(
|
|
|
+ reportId: map['ReportId'],
|
|
|
+ diseaseName: map['DiseaseName'],
|
|
|
+ diseaseConclusion: DiseaseConclusion.values.firstWhere((e) => e.index == map['DiseaseConclusion']),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(reportId != null)
|
|
|
+ map['ReportId'] = reportId;
|
|
|
+ if(diseaseName != null)
|
|
|
+ map['DiseaseName'] = diseaseName;
|
|
|
+ map['DiseaseConclusion'] = diseaseConclusion.index;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class LiveConsultationDTO extends BaseDTO{
|
|
|
+ String? code;
|
|
|
+ UserView? doctorInfo;
|
|
|
+ UserView? expertInfo;
|
|
|
+ PatientView? patientInfo;
|
|
|
+ OrganizationView? primaryHosptial;
|
|
|
+ OrganizationView? centralHospital;
|
|
|
+ DeviceView? deviceInfo;
|
|
|
+ String? checkPoint;
|
|
|
+ ConsultationState state;
|
|
|
+ String? consultationNumber;
|
|
|
+ String? queuingNumber;
|
|
|
+ QualityType qualityType;
|
|
|
+ FollowUpVisitStatusEnum followUpVisitStatus;
|
|
|
+ bool isNeedFollowUpVisit;
|
|
|
+ EvaluateGradeEnum evaluateGrade;
|
|
|
+ ICollection<LiveConsultationFileView>? fileInfos;
|
|
|
+ ICollection<ReportConclusionView>? reportConclusionInfos;
|
|
|
+ List<DataItemDTO >? patientDatas;
|
|
|
+ OrganizationPatientTypeEnum patientType;
|
|
|
+ String? scanPosition;
|
|
|
+ String? scanUserCode;
|
|
|
+ String? scanUserName;
|
|
|
+ String? operateUserCode;
|
|
|
+ String? operateUserName;
|
|
|
+ DateTime? consultationTime;
|
|
|
+ DateTime? consultationTimeEnd;
|
|
|
+ TransactionStatusEnum consultationStatus;
|
|
|
+ String? rejectReason;
|
|
|
+ String? location;
|
|
|
+ List<ConsultationMemberDTO >? consultationMembers;
|
|
|
+ String? description;
|
|
|
+ List<ConsultationReminderDTO >? consultationReminders;
|
|
|
+ String? approverCode;
|
|
|
+ ConsultationReportMode reportMode;
|
|
|
+ String? diseases;
|
|
|
+ String? primaryDiagnosis;
|
|
|
+ String? initiatorCode;
|
|
|
+ bool isEmergency;
|
|
|
+ String? emergencyCode;
|
|
|
+
|
|
|
+ LiveConsultationDTO({
|
|
|
+ this.code,
|
|
|
+ this.doctorInfo,
|
|
|
+ this.expertInfo,
|
|
|
+ this.patientInfo,
|
|
|
+ this.primaryHosptial,
|
|
|
+ this.centralHospital,
|
|
|
+ this.deviceInfo,
|
|
|
+ this.checkPoint,
|
|
|
+ this.state = ConsultationState.Unhandled,
|
|
|
+ this.consultationNumber,
|
|
|
+ this.queuingNumber,
|
|
|
+ this.qualityType = QualityType.None,
|
|
|
+ this.followUpVisitStatus = FollowUpVisitStatusEnum.Unknown,
|
|
|
+ this.isNeedFollowUpVisit = false,
|
|
|
+ this.evaluateGrade = EvaluateGradeEnum.UnSet,
|
|
|
+ this.fileInfos,
|
|
|
+ this.reportConclusionInfos,
|
|
|
+ this.patientDatas,
|
|
|
+ this.patientType = OrganizationPatientTypeEnum.Person,
|
|
|
+ this.scanPosition,
|
|
|
+ this.scanUserCode,
|
|
|
+ this.scanUserName,
|
|
|
+ this.operateUserCode,
|
|
|
+ this.operateUserName,
|
|
|
+ this.consultationTime,
|
|
|
+ this.consultationTimeEnd,
|
|
|
+ this.consultationStatus = TransactionStatusEnum.Applied,
|
|
|
+ this.rejectReason,
|
|
|
+ this.location,
|
|
|
+ this.consultationMembers,
|
|
|
+ this.description,
|
|
|
+ this.consultationReminders,
|
|
|
+ this.approverCode,
|
|
|
+ this.reportMode = ConsultationReportMode.ExpertReport,
|
|
|
+ this.diseases,
|
|
|
+ this.primaryDiagnosis,
|
|
|
+ this.initiatorCode,
|
|
|
+ this.isEmergency = false,
|
|
|
+ this.emergencyCode,
|
|
|
+ DateTime? createTime,
|
|
|
+ DateTime? updateTime,
|
|
|
+ }) : super(
|
|
|
+ createTime: createTime,
|
|
|
+ updateTime: updateTime,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory LiveConsultationDTO.fromJson(Map<String, dynamic> map) {
|
|
|
+ return LiveConsultationDTO(
|
|
|
+ code: map['Code'],
|
|
|
+ doctorInfo: map['DoctorInfo'] != null ? UserView.fromJson(map['DoctorInfo']) : null,
|
|
|
+ expertInfo: map['ExpertInfo'] != null ? UserView.fromJson(map['ExpertInfo']) : null,
|
|
|
+ patientInfo: map['PatientInfo'] != null ? PatientView.fromJson(map['PatientInfo']) : null,
|
|
|
+ primaryHosptial: map['PrimaryHosptial'] != null ? OrganizationView.fromJson(map['PrimaryHosptial']) : null,
|
|
|
+ centralHospital: map['CentralHospital'] != null ? OrganizationView.fromJson(map['CentralHospital']) : null,
|
|
|
+ deviceInfo: map['DeviceInfo'] != null ? DeviceView.fromJson(map['DeviceInfo']) : null,
|
|
|
+ checkPoint: map['CheckPoint'],
|
|
|
+ state: ConsultationState.values.firstWhere((e) => e.index == map['State']),
|
|
|
+ consultationNumber: map['ConsultationNumber'],
|
|
|
+ queuingNumber: map['QueuingNumber'],
|
|
|
+ qualityType: QualityType.values.firstWhere((e) => e.index == map['QualityType']),
|
|
|
+ followUpVisitStatus: FollowUpVisitStatusEnum.values.firstWhere((e) => e.index == map['FollowUpVisitStatus']),
|
|
|
+ isNeedFollowUpVisit: map['IsNeedFollowUpVisit'],
|
|
|
+ evaluateGrade: EvaluateGradeEnum.values.firstWhere((e) => e.index == map['EvaluateGrade']),
|
|
|
+ patientDatas: map['PatientDatas'] != null ? (map['PatientDatas'] as List).map((e)=>DataItemDTO.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ patientType: OrganizationPatientTypeEnum.values.firstWhere((e) => e.index == map['PatientType']),
|
|
|
+ scanPosition: map['ScanPosition'],
|
|
|
+ scanUserCode: map['ScanUserCode'],
|
|
|
+ scanUserName: map['ScanUserName'],
|
|
|
+ operateUserCode: map['OperateUserCode'],
|
|
|
+ operateUserName: map['OperateUserName'],
|
|
|
+ consultationTime: map['ConsultationTime'] != null ? DateTime.parse(map['ConsultationTime']) : null,
|
|
|
+ consultationTimeEnd: map['ConsultationTimeEnd'] != null ? DateTime.parse(map['ConsultationTimeEnd']) : null,
|
|
|
+ consultationStatus: TransactionStatusEnum.values.firstWhere((e) => e.index == map['ConsultationStatus']),
|
|
|
+ rejectReason: map['RejectReason'],
|
|
|
+ location: map['Location'],
|
|
|
+ consultationMembers: map['ConsultationMembers'] != null ? (map['ConsultationMembers'] as List).map((e)=>ConsultationMemberDTO.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ description: map['Description'],
|
|
|
+ consultationReminders: map['ConsultationReminders'] != null ? (map['ConsultationReminders'] as List).map((e)=>ConsultationReminderDTO.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ approverCode: map['ApproverCode'],
|
|
|
+ reportMode: ConsultationReportMode.values.firstWhere((e) => e.index == map['ReportMode']),
|
|
|
+ diseases: map['Diseases'],
|
|
|
+ primaryDiagnosis: map['PrimaryDiagnosis'],
|
|
|
+ initiatorCode: map['InitiatorCode'],
|
|
|
+ isEmergency: map['IsEmergency'],
|
|
|
+ emergencyCode: map['EmergencyCode'],
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(doctorInfo != null)
|
|
|
+ map['DoctorInfo'] = doctorInfo;
|
|
|
+ if(expertInfo != null)
|
|
|
+ map['ExpertInfo'] = expertInfo;
|
|
|
+ if(patientInfo != null)
|
|
|
+ map['PatientInfo'] = patientInfo;
|
|
|
+ if(primaryHosptial != null)
|
|
|
+ map['PrimaryHosptial'] = primaryHosptial;
|
|
|
+ if(centralHospital != null)
|
|
|
+ map['CentralHospital'] = centralHospital;
|
|
|
+ if(deviceInfo != null)
|
|
|
+ map['DeviceInfo'] = deviceInfo;
|
|
|
+ if(checkPoint != null)
|
|
|
+ map['CheckPoint'] = checkPoint;
|
|
|
+ map['State'] = state.index;
|
|
|
+ if(consultationNumber != null)
|
|
|
+ map['ConsultationNumber'] = consultationNumber;
|
|
|
+ if(queuingNumber != null)
|
|
|
+ map['QueuingNumber'] = queuingNumber;
|
|
|
+ map['QualityType'] = qualityType.index;
|
|
|
+ map['FollowUpVisitStatus'] = followUpVisitStatus.index;
|
|
|
+ map['IsNeedFollowUpVisit'] = isNeedFollowUpVisit;
|
|
|
+ map['EvaluateGrade'] = evaluateGrade.index;
|
|
|
+ if(fileInfos != null)
|
|
|
+ map['FileInfos'] = fileInfos;
|
|
|
+ if(reportConclusionInfos != null)
|
|
|
+ map['ReportConclusionInfos'] = reportConclusionInfos;
|
|
|
+ if(patientDatas != null)
|
|
|
+ map['PatientDatas'] = patientDatas;
|
|
|
+ map['PatientType'] = patientType.index;
|
|
|
+ if(scanPosition != null)
|
|
|
+ map['ScanPosition'] = scanPosition;
|
|
|
+ if(scanUserCode != null)
|
|
|
+ map['ScanUserCode'] = scanUserCode;
|
|
|
+ if(scanUserName != null)
|
|
|
+ map['ScanUserName'] = scanUserName;
|
|
|
+ if(operateUserCode != null)
|
|
|
+ map['OperateUserCode'] = operateUserCode;
|
|
|
+ if(operateUserName != null)
|
|
|
+ map['OperateUserName'] = operateUserName;
|
|
|
+ if(consultationTime != null)
|
|
|
+ map['ConsultationTime'] = JsonRpcUtils.dateFormat(consultationTime!);
|
|
|
+ if(consultationTimeEnd != null)
|
|
|
+ map['ConsultationTimeEnd'] = JsonRpcUtils.dateFormat(consultationTimeEnd!);
|
|
|
+ map['ConsultationStatus'] = consultationStatus.index;
|
|
|
+ if(rejectReason != null)
|
|
|
+ map['RejectReason'] = rejectReason;
|
|
|
+ if(location != null)
|
|
|
+ map['Location'] = location;
|
|
|
+ if(consultationMembers != null)
|
|
|
+ map['ConsultationMembers'] = consultationMembers;
|
|
|
+ if(description != null)
|
|
|
+ map['Description'] = description;
|
|
|
+ if(consultationReminders != null)
|
|
|
+ map['ConsultationReminders'] = consultationReminders;
|
|
|
+ if(approverCode != null)
|
|
|
+ map['ApproverCode'] = approverCode;
|
|
|
+ map['ReportMode'] = reportMode.index;
|
|
|
+ if(diseases != null)
|
|
|
+ map['Diseases'] = diseases;
|
|
|
+ if(primaryDiagnosis != null)
|
|
|
+ map['PrimaryDiagnosis'] = primaryDiagnosis;
|
|
|
+ if(initiatorCode != null)
|
|
|
+ map['InitiatorCode'] = initiatorCode;
|
|
|
+ map['IsEmergency'] = isEmergency;
|
|
|
+ if(emergencyCode != null)
|
|
|
+ map['EmergencyCode'] = emergencyCode;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class TeacherView extends UserView{
|
|
|
+ String? introduction;
|
|
|
+ List<int>? smallAvatar;
|
|
|
+
|
|
|
+ TeacherView({
|
|
|
+ this.introduction,
|
|
|
+ this.smallAvatar,
|
|
|
+ String? code,
|
|
|
+ String? name,
|
|
|
+ String? organizationCode,
|
|
|
+ String? organizationName,
|
|
|
+ }) : super(
|
|
|
+ code: code,
|
|
|
+ name: name,
|
|
|
+ organizationCode: organizationCode,
|
|
|
+ organizationName: organizationName,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory TeacherView.fromJson(Map<String, dynamic> map) {
|
|
|
+ final smallAvatarData = map['SmallAvatar'];
|
|
|
+ return TeacherView(
|
|
|
+ introduction: map['Introduction'],
|
|
|
+ smallAvatar: smallAvatarData != null ? (smallAvatarData as List).map((e) => e as int).toList(): null,
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ organizationCode: map['OrganizationCode'],
|
|
|
+ organizationName: map['OrganizationName'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(introduction != null)
|
|
|
+ map['Introduction'] = introduction;
|
|
|
+ if(smallAvatar != null)
|
|
|
+ map['SmallAvatar'] = smallAvatar;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class AudienceView extends UserView{
|
|
|
+ int totalMinutes;
|
|
|
+ List<GroupView >? groupInfos;
|
|
|
+
|
|
|
+ AudienceView({
|
|
|
+ this.totalMinutes = 0,
|
|
|
+ this.groupInfos,
|
|
|
+ String? code,
|
|
|
+ String? name,
|
|
|
+ String? organizationCode,
|
|
|
+ String? organizationName,
|
|
|
+ }) : super(
|
|
|
+ code: code,
|
|
|
+ name: name,
|
|
|
+ organizationCode: organizationCode,
|
|
|
+ organizationName: organizationName,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory AudienceView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return AudienceView(
|
|
|
+ totalMinutes: map['TotalMinutes'],
|
|
|
+ groupInfos: map['GroupInfos'] != null ? (map['GroupInfos'] as List).map((e)=>GroupView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ organizationCode: map['OrganizationCode'],
|
|
|
+ organizationName: map['OrganizationName'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ map['TotalMinutes'] = totalMinutes;
|
|
|
+ if(groupInfos != null)
|
|
|
+ map['GroupInfos'] = groupInfos;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class OnlineVideoDTO {
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? creatorCode;
|
|
|
+ String? creatorName;
|
|
|
+ UploadFileTypeEnum fodderType;
|
|
|
+ bool isPublic;
|
|
|
+ CourseViewRangeEnum viewRange;
|
|
|
+ String? videoToken;
|
|
|
+ String? vodFileId;
|
|
|
+ String? poster;
|
|
|
+ int duration;
|
|
|
+ double videoSize;
|
|
|
+ int playCount;
|
|
|
+ String? srcFileToken;
|
|
|
+
|
|
|
+ OnlineVideoDTO({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.creatorCode,
|
|
|
+ this.creatorName,
|
|
|
+ this.fodderType = UploadFileTypeEnum.Unknown,
|
|
|
+ this.isPublic = false,
|
|
|
+ this.viewRange = CourseViewRangeEnum.All,
|
|
|
+ this.videoToken,
|
|
|
+ this.vodFileId,
|
|
|
+ this.poster,
|
|
|
+ this.duration = 0,
|
|
|
+ this.videoSize = 0,
|
|
|
+ this.playCount = 0,
|
|
|
+ this.srcFileToken,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory OnlineVideoDTO.fromJson(Map<String, dynamic> map) {
|
|
|
+ return OnlineVideoDTO(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ creatorCode: map['CreatorCode'],
|
|
|
+ creatorName: map['CreatorName'],
|
|
|
+ fodderType: UploadFileTypeEnum.values.firstWhere((e) => e.index == map['FodderType']),
|
|
|
+ isPublic: map['IsPublic'],
|
|
|
+ viewRange: CourseViewRangeEnum.values.firstWhere((e) => e.index == map['ViewRange']),
|
|
|
+ videoToken: map['VideoToken'],
|
|
|
+ vodFileId: map['VodFileId'],
|
|
|
+ poster: map['Poster'],
|
|
|
+ duration: map['Duration'],
|
|
|
+ videoSize: double.parse(map['VideoSize'].toString()),
|
|
|
+ playCount: map['PlayCount'],
|
|
|
+ srcFileToken: map['SrcFileToken'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(creatorCode != null)
|
|
|
+ map['CreatorCode'] = creatorCode;
|
|
|
+ if(creatorName != null)
|
|
|
+ map['CreatorName'] = creatorName;
|
|
|
+ map['FodderType'] = fodderType.index;
|
|
|
+ map['IsPublic'] = isPublic;
|
|
|
+ map['ViewRange'] = viewRange.index;
|
|
|
+ if(videoToken != null)
|
|
|
+ map['VideoToken'] = videoToken;
|
|
|
+ if(vodFileId != null)
|
|
|
+ map['VodFileId'] = vodFileId;
|
|
|
+ if(poster != null)
|
|
|
+ map['Poster'] = poster;
|
|
|
+ map['Duration'] = duration;
|
|
|
+ map['VideoSize'] = videoSize;
|
|
|
+ map['PlayCount'] = playCount;
|
|
|
+ if(srcFileToken != null)
|
|
|
+ map['SrcFileToken'] = srcFileToken;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class OnlineTrainingDTO extends BaseDTO{
|
|
|
+ String? code;
|
|
|
+ String? name;
|
|
|
+ String? information;
|
|
|
+ double price;
|
|
|
+ CourseStatusEnum state;
|
|
|
+ CourseViewRangeEnum viewRange;
|
|
|
+ CourseAudienceTypeEnum audienceType;
|
|
|
+ DateTime? starTime;
|
|
|
+ int duration;
|
|
|
+ DateTime? deadline;
|
|
|
+ ApplyStateEnum applyState;
|
|
|
+ String? poster;
|
|
|
+ TeacherView? teacher;
|
|
|
+ ICollection<StudentView>? students;
|
|
|
+ String? conversationId;
|
|
|
+ ICollection<ChannelDataView>? channelDatas;
|
|
|
+ AdminView? createAdmin;
|
|
|
+ ICollection<AdminView>? owners;
|
|
|
+ bool teacherState;
|
|
|
+ bool startCourseInAdvance;
|
|
|
+ DateTime? actualStartTime;
|
|
|
+ DateTime? actualEndTime;
|
|
|
+ List<UserView >? assistantInfos;
|
|
|
+ List<UserView >? guestInfos;
|
|
|
+ String? credentialCode;
|
|
|
+ String? courseNotice;
|
|
|
+ List<UserView >? meetingMemberInfos;
|
|
|
+ CourseAvailabilityEnum availability;
|
|
|
+ List<UserView >? authorizedUserInfos;
|
|
|
+ List<GroupView >? authorizedGroupInfos;
|
|
|
+ List<AudienceView >? audienceInfos;
|
|
|
+ List<CaseLabelView >? caseLabelInfos;
|
|
|
+ String? coursewareToken;
|
|
|
+ CourseTypeEnum courseType;
|
|
|
+ ICollection<StudentView>? experts;
|
|
|
+ List<CustomerLabelView >? courseLabelInfos;
|
|
|
+ bool isAgentCourse;
|
|
|
+ bool isStick;
|
|
|
+ int sort;
|
|
|
+ List<OnlineVideoDTO >? courseVideoInfos;
|
|
|
+ CourseAppearTypeEnum courseAppearType;
|
|
|
+ List<CourseAlbumView >? courseAlbumInfos;
|
|
|
+ int playCount;
|
|
|
+
|
|
|
+ OnlineTrainingDTO({
|
|
|
+ this.code,
|
|
|
+ this.name,
|
|
|
+ this.information,
|
|
|
+ this.price = 0,
|
|
|
+ this.state = CourseStatusEnum.Unknown,
|
|
|
+ this.viewRange = CourseViewRangeEnum.All,
|
|
|
+ this.audienceType = CourseAudienceTypeEnum.Unknown,
|
|
|
+ this.starTime,
|
|
|
+ this.duration = 0,
|
|
|
+ this.deadline,
|
|
|
+ this.applyState = ApplyStateEnum.NotApply,
|
|
|
+ this.poster,
|
|
|
+ this.teacher,
|
|
|
+ this.students,
|
|
|
+ this.conversationId,
|
|
|
+ this.channelDatas,
|
|
|
+ this.createAdmin,
|
|
|
+ this.owners,
|
|
|
+ this.teacherState = false,
|
|
|
+ this.startCourseInAdvance = false,
|
|
|
+ this.actualStartTime,
|
|
|
+ this.actualEndTime,
|
|
|
+ this.assistantInfos,
|
|
|
+ this.guestInfos,
|
|
|
+ this.credentialCode,
|
|
|
+ this.courseNotice,
|
|
|
+ this.meetingMemberInfos,
|
|
|
+ this.availability = CourseAvailabilityEnum.Public,
|
|
|
+ this.authorizedUserInfos,
|
|
|
+ this.authorizedGroupInfos,
|
|
|
+ this.audienceInfos,
|
|
|
+ this.caseLabelInfos,
|
|
|
+ this.coursewareToken,
|
|
|
+ this.courseType = CourseTypeEnum.Unknown,
|
|
|
+ this.experts,
|
|
|
+ this.courseLabelInfos,
|
|
|
+ this.isAgentCourse = false,
|
|
|
+ this.isStick = false,
|
|
|
+ this.sort = 0,
|
|
|
+ this.courseVideoInfos,
|
|
|
+ this.courseAppearType = CourseAppearTypeEnum.Unknown,
|
|
|
+ this.courseAlbumInfos,
|
|
|
+ this.playCount = 0,
|
|
|
+ DateTime? createTime,
|
|
|
+ DateTime? updateTime,
|
|
|
+ }) : super(
|
|
|
+ createTime: createTime,
|
|
|
+ updateTime: updateTime,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory OnlineTrainingDTO.fromJson(Map<String, dynamic> map) {
|
|
|
+ return OnlineTrainingDTO(
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ information: map['Information'],
|
|
|
+ price: double.parse(map['Price'].toString()),
|
|
|
+ state: CourseStatusEnum.values.firstWhere((e) => e.index == map['State']),
|
|
|
+ viewRange: CourseViewRangeEnum.values.firstWhere((e) => e.index == map['ViewRange']),
|
|
|
+ audienceType: CourseAudienceTypeEnum.values.firstWhere((e) => e.index == map['AudienceType']),
|
|
|
+ starTime: map['StarTime'] != null ? DateTime.parse(map['StarTime']) : null,
|
|
|
+ duration: map['Duration'],
|
|
|
+ deadline: map['Deadline'] != null ? DateTime.parse(map['Deadline']) : null,
|
|
|
+ applyState: ApplyStateEnum.values.firstWhere((e) => e.index == map['ApplyState']),
|
|
|
+ poster: map['Poster'],
|
|
|
+ teacher: map['Teacher'] != null ? TeacherView.fromJson(map['Teacher']) : null,
|
|
|
+ conversationId: map['ConversationId'],
|
|
|
+ createAdmin: map['CreateAdmin'] != null ? AdminView.fromJson(map['CreateAdmin']) : null,
|
|
|
+ teacherState: map['TeacherState'],
|
|
|
+ startCourseInAdvance: map['StartCourseInAdvance'],
|
|
|
+ actualStartTime: map['ActualStartTime'] != null ? DateTime.parse(map['ActualStartTime']) : null,
|
|
|
+ actualEndTime: map['ActualEndTime'] != null ? DateTime.parse(map['ActualEndTime']) : null,
|
|
|
+ assistantInfos: map['AssistantInfos'] != null ? (map['AssistantInfos'] as List).map((e)=>UserView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ guestInfos: map['GuestInfos'] != null ? (map['GuestInfos'] as List).map((e)=>UserView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ credentialCode: map['CredentialCode'],
|
|
|
+ courseNotice: map['CourseNotice'],
|
|
|
+ meetingMemberInfos: map['MeetingMemberInfos'] != null ? (map['MeetingMemberInfos'] as List).map((e)=>UserView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ availability: CourseAvailabilityEnum.values.firstWhere((e) => e.index == map['Availability']),
|
|
|
+ authorizedUserInfos: map['AuthorizedUserInfos'] != null ? (map['AuthorizedUserInfos'] as List).map((e)=>UserView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ authorizedGroupInfos: map['AuthorizedGroupInfos'] != null ? (map['AuthorizedGroupInfos'] as List).map((e)=>GroupView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ audienceInfos: map['AudienceInfos'] != null ? (map['AudienceInfos'] as List).map((e)=>AudienceView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ caseLabelInfos: map['CaseLabelInfos'] != null ? (map['CaseLabelInfos'] as List).map((e)=>CaseLabelView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ coursewareToken: map['CoursewareToken'],
|
|
|
+ courseType: CourseTypeEnum.values.firstWhere((e) => e.index == map['CourseType']),
|
|
|
+ courseLabelInfos: map['CourseLabelInfos'] != null ? (map['CourseLabelInfos'] as List).map((e)=>CustomerLabelView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ isAgentCourse: map['IsAgentCourse'],
|
|
|
+ isStick: map['IsStick'],
|
|
|
+ sort: map['Sort'],
|
|
|
+ courseVideoInfos: map['CourseVideoInfos'] != null ? (map['CourseVideoInfos'] as List).map((e)=>OnlineVideoDTO.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ courseAppearType: CourseAppearTypeEnum.values.firstWhere((e) => e.index == map['CourseAppearType']),
|
|
|
+ courseAlbumInfos: map['CourseAlbumInfos'] != null ? (map['CourseAlbumInfos'] as List).map((e)=>CourseAlbumView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ playCount: map['PlayCount'],
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(name != null)
|
|
|
+ map['Name'] = name;
|
|
|
+ if(information != null)
|
|
|
+ map['Information'] = information;
|
|
|
+ map['Price'] = price;
|
|
|
+ map['State'] = state.index;
|
|
|
+ map['ViewRange'] = viewRange.index;
|
|
|
+ map['AudienceType'] = audienceType.index;
|
|
|
+ if(starTime != null)
|
|
|
+ map['StarTime'] = JsonRpcUtils.dateFormat(starTime!);
|
|
|
+ map['Duration'] = duration;
|
|
|
+ if(deadline != null)
|
|
|
+ map['Deadline'] = JsonRpcUtils.dateFormat(deadline!);
|
|
|
+ map['ApplyState'] = applyState.index;
|
|
|
+ if(poster != null)
|
|
|
+ map['Poster'] = poster;
|
|
|
+ if(teacher != null)
|
|
|
+ map['Teacher'] = teacher;
|
|
|
+ if(students != null)
|
|
|
+ map['Students'] = students;
|
|
|
+ if(conversationId != null)
|
|
|
+ map['ConversationId'] = conversationId;
|
|
|
+ if(channelDatas != null)
|
|
|
+ map['ChannelDatas'] = channelDatas;
|
|
|
+ if(createAdmin != null)
|
|
|
+ map['CreateAdmin'] = createAdmin;
|
|
|
+ if(owners != null)
|
|
|
+ map['Owners'] = owners;
|
|
|
+ map['TeacherState'] = teacherState;
|
|
|
+ map['StartCourseInAdvance'] = startCourseInAdvance;
|
|
|
+ if(actualStartTime != null)
|
|
|
+ map['ActualStartTime'] = JsonRpcUtils.dateFormat(actualStartTime!);
|
|
|
+ if(actualEndTime != null)
|
|
|
+ map['ActualEndTime'] = JsonRpcUtils.dateFormat(actualEndTime!);
|
|
|
+ if(assistantInfos != null)
|
|
|
+ map['AssistantInfos'] = assistantInfos;
|
|
|
+ if(guestInfos != null)
|
|
|
+ map['GuestInfos'] = guestInfos;
|
|
|
+ if(credentialCode != null)
|
|
|
+ map['CredentialCode'] = credentialCode;
|
|
|
+ if(courseNotice != null)
|
|
|
+ map['CourseNotice'] = courseNotice;
|
|
|
+ if(meetingMemberInfos != null)
|
|
|
+ map['MeetingMemberInfos'] = meetingMemberInfos;
|
|
|
+ map['Availability'] = availability.index;
|
|
|
+ if(authorizedUserInfos != null)
|
|
|
+ map['AuthorizedUserInfos'] = authorizedUserInfos;
|
|
|
+ if(authorizedGroupInfos != null)
|
|
|
+ map['AuthorizedGroupInfos'] = authorizedGroupInfos;
|
|
|
+ if(audienceInfos != null)
|
|
|
+ map['AudienceInfos'] = audienceInfos;
|
|
|
+ if(caseLabelInfos != null)
|
|
|
+ map['CaseLabelInfos'] = caseLabelInfos;
|
|
|
+ if(coursewareToken != null)
|
|
|
+ map['CoursewareToken'] = coursewareToken;
|
|
|
+ map['CourseType'] = courseType.index;
|
|
|
+ if(experts != null)
|
|
|
+ map['Experts'] = experts;
|
|
|
+ if(courseLabelInfos != null)
|
|
|
+ map['CourseLabelInfos'] = courseLabelInfos;
|
|
|
+ map['IsAgentCourse'] = isAgentCourse;
|
|
|
+ map['IsStick'] = isStick;
|
|
|
+ map['Sort'] = sort;
|
|
|
+ if(courseVideoInfos != null)
|
|
|
+ map['CourseVideoInfos'] = courseVideoInfos;
|
|
|
+ map['CourseAppearType'] = courseAppearType.index;
|
|
|
+ if(courseAlbumInfos != null)
|
|
|
+ map['CourseAlbumInfos'] = courseAlbumInfos;
|
|
|
+ map['PlayCount'] = playCount;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class QualifiedView {
|
|
|
+ QualifiedState qualifiedState;
|
|
|
+ QualityType qualityType;
|
|
|
+
|
|
|
+ QualifiedView({
|
|
|
+ this.qualifiedState = QualifiedState.UnSet,
|
|
|
+ this.qualityType = QualityType.None,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory QualifiedView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return QualifiedView(
|
|
|
+ qualifiedState: QualifiedState.values.firstWhere((e) => e.index == map['QualifiedState']),
|
|
|
+ qualityType: QualityType.values.firstWhere((e) => e.index == map['QualityType']),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ map['QualifiedState'] = qualifiedState.index;
|
|
|
+ map['QualityType'] = qualityType.index;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ScreenshotView {
|
|
|
+ String? createUserCode;
|
|
|
+ String? createUserName;
|
|
|
+ String? prelDiagnosis;
|
|
|
+ String? examDoctor;
|
|
|
+
|
|
|
+ ScreenshotView({
|
|
|
+ this.createUserCode,
|
|
|
+ this.createUserName,
|
|
|
+ this.prelDiagnosis,
|
|
|
+ this.examDoctor,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ScreenshotView.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ScreenshotView(
|
|
|
+ createUserCode: map['CreateUserCode'],
|
|
|
+ createUserName: map['CreateUserName'],
|
|
|
+ prelDiagnosis: map['PrelDiagnosis'],
|
|
|
+ examDoctor: map['ExamDoctor'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(createUserCode != null)
|
|
|
+ map['CreateUserCode'] = createUserCode;
|
|
|
+ if(createUserName != null)
|
|
|
+ map['CreateUserName'] = createUserName;
|
|
|
+ if(prelDiagnosis != null)
|
|
|
+ map['PrelDiagnosis'] = prelDiagnosis;
|
|
|
+ if(examDoctor != null)
|
|
|
+ map['ExamDoctor'] = examDoctor;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class RemoteDiagnosisDTO extends BaseDTO{
|
|
|
+ String? code;
|
|
|
+ String? examId;
|
|
|
+ OrganizationView? organizationInfo;
|
|
|
+ DeviceView? deviceInfo;
|
|
|
+ PatientView? patientInfo;
|
|
|
+ ScreenshotView? screenshotInfo;
|
|
|
+ QualifiedView? qualifiedInfo;
|
|
|
+ List<DiagnosisView >? diagnosisInfos;
|
|
|
+ List<String >? shareUserCodes;
|
|
|
+ String? customDoctor;
|
|
|
+ String? customOrganzation;
|
|
|
+ String? equipmentSN;
|
|
|
+ List<RemoteDiagnosisFileView >? fileInfos;
|
|
|
+ RecordStatusEnum recordStatus;
|
|
|
+ String? creatorCode;
|
|
|
+ String? tags;
|
|
|
+ RecordCreateTypeEnum createType;
|
|
|
+ List<DataItemDTO >? patientDataInfo;
|
|
|
+ List<PatientInfoExt >? patientInfoExtList;
|
|
|
+ String? patientType;
|
|
|
+ List<String >? readUsers;
|
|
|
+ List<String >? associatedExamCodes;
|
|
|
+
|
|
|
+ RemoteDiagnosisDTO({
|
|
|
+ this.code,
|
|
|
+ this.examId,
|
|
|
+ this.organizationInfo,
|
|
|
+ this.deviceInfo,
|
|
|
+ this.patientInfo,
|
|
|
+ this.screenshotInfo,
|
|
|
+ this.qualifiedInfo,
|
|
|
+ this.diagnosisInfos,
|
|
|
+ this.shareUserCodes,
|
|
|
+ this.customDoctor,
|
|
|
+ this.customOrganzation,
|
|
|
+ this.equipmentSN,
|
|
|
+ this.fileInfos,
|
|
|
+ this.recordStatus = RecordStatusEnum.NotScanned,
|
|
|
+ this.creatorCode,
|
|
|
+ this.tags,
|
|
|
+ this.createType = RecordCreateTypeEnum.Reservation,
|
|
|
+ this.patientDataInfo,
|
|
|
+ this.patientInfoExtList,
|
|
|
+ this.patientType,
|
|
|
+ this.readUsers,
|
|
|
+ this.associatedExamCodes,
|
|
|
+ DateTime? createTime,
|
|
|
+ DateTime? updateTime,
|
|
|
+ }) : super(
|
|
|
+ createTime: createTime,
|
|
|
+ updateTime: updateTime,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory RemoteDiagnosisDTO.fromJson(Map<String, dynamic> map) {
|
|
|
+ return RemoteDiagnosisDTO(
|
|
|
+ code: map['Code'],
|
|
|
+ examId: map['ExamId'],
|
|
|
+ organizationInfo: map['OrganizationInfo'] != null ? OrganizationView.fromJson(map['OrganizationInfo']) : null,
|
|
|
+ deviceInfo: map['DeviceInfo'] != null ? DeviceView.fromJson(map['DeviceInfo']) : null,
|
|
|
+ patientInfo: map['PatientInfo'] != null ? PatientView.fromJson(map['PatientInfo']) : null,
|
|
|
+ screenshotInfo: map['ScreenshotInfo'] != null ? ScreenshotView.fromJson(map['ScreenshotInfo']) : null,
|
|
|
+ qualifiedInfo: map['QualifiedInfo'] != null ? QualifiedView.fromJson(map['QualifiedInfo']) : null,
|
|
|
+ diagnosisInfos: map['DiagnosisInfos'] != null ? (map['DiagnosisInfos'] as List).map((e)=>DiagnosisView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ shareUserCodes: map['ShareUserCodes'] != null ? map['ShareUserCodes'].cast<String>().toList() : null,
|
|
|
+ customDoctor: map['CustomDoctor'],
|
|
|
+ customOrganzation: map['CustomOrganzation'],
|
|
|
+ equipmentSN: map['EquipmentSN'],
|
|
|
+ fileInfos: map['FileInfos'] != null ? (map['FileInfos'] as List).map((e)=>RemoteDiagnosisFileView.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ recordStatus: RecordStatusEnum.values.firstWhere((e) => e.index == map['RecordStatus']),
|
|
|
+ creatorCode: map['CreatorCode'],
|
|
|
+ tags: map['Tags'],
|
|
|
+ createType: RecordCreateTypeEnum.values.firstWhere((e) => e.index == map['CreateType']),
|
|
|
+ patientDataInfo: map['PatientDataInfo'] != null ? (map['PatientDataInfo'] as List).map((e)=>DataItemDTO.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ patientInfoExtList: map['PatientInfoExtList'] != null ? (map['PatientInfoExtList'] as List).map((e)=>PatientInfoExt.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ patientType: map['PatientType'],
|
|
|
+ readUsers: map['ReadUsers'] != null ? map['ReadUsers'].cast<String>().toList() : null,
|
|
|
+ associatedExamCodes: map['AssociatedExamCodes'] != null ? map['AssociatedExamCodes'].cast<String>().toList() : null,
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(code != null)
|
|
|
+ map['Code'] = code;
|
|
|
+ if(examId != null)
|
|
|
+ map['ExamId'] = examId;
|
|
|
+ if(organizationInfo != null)
|
|
|
+ map['OrganizationInfo'] = organizationInfo;
|
|
|
+ if(deviceInfo != null)
|
|
|
+ map['DeviceInfo'] = deviceInfo;
|
|
|
+ if(patientInfo != null)
|
|
|
+ map['PatientInfo'] = patientInfo;
|
|
|
+ if(screenshotInfo != null)
|
|
|
+ map['ScreenshotInfo'] = screenshotInfo;
|
|
|
+ if(qualifiedInfo != null)
|
|
|
+ map['QualifiedInfo'] = qualifiedInfo;
|
|
|
+ if(diagnosisInfos != null)
|
|
|
+ map['DiagnosisInfos'] = diagnosisInfos;
|
|
|
+ if(shareUserCodes != null)
|
|
|
+ map['ShareUserCodes'] = shareUserCodes;
|
|
|
+ if(customDoctor != null)
|
|
|
+ map['CustomDoctor'] = customDoctor;
|
|
|
+ if(customOrganzation != null)
|
|
|
+ map['CustomOrganzation'] = customOrganzation;
|
|
|
+ if(equipmentSN != null)
|
|
|
+ map['EquipmentSN'] = equipmentSN;
|
|
|
+ if(fileInfos != null)
|
|
|
+ map['FileInfos'] = fileInfos;
|
|
|
+ map['RecordStatus'] = recordStatus.index;
|
|
|
+ if(creatorCode != null)
|
|
|
+ map['CreatorCode'] = creatorCode;
|
|
|
+ if(tags != null)
|
|
|
+ map['Tags'] = tags;
|
|
|
+ map['CreateType'] = createType.index;
|
|
|
+ if(patientDataInfo != null)
|
|
|
+ map['PatientDataInfo'] = patientDataInfo;
|
|
|
+ if(patientInfoExtList != null)
|
|
|
+ map['PatientInfoExtList'] = patientInfoExtList;
|
|
|
+ if(patientType != null)
|
|
|
+ map['PatientType'] = patientType;
|
|
|
+ if(readUsers != null)
|
|
|
+ map['ReadUsers'] = readUsers;
|
|
|
+ if(associatedExamCodes != null)
|
|
|
+ map['AssociatedExamCodes'] = associatedExamCodes;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class CourseAlbumDTO extends BaseCourseAlbumDTO{
|
|
|
+ String? cover;
|
|
|
+ List<String >? courseCodes;
|
|
|
+ String? introduction;
|
|
|
+ List<String >? courseLabelCodes;
|
|
|
+ String? teacherCode;
|
|
|
+ String? teacherName;
|
|
|
+ CourseViewRangeEnum viewRange;
|
|
|
+ double price;
|
|
|
+ DateTime? createTime;
|
|
|
+ int sort;
|
|
|
+ bool isStick;
|
|
|
+
|
|
|
+ CourseAlbumDTO({
|
|
|
+ this.cover,
|
|
|
+ this.courseCodes,
|
|
|
+ this.introduction,
|
|
|
+ this.courseLabelCodes,
|
|
|
+ this.teacherCode,
|
|
|
+ this.teacherName,
|
|
|
+ this.viewRange = CourseViewRangeEnum.All,
|
|
|
+ this.price = 0,
|
|
|
+ this.createTime,
|
|
|
+ this.sort = 0,
|
|
|
+ this.isStick = false,
|
|
|
+ String? code,
|
|
|
+ String? name,
|
|
|
+ }) : super(
|
|
|
+ code: code,
|
|
|
+ name: name,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory CourseAlbumDTO.fromJson(Map<String, dynamic> map) {
|
|
|
+ return CourseAlbumDTO(
|
|
|
+ cover: map['Cover'],
|
|
|
+ courseCodes: map['CourseCodes'] != null ? map['CourseCodes'].cast<String>().toList() : null,
|
|
|
+ introduction: map['Introduction'],
|
|
|
+ courseLabelCodes: map['CourseLabelCodes'] != null ? map['CourseLabelCodes'].cast<String>().toList() : null,
|
|
|
+ teacherCode: map['TeacherCode'],
|
|
|
+ teacherName: map['TeacherName'],
|
|
|
+ viewRange: CourseViewRangeEnum.values.firstWhere((e) => e.index == map['ViewRange']),
|
|
|
+ price: double.parse(map['Price'].toString()),
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ sort: map['Sort'],
|
|
|
+ isStick: map['IsStick'],
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(cover != null)
|
|
|
+ map['Cover'] = cover;
|
|
|
+ if(courseCodes != null)
|
|
|
+ map['CourseCodes'] = courseCodes;
|
|
|
+ if(introduction != null)
|
|
|
+ map['Introduction'] = introduction;
|
|
|
+ if(courseLabelCodes != null)
|
|
|
+ map['CourseLabelCodes'] = courseLabelCodes;
|
|
|
+ if(teacherCode != null)
|
|
|
+ map['TeacherCode'] = teacherCode;
|
|
|
+ if(teacherName != null)
|
|
|
+ map['TeacherName'] = teacherName;
|
|
|
+ map['ViewRange'] = viewRange.index;
|
|
|
+ map['Price'] = price;
|
|
|
+ if(createTime != null)
|
|
|
+ map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
+ map['Sort'] = sort;
|
|
|
+ map['IsStick'] = isStick;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class CourseAlbumDetailDTO extends CourseAlbumDTO{
|
|
|
+ List<CourseInfoDetailDTO >? courseInfos;
|
|
|
+ int studentCount;
|
|
|
+
|
|
|
+ CourseAlbumDetailDTO({
|
|
|
+ this.courseInfos,
|
|
|
+ this.studentCount = 0,
|
|
|
+ String? cover,
|
|
|
+ List<String >? courseCodes,
|
|
|
+ String? introduction,
|
|
|
+ List<String >? courseLabelCodes,
|
|
|
+ String? teacherCode,
|
|
|
+ String? teacherName,
|
|
|
+ CourseViewRangeEnum viewRange = CourseViewRangeEnum.All,
|
|
|
+ double price = 0,
|
|
|
+ DateTime? createTime,
|
|
|
+ int sort = 0,
|
|
|
+ bool isStick = false,
|
|
|
+ String? code,
|
|
|
+ String? name,
|
|
|
+ }) : super(
|
|
|
+ cover: cover,
|
|
|
+ courseCodes: courseCodes,
|
|
|
+ introduction: introduction,
|
|
|
+ courseLabelCodes: courseLabelCodes,
|
|
|
+ teacherCode: teacherCode,
|
|
|
+ teacherName: teacherName,
|
|
|
+ viewRange: viewRange,
|
|
|
+ price: price,
|
|
|
+ createTime: createTime,
|
|
|
+ sort: sort,
|
|
|
+ isStick: isStick,
|
|
|
+ code: code,
|
|
|
+ name: name,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory CourseAlbumDetailDTO.fromJson(Map<String, dynamic> map) {
|
|
|
+ return CourseAlbumDetailDTO(
|
|
|
+ courseInfos: map['CourseInfos'] != null ? (map['CourseInfos'] as List).map((e)=>CourseInfoDetailDTO.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ studentCount: map['StudentCount'],
|
|
|
+ cover: map['Cover'],
|
|
|
+ courseCodes: map['CourseCodes'] != null ? map['CourseCodes'].cast<String>().toList() : null,
|
|
|
+ introduction: map['Introduction'],
|
|
|
+ courseLabelCodes: map['CourseLabelCodes'] != null ? map['CourseLabelCodes'].cast<String>().toList() : null,
|
|
|
+ teacherCode: map['TeacherCode'],
|
|
|
+ teacherName: map['TeacherName'],
|
|
|
+ viewRange: CourseViewRangeEnum.values.firstWhere((e) => e.index == map['ViewRange']),
|
|
|
+ price: double.parse(map['Price'].toString()),
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ sort: map['Sort'],
|
|
|
+ isStick: map['IsStick'],
|
|
|
+ code: map['Code'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(courseInfos != null)
|
|
|
+ map['CourseInfos'] = courseInfos;
|
|
|
+ map['StudentCount'] = studentCount;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
class BaseCoursePageDTO {
|
|
|
String? code;
|
|
|
String? name;
|