Uat_Study
he 2022-11-28 17:23:41 +08:00
parent 63ba5e4823
commit 551210901b
4 changed files with 67 additions and 22 deletions

View File

@ -251,15 +251,14 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
public string CreateUserName { get; set; } public string CreateUserName { get; set; }
public List<string> FileNameList { get; set; }
public List<ImageInfo> FileList { get; set; }
public List<string> ImagePathList { get; set; }
} }
public class GetMedicalReviewDialogInDto public class GetMedicalReviewDialogInDto
{ {
[NotDefault] [NotDefault]
@ -413,16 +412,16 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
public string DialogCloseReason { get; set; } = string.Empty; public string DialogCloseReason { get; set; } = string.Empty;
} }
public class SaveMedicalReviewInfoInDto public class SaveMedicalReviewInfoInDto
{ {
public bool IsSendDialog { get; set; } public bool IsSendDialog { get; set; }
public Guid TaskMedicalReviewId { get; set; } public Guid TaskMedicalReviewId { get; set; }
public List<string> FileNameList { get; set; }
public List<string> ImagePathList { get; set; } public List<ImageInfo> FileList { get; set; } = new List<ImageInfo>();
/// <summary> /// <summary>
@ -469,10 +468,7 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
public string Questioning { get; set; } = string.Empty; public string Questioning { get; set; } = string.Empty;
public List<string> FileNameList { get; set; } public List<ImageInfo> FileList { get; set; }
public List<string> ImagePathList { get; set; }
/// <summary> /// <summary>
/// 审核建议 /// 审核建议

View File

@ -10,6 +10,7 @@ using IRaCIS.Core.Application.Service.Reading.Dto;
using IRaCIS.Core.Domain.Share; using IRaCIS.Core.Domain.Share;
using Panda.DynamicWebApi.Attributes; using Panda.DynamicWebApi.Attributes;
using IRaCIS.Core.Application.Contracts; using IRaCIS.Core.Application.Contracts;
using Newtonsoft.Json;
namespace IRaCIS.Core.Application.Service namespace IRaCIS.Core.Application.Service
{ {
@ -331,12 +332,12 @@ namespace IRaCIS.Core.Application.Service
IsHaveQuestion = inDto.IsHaveQuestion, IsHaveQuestion = inDto.IsHaveQuestion,
Questioning = inDto.Questioning, Questioning = inDto.Questioning,
IsSendMessage = inDto.IsSendDialog && inDto.IsHaveQuestion, IsSendMessage = inDto.IsSendDialog && inDto.IsHaveQuestion,
ImagePath = string.Join(',',inDto.ImagePathList), ImagePath = JsonConvert.SerializeObject(inDto.FileList),
FileName = string.Join(',', inDto.FileNameList),
AuditAdviceEnum = inDto.AuditAdviceEnum, AuditAdviceEnum = inDto.AuditAdviceEnum,
SaveConclusionTime = DateTime.Now, SaveConclusionTime = DateTime.Now,
}); ; });
var medicalReview = await _taskMedicalReviewRepository.Where(x => x.Id == inDto.TaskMedicalReviewId).FirstNotNullAsync(); var medicalReview = await _taskMedicalReviewRepository.Where(x => x.Id == inDto.TaskMedicalReviewId).FirstNotNullAsync();
if (inDto.IsSendDialog&& !medicalReview.IsSendMessage && inDto.IsHaveQuestion) if (inDto.IsSendDialog&& !medicalReview.IsSendMessage && inDto.IsHaveQuestion)
@ -350,9 +351,9 @@ namespace IRaCIS.Core.Application.Service
IsHaveQuestion=inDto.IsHaveQuestion, IsHaveQuestion=inDto.IsHaveQuestion,
Questioning=inDto.Questioning, Questioning=inDto.Questioning,
VisitTaskId= medicalReview.VisitTaskId, VisitTaskId= medicalReview.VisitTaskId,
FileName = medicalReview.FileName,
UserTypeEnumInt = _userInfo.UserTypeEnumInt, UserTypeEnumInt = _userInfo.UserTypeEnumInt,
ImagePath= medicalReview.ImagePath, ImagePath = JsonConvert.SerializeObject(inDto.FileList),
}); });
} }

View File

@ -9,6 +9,7 @@ using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations.Schema;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
using Newtonsoft.Json;
namespace IRaCIS.Core.Domain.Models namespace IRaCIS.Core.Domain.Models
{ {
@ -171,11 +172,41 @@ namespace IRaCIS.Core.Domain.Models
/// </summary> /// </summary>
public bool IsInvalid { get; set; } public bool IsInvalid { get; set; }
/// <summary>
/// 文件
/// </summary>
[NotMapped] [NotMapped]
public List<string> FileNameList => this.FileName.Split(',').ToList(); public List<ImageInfo> FileList
{
get
{
try
{
return JsonConvert.DeserializeObject<List<ImageInfo>>(this.ImagePath);
}
catch (Exception)
{
return new List<ImageInfo>();
}
}
}
[NotMapped]
public List<string> ImagePathList => this.ImagePath.Split(',').ToList();
} }
#region 文件对象
public class ImageInfo
{
public string FileName { get; set; }
public string ImagePath { get; set; }
}
#endregion
} }

View File

@ -102,11 +102,28 @@ namespace IRaCIS.Core.Domain.Models
public TaskMedicalReview TaskMedicalReview { get; set; } public TaskMedicalReview TaskMedicalReview { get; set; }
/// <summary>
/// 文件
/// </summary>
[NotMapped] [NotMapped]
public List<string> FileNameList => this.FileName.Split(',').ToList(); public List<ImageInfo> FileList
{
get
{
[NotMapped]
public List<string> ImagePathList => this.ImagePath.Split(',').ToList(); try
{
return JsonConvert.DeserializeObject<List<ImageInfo>>(this.ImagePath);
}
catch (Exception)
{
return new List<ImageInfo>();
}
}
}
} }