Browse Source

客户退货取消零件存在多个客户校验

交付给东阳的源代码
周红军 2 weeks ago
parent
commit
c0adc5b457
  1. 10
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/CustomerProductionReturnNotes/CustomerProductionReturnNoteAppService.cs

10
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/CustomerProductionReturnNotes/CustomerProductionReturnNoteAppService.cs

@ -139,11 +139,11 @@ public class CustomerProductionReturnNoteAppService :
on itm.ItemCode equals itm1.ItemCode
select itm1;
var custErr= checkCustomer.Select(x => x.CustomerCode).Distinct().ToList();
if (custErr.Count > 1)
{
throw new UserFriendlyException($"提交客户退货物品{string.Join(",", custErr)}存在多个客户,不能退货!");
}
//var custErr= checkCustomer.Select(x => x.CustomerCode).Distinct().ToList();
//if (custErr.Count > 1)
//{
// throw new UserFriendlyException($"提交客户退货物品{string.Join(",", custErr)}存在多个客户,不能退货!");
//}
if(entity.Details.Count>0)
{
entity.CustomerCode = checkCustomer.FirstOrDefault().CustomerCode;

Loading…
Cancel
Save