导入忽略空格
parent
621fab16a0
commit
f94d1caa79
|
|
@ -768,9 +768,9 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
||||||
|
|
||||||
if (targetSegmentAnswer.IsNotNullOrEmpty())
|
if (targetSegmentAnswer.IsNotNullOrEmpty())
|
||||||
{
|
{
|
||||||
var targetSegmentValues = targetSegmentAnswer.Trim().Replace(",", ",").Split(",").ToList();
|
var targetSegmentValues = targetSegmentAnswer.Replace(" ", "").Replace(",", ",").Split(",").ToList();
|
||||||
var targetSegmentdic = await _dictionaryRepository.Where(x => x.Parent.Code == "TargetSegment").ToListAsync();
|
var targetSegmentdic = await _dictionaryRepository.Where(x => x.Parent.Code == "TargetSegment").ToListAsync();
|
||||||
targetSegmentAnswer = JsonConvert.SerializeObject(targetSegmentdic.Where(x => targetSegmentValues.Contains(x.ValueCN.Trim())).Select(x => x.Code).ToList());
|
targetSegmentAnswer = JsonConvert.SerializeObject(targetSegmentdic.Where(x => targetSegmentValues.Contains(x.ValueCN.Replace(" ", ""))).Select(x => x.Code).ToList());
|
||||||
}
|
}
|
||||||
|
|
||||||
questionAnswers.Add(new ReadingTaskQuestionAnswer()
|
questionAnswers.Add(new ReadingTaskQuestionAnswer()
|
||||||
|
|
@ -820,10 +820,10 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
||||||
|
|
||||||
if (plaqueTypeAnswer.IsNotNullOrEmpty())
|
if (plaqueTypeAnswer.IsNotNullOrEmpty())
|
||||||
{
|
{
|
||||||
var plaqueTypeAnswerValues = plaqueTypeAnswer.Trim().Replace(",", ",").Split(",").ToList();
|
var plaqueTypeAnswerValues = plaqueTypeAnswer.Replace(" ", "").Replace(",", ",").Split(",").ToList();
|
||||||
var plaqueTypeAnswerdic = await _dictionaryRepository.Where(x => x.Parent.Code == "PlaqueType").ToListAsync();
|
var plaqueTypeAnswerdic = await _dictionaryRepository.Where(x => x.Parent.Code == "PlaqueType").ToListAsync();
|
||||||
plaqueTypeAnswer = JsonConvert.SerializeObject(plaqueTypeAnswerdic
|
plaqueTypeAnswer = JsonConvert.SerializeObject(plaqueTypeAnswerdic
|
||||||
.Where(x => plaqueTypeAnswerValues.Any(val => x.ValueCN.Trim().Contains(val)))
|
.Where(x => plaqueTypeAnswerValues.Any(val => x.ValueCN.Replace(" ", "").Contains(val)))
|
||||||
.Select(x => x.Code)
|
.Select(x => x.Code)
|
||||||
.ToList());
|
.ToList());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -740,9 +740,9 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
||||||
|
|
||||||
if (targetSegmentAnswer.IsNotNullOrEmpty())
|
if (targetSegmentAnswer.IsNotNullOrEmpty())
|
||||||
{
|
{
|
||||||
var targetSegmentValues = targetSegmentAnswer.Trim().Replace(",", ",").Split(",").ToList();
|
var targetSegmentValues = targetSegmentAnswer.Replace(" ", "").Replace(",", ",").Split(",").ToList();
|
||||||
var targetSegmentdic = await _dictionaryRepository.Where(x => x.Parent.Code == "TargetSegment").ToListAsync();
|
var targetSegmentdic = await _dictionaryRepository.Where(x => x.Parent.Code == "TargetSegment").ToListAsync();
|
||||||
targetSegmentAnswer = JsonConvert.SerializeObject(targetSegmentdic.Where(x => targetSegmentValues.Contains(x.ValueCN.Trim())).Select(x => x.Code).ToList());
|
targetSegmentAnswer = JsonConvert.SerializeObject(targetSegmentdic.Where(x => targetSegmentValues.Contains(x.ValueCN.Replace(" ", ""))).Select(x => x.Code).ToList());
|
||||||
}
|
}
|
||||||
|
|
||||||
questionAnswers.Add(new ReadingTaskQuestionAnswer()
|
questionAnswers.Add(new ReadingTaskQuestionAnswer()
|
||||||
|
|
@ -781,10 +781,10 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
||||||
|
|
||||||
if (plaqueTypeAnswer.IsNotNullOrEmpty())
|
if (plaqueTypeAnswer.IsNotNullOrEmpty())
|
||||||
{
|
{
|
||||||
var plaqueTypeAnswerValues = plaqueTypeAnswer.Trim().Replace(",", ",").Split(",").ToList();
|
var plaqueTypeAnswerValues = plaqueTypeAnswer.Replace(" ", "").Replace(",", ",").Split(",").ToList();
|
||||||
var plaqueTypeAnswerdic = await _dictionaryRepository.Where(x => x.Parent.Code == "PlaqueType").ToListAsync();
|
var plaqueTypeAnswerdic = await _dictionaryRepository.Where(x => x.Parent.Code == "PlaqueType").ToListAsync();
|
||||||
plaqueTypeAnswer = JsonConvert.SerializeObject(plaqueTypeAnswerdic
|
plaqueTypeAnswer = JsonConvert.SerializeObject(plaqueTypeAnswerdic
|
||||||
.Where(x => plaqueTypeAnswerValues.Any(val => x.ValueCN.Trim().Contains(val)))
|
.Where(x => plaqueTypeAnswerValues.Any(val => x.ValueCN.Replace(" ", "").Contains(val)))
|
||||||
.Select(x => x.Code)
|
.Select(x => x.Code)
|
||||||
.ToList());
|
.ToList());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue