1
wangxinhui
2025-01-11 e9d4f92c5a680e6f705bb84843769a354a561643
1
已修改3个文件
已添加6个文件
118 ■■■■ 文件已修改
代码管理/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/read.lock 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/24d336e2-4ecf-49a4-b35f-69e0e3bc8d65.vsidx 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3ae4399a-b674-44c1-b399-de956d3e1f8a.vsidx 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/872f6857-ecdf-4715-ac7a-765ab4769441.vsidx 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/e1699c03-c050-4a8a-9e44-918bffcfc3ce.vsidx 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/read.lock 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs 115 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_UserService.cs 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Program.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
´úÂë¹ÜÀí/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/read.lock
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/24d336e2-4ecf-49a4-b35f-69e0e3bc8d65.vsidx
Binary files differ
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3ae4399a-b674-44c1-b399-de956d3e1f8a.vsidx
Binary files differ
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/872f6857-ecdf-4715-ac7a-765ab4769441.vsidx
Binary files differ
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/e1699c03-c050-4a8a-9e44-918bffcfc3ce.vsidx
Binary files differ
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/read.lock
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs
@@ -27,66 +27,67 @@
        }
        static object locker = new object();
        public override WebResponseContent AddData(SaveModel saveModel)
        {
            int warehouseId = 0;
            int count = 0;
            if (saveModel.MainData.TryGetValue("warehouseId", out object? warehouse) && warehouse != null)
            {
                warehouseId = warehouse.ObjToInt();
            }
            if (saveModel.MainData.TryGetValue("count", out object? countValue) && countValue != null)
            {
                count = countValue.ObjToInt();
            }
            lock (locker)
            {
                List<Dt_PalletCodeInfo> palletCodeInfos = new List<Dt_PalletCodeInfo>();
                int serialNo = 0;
                DateTime now = DateTime.Now;
                Dt_PalletCodeInfo palletCodeInfo = BaseDal.QueryFirst(x => x.WarehouseId == warehouseId, new Dictionary<string, OrderByType> { { nameof(Dt_PalletCodeInfo.SerialNo), OrderByType.Desc } });
                if (palletCodeInfo != null && palletCodeInfo.CreateDate.Year == now.Year && palletCodeInfo.CreateDate.Month == now.Month && palletCodeInfo.CreateDate.Day == now.Day)
                {
                    serialNo = palletCodeInfo.SerialNo + 1;
        //public override WebResponseContent AddData(SaveModel saveModel)
        //{
        //    int warehouseId = 0;
        //    int count = 0;
        //    if (saveModel.MainData.TryGetValue("warehouseId", out object? warehouse) && warehouse != null)
        //    {
        //        warehouseId = warehouse.ObjToInt();
        //    }
        //    if (saveModel.MainData.TryGetValue("count", out object? countValue) && countValue != null)
        //    {
        //        count = countValue.ObjToInt();
        //    }
        //    lock (locker)
        //    {
        //        List<Dt_PalletCodeInfo> palletCodeInfos = new List<Dt_PalletCodeInfo>();
        //        int serialNo = 0;
        //        DateTime now = DateTime.Now;
        //        Dt_PalletCodeInfo palletCodeInfo = BaseDal.QueryFirst(x => x.WarehouseId == warehouseId, new Dictionary<string, OrderByType> { { nameof(Dt_PalletCodeInfo.SerialNo), OrderByType.Desc } });
        //        if (palletCodeInfo != null && palletCodeInfo.CreateDate.Year == now.Year && palletCodeInfo.CreateDate.Month == now.Month && palletCodeInfo.CreateDate.Day == now.Day)
        //        {
        //            serialNo = palletCodeInfo.SerialNo + 1;
                }
                else
                {
                    serialNo = 1;
                }
                Dt_Warehouse _Warehouse = _warehouseRepository.QueryFirst(x => x.WarehouseId == warehouseId);
                string uplen = "";
                switch (_Warehouse.WarehouseCode)
                {
                    "HA57" => "B",
                    "HA58" => "P",
                    "HA152" => "G",
                    "HA64" => "S",
                    "阻焊仓" => "Z",
                    "HA153" => "Y",
                    "HA71" => "C",
                    "HA60" => "F",
                    _ => "N"
                };
                for (int i = 0; i < count; i++)
                {
        //        }
        //        else
        //        {
        //            serialNo = 1;
        //        }
        //        Dt_Warehouse _Warehouse = _warehouseRepository.QueryFirst(x => x.WarehouseId == warehouseId);
        //        string uplen = "";
        //        uplen = _Warehouse.WarehouseCode switch
        //        {
        //            "HA57" => "B",
        //            "HA58" => "P",
        //            "HA152" => "G",
        //            "HA64" => "S",
        //            "阻焊仓" => "Z",
        //            "HA153" => "Y",
        //            "HA71" => "C",
        //            "HA60" => "F",
        //            _ => "N"
        //        };
        //        for (int i = 0; i < count; i++)
        //        {
                    palletCodeInfos.Add(new Dt_PalletCodeInfo
                    {
                        SerialNo = serialNo,
                        PalletCode = uplen + now.ToString("yyyyMMdd") + serialNo.ToString().PadLeft(3, '0'),
                        PalletType = 1,
                        PalletTypeId = 0,
                        WarehouseId = warehouseId,
                        Status = 0,
                        Size = 0
                    });
        //            palletCodeInfos.Add(new Dt_PalletCodeInfo
        //            {
        //                SerialNo = serialNo,
        //                PalletCode = uplen + now.ToString("yyyyMMdd") + serialNo.ToString().PadLeft(3, '0'),
        //                PalletType = 1,
        //                PalletTypeId = 0,
        //                WarehouseId = warehouseId,
        //                Status = 0,
        //                Size = 0
        //            });
                    serialNo = serialNo + 1;
                }
                return base.AddData(palletCodeInfos);
            }
        }
        //            serialNo = serialNo + 1;
        //        }
        //        return base.AddData(palletCodeInfos);
        //    }
        //    }
        //}
        public WebResponseContent AddData(int warehouseId, int count, int palletTypeId)
        {
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/WIDESEA_SystemService/Sys_UserService.cs
@@ -19,6 +19,7 @@
using MailKit.Search;
using OrderByType = SqlSugar.OrderByType;
using System.Drawing.Printing;
using WIDESEA_Core.HostedService;
namespace WIDESEA_SystemService
{
´úÂë¹ÜÀí/WMS/WIDESEA_WMSServer/WIDESEA_WMSServer/Program.cs
@@ -43,7 +43,7 @@
builder.Services.AddWebSocketSetup();
builder.Services.AddSqlsugarSetup();//SqlSugar å¯åŠ¨æœåŠ¡
builder.Services.AddDbSetup();//Db å¯åŠ¨æœåŠ¡
//builder.Services.AddInitializationHostServiceSetup();//应用初始化服务注入
builder.Services.AddInitializationHostServiceSetup();//应用初始化服务注入
builder.Services.AddHostedService<PermissionDataHostService>();//应用初始化服务注入
builder.Services.AddAutoMapperSetup();