Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion easytrader/clienttrader.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,18 +144,21 @@ def _get_balance_from_statics(self):
@property
def position(self):
self._switch_left_menus(["查询[F4]", "资金股票"])
self.refresh()

return self._get_grid_data(self._config.COMMON_GRID_CONTROL_ID)

@property
def today_entrusts(self):
self._switch_left_menus(["查询[F4]", "当日委托"])
self.refresh()

return self._get_grid_data(self._config.COMMON_GRID_CONTROL_ID)

@property
def today_trades(self):
self._switch_left_menus(["查询[F4]", "当日成交"])
self.refresh()

return self._get_grid_data(self._config.COMMON_GRID_CONTROL_ID)

Expand Down Expand Up @@ -430,7 +433,7 @@ def _submit_trade(self):
time.sleep(0.2)
self._main.child_window(
control_id=self._config.TRADE_SUBMIT_CONTROL_ID, class_name="Button"
).click()
).type_keys('{ENTER}')

@perf_clock
def __get_top_window_pop_dialog(self):
Expand Down
4 changes: 3 additions & 1 deletion easytrader/grid_strategies.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,9 @@ def _get_clipboard_data(self) -> str:
if not found:
self._trader.app.top_window().Button2.click() # 点击取消
else:
Copy._need_captcha_reg = False
pass
# 不要将 Copy._need_captcha_reg 置为 False, 因为它是类方法, 一旦置为 False, 后续操作都不再进行验证码识别
# Copy._need_captcha_reg = False
count = 5
while count > 0:
try:
Expand Down