添加数据

This commit is contained in:
he
2022-04-25 13:35:44 +08:00
parent 7351415bbc
commit 04a608c28b
12 changed files with 133 additions and 56 deletions
@@ -78,6 +78,8 @@ namespace IRaCIS.Core.Application.Service
ModuleTypeId = additem?.ModuleTypeId,
ObjectTypeId = additem?.ObjectTypeId,
OptTypeId = additem?.OptTypeId,
DictionaryCode = lst.Max(x => x.DictionaryCode),
DictionaryType = lst.Max(x => x.DictionaryType),
DateType = lst.Select(x => x.DateType).FirstOrDefault(),
Id =Guid.NewGuid(),
}).ToList();
@@ -101,6 +103,8 @@ namespace IRaCIS.Core.Application.Service
{
x.Code=x.Code.IsNullOrEmpty()?item.Code:x.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;
}
});