|
|
@ -216,7 +216,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
_dbcontext.BulkDelete(notlist);//删除不可结数据
|
|
|
|
_dbcontext.BulkInsert(billDetails);//插入可结主表
|
|
|
|
_dbcontext.BulkInsert(billList);//插入可结明细
|
|
|
|
|
|
|
|
issucess = true; |
|
|
|
transaction.Commit(); |
|
|
|
} |
|
|
@ -258,7 +257,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
_dbcontext.BulkUpdate(salist);//更新结算数据
|
|
|
|
} |
|
|
|
} |
|
|
|
if (businesstype == "JisHBPO") |
|
|
|
if (businesstype == "JisHBPO" || businesstype== "MaiDanJianHBPO") |
|
|
|
{ |
|
|
|
List<HBPO_NOT_SA_DETAIL> notlist = new List<HBPO_NOT_SA_DETAIL>(); |
|
|
|
List<HBPO_CAN_SA> billList = new List<HBPO_CAN_SA>(); |
|
|
@ -300,7 +299,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
}, |
|
|
|
b = d |
|
|
|
}; |
|
|
|
|
|
|
|
var hbpo_can_list = query.Select(p => p.a).ToList(); |
|
|
|
var hbpo_not_list = query.Select(p => p.b).ToList(); |
|
|
|
if (hbpo_can_list.Count > 0) |
|
|
@ -314,7 +312,8 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
entity.State = SettleBillState.未结状态; |
|
|
|
entity.SettleBillNum = string.Empty; |
|
|
|
entity.Site = "104T"; |
|
|
|
entity.BusinessType = EnumBusinessType.JisBBAC; |
|
|
|
|
|
|
|
entity.BusinessType =(businesstype== "JisHBPO")?EnumBusinessType.JisHBPO:EnumBusinessType.MaiDanJianHBPO ; |
|
|
|
billList.Add(entity); |
|
|
|
notlist.AddRange(hbpo_not_list); |
|
|
|
foreach (var itm in hbpo_can_list) |
|
|
@ -370,7 +369,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
|
|
|
|
issucess = false;// 回滚事务
|
|
|
|
transaction.Rollback(); |
|
|
|
} |
|
|
@ -380,7 +378,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
flag.IsReturn = false; |
|
|
|
} |
|
|
|
_dbcontext.BulkUpdate(flaglist);//插入可结明细
|
|
|
|
|
|
|
|
} |
|
|
|
catch (Exception) |
|
|
|
{ |
|
|
@ -413,6 +410,12 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Syncs |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return id.ToString(); |
|
|
|
|
|
|
|
} |
|
|
|