This commit is contained in:
tongfei
2024-02-21 11:06:43 +08:00
parent 828323a6b9
commit 3b4b9ca593
5 changed files with 61 additions and 46 deletions

View File

@@ -129,10 +129,13 @@ namespace WMS.Web.Domain.Entitys
if (hasPart)
boxCount = Convert.ToInt32(Math.Ceiling(boxCount_tag));
for (int i = 0; i < boxCount; i++)
for (int i = 1; i <= boxCount; i++)
{
//添加编号生成
var bill = new BoxMarkBillNo();
var bill = new BoxMarkBillNo();
bill.Sort = i;
if (hasPart && i == boxCount)
bill.IsTail = true;
bill.GenerateBillNo(firstBillNo, lastBillNo);
this.BillNos.Add(bill);
@@ -141,8 +144,8 @@ namespace WMS.Web.Domain.Entitys
lastBillNo = bill.LastBillNo;
}
//判断有小数点,那么它就有尾箱,把当前第一条的编号是否是尾箱字段改为true
if (this.BillNos.Count != 0 && hasPart)
this.BillNos[0].IsTail = true;
//if (this.BillNos.Count != 0 && hasPart)
// this.BillNos[0].IsTail = true;
}
}

View File

@@ -43,6 +43,11 @@ namespace WMS.Web.Domain.Entitys
/// </summary>
public bool IsTail { get; set; }
/// <summary>
/// 排序
/// </summary>
public int Sort { get; set; }
/// <summary>
/// 生成编号
/// </summary>