diff --git a/chrome_tixcraft.py b/chrome_tixcraft.py index 0e83173..ab6d451 100644 --- a/chrome_tixcraft.py +++ b/chrome_tixcraft.py @@ -44,7 +44,7 @@ except Exception as exc: print(exc) pass -CONST_APP_VERSION = "MaxBot (2024.04.18)" +CONST_APP_VERSION = "MaxBot (2024.04.19)" CONST_MAXBOT_ANSWER_ONLINE_FILE = "MAXBOT_ONLINE_ANSWER.txt" CONST_MAXBOT_CONFIG_FILE = "settings.json" @@ -600,6 +600,7 @@ def get_driver_by_config(config_dict): homepage = config_dict["homepage"] # output config: + print("current time:", datetime.now().strftime('%Y-%m-%d %H:%M:%S')) print("maxbot app version:", CONST_APP_VERSION) print("python version:", platform.python_version()) print("platform:", platform.platform()) diff --git a/config_launcher.py b/config_launcher.py index f2e065a..ee4dd3d 100644 --- a/config_launcher.py +++ b/config_launcher.py @@ -24,7 +24,7 @@ import webbrowser import util -CONST_APP_VERSION = "MaxBot (2024.04.18)" +CONST_APP_VERSION = "MaxBot (2024.04.19)" CONST_MAXBOT_LAUNCHER_FILE = "config_launcher.json" CONST_MAXBOT_CONFIG_FILE = "settings.json" diff --git a/nodriver_tixcraft.py b/nodriver_tixcraft.py index 14e6cd3..bc030ea 100644 --- a/nodriver_tixcraft.py +++ b/nodriver_tixcraft.py @@ -32,7 +32,7 @@ except Exception as exc: print(exc) pass -CONST_APP_VERSION = "MaxBot (2024.04.18)" +CONST_APP_VERSION = "MaxBot (2024.04.19)" CONST_MAXBOT_ANSWER_ONLINE_FILE = "MAXBOT_ONLINE_ANSWER.txt" CONST_MAXBOT_CONFIG_FILE = "settings.json" @@ -490,6 +490,8 @@ async def nodriver_kktix_travel_price_list(tab, config_dict, kktix_area_auto_sel row_text = "" if not row_input is None: + is_match_area = False + # check ticket input textbox. if len(current_ticket_number) > 0: if current_ticket_number != "0": diff --git a/settings.py b/settings.py index 951da23..aaf0164 100644 --- a/settings.py +++ b/settings.py @@ -39,7 +39,7 @@ try: except Exception as exc: pass -CONST_APP_VERSION = "MaxBot (2024.04.18)" +CONST_APP_VERSION = "MaxBot (2024.04.19)" CONST_MAXBOT_ANSWER_ONLINE_FILE = "MAXBOT_ONLINE_ANSWER.txt" CONST_MAXBOT_CONFIG_FILE = "settings.json" diff --git a/settings_old.py b/settings_old.py index 247516e..05bb74e 100644 --- a/settings_old.py +++ b/settings_old.py @@ -34,7 +34,7 @@ try: except Exception as exc: pass -CONST_APP_VERSION = "MaxBot (2024.04.18)" +CONST_APP_VERSION = "MaxBot (2024.04.19)" CONST_MAXBOT_ANSWER_ONLINE_FILE = "MAXBOT_ONLINE_ANSWER.txt" CONST_MAXBOT_CONFIG_FILE = "settings.json" diff --git a/webdriver/Maxblockplus_1.0.0/data/settings.json b/webdriver/Maxblockplus_1.0.0/data/settings.json index f287627..1977f50 100644 --- a/webdriver/Maxblockplus_1.0.0/data/settings.json +++ b/webdriver/Maxblockplus_1.0.0/data/settings.json @@ -1 +1 @@ -{"homepage": "https://kktix.com/events/keswlkfo1/registrations/new", "browser": "chrome", "language": "English", "ticket_number": 2, "ocr_captcha": {"enable": true, "beta": true, "force_submit": true, "image_source": "canvas"}, "webdriver_type": "undetected_chromedriver", "date_auto_select": {"enable": true, "date_keyword": "\"\"", "mode": "random"}, "area_auto_select": {"enable": true, "mode": "random", "area_keyword": "\"\""}, "keyword_exclude": "\"\u8f2a\u6905\",\"\u8eab\u969c\",\"\u8eab\u5fc3 \u969c\u7919\",\"Restricted View\",\"\u71c8\u67f1\u906e\u853d\",\"\u8996\u7dda\u4e0d\u5b8c\u6574\"", "kktix": {"auto_press_next_step_button": true, "auto_fill_ticket_number": true, "kktix_status_api": false, "max_dwell_time": 60}, "cityline": {"cityline_queue_retry": true}, "tixcraft": {"pass_date_is_sold_out": true, "auto_reload_coming_soon_page": true}, "advanced": {"play_sound": {"ticket": true, "order": true, "filename": "ding-dong.wav"}, "tixcraft_sid": "", "ibonqware": "", "facebook_account": "", "kktix_account": "", "fami_account": "", "cityline_account": "", "urbtix_account": "", "hkticketing_account": "", "kham_account": "", "ticket_account": "", "udn_account": "", "ticketplus_account": "", "facebook_password": "", "kktix_password": "", "fami_password": "", "urbtix_password": "", "cityline_password": "", "hkticketing_password": "", "kham_password": "", "ticket_password": "", "udn_password": "", "ticketplus_password": "", "facebook_password_plaintext": "", "kktix_password_plaintext": "", "fami_password_plaintext": "", "urbtix_password_plaintext": "", "cityline_password_plaintext": "", "hkticketing_password_plaintext": "", "kham_password_plaintext": "", "ticket_password_plaintext": "", "udn_password_plaintext": "", "ticketplus_password_plaintext": "", "chrome_extension": true, "disable_adjacent_seat": true, "hide_some_image": true, "block_facebook_network": true, "headless": true, "verbose": true, "auto_guess_options": true, "user_guess_string": "\"\"", "remote_url": "\"http://maxbot.dropboxlike.com:16888/\"", "auto_reload_page_interval": 0.1, "reset_browser_interval": 0, "proxy_server_port": "", "window_size": "480,1024,0", "idle_keyword": "", "resume_keyword": "", "idle_keyword_second": "", "resume_keyword_second": ""}, "domain_filter": ["*.doubleclick.net/*", "*.googlesyndication.com/*", "*.ssp.hinet.net/*", "*a.amnet.tw/*", "*adx.c.appier.net/*", "*cdn.cookielaw.org/*", "*cdnjs.cloudflare.com/ajax/libs/clipboard.js/*", "*clarity.ms/*", "*cloudfront.com/*", "*cms.analytics.yahoo.com/*", "*e2elog.fetnet.net/*", "*fundingchoicesmessages.google.com/*", "*ghtinc.com/*", "*google-analytics.com/*", "*googletagmanager.com/*", "*googletagservices.com/*", "*img.uniicreative.com/*", "*lndata.com/*", "*match.adsrvr.org/*", "*onead.onevision.com.tw/*", "*play.google.com/log?*", "*popin.cc/*", "*rollbar.com/*", "*sb.scorecardresearch.com/*", "*tagtoo.co/*", "*ticketmaster.sg/js/adblock*", "*ticketmaster.sg/js/adblock.js*", "*tixcraft.com/js/analytics.js*", "*tixcraft.com/js/common.js*", "*tixcraft.com/js/custom.js*", "*treasuredata.com/*", "*www.youtube.com/youtubei/v1/player/heartbeat*"]} \ No newline at end of file +{"homepage": "about:blank", "browser": "chrome", "language": "English", "ticket_number": 2, "ocr_captcha": {"enable": true, "beta": true, "force_submit": true, "image_source": "canvas"}, "webdriver_type": "undetected_chromedriver", "date_auto_select": {"enable": true, "date_keyword": "", "mode": "random"}, "area_auto_select": {"enable": true, "mode": "random", "area_keyword": ""}, "keyword_exclude": "\"\u8f2a\u6905\",\"\u8eab\u969c\",\"\u8eab\u5fc3 \u969c\u7919\",\"Restricted View\",\"\u71c8\u67f1\u906e\u853d\",\"\u8996\u7dda\u4e0d\u5b8c\u6574\"", "kktix": {"auto_press_next_step_button": true, "auto_fill_ticket_number": true, "max_dwell_time": 60}, "cityline": {"cityline_queue_retry": true}, "tixcraft": {"pass_date_is_sold_out": true, "auto_reload_coming_soon_page": true}, "advanced": {"play_sound": {"ticket": true, "order": true, "filename": "ding-dong.wav"}, "tixcraft_sid": "", "ibonqware": "", "facebook_account": "", "kktix_account": "", "fami_account": "", "cityline_account": "", "urbtix_account": "", "hkticketing_account": "", "kham_account": "", "ticket_account": "", "udn_account": "", "ticketplus_account": "", "facebook_password": "", "kktix_password": "", "fami_password": "", "urbtix_password": "", "cityline_password": "", "hkticketing_password": "", "kham_password": "", "ticket_password": "", "udn_password": "", "ticketplus_password": "", "facebook_password_plaintext": "", "kktix_password_plaintext": "", "fami_password_plaintext": "", "urbtix_password_plaintext": "", "cityline_password_plaintext": "", "hkticketing_password_plaintext": "", "kham_password_plaintext": "", "ticket_password_plaintext": "", "udn_password_plaintext": "", "ticketplus_password_plaintext": "", "chrome_extension": true, "disable_adjacent_seat": false, "hide_some_image": false, "block_facebook_network": false, "headless": false, "verbose": false, "auto_guess_options": true, "user_guess_string": "", "remote_url": "\"http://127.0.0.1:16888/\"", "auto_reload_page_interval": 0.1, "reset_browser_interval": 0, "proxy_server_port": "", "window_size": "480,1024,1", "idle_keyword": "", "resume_keyword": "", "idle_keyword_second": "", "resume_keyword_second": ""}, "domain_filter": ["*.doubleclick.net/*", "*.googlesyndication.com/*", "*.ssp.hinet.net/*", "*a.amnet.tw/*", "*adx.c.appier.net/*", "*cdn.cookielaw.org/*", "*cdnjs.cloudflare.com/ajax/libs/clipboard.js/*", "*clarity.ms/*", "*cloudfront.com/*", "*cms.analytics.yahoo.com/*", "*e2elog.fetnet.net/*", "*fundingchoicesmessages.google.com/*", "*ghtinc.com/*", "*google-analytics.com/*", "*googletagmanager.com/*", "*googletagservices.com/*", "*img.uniicreative.com/*", "*lndata.com/*", "*match.adsrvr.org/*", "*onead.onevision.com.tw/*", "*play.google.com/log?*", "*popin.cc/*", "*rollbar.com/*", "*sb.scorecardresearch.com/*", "*tagtoo.co/*", "*ticketmaster.sg/js/adblock*", "*ticketmaster.sg/js/adblock.js*", "*tixcraft.com/js/analytics.js*", "*tixcraft.com/js/common.js*", "*tixcraft.com/js/custom.js*", "*treasuredata.com/*", "*www.youtube.com/youtubei/v1/player/heartbeat*"]} \ No newline at end of file diff --git a/webdriver/Maxbotplus_1.0.0/data/settings.json b/webdriver/Maxbotplus_1.0.0/data/settings.json index a54dd14..52d7916 100644 --- a/webdriver/Maxbotplus_1.0.0/data/settings.json +++ b/webdriver/Maxbotplus_1.0.0/data/settings.json @@ -1 +1 @@ -{"homepage": "https://kktix.com/events/keswlkfo1/registrations/new", "browser": "chrome", "language": "English", "ticket_number": 2, "ocr_captcha": {"enable": true, "beta": true, "force_submit": true, "image_source": "canvas"}, "webdriver_type": "undetected_chromedriver", "date_auto_select": {"enable": true, "date_keyword": "\"\"", "mode": "random"}, "area_auto_select": {"enable": true, "mode": "random", "area_keyword": "\"\""}, "keyword_exclude": "\"\u8f2a\u6905\",\"\u8eab\u969c\",\"\u8eab\u5fc3 \u969c\u7919\",\"Restricted View\",\"\u71c8\u67f1\u906e\u853d\",\"\u8996\u7dda\u4e0d\u5b8c\u6574\"", "kktix": {"auto_press_next_step_button": true, "auto_fill_ticket_number": true, "kktix_status_api": false, "max_dwell_time": 60}, "cityline": {"cityline_queue_retry": true}, "tixcraft": {"pass_date_is_sold_out": true, "auto_reload_coming_soon_page": true}, "advanced": {"play_sound": {"ticket": true, "order": true, "filename": "ding-dong.wav"}, "tixcraft_sid": "", "ibonqware": "", "facebook_account": "", "kktix_account": "", "fami_account": "", "cityline_account": "", "urbtix_account": "", "hkticketing_account": "", "kham_account": "", "ticket_account": "", "udn_account": "", "ticketplus_account": "", "facebook_password": "", "kktix_password": "", "fami_password": "", "urbtix_password": "", "cityline_password": "", "hkticketing_password": "", "kham_password": "", "ticket_password": "", "udn_password": "", "ticketplus_password": "", "facebook_password_plaintext": "", "kktix_password_plaintext": "", "fami_password_plaintext": "", "urbtix_password_plaintext": "", "cityline_password_plaintext": "", "hkticketing_password_plaintext": "", "kham_password_plaintext": "", "ticket_password_plaintext": "", "udn_password_plaintext": "", "ticketplus_password_plaintext": "", "chrome_extension": true, "disable_adjacent_seat": true, "hide_some_image": true, "block_facebook_network": true, "headless": true, "verbose": true, "auto_guess_options": true, "user_guess_string": "\"\"", "remote_url": "\"http://maxbot.dropboxlike.com:16888/\"", "auto_reload_page_interval": 0.1, "reset_browser_interval": 0, "proxy_server_port": "", "window_size": "480,1024,0", "idle_keyword": "", "resume_keyword": "", "idle_keyword_second": "", "resume_keyword_second": ""}} \ No newline at end of file +{"homepage": "about:blank", "browser": "chrome", "language": "English", "ticket_number": 2, "ocr_captcha": {"enable": true, "beta": true, "force_submit": true, "image_source": "canvas"}, "webdriver_type": "undetected_chromedriver", "date_auto_select": {"enable": true, "date_keyword": "", "mode": "random"}, "area_auto_select": {"enable": true, "mode": "random", "area_keyword": ""}, "keyword_exclude": "\"\u8f2a\u6905\",\"\u8eab\u969c\",\"\u8eab\u5fc3 \u969c\u7919\",\"Restricted View\",\"\u71c8\u67f1\u906e\u853d\",\"\u8996\u7dda\u4e0d\u5b8c\u6574\"", "kktix": {"auto_press_next_step_button": true, "auto_fill_ticket_number": true, "max_dwell_time": 60}, "cityline": {"cityline_queue_retry": true}, "tixcraft": {"pass_date_is_sold_out": true, "auto_reload_coming_soon_page": true}, "advanced": {"play_sound": {"ticket": true, "order": true, "filename": "ding-dong.wav"}, "tixcraft_sid": "", "ibonqware": "", "facebook_account": "", "kktix_account": "", "fami_account": "", "cityline_account": "", "urbtix_account": "", "hkticketing_account": "", "kham_account": "", "ticket_account": "", "udn_account": "", "ticketplus_account": "", "facebook_password": "", "kktix_password": "", "fami_password": "", "urbtix_password": "", "cityline_password": "", "hkticketing_password": "", "kham_password": "", "ticket_password": "", "udn_password": "", "ticketplus_password": "", "facebook_password_plaintext": "", "kktix_password_plaintext": "", "fami_password_plaintext": "", "urbtix_password_plaintext": "", "cityline_password_plaintext": "", "hkticketing_password_plaintext": "", "kham_password_plaintext": "", "ticket_password_plaintext": "", "udn_password_plaintext": "", "ticketplus_password_plaintext": "", "chrome_extension": true, "disable_adjacent_seat": false, "hide_some_image": false, "block_facebook_network": false, "headless": false, "verbose": false, "auto_guess_options": true, "user_guess_string": "", "remote_url": "\"http://127.0.0.1:16888/\"", "auto_reload_page_interval": 0.1, "reset_browser_interval": 0, "proxy_server_port": "", "window_size": "480,1024,1", "idle_keyword": "", "resume_keyword": "", "idle_keyword_second": "", "resume_keyword_second": ""}} \ No newline at end of file diff --git a/webdriver/Maxbotplus_1.0.0/js/fantopia_fill.js b/webdriver/Maxbotplus_1.0.0/js/fantopia_fill.js new file mode 100644 index 0000000..fe63459 --- /dev/null +++ b/webdriver/Maxbotplus_1.0.0/js/fantopia_fill.js @@ -0,0 +1,43 @@ +const storage = chrome.storage.local; +var settings = null; +var inputInterval = null; + +function fantopia_fill_main(settings) { + if(settings.ticket_number) { + let current_ticket_number = parseInt($("input.border-0").val()); + for(let i=0; i= settings.ticket_number) break; + $('button > img[src="https://p-st.fantopia.io/icon/add.svg"]').click(); + } + // check overflow + current_ticket_number = parseInt($("input.border-0").val()); + if(current_ticket_number > settings.ticket_number) { + $('button > img[src="https://p-st.fantopia.io/icon/reduce.svg"]').click(); + } else { + if(current_ticket_number == settings.ticket_number) { + $('div.border-t > div.text-right > button.relative > div.flex.items-center.justify-center').click(); + } + } + } +} + +storage.get('settings', function (items) +{ + if (items.settings) + { + settings = items.settings; + } +}); + +storage.get('status', function (items) +{ + if (items.status && items.status=='ON') + { + inputInterval= setInterval(() => { + fantopia_fill_main(settings); + }, 200); + } else { + //console.log('maxbot status is not ON'); + } +}); diff --git a/webdriver/Maxbotplus_1.0.0/manifest.json b/webdriver/Maxbotplus_1.0.0/manifest.json index f8ad8f6..b2b1c1d 100644 --- a/webdriver/Maxbotplus_1.0.0/manifest.json +++ b/webdriver/Maxbotplus_1.0.0/manifest.json @@ -465,7 +465,18 @@ "jquery.min.js", "js/hncb_fill.js" ] + }, + { + "matches": [ + "https://fantopia.io/events-tickets?eventsKey=*" + ], + "run_at": "document_end", + "js": [ + "jquery.min.js", + "js/fantopia_fill.js" + ] } + ], - "version": "1.0.26" + "version": "1.0.27" } diff --git a/www/.DS_Store b/www/.DS_Store deleted file mode 100644 index 9e9524a..0000000 Binary files a/www/.DS_Store and /dev/null differ diff --git a/www/settings.html b/www/settings.html index f6981b7..aae774a 100644 --- a/www/settings.html +++ b/www/settings.html @@ -19,15 +19,15 @@ - + - + - + @@ -60,7 +60,7 @@
台灣藝文活動的文創法第十條中的「不正方式」由於沒有明確定義,代表的是所有軟體都涉嫌違反。故在此呼籲大家,勿以身試法。 -
+
@@ -70,7 +70,7 @@
作者沒有意圖要他人購得的票券進行加價轉售或是使用在違法的事情上,他人的行為並不在作者的意識支配範圍之內,作者不對他人的非法行為負責。 -
+ @@ -80,7 +80,7 @@
- +

@@ -131,7 +131,7 @@

- 備註: + 備註: Cityline 只能使用 chrome 瀏覽器 + nodriver
@@ -226,14 +226,19 @@
-
+
- 提示: + 提示: 每組關鍵字需要用「雙引號」包起來, 用「逗號」分隔, 在關鍵字中使用「空格」為 AND 邏輯。完全不輸入或是加入 「,""」 代表符合所有關鍵字。 -
+
+
+
+
+ +

@@ -292,7 +297,7 @@ - +
@@ -529,9 +534,9 @@
- 提示: + 提示: 將密碼保存到設定檔中可能會讓您的密碼被盜。 -
+
@@ -601,6 +606,9 @@ +
+ +