diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Outputs/CarryQueryOutput.cs b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Outputs/CarryQueryOutput.cs
index 5ea456ca..99936dc3 100644
--- a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Outputs/CarryQueryOutput.cs
+++ b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Dto/Outputs/CarryQueryOutput.cs
@@ -64,6 +64,18 @@ namespace Tnb.WarehouseMgr.Entities.Dto.Outputs
///
public string? collocation_scheme_code { get; set; }
///
+ /// 供应商
+ ///
+ public string supplier_id { get; set; }
+ ///
+ /// 入库时间
+ ///
+ public DateTime instock_time { get; set; }
+ ///
+ /// 检验结论
+ ///
+ public int is_check { get; set; }
+ ///
/// 载具条码明细输出
///
public List? wmsCarryCodes { get; set; }
@@ -150,5 +162,7 @@ namespace Tnb.WarehouseMgr.Entities.Dto.Outputs
/// 仓库ID
///
public string? warehouse_id { get; set; }
+
+
}
}
diff --git a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsCarryH.part.cs b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsCarryH.part.cs
index 117b1bdf..20a8da90 100644
--- a/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsCarryH.part.cs
+++ b/WarehouseMgr/Tnb.WarehouseMgr.Entities/Entity/WmsCarryH.part.cs
@@ -15,4 +15,15 @@ public partial class WmsCarryH
[SugarColumn(IsIgnore = true)]
public int is_sign { get; set; }
+ ///
+ /// 供应商
+ ///
+ [SugarColumn(IsIgnore = true)]
+ public string supplier_id { get; set; }
+ ///
+ /// 入库时间
+ ///
+ [SugarColumn(IsIgnore = true)]
+ public DateTime instock_time { get; set; }
+
}
diff --git a/WarehouseMgr/Tnb.WarehouseMgr/PcStroageService.cs b/WarehouseMgr/Tnb.WarehouseMgr/PcStroageService.cs
index f90c24f0..123a358e 100644
--- a/WarehouseMgr/Tnb.WarehouseMgr/PcStroageService.cs
+++ b/WarehouseMgr/Tnb.WarehouseMgr/PcStroageService.cs
@@ -8,6 +8,7 @@ using System.Text;
using System.Threading.Tasks;
using JNPF;
using JNPF.Common.Extension;
+using Microsoft.Extensions.DependencyInjection;
using Tnb.WarehouseMgr.Entities.Attributes;
using Tnb.WarehouseMgr.Entities.Dto;
using Tnb.WarehouseMgr.Interfaces;
@@ -17,21 +18,20 @@ namespace Tnb.WarehouseMgr
[Caller("web")]
public class PcStroageService : IWHStorageService
{
- private static Dictionary> _serviceCallbackMap = new(StringComparer.OrdinalIgnoreCase);
+ private static Dictionary _serviceMap = new(StringComparer.OrdinalIgnoreCase);
static PcStroageService()
{
- _serviceCallbackMap = App.EffectiveTypes.AsParallel().Where(u => u.IsClass && !u.IsInterface && !u.IsAbstract && !typeof(IPdaStroage).IsAssignableFrom(u)
+
+ _serviceMap = App.EffectiveTypes.AsParallel().Where(u => u.IsClass && !u.IsInterface && !u.IsAbstract && !typeof(IPdaStroage).IsAssignableFrom(u)
&& u.IsSubclassOf(typeof(BaseWareHouseService)) && u.GetCustomAttribute() != null)
- .ToDictionary(x => x.GetCustomAttribute().BizTypeId,
- x => (Func)Delegate.CreateDelegate(typeof(Func), App.GetService(x), x.GetMethod(nameof(WareHouseService.ModifyAsync))));
+ .ToDictionary(x => x.GetCustomAttribute().BizTypeId, x => (BaseWareHouseService)App.GetService(x));
}
public async Task Do(WareHouseUpInput input)
{
- if (_serviceCallbackMap.ContainsKey(input.bizTypeId))
- {
- await _serviceCallbackMap[input.bizTypeId].Invoke(input);
- }
+ if (_serviceMap.ContainsKey(input.bizTypeId))
+ await _serviceMap[input.bizTypeId].ModifyAsync(input);
}
}
+
}
diff --git a/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryQueryService.cs b/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryQueryService.cs
index ac88c0a9..5819fcc1 100644
--- a/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryQueryService.cs
+++ b/WarehouseMgr/Tnb.WarehouseMgr/WmsCarryQueryService.cs
@@ -69,7 +69,12 @@ namespace Tnb.WarehouseMgr
var data = new CarryQueryOutput();
try
{
- var carry = await _db.Queryable().SingleAsync(it => it.carry_code == input.carry_code && it.status == 1);
+ var carry = await _db.Queryable().LeftJoin((a, b) => a.id == b.carry_id).Where(a => a.carry_code == input.carry_code && a.status == 1)
+ .Select((a, b) => new WmsCarryH
+ {
+ instock_time = b.create_time
+ }, true)
+ .FirstAsync();
if (carry.IsNull()) throw new AppFriendlyException($"编号{input.carry_code},对应载具不存在或被禁用", 500);
List carryCodes = new();
var carryDsLst = await _db.Queryable().Where(it => it.carry_id == carry.id).ToListAsync();