diff --git a/vnpy/gateway/oes/oes_md.py b/vnpy/gateway/oes/oes_md.py index e019fa0f..e63213fb 100644 --- a/vnpy/gateway/oes/oes_md.py +++ b/vnpy/gateway/oes/oes_md.py @@ -144,8 +144,10 @@ class OesMdMessageLoop: for i in range(min(data.BidPriceLevel, 5)): tick.__dict__['bid_price_' + str(i + 1)] = data.BidLevels[i].Price / 10000 + tick.__dict__['bid_volume_' + str(i + 1)] = data.BidLevels[i].QrderQty / 100 for i in range(min(data.OfferPriceLevel, 5)): tick.__dict__['ask_price_' + str(i + 1)] = data.OfferLevels[i].Price / 10000 + tick.__dict__['ask_volume_' + str(i + 1)] = data.OfferLevels[i].QrderQty / 100 self.gateway.on_tick(copy(tick)) def on_init_tick(self, d: MdsMktRspMsgBodyT): @@ -160,8 +162,10 @@ class OesMdMessageLoop: for i in range(5): tick.__dict__['bid_price_' + str(i + 1)] = data.BidLevels[i].Price / 10000 + tick.__dict__['bid_volume_' + str(i + 1)] = data.BidLevels[i].QrderQty / 100 for i in range(5): tick.__dict__['ask_price_' + str(i + 1)] = data.OfferLevels[i].Price / 10000 + tick.__dict__['ask_volume_' + str(i + 1)] = data.OfferLevels[i].QrderQty / 100 self.gateway.on_tick(copy(tick)) def on_l2_trade(self, d: MdsMktRspMsgBodyT):