|
|
@@ -3883,6 +3883,8 @@ namespace Business.Replenishment
|
|
|
List<string> orderCode = morders.Select(c => c.product_code).ToList();
|
|
|
//成品虚拟件对应关系
|
|
|
var productOpList = _productStructureOp.Select(x => orderCode.Contains(x.ProductItem) && x.Domain == param.factoryId.ToString());
|
|
|
+ //获取物料主数据
|
|
|
+ List<ItemMaster> itemMasters = _itemMaster.Select(p => p.Domain == param.factoryId.ToString() && orderCode.Contains(p.ItemNum)).ToList();
|
|
|
foreach (var item in morders)
|
|
|
{
|
|
|
var moItem = exmResult.Find(b => b.morder_no ==item.morder_no);
|
|
|
@@ -3900,6 +3902,8 @@ namespace Business.Replenishment
|
|
|
workOrd.Status ="";
|
|
|
workOrd.IsActive = true;
|
|
|
workOrd.IsConfirm = true;
|
|
|
+ var curItem = itemMasters.FirstOrDefault(p => p.ItemNum == item.product_code);
|
|
|
+ workOrd.CreateGLforLaborVar = curItem == null ? false : curItem.Install;
|
|
|
workOrd.CreateTime = DateTime.Now;
|
|
|
workOrd.Typed = "";
|
|
|
//workOrd.SalesJob = item.morder_no;
|