mirror of
https://gitee.com/fasiondog/hikyuu.git
synced 2024-11-30 10:59:43 +08:00
fixed 接收spot时,分钟级别的成交量为股数
This commit is contained in:
parent
c63f9d6360
commit
2169f3fef9
@ -25,7 +25,7 @@ public:
|
||||
price_t lowPrice; ///< 最低价
|
||||
price_t closePrice; ///< 最低价
|
||||
price_t transAmount; ///< 成交金额(千元)
|
||||
price_t transCount; ///< 成交量(手)
|
||||
price_t transCount; ///< 成交量(手),日线以下为股数
|
||||
|
||||
KRecord()
|
||||
: datetime(Null<Datetime>()),
|
||||
|
@ -156,7 +156,8 @@ static void updateStockMinData(const SpotRecord& spot, KQuery::KType ktype) {
|
||||
}
|
||||
|
||||
price_t amount = spot.amount > sum_amount ? spot.amount - sum_amount : spot.amount;
|
||||
price_t volume = spot.volume > sum_volume ? spot.volume - sum_volume : spot.volume;
|
||||
price_t spot_volume = spot.volume * 100; // spot 传过来的是手数
|
||||
price_t volume = spot_volume > sum_volume ? spot_volume - sum_volume : spot_volume;
|
||||
KRecord krecord(minute, spot.open, spot.high, spot.low, spot.close, amount, volume);
|
||||
stk.realtimeUpdate(krecord, ktype);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user