This commit is contained in:
he
2022-05-11 14:45:10 +08:00
parent 10f2887c2b
commit a6b39efdf2
7 changed files with 47 additions and 27 deletions
@@ -169,6 +169,10 @@ namespace IRaCIS.Core.Application.Service
DictionaryCode = lst.Max(x => x.DictionaryCode),
DictionaryType = lst.Max(x => x.DictionaryType),
DateType = lst.Select(x => x.DateType).FirstOrDefault(),
ForeignKeyValue = lst.Select(x => x.ForeignKeyValue).FirstOrDefault(),
ForeignKeyText = lst.Select(x => x.ForeignKeyText).FirstOrDefault(),
ForeignKeyTable = lst.Select(x => x.ForeignKeyTable).FirstOrDefault(),
DataType = lst.Select(x => x.DataType).FirstOrDefault(),
Id =NewId.NextGuid()//新id,
}).ToList();
@@ -189,10 +193,18 @@ namespace IRaCIS.Core.Application.Service
var item = alllist.FirstOrDefault(y => y.ValueCN == x.ValueCN);
if (item != null)
{
x.Code=x.Code.IsNullOrEmpty()?item.Code:x.Code;
x.Code=item.Code;
x.Value = x.Code.IsNullOrEmpty() ? item.Value : x.Value;
x.DictionaryType = x.DictionaryType.IsNullOrEmpty() ? item.DictionaryType : x.DictionaryType;
x.DictionaryCode = x.DictionaryCode.IsNullOrEmpty() ? item.DictionaryCode : x.DictionaryCode;
x.DataType = x.DataType.IsNullOrEmpty() ? item.DataType : x.DataType;
x.DateType = x.DateType.IsNullOrEmpty() ? item.DateType : x.DateType;
x.DictionaryKey = x.DictionaryKey.IsNullOrEmpty() ? item.DictionaryKey : x.DictionaryKey;
x.IsShowParent = x.IsShowParent==null ? item.IsShowParent : x.IsShowParent;
x.ForeignKeyTable = x.ForeignKeyTable.IsNullOrEmpty() ? item.ForeignKeyTable : x.ForeignKeyTable;
x.ForeignKeyText = x.ForeignKeyText.IsNullOrEmpty() ? item.ForeignKeyText : x.ForeignKeyText;
x.ForeignKeyValue = x.ForeignKeyValue.IsNullOrEmpty() ? item.ForeignKeyValue : x.ForeignKeyValue;
x.EnumType = x.EnumType.IsNullOrEmpty() ? item.EnumType : x.EnumType;
}
});
@@ -79,7 +79,7 @@ namespace IRaCIS.Core.Application.Service.Inspection
from lefttrialSign in trialSigntemp.DefaultIfEmpty()
join leftfrontAuditConfig in _repository.GetQueryable<FrontAuditConfig>().Where(x=>x.ConfigType=="M"&&x.Identification!=null) on
join leftfrontAuditConfig in _repository.GetQueryable<FrontAuditConfig>().Where(x=>x.ConfigType=="M"&&x.Identification!=null&&x.IsEnable==true) on
data.Identification.ToLower()
equals
leftfrontAuditConfig.Identification.ToLower()
@@ -1441,7 +1441,7 @@ namespace IRaCIS.Core.Application.Image.QA
}
}
dbSubjectVisit.Auditor = _userInfo.Id;
dbSubjectVisit.IsTake = false;
dbSubjectVisit.CurrentActionUserId = null;
dbSubjectVisit.CurrentActionUserExpireTime = null;
@@ -54,7 +54,7 @@ namespace IRaCIS.Application.Services
//添加受试者的时候,获取访视计划列表,添加到受试者访视表。
var visitPlan = await _repository.Where<VisitStage>(t => t.TrialId == subjectCommand.TrialId).ToListAsync();
var visitPlan = await _repository.Where<VisitStage>(t => t.TrialId == subjectCommand.TrialId&&t.IsConfirmed).ToListAsync();
svlist = _mapper.Map<List<SubjectVisit>>(visitPlan);