Uat_Study
hang 2022-07-18 15:48:46 +08:00
parent 2dbcdc0377
commit 97f11e7c0b
3 changed files with 12 additions and 2 deletions

View File

@ -122,6 +122,10 @@ namespace IRaCIS.Core.Application.ViewModel
public Arm ArmEnum { get; set; } public Arm ArmEnum { get; set; }
public Guid? SourceSubjectVisitId { get; set; }
public Guid? SouceReadModuleId { get; set; }
} }
public class VisitTaskSimpleDTO :VisitTaskGroupSimpleDTO public class VisitTaskSimpleDTO :VisitTaskGroupSimpleDTO

View File

@ -216,7 +216,7 @@ namespace IRaCIS.Core.Application.Service
foreach (var visitGroup in followVisitGroup) foreach (var visitGroup in followVisitGroup)
{ {
var arm1 = visitGroup.FirstOrDefault(t => t.TaskState == TaskState.Effect && t.DoctorUserId == null && t.ArmEnum == Arm.DoubleReadingArm1); var arm1 = visitGroup.FirstOrDefault(t => t.TaskState == TaskState.Effect && t.TaskAllocationState==TaskAllocationState.NotAllocate && t.DoctorUserId == null && t.ArmEnum == Arm.DoubleReadingArm1);
if (arm1 != null) if (arm1 != null)
{ {
arm1.TaskAllocationState = TaskAllocationState.Allocated; arm1.TaskAllocationState = TaskAllocationState.Allocated;
@ -256,7 +256,7 @@ namespace IRaCIS.Core.Application.Service
_provider.Set<int>($"{trialId}_{StaticData.CacheKey.TaskMaxCode}", currentMaxCodeInt, TimeSpan.FromMinutes(30)); _provider.Set<int>($"{trialId}_{StaticData.CacheKey.TaskMaxCode}", currentMaxCodeInt, TimeSpan.FromMinutes(30));
} }
var arm2 = visitGroup.FirstOrDefault(t => t.TaskState == TaskState.Effect && t.DoctorUserId == null && t.ArmEnum == Arm.DoubleReadingArm2); var arm2 = visitGroup.FirstOrDefault(t => t.TaskState == TaskState.Effect && t.TaskAllocationState == TaskAllocationState.NotAllocate && t.DoctorUserId == null && t.ArmEnum == Arm.DoubleReadingArm2);
if (arm2 != null) if (arm2 != null)
{ {
arm2.TaskAllocationState = TaskAllocationState.Allocated; arm2.TaskAllocationState = TaskAllocationState.Allocated;
@ -591,6 +591,8 @@ namespace IRaCIS.Core.Application.Service
TaskAllocationState = TaskAllocationState.Allocated, TaskAllocationState = TaskAllocationState.Allocated,
AllocateTime = DateTime.Now, AllocateTime = DateTime.Now,
SouceReadModuleId = task.SouceReadModuleId,
SourceSubjectVisitId = task.SourceSubjectVisitId,
BlindTrialSiteCode = task.BlindTrialSiteCode, BlindTrialSiteCode = task.BlindTrialSiteCode,
BlindSubjectCode = task.BlindSubjectCode, BlindSubjectCode = task.BlindSubjectCode,
ConsistentAnalysisOriginalTaskId = task.Id, ConsistentAnalysisOriginalTaskId = task.Id,
@ -627,6 +629,8 @@ namespace IRaCIS.Core.Application.Service
Code = currentMaxCodeInt + 1, Code = currentMaxCodeInt + 1,
TaskCode = AppSettings.GetCodeStr(currentMaxCodeInt + 1, nameof(VisitTask)), TaskCode = AppSettings.GetCodeStr(currentMaxCodeInt + 1, nameof(VisitTask)),
SouceReadModuleId = task.SouceReadModuleId,
SourceSubjectVisitId = task.SourceSubjectVisitId,
DoctorUserId = task.DoctorUserId, DoctorUserId = task.DoctorUserId,
TaskAllocationState = TaskAllocationState.Allocated, TaskAllocationState = TaskAllocationState.Allocated,
AllocateTime = DateTime.Now, AllocateTime = DateTime.Now,

View File

@ -1098,6 +1098,8 @@ namespace IRaCIS.Core.Application.Service
origenalTask.ReReadingApplyState = (agreeReReadingCommand.RequestReReadingResultEnum == RequestReReadingResult.Agree ? ReReadingApplyState.Agree : ReReadingApplyState.Reject); origenalTask.ReReadingApplyState = (agreeReReadingCommand.RequestReReadingResultEnum == RequestReReadingResult.Agree ? ReReadingApplyState.Agree : ReReadingApplyState.Reject);
origenalTask.TaskState = (agreeReReadingCommand.RequestReReadingResultEnum == RequestReReadingResult.Agree ? TaskState.HaveReturned : origenalTask.TaskState); origenalTask.TaskState = (agreeReReadingCommand.RequestReReadingResultEnum == RequestReReadingResult.Agree ? TaskState.HaveReturned : origenalTask.TaskState);
//更新申请信息 //更新申请信息
var visitTaskReReadingAppply = await _visitTaskReReadingRepository.FirstOrDefaultAsync(t => t.Id == item.Id); var visitTaskReReadingAppply = await _visitTaskReReadingRepository.FirstOrDefaultAsync(t => t.Id == item.Id);
visitTaskReReadingAppply.RequestReReadingConfirmUserId = _userInfo.Id; visitTaskReReadingAppply.RequestReReadingConfirmUserId = _userInfo.Id;