|
@@ -1492,4 +1492,711 @@ class DownloadFileRequest extends AppletAPIBaseRequest{
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+class VinnoTemplateInfo {
|
|
|
+ String? templateName;
|
|
|
+ String? templateUrl;
|
|
|
+
|
|
|
+ VinnoTemplateInfo({
|
|
|
+ this.templateName,
|
|
|
+ this.templateUrl,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory VinnoTemplateInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return VinnoTemplateInfo(
|
|
|
+ templateName: map['TemplateName'],
|
|
|
+ templateUrl: map['TemplateUrl'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(templateName != null) {
|
|
|
+ map['TemplateName'] = templateName;
|
|
|
+ }
|
|
|
+ if(templateUrl != null) {
|
|
|
+ map['TemplateUrl'] = templateUrl;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class GetReportTemplatesRequest extends AppletAPIBaseRequest{
|
|
|
+ String? languageCode;
|
|
|
+
|
|
|
+ GetReportTemplatesRequest({
|
|
|
+ this.languageCode,
|
|
|
+ String? openId,
|
|
|
+ }) : super(
|
|
|
+ openId: openId,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory GetReportTemplatesRequest.fromJson(Map<String, dynamic> map) {
|
|
|
+ return GetReportTemplatesRequest(
|
|
|
+ languageCode: map['LanguageCode'],
|
|
|
+ openId: map['OpenId'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(languageCode != null)
|
|
|
+ map['LanguageCode'] = languageCode;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class GetThesaurusTemplatesRequest extends AppletAPIBaseRequest{
|
|
|
+ String? languageCode;
|
|
|
+
|
|
|
+ GetThesaurusTemplatesRequest({
|
|
|
+ this.languageCode,
|
|
|
+ String? openId,
|
|
|
+ }) : super(
|
|
|
+ openId: openId,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory GetThesaurusTemplatesRequest.fromJson(Map<String, dynamic> map) {
|
|
|
+ return GetThesaurusTemplatesRequest(
|
|
|
+ languageCode: map['LanguageCode'],
|
|
|
+ openId: map['OpenId'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(languageCode != null)
|
|
|
+ map['LanguageCode'] = languageCode;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportElementTagMessage {
|
|
|
+ String? id;
|
|
|
+ String? name;
|
|
|
+
|
|
|
+ ReportElementTagMessage({
|
|
|
+ this.id,
|
|
|
+ this.name,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportElementTagMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportElementTagMessage(
|
|
|
+ id: map['Id'],
|
|
|
+ name: map['Name'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(id != null) {
|
|
|
+ map['Id'] = id;
|
|
|
+ }
|
|
|
+ if(name != null) {
|
|
|
+ map['Name'] = name;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportBaseElementValueMessage {
|
|
|
+
|
|
|
+ ReportBaseElementValueMessage();
|
|
|
+
|
|
|
+ factory ReportBaseElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportBaseElementValueMessage(
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportTextElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ String? text;
|
|
|
+
|
|
|
+ ReportTextElementValueMessage({
|
|
|
+ this.text,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportTextElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportTextElementValueMessage(
|
|
|
+ text: map['Text'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(text != null)
|
|
|
+ map['Text'] = text;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportIntegerElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ int value;
|
|
|
+
|
|
|
+ ReportIntegerElementValueMessage({
|
|
|
+ this.value = 0,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportIntegerElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportIntegerElementValueMessage(
|
|
|
+ value: map['Value'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ map['Value'] = value;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportFloatElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ double value;
|
|
|
+
|
|
|
+ ReportFloatElementValueMessage({
|
|
|
+ this.value = 0,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportFloatElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportFloatElementValueMessage(
|
|
|
+ value: double.parse(map['Value'].toString()),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ map['Value'] = value;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportBufferImageElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ List<int>? value;
|
|
|
+
|
|
|
+ ReportBufferImageElementValueMessage({
|
|
|
+ this.value,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportBufferImageElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ final valueData = map['Value'];
|
|
|
+ return ReportBufferImageElementValueMessage(
|
|
|
+ value: valueData != null ? (valueData as List).map((e) => e as int).toList(): null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(value != null)
|
|
|
+ map['Value'] = value;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportDateTimeElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ DateTime? value;
|
|
|
+
|
|
|
+ ReportDateTimeElementValueMessage({
|
|
|
+ this.value,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportDateTimeElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportDateTimeElementValueMessage(
|
|
|
+ value: map['Value'] != null ? DateTime.parse(map['Value']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(value != null)
|
|
|
+ map['Value'] = JsonRpcUtils.dateFormat(value!);
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportFileElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ String? value;
|
|
|
+ String? examDataId;
|
|
|
+
|
|
|
+ ReportFileElementValueMessage({
|
|
|
+ this.value,
|
|
|
+ this.examDataId,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportFileElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportFileElementValueMessage(
|
|
|
+ value: map['Value'],
|
|
|
+ examDataId: map['ExamDataId'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(value != null)
|
|
|
+ map['Value'] = value;
|
|
|
+ if(examDataId != null)
|
|
|
+ map['ExamDataId'] = examDataId;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportImageListElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ List<ReportFileElementValueMessage>? value;
|
|
|
+
|
|
|
+ ReportImageListElementValueMessage({
|
|
|
+ this.value,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportImageListElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportImageListElementValueMessage(
|
|
|
+ value: map['Value'] != null ? (map['Value'] as List).map((e)=>ReportFileElementValueMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(value != null)
|
|
|
+ map['Value'] = value;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportStringListElementValueMessage extends ReportBaseElementValueMessage{
|
|
|
+ List<ReportTextElementValueMessage>? value;
|
|
|
+
|
|
|
+ ReportStringListElementValueMessage({
|
|
|
+ this.value,
|
|
|
+ }) : super(
|
|
|
+ );
|
|
|
+
|
|
|
+ factory ReportStringListElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportStringListElementValueMessage(
|
|
|
+ value: map['Value'] != null ? (map['Value'] as List).map((e)=>ReportTextElementValueMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(value != null)
|
|
|
+ map['Value'] = value;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportElementValues {
|
|
|
+ ReportTextElementValueMessage? textElement;
|
|
|
+ ReportIntegerElementValueMessage? integerElement;
|
|
|
+ ReportFloatElementValueMessage? floatElement;
|
|
|
+ ReportBufferImageElementValueMessage? bufferImageElement;
|
|
|
+ ReportDateTimeElementValueMessage? dateTimeElement;
|
|
|
+ ReportFileElementValueMessage? fileElement;
|
|
|
+ ReportImageListElementValueMessage? imageListElement;
|
|
|
+ ReportStringListElementValueMessage? stringListElement;
|
|
|
+
|
|
|
+ ReportElementValues({
|
|
|
+ this.textElement,
|
|
|
+ this.integerElement,
|
|
|
+ this.floatElement,
|
|
|
+ this.bufferImageElement,
|
|
|
+ this.dateTimeElement,
|
|
|
+ this.fileElement,
|
|
|
+ this.imageListElement,
|
|
|
+ this.stringListElement,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportElementValues.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportElementValues(
|
|
|
+ textElement: map['TextElement'] != null ? ReportTextElementValueMessage.fromJson(map['TextElement']) : null,
|
|
|
+ integerElement: map['IntegerElement'] != null ? ReportIntegerElementValueMessage.fromJson(map['IntegerElement']) : null,
|
|
|
+ floatElement: map['FloatElement'] != null ? ReportFloatElementValueMessage.fromJson(map['FloatElement']) : null,
|
|
|
+ bufferImageElement: map['BufferImageElement'] != null ? ReportBufferImageElementValueMessage.fromJson(map['BufferImageElement']) : null,
|
|
|
+ dateTimeElement: map['DateTimeElement'] != null ? ReportDateTimeElementValueMessage.fromJson(map['DateTimeElement']) : null,
|
|
|
+ fileElement: map['FileElement'] != null ? ReportFileElementValueMessage.fromJson(map['FileElement']) : null,
|
|
|
+ imageListElement: map['ImageListElement'] != null ? ReportImageListElementValueMessage.fromJson(map['ImageListElement']) : null,
|
|
|
+ stringListElement: map['StringListElement'] != null ? ReportStringListElementValueMessage.fromJson(map['StringListElement']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(textElement != null) {
|
|
|
+ map['TextElement'] = textElement;
|
|
|
+ }
|
|
|
+ if(integerElement != null) {
|
|
|
+ map['IntegerElement'] = integerElement;
|
|
|
+ }
|
|
|
+ if(floatElement != null) {
|
|
|
+ map['FloatElement'] = floatElement;
|
|
|
+ }
|
|
|
+ if(bufferImageElement != null) {
|
|
|
+ map['BufferImageElement'] = bufferImageElement;
|
|
|
+ }
|
|
|
+ if(dateTimeElement != null) {
|
|
|
+ map['DateTimeElement'] = dateTimeElement;
|
|
|
+ }
|
|
|
+ if(fileElement != null) {
|
|
|
+ map['FileElement'] = fileElement;
|
|
|
+ }
|
|
|
+ if(imageListElement != null) {
|
|
|
+ map['ImageListElement'] = imageListElement;
|
|
|
+ }
|
|
|
+ if(stringListElement != null) {
|
|
|
+ map['StringListElement'] = stringListElement;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportElementMessage {
|
|
|
+ ReportElementTagMessage? elementTag;
|
|
|
+ ReportElementValues? reportElementValue;
|
|
|
+
|
|
|
+ ReportElementMessage({
|
|
|
+ this.elementTag,
|
|
|
+ this.reportElementValue,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportElementMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportElementMessage(
|
|
|
+ elementTag: map['ElementTag'] != null ? ReportElementTagMessage.fromJson(map['ElementTag']) : null,
|
|
|
+ reportElementValue: map['ReportElementValue'] != null ? ReportElementValues.fromJson(map['ReportElementValue']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(elementTag != null) {
|
|
|
+ map['ElementTag'] = elementTag;
|
|
|
+ }
|
|
|
+ if(reportElementValue != null) {
|
|
|
+ map['ReportElementValue'] = reportElementValue;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class IReadOnlyCollection<T> {
|
|
|
+ int count;
|
|
|
+
|
|
|
+ IReadOnlyCollection({
|
|
|
+ this.count = 0,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory IReadOnlyCollection.fromJson(Map<String, dynamic> map) {
|
|
|
+ return IReadOnlyCollection(
|
|
|
+ count: map['Count'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ map['Count'] = count;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportMeasureTagMessage {
|
|
|
+ IReadOnlyCollection<String>? availableMethods;
|
|
|
+ String? baseType;
|
|
|
+ String? calculationId;
|
|
|
+ String? matchId;
|
|
|
+ String? method;
|
|
|
+ String? mode;
|
|
|
+ String? output;
|
|
|
+ String? outputV2;
|
|
|
+ String? unit;
|
|
|
+ String? userId;
|
|
|
+
|
|
|
+ ReportMeasureTagMessage({
|
|
|
+ this.availableMethods,
|
|
|
+ this.baseType,
|
|
|
+ this.calculationId,
|
|
|
+ this.matchId,
|
|
|
+ this.method,
|
|
|
+ this.mode,
|
|
|
+ this.output,
|
|
|
+ this.outputV2,
|
|
|
+ this.unit,
|
|
|
+ this.userId,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportMeasureTagMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportMeasureTagMessage(
|
|
|
+ availableMethods: map['AvailableMethods']?.cast<String>().toList(),
|
|
|
+ baseType: map['BaseType'],
|
|
|
+ calculationId: map['CalculationId'],
|
|
|
+ matchId: map['MatchId'],
|
|
|
+ method: map['Method'],
|
|
|
+ mode: map['Mode'],
|
|
|
+ output: map['Output'],
|
|
|
+ outputV2: map['OutputV2'],
|
|
|
+ unit: map['Unit'],
|
|
|
+ userId: map['UserId'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(availableMethods != null) {
|
|
|
+ map['AvailableMethods'] = availableMethods;
|
|
|
+ }
|
|
|
+ if(baseType != null) {
|
|
|
+ map['BaseType'] = baseType;
|
|
|
+ }
|
|
|
+ if(calculationId != null) {
|
|
|
+ map['CalculationId'] = calculationId;
|
|
|
+ }
|
|
|
+ if(matchId != null) {
|
|
|
+ map['MatchId'] = matchId;
|
|
|
+ }
|
|
|
+ if(method != null) {
|
|
|
+ map['Method'] = method;
|
|
|
+ }
|
|
|
+ if(mode != null) {
|
|
|
+ map['Mode'] = mode;
|
|
|
+ }
|
|
|
+ if(output != null) {
|
|
|
+ map['Output'] = output;
|
|
|
+ }
|
|
|
+ if(outputV2 != null) {
|
|
|
+ map['OutputV2'] = outputV2;
|
|
|
+ }
|
|
|
+ if(unit != null) {
|
|
|
+ map['Unit'] = unit;
|
|
|
+ }
|
|
|
+ if(userId != null) {
|
|
|
+ map['UserId'] = userId;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportMeasrueElementValueMessage {
|
|
|
+ ReportMeasureTagMessage? measureTag;
|
|
|
+ ReportTextElementValueMessage? elementValue;
|
|
|
+
|
|
|
+ ReportMeasrueElementValueMessage({
|
|
|
+ this.measureTag,
|
|
|
+ this.elementValue,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportMeasrueElementValueMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportMeasrueElementValueMessage(
|
|
|
+ measureTag: map['MeasureTag'] != null ? ReportMeasureTagMessage.fromJson(map['MeasureTag']) : null,
|
|
|
+ elementValue: map['ElementValue'] != null ? ReportTextElementValueMessage.fromJson(map['ElementValue']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(measureTag != null) {
|
|
|
+ map['MeasureTag'] = measureTag;
|
|
|
+ }
|
|
|
+ if(elementValue != null) {
|
|
|
+ map['ElementValue'] = elementValue;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportMeasureElementMessage {
|
|
|
+ ReportElementTagMessage? elementTag;
|
|
|
+ List<ReportMeasrueElementValueMessage>? reportElementValues;
|
|
|
+
|
|
|
+ ReportMeasureElementMessage({
|
|
|
+ this.elementTag,
|
|
|
+ this.reportElementValues,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportMeasureElementMessage.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportMeasureElementMessage(
|
|
|
+ elementTag: map['ElementTag'] != null ? ReportElementTagMessage.fromJson(map['ElementTag']) : null,
|
|
|
+ reportElementValues: map['ReportElementValues'] != null ? (map['ReportElementValues'] as List).map((e)=>ReportMeasrueElementValueMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(elementTag != null) {
|
|
|
+ map['ElementTag'] = elementTag;
|
|
|
+ }
|
|
|
+ if(reportElementValues != null) {
|
|
|
+ map['ReportElementValues'] = reportElementValues;
|
|
|
+ }
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+enum QualifiedState {
|
|
|
+ UnSet,
|
|
|
+ Qualified,
|
|
|
+ UnQualified,
|
|
|
+}
|
|
|
+
|
|
|
+enum QualityType {
|
|
|
+ None,
|
|
|
+ Qualified,
|
|
|
+ InformationUnCompleted,
|
|
|
+ ImageNotClear,
|
|
|
+ PositiveSiteNotClear,
|
|
|
+}
|
|
|
+
|
|
|
+class ReportResultInfo {
|
|
|
+ String? id;
|
|
|
+ List<ReportImageInfo>? previewImages;
|
|
|
+ String? template;
|
|
|
+ List<ReportElementMessage>? reportElementValues;
|
|
|
+ List<ReportMeasureElementMessage>? reportMeasureElementValues;
|
|
|
+ List<String>? tagCodeList;
|
|
|
+ DiagnosisOrganEnum organ;
|
|
|
+ QualifiedState qualifiedState;
|
|
|
+ QualityType qualityType;
|
|
|
+
|
|
|
+ ReportResultInfo({
|
|
|
+ this.id,
|
|
|
+ this.previewImages,
|
|
|
+ this.template,
|
|
|
+ this.reportElementValues,
|
|
|
+ this.reportMeasureElementValues,
|
|
|
+ this.tagCodeList,
|
|
|
+ this.organ = DiagnosisOrganEnum.Null,
|
|
|
+ this.qualifiedState = QualifiedState.UnSet,
|
|
|
+ this.qualityType = QualityType.None,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportResultInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportResultInfo(
|
|
|
+ id: map['Id'],
|
|
|
+ previewImages: map['PreviewImages'] != null ? (map['PreviewImages'] as List).map((e)=>ReportImageInfo.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ template: map['Template'],
|
|
|
+ reportElementValues: map['ReportElementValues'] != null ? (map['ReportElementValues'] as List).map((e)=>ReportElementMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ reportMeasureElementValues: map['ReportMeasureElementValues'] != null ? (map['ReportMeasureElementValues'] as List).map((e)=>ReportMeasureElementMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ tagCodeList: map['TagCodeList']?.cast<String>().toList(),
|
|
|
+ organ: DiagnosisOrganEnum.values.firstWhere((e) => e.index == map['Organ']),
|
|
|
+ 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>();
|
|
|
+ if(id != null) {
|
|
|
+ map['Id'] = id;
|
|
|
+ }
|
|
|
+ if(previewImages != null) {
|
|
|
+ map['PreviewImages'] = previewImages;
|
|
|
+ }
|
|
|
+ if(template != null) {
|
|
|
+ map['Template'] = template;
|
|
|
+ }
|
|
|
+ if(reportElementValues != null) {
|
|
|
+ map['ReportElementValues'] = reportElementValues;
|
|
|
+ }
|
|
|
+ if(reportMeasureElementValues != null) {
|
|
|
+ map['ReportMeasureElementValues'] = reportMeasureElementValues;
|
|
|
+ }
|
|
|
+ if(tagCodeList != null) {
|
|
|
+ map['TagCodeList'] = tagCodeList;
|
|
|
+ }
|
|
|
+ map['Organ'] = organ.index;
|
|
|
+ map['QualifiedState'] = qualifiedState.index;
|
|
|
+ map['QualityType'] = qualityType.index;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class SaveAppletReportRequest extends ReportResultInfo{
|
|
|
+ String? openId;
|
|
|
+ String? terminalRecordId;
|
|
|
+
|
|
|
+ SaveAppletReportRequest({
|
|
|
+ this.openId,
|
|
|
+ this.terminalRecordId,
|
|
|
+ String? id,
|
|
|
+ List<ReportImageInfo>? previewImages,
|
|
|
+ String? template,
|
|
|
+ List<ReportElementMessage>? reportElementValues,
|
|
|
+ List<ReportMeasureElementMessage>? reportMeasureElementValues,
|
|
|
+ List<String>? tagCodeList,
|
|
|
+ DiagnosisOrganEnum organ = DiagnosisOrganEnum.Null,
|
|
|
+ QualifiedState qualifiedState = QualifiedState.UnSet,
|
|
|
+ QualityType qualityType = QualityType.None,
|
|
|
+ }) : super(
|
|
|
+ id: id,
|
|
|
+ previewImages: previewImages,
|
|
|
+ template: template,
|
|
|
+ reportElementValues: reportElementValues,
|
|
|
+ reportMeasureElementValues: reportMeasureElementValues,
|
|
|
+ tagCodeList: tagCodeList,
|
|
|
+ organ: organ,
|
|
|
+ qualifiedState: qualifiedState,
|
|
|
+ qualityType: qualityType,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory SaveAppletReportRequest.fromJson(Map<String, dynamic> map) {
|
|
|
+ return SaveAppletReportRequest(
|
|
|
+ openId: map['OpenId'],
|
|
|
+ terminalRecordId: map['TerminalRecordId'],
|
|
|
+ id: map['Id'],
|
|
|
+ previewImages: map['PreviewImages'] != null ? (map['PreviewImages'] as List).map((e)=>ReportImageInfo.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ template: map['Template'],
|
|
|
+ reportElementValues: map['ReportElementValues'] != null ? (map['ReportElementValues'] as List).map((e)=>ReportElementMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ reportMeasureElementValues: map['ReportMeasureElementValues'] != null ? (map['ReportMeasureElementValues'] as List).map((e)=>ReportMeasureElementMessage.fromJson(e as Map<String,dynamic>)).toList() : null,
|
|
|
+ tagCodeList: map['TagCodeList']?.cast<String>().toList(),
|
|
|
+ organ: DiagnosisOrganEnum.values.firstWhere((e) => e.index == map['Organ']),
|
|
|
+ qualifiedState: QualifiedState.values.firstWhere((e) => e.index == map['QualifiedState']),
|
|
|
+ qualityType: QualityType.values.firstWhere((e) => e.index == map['QualityType']),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(openId != null)
|
|
|
+ map['OpenId'] = openId;
|
|
|
+ if(terminalRecordId != null)
|
|
|
+ map['TerminalRecordId'] = terminalRecordId;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class GetAppletReportRequest extends AppletAPIBaseRequest{
|
|
|
+ String? recordId;
|
|
|
+ String? reportId;
|
|
|
+
|
|
|
+ GetAppletReportRequest({
|
|
|
+ this.recordId,
|
|
|
+ this.reportId,
|
|
|
+ String? openId,
|
|
|
+ }) : super(
|
|
|
+ openId: openId,
|
|
|
+ );
|
|
|
+
|
|
|
+ factory GetAppletReportRequest.fromJson(Map<String, dynamic> map) {
|
|
|
+ return GetAppletReportRequest(
|
|
|
+ recordId: map['RecordId'],
|
|
|
+ reportId: map['ReportId'],
|
|
|
+ openId: map['OpenId'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = super.toJson();
|
|
|
+ if(recordId != null)
|
|
|
+ map['RecordId'] = recordId;
|
|
|
+ if(reportId != null)
|
|
|
+ map['ReportId'] = reportId;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
|