fix for tixcraft UI upgrade at 2023-02-21

master
Max 2023-02-21 12:43:07 +08:00 committed by GitHub
parent b7d000c39e
commit 6a62e18472
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 4 deletions

View File

@ -1267,7 +1267,7 @@ def tixcraft_date_auto_select(driver, url, config_dict, domain_name):
if is_match_keyword_row: if is_match_keyword_row:
el = None el = None
try: try:
el = row.find_element(By.CSS_SELECTOR, '.btn-next') el = row.find_element(By.CSS_SELECTOR, 'button')
except Exception as exc: except Exception as exc:
if show_debug_message: if show_debug_message:
print("find .btn-next fail") print("find .btn-next fail")
@ -1813,7 +1813,7 @@ def tixcraft_verify(driver, presale_code, presale_code_delimiter, answer_index):
form_input = None form_input = None
try: try:
form_input = driver.find_element(By.CSS_SELECTOR, '#checkCode') form_input = driver.find_element(By.CSS_SELECTOR, "input[name='checkCode']")
except Exception as exc: except Exception as exc:
print("find verify code fail") print("find verify code fail")
pass pass
@ -2003,7 +2003,7 @@ def tixcraft_auto_ocr(driver, ocr, away_from_keyboard_enable, previous_answer, C
if not Captcha_Browser is None: if not Captcha_Browser is None:
img_base64 = base64.b64decode(Captcha_Browser.Request_Captcha()) img_base64 = base64.b64decode(Captcha_Browser.Request_Captcha())
if ocr_captcha_image_source == CONST_OCR_CAPTCH_IMAGE_SOURCE_CANVAS: if ocr_captcha_image_source == CONST_OCR_CAPTCH_IMAGE_SOURCE_CANVAS:
image_id = 'yw0' image_id = 'TicketForm_verifyCode-image'
if 'indievox.com' in domain_name: if 'indievox.com' in domain_name:
image_id = 'TicketForm_verifyCode-image' image_id = 'TicketForm_verifyCode-image'
try: try:
@ -2090,7 +2090,10 @@ def tixcraft_ticket_main(driver, config_dict, ocr, Captcha_Browser, domain_name)
ocr_captcha_image_source = config_dict["ocr_captcha"]["image_source"] ocr_captcha_image_source = config_dict["ocr_captcha"]["image_source"]
if auto_check_agree: if auto_check_agree:
tixcraft_ticket_agree(driver) for i in range(3):
is_finish_checkbox_click = tixcraft_ticket_agree(driver)
if is_finish_checkbox_click:
break
# allow agree not enable to assign ticket number. # allow agree not enable to assign ticket number.
form_select = None form_select = None