From 90c96889bd3348740eb8952901f6f3d7e6c8d340 Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期五, 24 十月 2025 10:13:58 +0800
Subject: [PATCH] 1

---
 新建文件夹/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs |   42 ++++++++++++++++++++++++------------------
 1 files changed, 24 insertions(+), 18 deletions(-)

diff --git "a/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs" "b/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs"
index 4e2449d..172381b 100644
--- "a/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs"
+++ "b/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_DictionaryService.cs"
@@ -145,22 +145,6 @@
                 }
                 vueDictionaryDTOs.AddRange(selectDics);
             }
-
-            //object GetSourceData(string dicNo, string dbSql, object data)
-            //{
-            //    if (string.IsNullOrEmpty(dbSql))
-            //    {
-            //        return data;
-            //    }
-            //    return BaseDal.QueryObjectDataBySql(dbSql, null);
-            //}
-            //List<VueDictionaryDTO> vueDictionaryDTOs = dicConfig.Select(item => new VueDictionaryDTO
-            //{
-            //    DicNo = item.dicNo,
-            //    Config = item.config,
-            //    Data = GetSourceData(item.dicNo, item.dbSql, item.list)
-            //}).ToList();
-
             try
             {
                 List<string> dicList = dicNos.ToList();
@@ -211,9 +195,31 @@
             {
                 switch (key)
                 {
-                    default:
-                        return result;
+                    case "taskStatusEnum":
+                        {
+                            List<object> data = new List<object>();
+                            Type type = typeof(SupplyStatusEnum);
+                            List<int> enums = Enum.GetValues(typeof(SupplyStatusEnum)).Cast<int>().ToList();
+                            int index = 0;
+                            foreach (var item in enums)
+                            {
+                                FieldInfo? fieldInfo = typeof(SupplyStatusEnum).GetField(((SupplyStatusEnum)item).ToString());
+                                DescriptionAttribute? description = fieldInfo.GetCustomAttribute<DescriptionAttribute>();
+                                if (description != null)
+                                {
+                                    data.Add(new { key = item.ToString(), value = description.Description });
+                                }
+                                else
+                                {
+                                    data.Add(new { key = item.ToString(), value = item.ToString() });
+                                }
+                                index++;
+                            }
+                            result = new VueDictionaryDTO { DicNo = key, Config = "", Data = data };
+                        }
+                        break;
                 }
+                return result;
             }
             catch (Exception ex)
             {

--
Gitblit v1.9.3