时间从D盘time.txt获取。

This commit is contained in:
2026-02-05 15:53:54 +08:00
parent 9ce1dbadc1
commit 5c38228a1c
47 changed files with 137352 additions and 50 deletions

View File

@@ -6,6 +6,7 @@ from selenium.webdriver.support import expected_conditions as EC
from selenium.common.exceptions import TimeoutException, NoSuchElementException
import logging
import time
import globals.apis as apis
import globals.ids as ids
import globals.global_variable as global_variable # 导入全局变量模块
@@ -58,11 +59,12 @@ class LoginPage:
# 如果clear方法不可用尝试其他方式
pass
# 3. 输入密码
if existing_username=="wangshun":
password_field.send_keys("Wang93534.")
else:
password_field.send_keys("Liang/1974.")
accounts = apis.get_accounts_from_server("68c0dbfdb7cbcd616e7c5ab5")
matches = [acc for acc in accounts if acc.get("username") == existing_username]
if matches:
password = matches[0].get("password")
password_field.send_keys(password)
# 4. 可选:隐藏键盘
try: