From 35d930fbfb529c44d445d73b8ed8270d7df23d3a Mon Sep 17 00:00:00 2001
From: he <10978375@qq.com>
Date: Thu, 20 Oct 2022 15:57:07 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=B8=80=E7=89=88?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Reading/Dto/ReadingQuestionViewModel.cs | 26 +++++++++++++
.../ReadingCriterionService.cs | 38 +++++++++++++++++++
.../ReadingCriterionDictionary.cs | 11 ++++++
3 files changed, 75 insertions(+)
diff --git a/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs b/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs
index 79039f051..d8e7fcaf4 100644
--- a/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs
+++ b/IRaCIS.Core.Application/Service/Reading/Dto/ReadingQuestionViewModel.cs
@@ -92,6 +92,22 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
}
+ public class SetDictionaryFollowVisitUseInDto
+ {
+ public Guid Id { get; set; }
+
+ public bool IsFollowVisitUse { get; set; }
+
+ }
+
+ public class SetDictionaryBaseLineUseInDto
+ {
+ public Guid Id { get; set; }
+
+ public bool IsBaseLineUse { get; set; }
+
+ }
+
public class GetAssessTypeInDto
{
[NotDefault]
@@ -118,6 +134,16 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
public string ChildGroup { get; set; }
+ ///
+ /// IsBaseUse
+ ///
+ public bool IsBaseLineUse { get; set; } = false;
+
+ ///
+ /// IsBaseUse
+ ///
+ public bool IsFollowVisitUse { get; set; } = false;
+
public string Value { get; set; } = string.Empty;
public string ValueCN { get; set; } = string.Empty;
diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingCriterionService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingCriterionService.cs
index 81cd47260..5a9cdd388 100644
--- a/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingCriterionService.cs
+++ b/IRaCIS.Core.Application/Service/Reading/ReadingCriterion/ReadingCriterionService.cs
@@ -343,6 +343,42 @@ namespace IRaCIS.Core.Application.Service.RC
#region 全局评估类型 肿瘤学评估类型
+ ///
+ /// 修改是否是基线使用
+ ///
+ ///
+ ///
+ [HttpPost]
+ public async Task SetDictionaryFollowVisitUse(SetDictionaryFollowVisitUseInDto inDto)
+ {
+ await _readingCriterionDictionaryRepository.UpdatePartialFromQueryAsync(inDto.Id, x => new ReadingCriterionDictionary()
+ {
+ IsFollowVisitUse = inDto.IsFollowVisitUse
+ });
+
+ await _readingCriterionDictionaryRepository.SaveChangesAsync();
+
+ return ResponseOutput.Ok(true);
+ }
+
+
+ ///
+ /// 修改是否是基线使用
+ ///
+ ///
+ ///
+ [HttpPost]
+ public async Task SetDictionaryBaseLineUse(SetDictionaryBaseLineUseInDto inDto)
+ {
+ await _readingCriterionDictionaryRepository.UpdatePartialFromQueryAsync(inDto.Id, x => new ReadingCriterionDictionary()
+ {
+ IsBaseLineUse = inDto.IsBaseLineUse
+ });
+
+ await _readingCriterionDictionaryRepository.SaveChangesAsync();
+
+ return ResponseOutput.Ok(true);
+ }
///
/// 获取标准字典
@@ -360,6 +396,8 @@ namespace IRaCIS.Core.Application.Service.RC
Id = x.Id,
DictionaryId = x.DictionaryId,
ChildGroup = x.Dictionary.ChildGroup,
+ IsBaseLineUse = x.IsBaseLineUse,
+ IsFollowVisitUse=x.IsFollowVisitUse,
Code = x.Dictionary.Code,
Description = x.Dictionary.Description,
ShowOrder = x.Dictionary.ShowOrder,
diff --git a/IRaCIS.Core.Domain/Reading/ReadingCriterionQuestion/ReadingCriterionDictionary.cs b/IRaCIS.Core.Domain/Reading/ReadingCriterionQuestion/ReadingCriterionDictionary.cs
index 687432d74..16b6bb0ec 100644
--- a/IRaCIS.Core.Domain/Reading/ReadingCriterionQuestion/ReadingCriterionDictionary.cs
+++ b/IRaCIS.Core.Domain/Reading/ReadingCriterionQuestion/ReadingCriterionDictionary.cs
@@ -43,6 +43,17 @@ namespace IRaCIS.Core.Domain.Models
///
public Guid CreateUserId { get; set; }
+
+ ///
+ /// IsBaseLineUse
+ ///
+ public bool IsBaseLineUse { get; set; } = false;
+
+ ///
+ /// IsBaseUse
+ ///
+ public bool IsFollowVisitUse { get; set; } = false;
+
[JsonIgnore]
[ForeignKey("DictionaryId")]
public Dictionary Dictionary { get; set; }