|
@ -431,7 +431,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
{ |
|
|
{ |
|
|
foreach (var itm in adjlist) |
|
|
foreach (var itm in adjlist) |
|
|
{ |
|
|
{ |
|
|
entityList.Add(new BBAC_CAN_SA_DETAIL( |
|
|
var detail = new BBAC_CAN_SA_DETAIL( |
|
|
guid: GuidGenerator.Create(), |
|
|
guid: GuidGenerator.Create(), |
|
|
keyCode: itm.KeyCode, |
|
|
keyCode: itm.KeyCode, |
|
|
version: itm.Version, |
|
|
version: itm.Version, |
|
@ -449,9 +449,10 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
contactid: itm.Extend1,//生产号
|
|
|
contactid: itm.Extend1,//生产号
|
|
|
invbillnum: itm.InvBillNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
partcode:itm.PartCode |
|
|
partcode: itm.PartCode); |
|
|
|
|
|
detail.ErpLoc = itm.ErpLoc; |
|
|
)); |
|
|
detail.RealPartCode = itm.RealPartCode; |
|
|
|
|
|
entityList.Add(detail); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -464,7 +465,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
{ |
|
|
{ |
|
|
foreach (var itm in adjlist) |
|
|
foreach (var itm in adjlist) |
|
|
{ |
|
|
{ |
|
|
entityDetail.Add(new BBAC_CAN_SA_DETAIL( |
|
|
var detail = new BBAC_CAN_SA_DETAIL( |
|
|
guid: GuidGenerator.Create(), |
|
|
guid: GuidGenerator.Create(), |
|
|
keyCode: itm.KeyCode, |
|
|
keyCode: itm.KeyCode, |
|
|
version: itm.Version, |
|
|
version: itm.Version, |
|
@ -482,9 +483,11 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
contactid: itm.Extend1,//生产号
|
|
|
contactid: itm.Extend1,//生产号
|
|
|
invbillnum: itm.InvBillNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
partcode:itm.PartCode |
|
|
partcode: itm.PartCode |
|
|
|
|
|
); |
|
|
)); |
|
|
detail.ErpLoc = itm.ErpLoc; |
|
|
|
|
|
detail.RealPartCode = itm.RealPartCode; |
|
|
|
|
|
entityDetail.Add(detail); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
entityList.AddRange(entityDetail); |
|
|
entityList.AddRange(entityDetail); |
|
@ -500,12 +503,8 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
state: SettleBillState.客户已收票, |
|
|
state: SettleBillState.客户已收票, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
site: string.Empty |
|
|
site: string.Empty |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
); |
|
|
); |
|
|
|
|
|
|
|
|
bbacmainlist.Add( bbac ); |
|
|
bbacmainlist.Add( bbac ); |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
var bbacDetail = new List<BBAC_PD_DETAIL>(); |
|
|
var bbacDetail = new List<BBAC_PD_DETAIL>(); |
|
|
foreach (var itm in entityList) |
|
|
foreach (var itm in entityList) |
|
@ -570,8 +569,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
} |
|
|
} |
|
|
newlist = p_invs.Where(p => !oldlist.Contains(p)).ToList();//不存在扣减记录的发票号
|
|
|
newlist = p_invs.Where(p => !oldlist.Contains(p)).ToList();//不存在扣减记录的发票号
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<HBPO_CAN_SA_DETAIL> entityList = new List<HBPO_CAN_SA_DETAIL>();//结算明细
|
|
|
List<HBPO_CAN_SA_DETAIL> entityList = new List<HBPO_CAN_SA_DETAIL>();//结算明细
|
|
|
var namelist = invList.Select(p => p.InvbillNum).ToList(); |
|
|
var namelist = invList.Select(p => p.InvbillNum).ToList(); |
|
|
if (oldlist.Count > 0) |
|
|
if (oldlist.Count > 0) |
|
@ -584,24 +581,27 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
{ |
|
|
{ |
|
|
foreach (var itm in adjlist) |
|
|
foreach (var itm in adjlist) |
|
|
{ |
|
|
{ |
|
|
entityList.Add(new HBPO_CAN_SA_DETAIL( |
|
|
var detail = new HBPO_CAN_SA_DETAIL( |
|
|
guid: GuidGenerator.Create(), |
|
|
guid: GuidGenerator.Create(), |
|
|
keyCode: itm.KeyCode, |
|
|
keyCode: itm.KeyCode, |
|
|
version: itm.Version, |
|
|
version: itm.Version, |
|
|
billNum: itm.InvGroupNum, |
|
|
billNum: itm.InvGroupNum, |
|
|
settleBillNum: itm.SettleBillNum, |
|
|
settleBillNum: itm.SettleBillNum, |
|
|
lU: itm.LU, |
|
|
lU: itm.LU, |
|
|
pN: itm.PN, |
|
|
pN: itm.PN, |
|
|
site: itm.Site, |
|
|
site: itm.Site, |
|
|
qty: itm.Qty, |
|
|
qty: itm.Qty, |
|
|
price: 0, |
|
|
price: 0, |
|
|
businessType: itm.BusinessType, |
|
|
businessType: itm.BusinessType, |
|
|
settleDate: itm.SettleDate, |
|
|
settleDate: itm.SettleDate, |
|
|
groupNum: itm.GroupNum, |
|
|
groupNum: itm.GroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
partcode:itm.PartCode |
|
|
partcode: itm.PartCode |
|
|
)); |
|
|
); |
|
|
|
|
|
detail.ErpLoc = itm.ErpLoc; |
|
|
|
|
|
detail.RealPartCode = itm.RealPartCode; |
|
|
|
|
|
entityList.Add(detail); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -631,8 +631,10 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
partcode: itm.PartCode); |
|
|
partcode: itm.PartCode); |
|
|
entityDetail.Add(entity |
|
|
entity.ErpLoc = itm.ErpLoc;//补字段库位
|
|
|
); |
|
|
entity.PartCode = itm.RealPartCode;//真实零件号
|
|
|
|
|
|
|
|
|
|
|
|
entityDetail.Add(entity); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
entityList.AddRange(entityDetail); |
|
|
entityList.AddRange(entityDetail); |
|
@ -724,7 +726,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
{ |
|
|
{ |
|
|
foreach (var itm in adjlist) |
|
|
foreach (var itm in adjlist) |
|
|
{ |
|
|
{ |
|
|
entityList.Add(new PUB_CAN_SA_DETAIL( |
|
|
var detail = new PUB_CAN_SA_DETAIL( |
|
|
guid: GuidGenerator.Create(), |
|
|
guid: GuidGenerator.Create(), |
|
|
keyCode: itm.KeyCode, |
|
|
keyCode: itm.KeyCode, |
|
|
version: itm.Version, |
|
|
version: itm.Version, |
|
@ -740,11 +742,13 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
groupNum: itm.GroupNum, |
|
|
groupNum: itm.GroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
partcode:itm.PartCode, |
|
|
partcode: itm.PartCode, |
|
|
pobillnum:string.Empty |
|
|
pobillnum: string.Empty |
|
|
|
|
|
); |
|
|
|
|
|
detail.RealPartCode = itm.RealPartCode;//厂内替换零件号
|
|
|
|
|
|
detail.ErpLoc = itm.ErpLoc;//ERP库位
|
|
|
|
|
|
|
|
|
)); |
|
|
entityList.Add(detail); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -757,25 +761,28 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
{ |
|
|
{ |
|
|
foreach (var itm in adjlist) |
|
|
foreach (var itm in adjlist) |
|
|
{ |
|
|
{ |
|
|
entityDetail.Add(new PUB_CAN_SA_DETAIL( |
|
|
var detail = new PUB_CAN_SA_DETAIL( |
|
|
guid: GuidGenerator.Create(), |
|
|
guid: GuidGenerator.Create(), |
|
|
keyCode: itm.KeyCode, |
|
|
keyCode: itm.KeyCode, |
|
|
version: itm.Version, |
|
|
version: itm.Version, |
|
|
billNum: itm.InvGroupNum, |
|
|
billNum: itm.InvGroupNum, |
|
|
settleBillNum: itm.SettleBillNum, |
|
|
settleBillNum: itm.SettleBillNum, |
|
|
lU: itm.LU, |
|
|
lU: itm.LU, |
|
|
pN: itm.PN, |
|
|
pN: itm.PN, |
|
|
site: itm.Site, |
|
|
site: itm.Site, |
|
|
qty: itm.Qty, |
|
|
qty: itm.Qty, |
|
|
price: 0, |
|
|
price: 0, |
|
|
businessType: itm.BusinessType, |
|
|
businessType: itm.BusinessType, |
|
|
settleDate: itm.SettleDate, |
|
|
settleDate: itm.SettleDate, |
|
|
groupNum: itm.GroupNum, |
|
|
groupNum: itm.GroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invGroupNum: itm.InvGroupNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
invbillnum: itm.InvBillNum, |
|
|
partcode: itm.PartCode, |
|
|
partcode: itm.PartCode, |
|
|
pobillnum: string.Empty |
|
|
pobillnum: string.Empty |
|
|
)); |
|
|
); |
|
|
|
|
|
detail.RealPartCode = itm.RealPartCode;//厂内替换零件号
|
|
|
|
|
|
detail.ErpLoc = itm.ErpLoc;//ERP库位
|
|
|
|
|
|
entityDetail.Add(detail); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
entityList.AddRange(entityDetail); |
|
|
entityList.AddRange(entityDetail); |
|
|