2023-09-05 16:03:33 +08:00

1 line
16 KiB
JSON

{"id":40,"name":"NUS","url":"https://reboks.nus.edu.sg/","links":"https://reboks.nus.edu.sg/","create_time":"9/5/2023, 12:28:18 PM","update_time":"9/5/2023, 1:02:52 PM","version":"0.5.0","saveThreshold":10,"cloudflare":0,"environment":0,"maxViewLength":15,"recordLog":1,"outputFormat":"xlsx","saveName":"current_time","inputExcel":"","startFromExit":0,"containJudge":false,"desc":"https://reboks.nus.edu.sg/","inputParameters":[{"id":0,"name":"urlList_0","nodeId":1,"nodeName":"打开网页","value":"https://reboks.nus.edu.sg/","desc":"要采集的网址列表,多行以\\n分开","type":"text","exampleValue":"https://reboks.nus.edu.sg/"},{"id":1,"name":"inputText_1","nodeName":"输入文字","nodeId":3,"desc":"要输入的文本,如京东搜索框输入:电脑","type":"text","exampleValue":"nusstu\\e0546263","value":"nusstu\\e0546263"},{"id":2,"name":"inputText_2","nodeName":"输入文字","nodeId":4,"desc":"要输入的文本,如京东搜索框输入:电脑","type":"text","exampleValue":"Qw982311099.","value":"Qw982311099."},{"id":3,"name":"urlList_3","nodeId":16,"nodeName":"打开网页","value":"https://reboks.nus.edu.sg/nus_public_web/public/facilities/view/activity/58/venue/15?time_from=1694016000","desc":"要采集的网址列表,多行以\\n分开","type":"text","exampleValue":"https://reboks.nus.edu.sg/nus_public_web/public/facilities/view/activity/58/venue/15?time_from=1694016000"}],"outputParameters":[{"id":0,"name":"自定义操作","desc":"自定义操作返回的数据","type":"text","recordASField":0,"exampleValue":""}],"graph":[{"index":0,"id":0,"parentId":0,"type":-1,"option":0,"title":"root","sequence":[1,2,3,4,5,16,17,18,19],"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0},"isInLoop":false},{"id":1,"index":1,"parentId":0,"type":0,"option":1,"title":"打开网页","sequence":[],"isInLoop":false,"position":0,"parameters":{"useLoop":false,"xpath":"","wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"url":"https://reboks.nus.edu.sg/","links":"https://reboks.nus.edu.sg/","maxWaitTime":10,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"cookies":""}},{"id":2,"index":2,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[contains(@class, \"btn-facebook\")]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[1]/div[1]/div[5]/div[2]/div[1]/fieldset[1]/div[1]/div[1]/div[2]/a[1]","//a[contains(., '')]","//A[@class='btn btn-block btn-facebook']","/html/body/div[last()-3]/div/div/div[last()-2]/div/div/fieldset/div/div/div[last()-1]/a[last()-1]"]}},{"id":3,"index":3,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":2,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"userNameInput\"]","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"value":"nusstu\\e0546263","index":0,"allXPaths":["/html/body/div[2]/div[2]/div[1]/div[2]/div[1]/div[1]/form[1]/div[2]/div[1]/input[1]","//input[contains(., '')]","id(\"userNameInput\")","//INPUT[@class='text fullWidth']","//INPUT[@name='UserName']","/html/body/div[last()-3]/div/div[last()-1]/div[last()-1]/div/div/form/div/div[last()-3]/input"]}},{"id":4,"index":4,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":3,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"passwordInput\"]","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"value":"Qw982311099.","index":0,"allXPaths":["/html/body/div[2]/div[2]/div[1]/div[2]/div[1]/div[1]/form[1]/div[2]/div[2]/input[1]","//input[contains(., '')]","id(\"passwordInput\")","//INPUT[@class='text fullWidth']","//INPUT[@name='Password']","/html/body/div[last()-3]/div/div[last()-1]/div[last()-1]/div/div/form/div/div[last()-2]/input"]}},{"id":5,"index":5,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":4,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"submitButton\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[2]/div[1]/div[2]/div[1]/div[1]/form[1]/div[2]/div[4]/span[1]","//span[contains(., 'Sign in')]","id(\"submitButton\")","//SPAN[@class='submit']","/html/body/div[last()-3]/div/div[last()-1]/div[last()-1]/div/div/form/div/div/span"]}},{"id":-1,"index":6,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":5,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"submitButton\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[2]/div[1]/div[2]/div[1]/div[1]/form[1]/div[2]/div[4]/span[1]","//span[contains(., 'Sign in')]","id(\"submitButton\")","//SPAN[@class='submit']","/html/body/div[last()-3]/div/div[last()-1]/div[last()-1]/div/div/form/div/div/span"]}},{"id":-1,"index":7,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":5,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"bookfacility\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/div[3]/ul[1]/li[5]/a[1]","//a[contains(., 'Book Facil')]","id(\"bookfacility\")","//A[@class='parent']","//A[@name='bookfacility']","/html/body/div[last()-4]/div/div[last()-1]/div[last()-5]/ul/li[last()-4]/a"]}},{"id":-1,"index":8,"parentId":0,"type":0,"option":6,"title":"切换下拉选项","sequence":[],"isInLoop":false,"position":6,"parameters":{"history":7,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"activity_filter\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"optionMode":0,"optionValue":"Badminton","index":0,"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[1]/form[1]/fieldset[1]/select[1]","//select[contains(., 'Select an')]","id(\"activity_filter\")","//SELECT[@class='input-xlarge ']","//SELECT[@name='activity_filter']","/html/body/div[last()-5]/div/div[last()-1]/section/div/form/fieldset[last()-3]/select"]}},{"id":-1,"index":9,"parentId":0,"type":0,"option":6,"title":"切换下拉选项","sequence":[],"isInLoop":false,"position":7,"parameters":{"history":7,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"activity_filter\"]","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"optionMode":"1","optionValue":1,"index":0,"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[1]/form[1]/fieldset[1]/select[1]","//select[contains(., 'Select an')]","id(\"activity_filter\")","//SELECT[@class='input-xlarge ']","//SELECT[@name='activity_filter']","/html/body/div[last()-5]/div/div[last()-1]/section/div/form/fieldset[last()-3]/select"]}},{"id":-1,"index":10,"parentId":0,"type":0,"option":6,"title":"切换下拉选项","sequence":[],"isInLoop":false,"position":7,"parameters":{"history":7,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"venue_filter\"]","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"optionMode":"1","optionValue":"1","index":0,"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[1]/form[1]/fieldset[2]/select[1]","//select[contains(., 'Select a v')]","id(\"venue_filter\")","//SELECT[@class='input-xlarge ']","//SELECT[@name='venue_filter']","/html/body/div[last()-5]/div/div[last()-1]/section/div/form/fieldset[last()-2]/select"]}},{"id":-1,"index":11,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":8,"parameters":{"history":7,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"date_filter\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[1]/form[1]/fieldset[3]/input[1]","//input[contains(., '')]","id(\"date_filter\")","//INPUT[@class='chosen-container datepicker hasDatepicker']","//INPUT[@name='date_filter']","/html/body/div[last()-5]/div/div[last()-1]/section/div/form/fieldset[last()-1]/input"]}},{"id":-1,"index":12,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":9,"parameters":{"history":7,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"search\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[1]/form[1]/fieldset[4]/input[1]","//input[contains(., '')]","id(\"search\")","//INPUT[@class='btn btn-filter-search']","//INPUT[@name='search']","/html/body/div[last()-5]/div/div[last()-1]/section/div/form/fieldset/input"]}},{"id":-1,"index":13,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":10,"parameters":{"history":8,"tabIndex":-1,"useLoop":false,"xpath":"//*[contains(@class, \"timeslot-container\")]/div[5]/div[1]/div[7]/label[1]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[4]/div[1]/form[1]/div[1]/div[5]/div[1]/div[7]/label[1]","//label[contains(., '01:00 PM')]","/html/body/div[last()-5]/div/div[last()-1]/section/div/div/form/div[last()-1]/div[last()-1]/div/div[last()-7]/label"]}},{"id":-1,"index":14,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":11,"parameters":{"history":8,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"paynow\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[4]/div[1]/form[1]/div[2]/div[1]/input[1]","//input[contains(., '')]","id(\"paynow\")","//INPUT[@class='btn btn-flat blue last-child']","//INPUT[@name='cart']","/html/body/div[last()-5]/div/div[last()-1]/section/div/div/form/div/div/input"]}},{"id":-1,"index":15,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":12,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"bookfacility\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/div[3]/ul[1]/li[5]/a[1]","//a[contains(., 'Book Facil')]","id(\"bookfacility\")","//A[@class='parent']","//A[@name='bookfacility']","/html/body/div[last()-4]/div/div[last()-1]/div[last()-5]/ul/li[last()-4]/a"]}},{"id":6,"index":16,"parentId":0,"type":0,"option":1,"title":"打开网页","sequence":[],"isInLoop":false,"position":5,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"url":"about:blank","links":"https://reboks.nus.edu.sg/nus_public_web/public/facilities/view/activity/58/venue/15?time_from=1694016000","maxWaitTime":10,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"cookies":""}},{"id":7,"index":17,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":6,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[contains(@class, \"timeslot-container\")]/div[1]/div[1]/div[1]/label[1]","iframe":false,"wait":4,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[4]/div[1]/form[1]/div[1]/div[1]/div[1]/div[1]/label[1]","//label[contains(., '07:00 AM')]","/html/body/div[last()-5]/div/div[last()-1]/section/div/div/form/div[last()-1]/div[last()-5]/div/div[last()-13]/label"]}},{"id":8,"index":18,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":7,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"paynow\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[2]/div[1]/div[1]/section[3]/div[4]/div[1]/form[1]/div[2]/div[1]/input[1]","//input[contains(., '')]","id(\"paynow\")","//INPUT[@class='btn btn-flat blue last-child']","//INPUT[@name='cart']","/html/body/div[last()-5]/div/div[last()-1]/section/div/div/form/div/div/input"]}},{"id":9,"index":19,"parentId":0,"type":0,"option":5,"title":"自定义操作","sequence":[],"isInLoop":false,"position":8,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"clear":0,"codeMode":"5","code":"from selenium.webdriver.support.ui import WebDriverWait\nfrom selenium.webdriver.support import expected_conditions as EC\n\ntry:\n # 等待警告出现并获取警告对话框\n WebDriverWait(self.browser, 5).until(EC.alert_is_present())\n\n # 切换到警告并接受\n alert = self.browser.switch_to.alert\n alert.accept()\nexcept Exception as e:\n print(e)","waitTime":0,"recordASField":0,"paraType":"text"}}]}