#EQD-6948 国联民生-实现保证金规则(2)追保金额的产生与收盘计算 收盘计算和授信占用

This commit is contained in:
锦麟 王
2026-08-24 16:34:18 +08:00
parent 8648b62af9
commit c35befbe8f
49 changed files with 2814 additions and 272 deletions
@@ -1,6 +1,7 @@
using Newtonsoft.Json;
using YLErp.DBModels;
using YLErp.DBModels.Enums;
using YLErp.Modules.SwapModule.Margin;
namespace YLErp.Modules.SwapModule
{
@@ -113,6 +114,11 @@ namespace YLErp.Modules.SwapModule
CloseReCheckCallCount++;
}
// R4 按标签分流释放:纯内存测试不连库,stub 为全现金(与既有断言语义一致)
protected override UnwindTagSplit ReleaseMarginByFundTag(trade td, DateTime valueDate, List<swap_flow_event> interestEvents,
decimal marginAmount, decimal marginRebate)
=> new UnwindTagSplit { CashMargin = Convert.ToDouble(marginAmount), CashRebate = Convert.ToDouble(marginRebate) };
protected override void SaveAllChanges() { SaveAllChangesCount++; }
protected override void ExecuteInTransaction(Action action) => action(); // 不包事务,直接执行
protected override void CallSaveSwapTradeClientCash(trade td, DateTime valueDate) { } // 空操作