1
huangxiaoqiang
昨天 af5847927931d3f491d7be5e0178cff3c37ac6f9
ÏîÄ¿´úÂë/WMS/WIDESEA_WMSServer/WIDESEA_StorageTaskServices/Task/Dt_TaskService.cs
@@ -24,6 +24,7 @@
using WIDESEA_Core.BaseRepository;
using WIDESEA_Core.Const;
using WIDESEA_Core.Enums;
using WIDESEA_DTO.Basic;
using WIDESEA_DTO.ERP;
using WIDESEA_DTO.Location;
using WIDESEA_DTO.Stock;
@@ -121,7 +122,7 @@
            var allocateOrderdetail = orderDetails.Where(x => true).ToList();
            await ERPAllocateOut(stock);
            //await ERPAllocateOut(stock);
            //调拨出库
            if (task.TaskType == (int)TaskOutboundTypeEnum.OutAllocate)
@@ -834,12 +835,12 @@
                return content.Error("该托盘库存已在出库缓存区");
            }
            Dt_Task taskNew = await RequestOutboundTaskAsync(new RequestTaskDto { PalletCode = stock.PalletCode, AreaId = 2, Position = stock.LocationCode, TaskType = (int)TaskOutboundTypeEnum.OutOther });
            Dt_Task taskNew = await RequestOutboundTaskAsync(new RequestTaskDto { PalletCode = stock.PalletCode, AreaId = 2, Position = stock.LocationCode, TaskType = (int)TaskOutboundTypeEnum.OutAllocate });
            List<Dt_OrderOutDetails> outDetails = new List<Dt_OrderOutDetails>();
            details.Where(x => x.OutboundQuantity > 0).ForEach(x =>
            {
                var areaName = _areaInfoRepository.QueryFirst(y => y.AreaName == x.Remark);
                var areaName = _areaInfoRepository.QueryFirst(y => y.AreaID == Convert.ToInt32(x.Remark));
                if (areaName == null)
                {
                    throw new Exception($"未找到调拨仓库{x.Remark}数据");
@@ -856,10 +857,10 @@
                    ERPOrderId = "",
                    MaterielCode = x.MaterielCode,
                    MaterielName = x.MaterielName,
                    AllocateWarehouse = x.Remark,
                    AllocateWarehouse = areaName.AreaName,
                    Warehouse = "智能立库",
                    WareHouseId = "107",
                    AllocateWarehouseId = areaName.AreaName,
                    AllocateWarehouseId = areaName.AreaCode ,
                    OutboundQuantity = x.OutboundQuantity,
                });
            });
@@ -1392,14 +1393,22 @@
        WebResponseContent content = new WebResponseContent();
        try
        {
            var task = BaseDal.QueryData(x => true);
            Dictionary<string,object> obj=new Dictionary<string, object>()
            var task = await BaseDal.QueryDataAsync(x => true);
            var taskData = new List<TaskData>
            {
                 {"name","已完成"},
                new TaskData { Status = "已取消", Count = task.Count+50 },
                new TaskData { Status = "已完成", Count = 735 }
            };
            return content.OK(data:obj);
            // æž„建符合要求的格式
            var result = taskData.Select(item => new
            {
                value = item.Count,
                name = item.Status,
                itemStyle = new { color = item.Status == "已取消" ? "#FF0000" : "#00FF00" }
            }).ToList();
            return content.OK(data: result);
        }
        catch (Exception ex)
        {