From 0ab6091962cd875083f3dcbee6a9f178feb1c11d Mon Sep 17 00:00:00 2001 From: hjhan Date: Thu, 25 Jun 2026 18:08:39 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=88=86=E7=BA=A2=E5=9E=8B?= =?UTF-8?q?=E8=87=AA=E5=8A=A8=E4=BA=92=E6=8D=A2=E5=9C=A8=E4=BA=92=E6=8D=A2?= =?UTF-8?q?Tab=E6=98=BE=E7=A4=BA=E6=9C=9F=E5=88=9D/=E6=9C=9F=E6=9C=AB?= =?UTF-8?q?=E4=BB=B7=E6=9C=AA=C3=97100=E5=8F=8A=E6=9C=9F=E5=88=9D=E5=87=80?= =?UTF-8?q?=E4=BB=B7=E4=B8=BA0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DealDividends生成分红型自动互换事件时,漏赋了UnderlyingInstrumentType和 TradingAmountNetAvg两个字段,导致互换Tab(TradeView)显示异常: 1. UnderlyingInstrumentType缺失:TradeView第654行IsBond判断为false, multiplier=1,走了非债券分支(不×100),使期初/期末价显示为相对价(1.00) 而非百分比(100%)。补赋eodPosi.UnderlyingInstrumentType后, 与手动互换一致走债券分支(×100)。 2. TradingAmountNetAvg缺失:TradeView第993行显示期初净价取该字段, 缺失导致显示0。补赋eodPosi.PosiNetNoFeePrice修复。 入库的TradingAmountAvg(相对价)本来就正确,仅显示层判断缺字段。 仅改动DealDividends,不影响平仓/手动互换/显示层逻辑。 --- YLErpDAL/Modules/SwapModule/SwapEodPositionService.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/YLErpDAL/Modules/SwapModule/SwapEodPositionService.cs b/YLErpDAL/Modules/SwapModule/SwapEodPositionService.cs index e5792425..a33f9e92 100644 --- a/YLErpDAL/Modules/SwapModule/SwapEodPositionService.cs +++ b/YLErpDAL/Modules/SwapModule/SwapEodPositionService.cs @@ -450,12 +450,14 @@ namespace YLErp.Modules.SwapModule PayDate = dividendPayDate, PositionId = eodPosi.PositionId, UnderlyingCode = eodPosi.UnderlyingCode, + UnderlyingInstrumentType = eodPosi.UnderlyingInstrumentType, PayDirection = eodPosi.PosiDirection, PositionType = eodPosi.PositionType, PositionQty = eodPosi.PosiQuantity, Quantity = 0, ContractSize = eodPosi.ContractSize, TradingAmountAvg = eodPosi.PosiNetPrice, + TradingAmountNetAvg = eodPosi.PosiNetNoFeePrice, PosiGrossPrice = eodPosi.PosiGrossPrice, PosiNetPrice = eodPosi.PosiNetPrice, MarkClosePnl = eodPosi.PosiDividendSum,