修改
This commit is contained in:
@@ -15,6 +15,7 @@ using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using IRaCIS.Core.Domain.Share;
|
||||
using IRaCIS.Core.Domain.Share.Management;
|
||||
using System.Text.Json.Nodes;
|
||||
|
||||
namespace IRaCIS.Core.Application.Service
|
||||
{
|
||||
@@ -771,6 +772,37 @@ namespace IRaCIS.Core.Application.Service
|
||||
}).Select(x => x.value).ToListAsync()
|
||||
);
|
||||
}
|
||||
|
||||
else if (item.Type.ToLower() == FrontAudit.DictionaryType.GetDescription().ToLower())
|
||||
{
|
||||
|
||||
List<JObject> jsonList = new List<JObject>();
|
||||
|
||||
foreach (JToken arraysItem in arrays)
|
||||
{
|
||||
var jsonObject = JObject.Parse(arraysItem.ToString());
|
||||
try
|
||||
{
|
||||
|
||||
jsonObject[item.Code]= await _dictionaryRepository.Where(x => x.Code == jsonObject["DictionaryCode"].ToString()).Join(_dictionaryRepository.Where(x => x.Code == jsonObject[item.Code].ToString()), a => a.Id, b => b.ParentId, (a, b) => new
|
||||
{
|
||||
value = b.ValueCN
|
||||
}).Select(x => x.value).FirstOrDefaultAsync();
|
||||
|
||||
|
||||
jsonList.Add(jsonObject);
|
||||
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
jsonList.Add(jsonObject);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
jsonDataDic[item.Key] = JToken.FromObject(jsonList);
|
||||
}
|
||||
else
|
||||
{
|
||||
List<string> guids = new List<string>();
|
||||
|
||||
Reference in New Issue
Block a user