diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_CAN_SA_SERVICE.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_CAN_SA_SERVICE.cs index ea44fe78..e9eff054 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_CAN_SA_SERVICE.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_CAN_SA_SERVICE.cs @@ -85,8 +85,13 @@ namespace Win.Sfs.SettleAccount.Entities.BQ public async override Task GenerateInvoice(string invbillNum) { var main =await _bbacMng.GetMainAsync(invbillNum); + if (main != null) { + if (main.State != SettleBillState.未结状态) + { + return new JsonResult(new { Code = 400, Message = "已创建发票不能重复创建" }); + } if (await _bbacMng.SetForwardState(main, SettleBillState.已开票)) { var entitys = await _bbacMng.GetDetalListAsync(invbillNum);//可结算 @@ -105,6 +110,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ where d.SettleDate >= p.BeginTime && d.SettleDate <= p.EndTime select new TEMP_CAN_SA_DETAIL { + SettleBillNum = d.SettleBillNum, Site = d.Site, Version = d.Version, @@ -159,7 +165,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ } else { - throw new UserFriendlyException(string.Format("{0}不存在该可结算单号", invbillNum)); + return new JsonResult(new { Code = 400, Message = "不存在发票记录" }); } return new JsonResult(new { Code = 200, Message = "生成成功" }); } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_PD_SERVICE.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_PD_SERVICE.cs index dc2197d6..940af115 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_PD_SERVICE.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_PD_SERVICE.cs @@ -95,7 +95,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ // }); // } //} - return ApplicationConsts.SuccessStr; + // return ApplicationConsts.SuccessStr; } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/HBPO_CAN_SA_SERVICE.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/HBPO_CAN_SA_SERVICE.cs index 9a3ff640..ff25379e 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/HBPO_CAN_SA_SERVICE.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/HBPO_CAN_SA_SERVICE.cs @@ -11,6 +11,7 @@ using System.Linq; using System.Security.Policy; using System.Text; using System.Threading.Tasks; +using Volo.Abp; using Volo.Abp.Application.Dtos; using Volo.Abp.Application.Services; using Volo.Abp.ObjectMapping; @@ -78,19 +79,27 @@ namespace Win.Sfs.SettleAccount.Entities.BQ { var main =await _hbpoMng.GetMainAsync(invbillnum); + if (main != null) { + if (main.State != SettleBillState.未结状态) + { + + return new JsonResult(new { Code = 400, Message = "已创建发票不能重复创建" }); + } + + if (await _hbpoMng.SetForwardState(main, SettleBillState.已开票)) { var entitys = await _hbpoMng.GetDetalListAsync(invbillnum); var groupNumList = entitys.Select(p => p.GroupNum).Distinct().ToList(); var notQuery = _notRepository.Where(p => groupNumList.Contains(p.InvGroupNum)).ToList(); - + var priceList = _priceRepository.ToList();//价格单 - var errorList=await CheckInvoiceGenerationRules(entitys, priceList,main.BusinessType);//校验生成规则 + var errorList = await CheckInvoiceGenerationRules(entitys, priceList, main.BusinessType);//校验生成规则 if (errorList.Count() > 0) { - return new JsonResult(new { Code = ApplicationConsts.ImportFailCode, fileName = await ExportErrorReportAsync(errorList) }); + return new JsonResult(new { Code = ApplicationConsts.ImportFailCode, fileName = await ExportErrorReportAsync(errorList) }); } var dto1s = ObjectMapper.Map, List>(entitys); var q = from d in dto1s @@ -111,11 +120,11 @@ namespace Win.Sfs.SettleAccount.Entities.BQ Qty = d.Qty, GroupNum = d.GroupNum, Amt = Math.Round(d.Qty * p.Price, 2), - ContractDocID="no", + ContractDocID = "no", BeginDate = p.BeginTime, EndDate = p.EndTime, - PartCode=d.PartCode - + PartCode = d.PartCode + }; var dtos = q.ToList(); if (dtos != null && dtos.Count > 0) @@ -138,19 +147,23 @@ namespace Win.Sfs.SettleAccount.Entities.BQ SettleDate = p.SettleDate, GroupNum = p.GroupNum, ContractDocID = string.Empty, - PartCode=p.PartCode + PartCode = p.PartCode }).ToList();//不能结算 - var falg= await FirstInvoice(entitys,new List(), dtos, notlist, main.Version, main.InvGroupNum, string.Empty,main.BusinessType); + var falg = await FirstInvoice(entitys, new List(), dtos, notlist, main.Version, main.InvGroupNum, string.Empty, main.BusinessType); } else//二次开票 { - var flag=await SecInvoice(entitys,new List(),dtos, main.Version, main.InvGroupNum, string.Empty, main.BusinessType); + var flag = await SecInvoice(entitys, new List(), dtos, main.Version, main.InvGroupNum, string.Empty, main.BusinessType); } } } } + else + { + return new JsonResult(new { Code = 400, Message = "不存在发票记录" }); + } return new JsonResult(new { Code = 200, Message = "生成成功" }); } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_CAN_SA_SERVICE.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_CAN_SA_SERVICE.cs index 0e584220..af2170b6 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_CAN_SA_SERVICE.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/PUB_CAN_SA_SERVICE.cs @@ -7,6 +7,7 @@ using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Microsoft.EntityFrameworkCore.Migrations; using SettleAccount.Domain.BQ; +using Volo.Abp; using Volo.Abp.Data; using Volo.Abp.Domain.Entities; using Win.Abp.Snowflakes; @@ -68,8 +69,15 @@ namespace Win.Sfs.SettleAccount.Entities.BQ public async override Task GenerateInvoice(string billnum) { var main = await _pubMng.GetMainAsync(billnum); + if (main != null) { + if (main.State != SettleBillState.未结状态) + { + return new JsonResult(new { Code = 400, Message = "已创建发票不能重复创建" }); + } + + if (await _pubMng.SetForwardState(main, SettleBillState.已开票)) { var entitys = await _pubMng.GetDetalListAsync(billnum); @@ -99,6 +107,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ where d.SettleDate >= p.BeginTime && d.SettleDate <= p.EndTime select new TEMP_CAN_SA_DETAIL { + Id = d.Id, SettleBillNum = d.SettleBillNum, Site = d.Site, Version = d.Version, @@ -115,7 +124,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ ContractDocID = "no", BeginDate = p.BeginTime, EndDate = p.EndTime, - PartCode=d.PartCode,//客户零件号 + PartCode = d.PartCode,//客户零件号 }; var dtos = q.ToList(); if (dtos != null && dtos.Count > 0) @@ -123,16 +132,20 @@ namespace Win.Sfs.SettleAccount.Entities.BQ if (billnum.Substring(0, 1) == "C")//一次开票 { - await FirstInvoice(entitys, new List(), dtos, new List(), main.Version, main.InvGroupNum, string.Empty, main.BusinessType); - + await FirstInvoice(entitys, new List(), dtos, new List(), main.Version, main.InvGroupNum, string.Empty, main.BusinessType); + } else//二次开票 { - await SecInvoice(entitys,new List(), dtos, main.Version, main.InvGroupNum, string.Empty, main.BusinessType); + await SecInvoice(entitys, new List(), dtos, main.Version, main.InvGroupNum, string.Empty, main.BusinessType); } } } } + else + { + return new JsonResult(new { Code = 400, Message = "不存在发票记录" }); + } return new JsonResult(new { Code = 200, Message = "生成成功" }); } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/Syncs/PendingDeductionService.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/Syncs/PendingDeductionService.cs index b5df5fe5..8d19fbdf 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/Syncs/PendingDeductionService.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/Syncs/PendingDeductionService.cs @@ -32,8 +32,6 @@ public class PendingDeductionService : ITransientDependency, IExportJob INormalEfCoreRepository hbpoRepository, INormalEfCoreRepository pubRepository, VmiAppService vimservice - - ) { _hbpoRepository = hbpoRepository; @@ -105,8 +103,8 @@ public class PendingDeductionService : ITransientDependency, IExportJob LogType = Entities.BQ.Vmi.VmiLogType.Type200, ChangedQty = itm.Qty, ChangedType = VmiType.Out, - SubBillType = EnumDeliverSubBillType.小件BBAC, - BillType = EnumDeliverBjBmpBillType.JIS件, + //SubBillType = EnumDeliverSubBillType.小件BBAC, + //BillType = EnumDeliverBjBmpBillType.JIS件, PartCode = itm.PartCode, SettlementVinCode = itm.VinCode, PartCode2 = itm.PartCode2, @@ -130,45 +128,118 @@ public class PendingDeductionService : ITransientDependency, IExportJob BillTime = itm.CreationTime, ChangedTime = DateTime.Now, Qty = itm.Qty, - DeliverTime = itm.CreationTime, + // DeliverTime = , LogType = Entities.BQ.Vmi.VmiLogType.Type200, ChangedQty = itm.Qty, ChangedType = VmiType.Out, - SubBillType = EnumDeliverSubBillType.小件BBAC, - BillType = EnumDeliverBjBmpBillType.JIS件, - PartCode = itm.LU, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 SettlementVinCode = itm.PN, - PartCode2 = itm.LU, + PartCode2 = itm.LU,//厂内 CustomerPartCode = itm.LU, VinCode = itm.PN, - OrderNum = itm.GroupNum, + // OrderNum = itm.GroupNum, 非JIS传ASN 交付识别号 ErpToLoc = "C0001" }).ConfigureAwait(false); } } - } else { var detailist = _hbpoRepository.Where(p => list.Contains(p.BillNum)).ToList(); - switch (type) { case "ZhiGongJianBBAC": - - - + if (detailist != null && detailist.Count > 0) + { + foreach (var itm in detailist) + { + _vimservice.Out(Entities.BQ.Vmi.VmiLogType.Type200, "1", new Entities.BQ.Vmi.VmiLog() + { + BillTime = itm.CreationTime, + ChangedTime = DateTime.Now, + Qty = itm.Qty, + // DeliverTime = , + LogType = Entities.BQ.Vmi.VmiLogType.Type200, + ChangedQty = itm.Qty, + ChangedType = VmiType.Out, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 + SettlementVinCode = itm.PN, + PartCode2 = itm.LU,//厂内 + CustomerPartCode = itm.LU, + VinCode = itm.PN, + OrderNum = itm.PN, + ErpToLoc = "C0001" + }).ConfigureAwait(false); + } + } break; case "ZhiGongJianHBPO": + if (detailist != null && detailist.Count > 0) + { + foreach (var itm in detailist) + { + _vimservice.Out(Entities.BQ.Vmi.VmiLogType.Type200, "1", new Entities.BQ.Vmi.VmiLog() + { + BillTime = itm.CreationTime, + ChangedTime = DateTime.Now, + Qty = itm.Qty, + // DeliverTime = , + LogType = Entities.BQ.Vmi.VmiLogType.Type200, + ChangedQty = itm.Qty, + ChangedType = VmiType.Out, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 + SettlementVinCode = itm.PN, + PartCode2 = itm.LU,//厂内 + CustomerPartCode = itm.LU, + VinCode = itm.PN, + OrderNum = itm.PN,// 非JIS传ASN 交付识别号 + ErpToLoc = "C0001" + }).ConfigureAwait(false); + } + } break; case "MaiDanJianBBAC": + if (detailist != null && detailist.Count > 0) + { + foreach (var itm in detailist) + { + _vimservice.Out(Entities.BQ.Vmi.VmiLogType.Type200, "1", new Entities.BQ.Vmi.VmiLog() + { + BillTime = itm.CreationTime, + ChangedTime = DateTime.Now, + Qty = itm.Qty, + // DeliverTime = , + LogType = Entities.BQ.Vmi.VmiLogType.Type200, + ChangedQty = itm.Qty, + ChangedType = VmiType.Out, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 + SettlementVinCode = itm.PN, + PartCode2 = itm.LU,//厂内 + CustomerPartCode = itm.LU, + VinCode = itm.PN, + // OrderNum = itm.GroupNum, 非JIS传ASN 交付识别号 + ErpToLoc = "C0001" + }).ConfigureAwait(false); + } + } + + + @@ -176,18 +247,99 @@ public class PendingDeductionService : ITransientDependency, IExportJob case "MaiDanJianHBPO": + if (detailist != null && detailist.Count > 0) + { + foreach (var itm in detailist) + { + _vimservice.Out(Entities.BQ.Vmi.VmiLogType.Type200, "1", new Entities.BQ.Vmi.VmiLog() + { + BillTime = itm.CreationTime, + ChangedTime = DateTime.Now, + Qty = itm.Qty, + // DeliverTime = , + LogType = Entities.BQ.Vmi.VmiLogType.Type200, + ChangedQty = itm.Qty, + ChangedType = VmiType.Out, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 + SettlementVinCode = itm.PN, + PartCode2 = itm.LU,//厂内 + CustomerPartCode = itm.LU, + VinCode = itm.PN, + // OrderNum = itm.GroupNum, 非JIS传ASN 交付识别号 + ErpToLoc = "C0001" + }).ConfigureAwait(false); + } + } + + break; case "BeiJian": + if (detailist != null && detailist.Count > 0) + { + foreach (var itm in detailist) + { + _vimservice.Out(Entities.BQ.Vmi.VmiLogType.Type200, "1", new Entities.BQ.Vmi.VmiLog() + { + BillTime = itm.CreationTime, + ChangedTime = DateTime.Now, + Qty = itm.Qty, + // DeliverTime = , + LogType = Entities.BQ.Vmi.VmiLogType.Type200, + ChangedQty = itm.Qty, + ChangedType = VmiType.Out, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 + SettlementVinCode = itm.PN, + PartCode2 = itm.LU,//厂内 + CustomerPartCode = itm.LU, + VinCode = itm.PN, + // OrderNum = itm.GroupNum, 非JIS传ASN 交付识别号 + ErpToLoc = "C0001" + }).ConfigureAwait(false); + } + } + + break; case "YinDuJian": + if (detailist != null && detailist.Count > 0) + { + foreach (var itm in detailist) + { + _vimservice.Out(Entities.BQ.Vmi.VmiLogType.Type200, "1", new Entities.BQ.Vmi.VmiLog() + { + BillTime = itm.CreationTime, + ChangedTime = DateTime.Now, + Qty = itm.Qty, + // DeliverTime = , + LogType = Entities.BQ.Vmi.VmiLogType.Type200, + ChangedQty = itm.Qty, + ChangedType = VmiType.Out, + // SubBillType = EnumDeliverSubBillType.保险杠HBPO, + // BillType = EnumDeliverBjBmpBillType.JIS件, + PartCode = itm.LU,//客户 + SettlementVinCode = itm.PN, + PartCode2 = itm.LU,//厂内 + CustomerPartCode = itm.LU, + VinCode = itm.PN, + // OrderNum = itm.GroupNum, 非JIS传ASN 交付识别号 + ErpToLoc = "C0001" + }).ConfigureAwait(false); + } + } + + diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs index 421b32ec..4fd7dca0 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs @@ -174,11 +174,6 @@ public class PriceListAppService : SettleAccountApplicationBase return await _priceListManager.DeleteListAsync(ids); } #endregion - - - - - #region 原方法(废弃) // /// // /// 获取总数 diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationModule.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationModule.cs index 6085eb0f..9a330ce1 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationModule.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/SettleAccountApplicationModule.cs @@ -78,151 +78,6 @@ namespace Win.Sfs.SettleAccount - //if (key.Equals(typeof(InvoiceSettledDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(UnSettledExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(fisUnsettledDiffReport).FullName)) - //{//ERP总成开票报表 - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(PriceQtyDifferenceExportService).FullName)) - //{//量差和价差分析报表 - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(SettledPartAndErpPartPriceDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(SecMatchBaseExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - - //if (key.Equals(typeof(SettleFisDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - - ////大众看板结算与交货核对明细表(有条码) - //if (key.Equals(typeof(SettleKBWithCodeExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////大众备件结算核对明细表 - //if (key.Equals(typeof(SettleSparePartExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////大众备件未结明细 - //if (key.Equals(typeof(SettleUnSparePartExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////大众备件90天核对明细 - //if (key.Equals(typeof(SettleSparePart90ExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(InvoiceSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(UnInvoiceSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(UnSettleDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - - //if (key.Equals(typeof(SettleDoorPanelExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(UnsettledDetailReportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(SettleKBWithOutCodeExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(SharePartUnSettledExport).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////红旗、一汽轿车结算报表 - //if (key.Equals(typeof(HQFSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQFSharePartSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQMSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQMSharePartSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQHSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////红旗结算未结明细 - //if (key.Equals(typeof(HQHUnSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////红旗未结核对 - //if (key.Equals(typeof(HQFactoryUnSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQHSharePartSettledDetailDiffExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////红旗、轿车发运报表 - //if (key.Equals(typeof(HQMShippingExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQHShippingExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(HQFShippingExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(WmsOutputSumExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - ////大众看板未结输出 - //if (key.Equals(typeof(KanBanUnSettledExport).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(FisUpdateExportService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - //if (key.Equals(typeof(FisOutputService).FullName)) - //{ - // return implementationFactory.GetService(); - //} - diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG_EXT.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG_EXT.cs index 831b622e..4d595af3 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG_EXT.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG_EXT.cs @@ -1078,7 +1078,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers var query = from inv1 in invdetails join dto1 in dtos on - new { inv1.LU, inv1.PN } equals new { dto1.LU, dto1.PN } + new { inv1.LU, inv1.PN,inv1.Id } equals new { dto1.LU, dto1.PN, dto1.Id } select new { PartCode = inv1.PartCode,