Browse Source

[CI SKIP] 补充注释

master
mahao 1 year ago
parent
commit
bf0c0e11ac
  1. 29
      code/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/PubSaSeCompareExportService.cs
  2. 15
      code/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/SaSeCompareExportBaseService.cs

29
code/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/PubSaSeCompareExportService.cs

@ -178,6 +178,19 @@ namespace SettleAccount.Job.Services.Report
}
//结算
var saGroup = from sa in _settleAccountDbContext.Set<PUB_SA_DETAIL>()
where sa.BusinessType == businessType
group sa by new { sa.PN, sa.CustomerPartCodeNoSpace } into groupItem
select new
{
groupItem.Key.PN,
groupItem.Key.CustomerPartCodeNoSpace,
Qty = groupItem.Sum(t => t.Qty),
Version = groupItem.Max(t => t.Version),
LU = groupItem.Max(t => t.LU),
SettleDate = groupItem.Max(t => t.SettleDate),
PartCode = groupItem.Max(t => t.PartCode)
};
var saGroupByMappingType = from sa in _settleAccountDbContext.Set<PUB_SA_DETAIL>()
where sa.BusinessType == businessType && sa.MappingType == EnumMappingType.None
group sa by new { sa.PN, sa.CustomerPartCodeNoSpace } into groupItem
select new
@ -221,7 +234,7 @@ namespace SettleAccount.Job.Services.Report
};
//有结算无发运
var haveSaNotHaveSeList = (from sa in saGroup
var haveSaNotHaveSeList = (from sa in saGroupByMappingType
join se in seGroup
on new { sa.PN, sa.CustomerPartCodeNoSpace } equals new { se.PN, se.CustomerPartCodeNoSpace }
into temp
@ -291,6 +304,18 @@ namespace SettleAccount.Job.Services.Report
{
//结算
var saGroup = from sa in _settleAccountDbContext.Set<PUB_SA_DETAIL>()
where sa.BusinessType == EnumBusinessType.YinDuJian
group sa by new { sa.CustomerPartCodeNoSpace } into groupItem
select new
{
groupItem.Key.CustomerPartCodeNoSpace,
Qty = groupItem.Sum(t => t.Qty),
Version = groupItem.Max(t => t.Version),
LU = groupItem.Max(t => t.LU),
SettleDate = groupItem.Max(t => t.SettleDate),
PartCode = groupItem.Max(t => t.PartCode)
};
var saGroupByMappingType = from sa in _settleAccountDbContext.Set<PUB_SA_DETAIL>()
where sa.BusinessType == EnumBusinessType.YinDuJian && sa.MappingType == EnumMappingType.None
group sa by new { sa.CustomerPartCodeNoSpace } into groupItem
select new
@ -331,7 +356,7 @@ namespace SettleAccount.Job.Services.Report
};
//有结算无发运
var haveSaNotHaveSeList = (from sa in saGroup
var haveSaNotHaveSeList = (from sa in saGroupByMappingType
join se in seGroup
on sa.CustomerPartCodeNoSpace equals se.CustomerPartCodeNoSpace
into temp

15
code/src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/SaSeCompareExportBaseService.cs

@ -49,6 +49,19 @@ namespace SettleAccount.Job.Services.Report
{
//结算
var saGroup = from sa in _settleAccountDbContext.Set<TSaDetail>()
where sa.BusinessType == businessType
group sa by new { sa.PN, sa.CustomerPartCodeNoSpace } into groupItem
select new
{
groupItem.Key.PN,
groupItem.Key.CustomerPartCodeNoSpace,
Qty = groupItem.Sum(t => t.Qty),
Version = groupItem.Max(t => t.Version),
LU = groupItem.Max(t => t.LU),
SettleDate = groupItem.Max(t => t.SettleDate),
PartCode = groupItem.Max(t => t.PartCode)
};
var saGroupByMappingType = from sa in _settleAccountDbContext.Set<TSaDetail>()
where sa.BusinessType == businessType && sa.MappingType == EnumMappingType.None
group sa by new { sa.PN, sa.CustomerPartCodeNoSpace } into groupItem
select new
@ -92,7 +105,7 @@ namespace SettleAccount.Job.Services.Report
};
//有结算无发运
var haveSaNotHaveSeList = (from sa in saGroup
var haveSaNotHaveSeList = (from sa in saGroupByMappingType
join se in seGroup
on new { sa.PN, sa.CustomerPartCodeNoSpace } equals new { se.PN, se.CustomerPartCodeNoSpace }
into temp

Loading…
Cancel
Save