优化
This commit is contained in:
@@ -308,6 +308,38 @@ namespace WMS.Web.Domain.Services
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
////
|
||||||
|
//var noMartDetails = new List<InStockTaskDetails>();
|
||||||
|
//var data_list_details_new = data_list.SelectMany(x => x.Details).ToList();
|
||||||
|
//data_list_details_new.ForEach(x =>
|
||||||
|
//{
|
||||||
|
// //2.1.1对比erp的物料信息
|
||||||
|
// var erp_data = erp_list.Where(t => t.ErpDetailId == x.ErpDetailId).FirstOrDefault();
|
||||||
|
// if (erp_data != null)
|
||||||
|
// {
|
||||||
|
// if (erp_data.MaterialId != x.MaterialId)
|
||||||
|
// {
|
||||||
|
// //明细的物料改变了:新的物料重新添加一条明细
|
||||||
|
// var Add_task_no_materials = _mapper.Map<InStockTaskDetails>(erp_data);
|
||||||
|
// noMartDetails.Add(Add_task_no_materials);
|
||||||
|
// //给老的物料应收数量改为0
|
||||||
|
// x.AccruedQty = 0;
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// else
|
||||||
|
// {
|
||||||
|
// x.AccruedQty = 0;
|
||||||
|
// }
|
||||||
|
//});
|
||||||
|
////明细的物料改变了:新的物料重新添加一条明细
|
||||||
|
//if (noMartDetails.Count != 0)
|
||||||
|
//{
|
||||||
|
// foreach (var item in noMartDetails)
|
||||||
|
// {
|
||||||
|
// data_list_details_new.Add(item);
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
//2.2.提交修改
|
//2.2.提交修改
|
||||||
var isSuccess = await _inStockTaskRepositories.UpdateRange(data_list, isTransaction);
|
var isSuccess = await _inStockTaskRepositories.UpdateRange(data_list, isTransaction);
|
||||||
if (!isSuccess)
|
if (!isSuccess)
|
||||||
|
|||||||
Reference in New Issue
Block a user