优化
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using Npoi.Mapper.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -12,70 +13,85 @@ namespace WMS.Web.Core.Dto
|
||||
/// <summary>
|
||||
/// ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 明细ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int DetailsId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单据编号
|
||||
/// </summary>
|
||||
[Column("单据号")]
|
||||
public string BillNo { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 所属箱号编码
|
||||
/// </summary>
|
||||
[Column("箱号")]
|
||||
public string BoxBillNo { get; set; }
|
||||
/// <summary>
|
||||
/// 类型:1为入库回退下架,2为出库回退上架
|
||||
/// </summary>
|
||||
[Column("单据类型")]
|
||||
public string Type { get; set; }
|
||||
/// <summary>
|
||||
/// 操作人
|
||||
/// </summary>
|
||||
[Column("操作人")]
|
||||
public string Creator { get; set; }
|
||||
/// <summary>
|
||||
/// 操作时间
|
||||
/// </summary>
|
||||
[Column("操作时间")]
|
||||
public DateTime CreateTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 物料名称
|
||||
/// </summary>
|
||||
[Column("物料名称")]
|
||||
public string MaterialName { get; set; }
|
||||
/// <summary>
|
||||
/// 物料编码
|
||||
/// </summary>
|
||||
[Column("物料编码")]
|
||||
public string MaterialNumber { get; set; }
|
||||
/// <summary>
|
||||
/// 物料规格型号
|
||||
/// </summary>
|
||||
[Column("规格型号")]
|
||||
public string Specifications { get; set; }
|
||||
/// <summary>
|
||||
/// 数量
|
||||
/// </summary>
|
||||
[Column("操作数量")]
|
||||
public decimal Qty { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public string Org { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 仓位
|
||||
/// </summary>
|
||||
[Column("仓位")]
|
||||
public string SubStock { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 仓库
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public string Stock { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 序列号集
|
||||
/// </summary>
|
||||
[Column("序列号")]
|
||||
public string SerialNumbers { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using Npoi.Mapper.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -12,67 +13,82 @@ namespace WMS.Web.Core.Dto
|
||||
/// <summary>
|
||||
/// 单据ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 明细ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int DetailsId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单据编号
|
||||
/// </summary>
|
||||
[Column("入库单号")]
|
||||
public string BillNo { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 入库类型
|
||||
/// </summary>
|
||||
[Column("入库类型")]
|
||||
public string Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 来源单号
|
||||
/// </summary>
|
||||
[Column("来源单号")]
|
||||
public string SourceBillNo { get; set; }
|
||||
/// <summary>
|
||||
/// 供应商
|
||||
/// </summary>
|
||||
[Column("供应商")]
|
||||
public string Supplier { get; set; }
|
||||
/// <summary>
|
||||
/// 组织
|
||||
/// </summary>
|
||||
[Column("组织")]
|
||||
public string Org { get; set; }
|
||||
/// <summary>
|
||||
/// 物料名称
|
||||
/// </summary>
|
||||
[Column("物料名称")]
|
||||
public string MaterialName { get; set; }
|
||||
/// <summary>
|
||||
/// 物料编码
|
||||
/// </summary>
|
||||
[Column("物料编码")]
|
||||
public string MaterialNumber { get; set; }
|
||||
/// <summary>
|
||||
/// 物料规格型号
|
||||
/// </summary>
|
||||
[Column("规格型号")]
|
||||
public string Specifications { get; set; }
|
||||
/// <summary>
|
||||
/// 仓库
|
||||
/// </summary>
|
||||
[Column("仓库")]
|
||||
public string Stock { get; set; }
|
||||
/// <summary>
|
||||
/// 数量
|
||||
/// </summary>
|
||||
[Column("入库数量")]
|
||||
public decimal Qty { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建人
|
||||
/// </summary>
|
||||
[Column("创建人")]
|
||||
public string Creator { get; set; }
|
||||
/// <summary>
|
||||
/// 创建时间(入库时间)
|
||||
/// </summary>
|
||||
[Column("入库时间")]
|
||||
public string CreateTime { get; set; }
|
||||
/// <summary>
|
||||
/// 同步成功或者失败
|
||||
/// </summary>
|
||||
[Column("金蝶同步状态")]
|
||||
public string SuccessSync { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using Npoi.Mapper.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -12,101 +13,123 @@ namespace WMS.Web.Core.Dto
|
||||
/// <summary>
|
||||
/// ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 明细ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int DetailsId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单据编号
|
||||
/// </summary>
|
||||
[Column("入库任务单号")]
|
||||
public string BillNo { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 来源单号
|
||||
/// </summary>
|
||||
[Column("来源单号")]
|
||||
public string SourceBillNo { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 入库状态
|
||||
/// </summary>
|
||||
[Column("入库状态")]
|
||||
public string Status { get; set; }
|
||||
/// <summary>
|
||||
/// 入库类型
|
||||
/// </summary>
|
||||
[Column("入库类型")]
|
||||
public string Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 供应商Id
|
||||
/// </summary>
|
||||
[Column("供应商")]
|
||||
public string Supplier { get; set; }
|
||||
/// <summary>
|
||||
/// 组织ID
|
||||
/// </summary>
|
||||
[Column("组织")]
|
||||
public string Org { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 物料名称
|
||||
/// </summary>
|
||||
[Column("物料名称")]
|
||||
public string MaterialName { get; set; }
|
||||
/// <summary>
|
||||
/// 物料编码
|
||||
/// </summary>
|
||||
[Column("物料编码")]
|
||||
public string MaterialNumber { get; set; }
|
||||
/// <summary>
|
||||
/// 物料规格型号
|
||||
/// </summary>
|
||||
[Column("规格型号")]
|
||||
public string Specifications { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 出厂价
|
||||
/// </summary>
|
||||
[Column("出厂价")]
|
||||
public decimal FactoryPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 收货仓库
|
||||
/// </summary>
|
||||
[Column("收货仓库")]
|
||||
public string Stock { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 应入数量
|
||||
/// </summary>
|
||||
[Column("应入库数量")]
|
||||
public decimal AccruedQty { get; set; }
|
||||
/// <summary>
|
||||
/// 收货数量
|
||||
/// </summary>
|
||||
[Column("收货数量")]
|
||||
public decimal ReceiveQty { get; set; }
|
||||
/// <summary>
|
||||
/// 实际入库数量
|
||||
/// </summary>
|
||||
[Column("实入库数量")]
|
||||
public decimal RealityQty { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 收货人
|
||||
/// </summary>
|
||||
[Column("收货人")]
|
||||
public string Receiver { get; set; }
|
||||
/// <summary>
|
||||
/// 收货时间
|
||||
/// </summary>
|
||||
[Column("收货时间")]
|
||||
public string ReceiveTime { get; set; }
|
||||
/// <summary>
|
||||
/// 上架人
|
||||
/// </summary>
|
||||
[Column("上架人")]
|
||||
public string Shelfer { get; set; }
|
||||
/// <summary>
|
||||
/// 入库时间
|
||||
/// </summary>
|
||||
[Column("入库时间")]
|
||||
public string ShelfTime { get; set; }
|
||||
/// <summary>
|
||||
/// 明细备注
|
||||
/// </summary>
|
||||
[Column("订单明细备注")]
|
||||
public string Remark { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建时间(erp那边的创建时间)
|
||||
/// </summary>
|
||||
[Column("创建时间")]
|
||||
public string CreateTime { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using Npoi.Mapper.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -12,49 +13,60 @@ namespace WMS.Web.Core.Dto.Inventory
|
||||
/// <summary>
|
||||
/// ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 明细ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int DetailsId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 箱号
|
||||
/// </summary>
|
||||
[Column("箱号")]
|
||||
public string BoxBillNo { get; set; }
|
||||
/// <summary>
|
||||
/// 仓库
|
||||
/// </summary>
|
||||
[Column("仓库")]
|
||||
public string Stock { get; set; }
|
||||
/// <summary>
|
||||
/// 仓位
|
||||
/// </summary>
|
||||
[Column("仓位")]
|
||||
public string SubStock { get; set; }
|
||||
/// <summary>
|
||||
/// 物料名称
|
||||
/// </summary>
|
||||
[Column("物料名称")]
|
||||
public string MaterialName { get; set; }
|
||||
/// <summary>
|
||||
/// 物料编码
|
||||
/// </summary>
|
||||
[Column("物料编码")]
|
||||
public string MaterialNumber { get; set; }
|
||||
/// <summary>
|
||||
/// 物料规格型号
|
||||
/// </summary>
|
||||
[Column("规格型号")]
|
||||
public string Specifications { get; set; }
|
||||
/// <summary>
|
||||
/// 序列号集
|
||||
/// </summary>
|
||||
[Column("序列号")]
|
||||
public string SerialNumbers { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织
|
||||
/// </summary>
|
||||
[Column("组织")]
|
||||
public string Org { get; set; }
|
||||
/// <summary>
|
||||
/// 物料库存数量
|
||||
/// </summary>
|
||||
[Column("数量")]
|
||||
public decimal Qty { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using Npoi.Mapper.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -12,43 +13,52 @@ namespace WMS.Web.Core.Dto.Inventory
|
||||
/// <summary>
|
||||
/// ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 物料名称
|
||||
/// </summary>
|
||||
[Column("物料名称")]
|
||||
public string MaterialName { get; set; }
|
||||
/// <summary>
|
||||
/// 物料编码
|
||||
/// </summary>
|
||||
[Column("物料编码")]
|
||||
public string MaterialNumber { get; set; }
|
||||
/// <summary>
|
||||
/// 物料规格型号
|
||||
/// </summary>
|
||||
[Column("规格型号")]
|
||||
public string Specifications { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织
|
||||
/// </summary>
|
||||
[Column("组织")]
|
||||
public string Org { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 仓库
|
||||
/// </summary>
|
||||
[Column("仓库")]
|
||||
public string Stock { get; set; }
|
||||
/// <summary>
|
||||
/// 仓位
|
||||
/// </summary>
|
||||
[Column("仓位")]
|
||||
public string SubStock { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 库存量
|
||||
/// </summary>
|
||||
[Column("库存量")]
|
||||
public decimal Qty { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单位
|
||||
/// </summary>
|
||||
[Column("单位")]
|
||||
public string Unit { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using Npoi.Mapper.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
@@ -12,57 +13,69 @@ namespace WMS.Web.Core.Dto.Inventory
|
||||
/// <summary>
|
||||
/// ID
|
||||
/// </summary>
|
||||
[Ignore]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 物料名称
|
||||
/// </summary>
|
||||
[Column("物料名称")]
|
||||
public string MaterialName { get; set; }
|
||||
/// <summary>
|
||||
/// 物料编码
|
||||
/// </summary>
|
||||
[Column("物料编码")]
|
||||
public string MaterialNumber { get; set; }
|
||||
/// <summary>
|
||||
/// 物料规格型号
|
||||
/// </summary>
|
||||
[Column("规格型号")]
|
||||
public string Specifications { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 类型:1为入库,2为出库
|
||||
/// </summary>
|
||||
[Column("出入库类型")]
|
||||
public string Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织
|
||||
/// </summary>
|
||||
[Column("组织")]
|
||||
public string Org { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 仓库
|
||||
/// </summary>
|
||||
[Column("仓库")]
|
||||
public string Stock { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单据类型
|
||||
/// </summary>
|
||||
[Column("单据类型")]
|
||||
public string OrderType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单据编号
|
||||
/// </summary>
|
||||
[Column("单号")]
|
||||
public string OrderBillNo { get; set; }
|
||||
/// <summary>
|
||||
/// 数量
|
||||
/// </summary>
|
||||
[Column("数量")]
|
||||
public decimal Qty { get; set; }
|
||||
/// <summary>
|
||||
/// 结存
|
||||
/// </summary>
|
||||
[Column("结存")]
|
||||
public decimal SurplusQty { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 创建日期
|
||||
/// </summary>
|
||||
[Column("日期")]
|
||||
public string CreateTime { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -782,9 +782,9 @@ namespace WMS.Web.Domain.Services
|
||||
//3.3组装要新增的箱库存:明细中的序列号
|
||||
foreach (var item in addEntity.Details)
|
||||
{
|
||||
var box_serialNub = box_serialNumbers.Where(x => x.MaterialId == item.MaterialId).FirstOrDefault();
|
||||
if (box_serialNub != null)
|
||||
item.SerialNumbers.Add(box_serialNub.SerialNumber);
|
||||
var box_serialNubs = box_serialNumbers.Where(x => x.MaterialId == item.MaterialId).Select(x=>x.SerialNumber).ToList();
|
||||
if (box_serialNubs != null && box_serialNubs.Count!=0)
|
||||
item.SerialNumbers.AddRange(box_serialNubs);
|
||||
}
|
||||
//3.4箱库存:要新增的集合
|
||||
add_entitys.Add(addEntity);
|
||||
|
||||
Reference in New Issue
Block a user