BugFix 估值单浮动利息第一天也要计算

This commit is contained in:
锦麟 王
2025-12-18 15:11:35 +08:00
parent bbd5aabca3
commit d3e908de14
@@ -1379,12 +1379,12 @@ namespace YLErp.Modules.SwapModule
curretEod.PosiTradingFee = position.PosiTradingFee;
curretEod.UnderlyingPrice = UnderlyingCodePrice(position.UnderlyingCode, dealDate, out decimal vobp);
SetPriceInfoByFlowEvent(eod, curretEod, unwindEvents, position);
if (settleDate == td.TradeDate)
{
curretEod.UnderlyingPrice = curretEod.PosiGrossPrice;
//curretEod.TdCloseMtmPnl = 0;
//curretEod.TdCloseFee = 0;
}
//if (settleDate == td.TradeDate)
//{
// curretEod.UnderlyingPrice = curretEod.PosiGrossPrice;
// //curretEod.TdCloseMtmPnl = 0;
// //curretEod.TdCloseFee = 0;
//}
curretEod.TdCloseDividend = curretEod.TdPosiDividend;
curretEod.UnderlyingMarketValue = curretEod.UnderlyingPrice * curretEod.PosiQuantity * curretEod.ContractSize * shortRatio;
curretEod.PosiMtmPnL = (curretEod.UnderlyingPrice - curretEod.PosiGrossPrice) * curretEod.PosiQuantity * curretEod.ContractSize * shortRatio * directionRatio;