提交
This commit is contained in:
@@ -76,14 +76,31 @@ namespace ZR.Service.mes.wms
|
||||
/// <returns></returns>
|
||||
public int isProductionPackage(string production_packcode)
|
||||
{
|
||||
Regex r = new Regex("BNW_\\d{9}_\\d{3}");
|
||||
Regex r = new Regex("CodeBNW\\d{9}_\\d{0,3}");
|
||||
Regex r1 = new Regex("Code=BNW\\d{9}_\\d{0,3}");
|
||||
|
||||
|
||||
//todo 不是箱子
|
||||
if (!r.IsMatch(production_packcode))
|
||||
if (!r.IsMatch(production_packcode)& !r1.IsMatch(production_packcode))
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
// 匹配 CodeBNW\\d{9}_\\d{0,3}
|
||||
|
||||
if (r.IsMatch(production_packcode))
|
||||
{
|
||||
string workorder_id = production_packcode.Substring(3, 9);
|
||||
string flow_id = production_packcode.Substring(13, 3).ToString("000");
|
||||
|
||||
}
|
||||
|
||||
if (r1.IsMatch(production_packcode))
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
string workorder_id = production_packcode.Substring(3, 9);
|
||||
string flow_id = production_packcode.Substring(13, 3);
|
||||
string flow_id = production_packcode.Substring(13, 3).ToString("000");
|
||||
bool isExist = Context.Queryable<WmPackingrecord>()
|
||||
.Where(it => it.WorkOrderNum == workorder_id)
|
||||
.Where(it => it.PackingCode.EndsWith(flow_id))
|
||||
|
||||
Reference in New Issue
Block a user