| | |
| | | try |
| | | { |
| | | List<string> cacheDicNos = new List<string>(); |
| | | //foreach (string n in dicNos) |
| | | //{ |
| | | // string str = _cacheService.Get(n); |
| | | // if (!string.IsNullOrEmpty(str)) |
| | | // { |
| | | // VueDictionaryDTO? vueDictionary = JsonConvert.DeserializeObject<VueDictionaryDTO>(str); |
| | | foreach (string n in dicNos) |
| | | { |
| | | string str = _cacheService.Get(n); |
| | | if (!string.IsNullOrEmpty(str)) |
| | | { |
| | | VueDictionaryDTO? vueDictionary = JsonConvert.DeserializeObject<VueDictionaryDTO>(str); |
| | | |
| | | // if (vueDictionary != null) |
| | | // { |
| | | // vueDictionaryDTOs.Add(vueDictionary); |
| | | // cacheDicNos.Add(n); |
| | | // } |
| | | // } |
| | | //} |
| | | if (vueDictionary != null && vueDictionaryDTOs.Where(x => x.DicNo == vueDictionary.DicNo).FirstOrDefault() == null) |
| | | { |
| | | vueDictionaryDTOs.Add(vueDictionary); |
| | | cacheDicNos.Add(n); |
| | | } |
| | | } |
| | | } |
| | | List<string> dicList = dicNos.ToList(); |
| | | if (dicNos.Where(x => !cacheDicNos.Contains(x)).Count() > 0) |
| | | { |
| | |
| | | DescriptionAttribute? description = fieldInfo.GetCustomAttribute<DescriptionAttribute>(); |
| | | if (description != null) |
| | | { |
| | | data.Add(new { key = index , value = description.Description }); |
| | | data.Add(new { key = index, value = description.Description }); |
| | | } |
| | | else |
| | | { |