From 0d2f7d905975c1f5d39f70689760b070cef31349 Mon Sep 17 00:00:00 2001 From: dengjunjie <dengjunjie@hnkhzn.com> Date: 星期三, 20 十一月 2024 22:06:23 +0800 Subject: [PATCH] 优化前端界面 --- 项目代码/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs | 28 ++++++++++++++++++++++++++-- 1 files changed, 26 insertions(+), 2 deletions(-) diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs" index cae10a8..6200cdc 100644 --- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs" +++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs" @@ -508,11 +508,35 @@ DescriptionAttribute? description = fieldInfo.GetCustomAttribute<DescriptionAttribute>(); if (description != null) { - data.Add(new { key = item.ToString(), value = description.Description }); + data.Add(new { key = item, value = description.Description }); } else { - data.Add(new { key = item.ToString(), value = item.ToString() }); + data.Add(new { key = item, value = item.ToString() }); + } + index++; + } + + result = new VueDictionaryDTO { DicNo = key, Config = "", Data = data }; + } + break; + case "locationChangeType": + { + List<object> data = new List<object>(); + Type type = typeof(LocationChangeType); + List<int> enums = Enum.GetValues(typeof(LocationChangeType)).Cast<int>().ToList(); + int index = 0; + foreach (var item in enums) + { + FieldInfo? fieldInfo = typeof(LocationChangeType).GetField(((LocationChangeType)item).ToString()); + DescriptionAttribute? description = fieldInfo.GetCustomAttribute<DescriptionAttribute>(); + if (description != null) + { + data.Add(new { key = item, value = description.Description }); + } + else + { + data.Add(new { key = item, value = item.ToString() }); } index++; } -- Gitblit v1.9.3