From da6f078a5ce4e644e50bb082771057ca4af41ef0 Mon Sep 17 00:00:00 2001 From: NaiboWang-Alienware Date: Sun, 16 Jul 2023 12:11:39 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=97=A0=E5=8F=98=E5=8C=96?= =?UTF-8?q?=E8=AE=A1=E7=AE=97=E6=89=80=E6=9C=89iframe=E5=86=85=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ElectronJS/tasks/125.json | 2 +- ElectronJS/tasks/184.json | 1 + ExecuteStage/.vscode/launch.json | 2 +- ExecuteStage/easyspider_executestage.py | 28 +++++++++++++++++++++---- 4 files changed, 27 insertions(+), 6 deletions(-) create mode 100644 ElectronJS/tasks/184.json diff --git a/ElectronJS/tasks/125.json b/ElectronJS/tasks/125.json index e9ea0f0..2409e5c 100644 --- a/ElectronJS/tasks/125.json +++ b/ElectronJS/tasks/125.json @@ -1 +1 @@ -{"id":125,"name":"Dynamic Iframe","url":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","links":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","create_time":"7/4/2023, 9:23:59 PM","version":"0.3.5","saveThreshold":10,"cloudflare":0,"environment":0,"containJudge":true,"desc":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","inputParameters":[{"id":0,"name":"urlList_0","nodeId":1,"nodeName":"打开网页","value":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","desc":"要采集的网址列表,多行以\\n分开","type":"string","exampleValue":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history"},{"id":1,"name":"inputText_1","nodeName":"输入文字","nodeId":6,"desc":"要输入的文本,如京东搜索框输入:电脑","type":"string","exampleValue":"12","value":"12"},{"id":2,"name":"loopTimes_循环1_2","nodeId":8,"nodeName":"循环1","desc":"循环循环1执行的次数(0代表无限循环)","type":"int","exampleValue":0,"value":0}],"outputParameters":[{"id":0,"name":"参数1_文本","desc":"","type":"string","exampleValue":"2.2"},{"id":1,"name":"参数2_文本","desc":"","type":"string","exampleValue":"2023-06-1422:24:41"},{"id":2,"name":"参数3_文本","desc":"","type":"string","exampleValue":"37.12"},{"id":3,"name":"参数4_文本","desc":"","type":"string","exampleValue":"114.78"},{"id":4,"name":"参数5_文本","desc":"","type":"string","exampleValue":"10"},{"id":5,"name":"参数6_链接文本","desc":"","type":"string","exampleValue":"河北邢台市任泽区"},{"id":6,"name":"参数7_链接地址","desc":"","type":"string","exampleValue":"https://news.ceic.ac.cn/CD20230614222441.html"},{"id":7,"name":"参数8_文本","desc":"","type":"string","exampleValue":"震级(M)"},{"id":8,"name":"参数9_文本","desc":"","type":"string","exampleValue":"发震时刻(UTC+8)"},{"id":9,"name":"参数10_文本","desc":"","type":"string","exampleValue":"纬度(°)"},{"id":10,"name":"参数11_文本","desc":"","type":"string","exampleValue":"经度(°)"},{"id":11,"name":"参数12_文本","desc":"","type":"string","exampleValue":"深度(千米)"},{"id":12,"name":"参数13_文本","desc":"","type":"string","exampleValue":"参考位置"},{"id":13,"name":"参数111_文本","desc":"","type":"string","exampleValue":"IFRAME TEST"}],"graph":[{"index":0,"id":0,"parentId":0,"type":-1,"option":0,"title":"root","sequence":[1,6,7,12,8],"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","wait":0},"isInLoop":false},{"id":1,"index":1,"parentId":0,"type":0,"option":1,"title":"打开网页","sequence":[],"isInLoop":false,"position":0,"parameters":{"useLoop":false,"xpath":"","wait":10,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"url":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","links":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","maxWaitTime":10,"scrollType":0,"scrollCount":1,"scrollWaitTime":1}},{"id":-1,"index":2,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"15","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":-1,"index":3,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":2,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"search\"]","iframe":true,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[5]/a[1]","//a[contains(., '查询')]","id(\"search\")","//A[@class='check']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div/a"]}},{"id":-1,"index":4,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"11","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":-1,"index":5,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"123","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":2,"index":6,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"12","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":3,"index":7,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":2,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"search\"]","iframe":true,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[5]/a[1]","//a[contains(., '查询')]","id(\"search\")","//A[@class='check']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div/a"]}},{"id":5,"index":8,"parentId":0,"type":1,"option":8,"title":"循环1","sequence":[10,9],"isInLoop":false,"position":4,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[contains(@class, \"pagination\")]/ul[1]/li[last()-1]/a[1]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"loopType":0,"pathList":"","textList":"","code":"","waitTime":0,"exitCount":0,"historyWait":2,"breakMode":0,"breakCode":"","breakCodeWaitTime":0,"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[2]/div[1]/div[1]/ul[1]/li[12]/a[1]","//a[contains(., '»')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div/div/div/ul/li[last()-1]/a"]}},{"id":7,"index":9,"parentId":5,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":true,"position":1,"parameters":{"history":4,"tabIndex":-1,"useLoop":true,"xpath":"//*[contains(@class, \"pagination\")]/ul[1]/li[12]/a[1]","iframe":true,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[2]/div[1]/div[1]/ul[1]/li[12]/a[1]","//a[contains(., '»')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div/div/div/ul/li[last()-1]/a"],"loopType":0}},{"id":6,"index":10,"parentId":5,"type":1,"option":8,"title":"循环23123","sequence":[13],"isInLoop":true,"position":0,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[1]/table[1]/tbody[1]/tr","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"loopType":1,"pathList":"","textList":"","code":"","waitTime":0,"exitCount":0,"historyWait":2,"breakMode":0,"breakCode":"","breakCodeWaitTime":0,"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[1]/table[1]/tbody[1]/tr[1]","//tr[contains(., '震级(M)发震时刻(')]","//TR[@class='speed-tr-h1']","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]"]}},{"id":10,"index":11,"parentId":9,"type":0,"option":3,"title":"提取数据","sequence":[],"isInLoop":true,"position":0,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"paras":[{"nodeType":0,"contentType":1,"relative":true,"name":"参数1_文本","desc":"","relativeXPath":"/td[1]","allXPaths":["/td[1]","//td[contains(., '2.2')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-5]"],"exampleValues":[{"num":0,"value":"2.2"}],"unique_index":"/td[1]","iframe":true,"default":"","beforeJS":"arguments[0].innerText += \"TESA\"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数2_文本","desc":"","relativeXPath":"/td[2]","allXPaths":["/td[2]","//td[contains(., '2023-06-14')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-4]"],"exampleValues":[{"num":0,"value":"2023-06-1422:24:41"}],"unique_index":"/td[2]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数3_文本","desc":"","relativeXPath":"/td[3]","allXPaths":["/td[3]","//td[contains(., '37.12')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-3]"],"exampleValues":[{"num":0,"value":"37.12"}],"unique_index":"/td[3]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数4_文本","desc":"","relativeXPath":"/td[4]","allXPaths":["/td[4]","//td[contains(., '114.78')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-2]"],"exampleValues":[{"num":0,"value":"114.78"}],"unique_index":"/td[4]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数5_文本","desc":"","relativeXPath":"/td[5]","allXPaths":["/td[5]","//td[contains(., '10')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-1]"],"exampleValues":[{"num":0,"value":"10"}],"unique_index":"/td[5]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数6_链接文本","desc":"","relativeXPath":"/td[6]/a[1]","allXPaths":["/td[6]/a[1]","//a[contains(., '河北邢台市任泽区')]","id(\"cid\")","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td/a"],"exampleValues":[{"num":0,"value":"河北邢台市任泽区"}],"unique_index":"/td[6]/a[1]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数7_链接地址","desc":"","relativeXPath":"/td[6]/a[1]","allXPaths":["/td[6]/a[1]","//a[contains(., '河北邢台市任泽区')]","id(\"cid\")","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td/a"],"exampleValues":[{"num":0,"value":"https://news.ceic.ac.cn/CD20230614222441.html"}],"unique_index":"/td[6]/a[1]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数8_文本","desc":"","relativeXPath":"/th[1]","allXPaths":["/th[1]","//th[contains(., '震级(M)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-5]"],"exampleValues":[{"num":1,"value":"震级(M)"}],"unique_index":"/th[1]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数9_文本","desc":"","relativeXPath":"/th[2]","allXPaths":["/th[2]","//th[contains(., '发震时刻(UTC+8')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-4]"],"exampleValues":[{"num":1,"value":"发震时刻(UTC+8)"}],"unique_index":"/th[2]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数10_文本","desc":"","relativeXPath":"/th[3]","allXPaths":["/th[3]","//th[contains(., '纬度(°)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-3]"],"exampleValues":[{"num":1,"value":"纬度(°)"}],"unique_index":"/th[3]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数11_文本","desc":"","relativeXPath":"/th[4]","allXPaths":["/th[4]","//th[contains(., '经度(°)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-2]"],"exampleValues":[{"num":1,"value":"经度(°)"}],"unique_index":"/th[4]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数12_文本","desc":"","relativeXPath":"/th[5]","allXPaths":["/th[5]","//th[contains(., '深度(千米)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-1]"],"exampleValues":[{"num":1,"value":"深度(千米)"}],"unique_index":"/th[5]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数13_文本","desc":"","relativeXPath":"/th[6]","allXPaths":["/th[6]","//th[contains(., '参考位置')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th"],"exampleValues":[{"num":1,"value":"参考位置"}],"unique_index":"/th[6]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0}],"loopType":1}},{"id":4,"index":12,"parentId":0,"type":0,"option":3,"title":"提取数据","sequence":[],"isInLoop":false,"position":3,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"paras":[{"nodeType":0,"contentType":0,"relative":false,"name":"参数111_文本","desc":"","extractType":0,"relativeXPath":"/html/body/h1[1]","allXPaths":["/html/body/h1[1]","//h1[contains(., 'IFRAME TES')]","/html/body/h1"],"exampleValues":[{"num":0,"value":"IFRAME TEST"}],"unique_index":"0i681vbofdwrljo9xcbf","iframe":false,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0}]}},{"id":8,"index":13,"parentId":6,"type":2,"option":9,"title":"判断条件","sequence":[14],"isInLoop":true,"position":0,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0}},{"id":9,"parentId":8,"index":14,"type":3,"option":10,"title":"条件分支","sequence":[11],"isInLoop":true,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"class":"3","value":"新疆","code":"","waitTime":0},"position":0},{"id":-1,"parentId":8,"index":15,"type":3,"option":10,"title":"条件分支","sequence":[],"isInLoop":true,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"class":0,"value":"","code":"","waitTime":0},"position":1}]} \ No newline at end of file +{"id":125,"name":"地震台网IFrame","url":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","links":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","create_time":"7/4/2023, 9:23:59 PM","update_time":"7/16/2023, 12:02:30 PM","version":"0.3.6","saveThreshold":10,"cloudflare":0,"environment":0,"maxViewLength":15,"outputFormat":"xlsx","saveName":"current_time","inputExcel":"","startFromExit":0,"containJudge":true,"desc":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","inputParameters":[{"id":0,"name":"urlList_0","nodeId":1,"nodeName":"打开网页","value":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","desc":"要采集的网址列表,多行以\\n分开","type":"text","exampleValue":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history"},{"id":1,"name":"inputText_1","nodeName":"输入文字","nodeId":6,"desc":"要输入的文本,如京东搜索框输入:电脑","type":"text","exampleValue":"12","value":"12"},{"id":2,"name":"loopTimes_循环1_2","nodeId":8,"nodeName":"循环1","desc":"循环循环1执行的次数(0代表无限循环)","type":"int","exampleValue":0,"value":0}],"outputParameters":[{"id":0,"name":"参数1_文本","desc":"","exampleValue":"2.2"},{"id":1,"name":"参数2_文本","desc":"","exampleValue":"2023-06-1422:24:41"},{"id":2,"name":"参数3_文本","desc":"","exampleValue":"37.12"},{"id":3,"name":"参数4_文本","desc":"","exampleValue":"114.78"},{"id":4,"name":"参数5_文本","desc":"","exampleValue":"10"},{"id":5,"name":"参数6_链接文本","desc":"","exampleValue":"河北邢台市任泽区"},{"id":6,"name":"参数7_链接地址","desc":"","exampleValue":"https://news.ceic.ac.cn/CD20230614222441.html"},{"id":7,"name":"参数8_文本","desc":"","exampleValue":"震级(M)"},{"id":8,"name":"参数9_文本","desc":"","exampleValue":"发震时刻(UTC+8)"},{"id":9,"name":"参数10_文本","desc":"","exampleValue":"纬度(°)"},{"id":10,"name":"参数11_文本","desc":"","exampleValue":"经度(°)"},{"id":11,"name":"参数12_文本","desc":"","exampleValue":"深度(千米)"},{"id":12,"name":"参数13_文本","desc":"","exampleValue":"参考位置"},{"id":13,"name":"参数111_文本","desc":"","exampleValue":"IFRAME TEST"}],"graph":[{"index":0,"id":0,"parentId":0,"type":-1,"option":0,"title":"root","sequence":[1,6,7,12,8],"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","wait":0},"isInLoop":false},{"id":1,"index":1,"parentId":0,"type":0,"option":1,"title":"打开网页","sequence":[],"isInLoop":false,"position":0,"parameters":{"useLoop":false,"xpath":"","wait":10,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"url":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","links":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=http://www.ceic.ac.cn/history","maxWaitTime":10,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"cookies":""}},{"id":-1,"index":2,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"15","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":-1,"index":3,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":2,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"search\"]","iframe":true,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[5]/a[1]","//a[contains(., '查询')]","id(\"search\")","//A[@class='check']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div/a"]}},{"id":-1,"index":4,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"11","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":-1,"index":5,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":6,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"123","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":2,"index":6,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"weidu1\"]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"value":"12","allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[2]/input[1]","//input[contains(., '')]","id(\"weidu1\")","//INPUT[@class='span1']","//INPUT[@name='weidu1']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div[last()-3]/input[last()-1]"]}},{"id":3,"index":7,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":2,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"search\"]","iframe":true,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":"3","scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[1]/form[1]/div[5]/a[1]","//a[contains(., '查询')]","id(\"search\")","//A[@class='check']","/html/body/div[last()-3]/div[last()-1]/div/div/div[last()-1]/form/div/a"]}},{"id":5,"index":8,"parentId":0,"type":1,"option":8,"title":"循环1","sequence":[10,9],"isInLoop":false,"position":4,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"//*[contains(@class, \"pagination\")]/ul[1]/li[last()-1]/a[1]","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"loopType":0,"pathList":"","textList":"","code":"","waitTime":0,"exitCount":0,"historyWait":2,"breakMode":0,"breakCode":"","breakCodeWaitTime":0,"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[2]/div[1]/div[1]/ul[1]/li[12]/a[1]","//a[contains(., '»')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div/div/div/ul/li[last()-1]/a"]}},{"id":7,"index":9,"parentId":5,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":true,"position":1,"parameters":{"history":4,"tabIndex":-1,"useLoop":true,"xpath":"","iframe":true,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[2]/div[1]/div[1]/ul[1]/li[12]/a[1]","//a[contains(., '»')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div/div/div/ul/li[last()-1]/a"],"loopType":0}},{"id":6,"index":10,"parentId":5,"type":1,"option":8,"title":"循环23123","sequence":[13],"isInLoop":true,"position":0,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[1]/table[1]/tbody[1]/tr","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"loopType":1,"pathList":"","textList":"","code":"","waitTime":0,"exitCount":0,"historyWait":2,"breakMode":0,"breakCode":"","breakCodeWaitTime":0,"allXPaths":["/html/body/div[1]/div[3]/div[1]/div[1]/div[2]/div[1]/div[1]/table[1]/tbody[1]/tr[1]","//tr[contains(., '震级(M)发震时刻(')]","//TR[@class='speed-tr-h1']","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]"]}},{"id":10,"index":11,"parentId":9,"type":0,"option":3,"title":"提取数据","sequence":[],"isInLoop":true,"position":0,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"paras":[{"nodeType":0,"contentType":1,"relative":true,"name":"参数1_文本","desc":"","relativeXPath":"/td[1]","allXPaths":["/td[1]","//td[contains(., '2.2')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-5]"],"exampleValues":[{"num":0,"value":"2.2"}],"unique_index":"/td[1]","iframe":true,"default":"","beforeJS":"arguments[0].innerText += \"TESA\"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数2_文本","desc":"","relativeXPath":"/td[2]","allXPaths":["/td[2]","//td[contains(., '2023-06-14')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-4]"],"exampleValues":[{"num":0,"value":"2023-06-1422:24:41"}],"unique_index":"/td[2]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数3_文本","desc":"","relativeXPath":"/td[3]","allXPaths":["/td[3]","//td[contains(., '37.12')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-3]"],"exampleValues":[{"num":0,"value":"37.12"}],"unique_index":"/td[3]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数4_文本","desc":"","relativeXPath":"/td[4]","allXPaths":["/td[4]","//td[contains(., '114.78')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-2]"],"exampleValues":[{"num":0,"value":"114.78"}],"unique_index":"/td[4]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数5_文本","desc":"","relativeXPath":"/td[5]","allXPaths":["/td[5]","//td[contains(., '10')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td[last()-1]"],"exampleValues":[{"num":0,"value":"10"}],"unique_index":"/td[5]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数6_链接文本","desc":"","relativeXPath":"/td[6]/a[1]","allXPaths":["/td[6]/a[1]","//a[contains(., '河北邢台市任泽区')]","id(\"cid\")","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td/a"],"exampleValues":[{"num":0,"value":"河北邢台市任泽区"}],"unique_index":"/td[6]/a[1]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数7_链接地址","desc":"","relativeXPath":"/td[6]/a[1]","allXPaths":["/td[6]/a[1]","//a[contains(., '河北邢台市任泽区')]","id(\"cid\")","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-19]/td/a"],"exampleValues":[{"num":0,"value":"https://news.ceic.ac.cn/CD20230614222441.html"}],"unique_index":"/td[6]/a[1]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数8_文本","desc":"","relativeXPath":"/th[1]","allXPaths":["/th[1]","//th[contains(., '震级(M)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-5]"],"exampleValues":[{"num":1,"value":"震级(M)"}],"unique_index":"/th[1]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数9_文本","desc":"","relativeXPath":"/th[2]","allXPaths":["/th[2]","//th[contains(., '发震时刻(UTC+8')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-4]"],"exampleValues":[{"num":1,"value":"发震时刻(UTC+8)"}],"unique_index":"/th[2]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数10_文本","desc":"","relativeXPath":"/th[3]","allXPaths":["/th[3]","//th[contains(., '纬度(°)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-3]"],"exampleValues":[{"num":1,"value":"纬度(°)"}],"unique_index":"/th[3]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数11_文本","desc":"","relativeXPath":"/th[4]","allXPaths":["/th[4]","//th[contains(., '经度(°)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-2]"],"exampleValues":[{"num":1,"value":"经度(°)"}],"unique_index":"/th[4]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数12_文本","desc":"","relativeXPath":"/th[5]","allXPaths":["/th[5]","//th[contains(., '深度(千米)')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th[last()-1]"],"exampleValues":[{"num":1,"value":"深度(千米)"}],"unique_index":"/th[5]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数13_文本","desc":"","relativeXPath":"/th[6]","allXPaths":["/th[6]","//th[contains(., '参考位置')]","/html/body/div[last()-3]/div[last()-1]/div/div/div/div/div[last()-1]/table/tbody/tr[last()-20]/th"],"exampleValues":[{"num":1,"value":"参考位置"}],"unique_index":"/th[6]","iframe":true,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0}],"loopType":1}},{"id":4,"index":12,"parentId":0,"type":0,"option":3,"title":"提取数据","sequence":[],"isInLoop":false,"position":3,"parameters":{"history":4,"tabIndex":-1,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"paras":[{"nodeType":0,"contentType":0,"relative":false,"name":"参数111_文本","desc":"","extractType":0,"relativeXPath":"/html/body/h1[1]","allXPaths":["/html/body/h1[1]","//h1[contains(., 'IFRAME TES')]","/html/body/h1"],"exampleValues":[{"num":0,"value":"IFRAME TEST"}],"unique_index":"0i681vbofdwrljo9xcbf","iframe":false,"default":"","beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0}]}},{"id":8,"index":13,"parentId":6,"type":2,"option":9,"title":"判断条件","sequence":[14],"isInLoop":true,"position":0,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0}},{"id":9,"parentId":8,"index":14,"type":3,"option":10,"title":"条件分支","sequence":[11],"isInLoop":true,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"class":"3","value":"新疆","code":"","waitTime":0},"position":0},{"id":-1,"parentId":8,"index":15,"type":3,"option":10,"title":"条件分支","sequence":[],"isInLoop":true,"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"class":0,"value":"","code":"","waitTime":0},"position":1}]} \ No newline at end of file diff --git a/ElectronJS/tasks/184.json b/ElectronJS/tasks/184.json new file mode 100644 index 0000000..d21e4d5 --- /dev/null +++ b/ElectronJS/tasks/184.json @@ -0,0 +1 @@ +{"id":184,"name":"JD IFRAME","url":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e","links":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e","create_time":"7/16/2023, 12:06:18 PM","update_time":"7/16/2023, 12:09:15 PM","version":"0.3.6","saveThreshold":10,"cloudflare":0,"environment":0,"maxViewLength":15,"outputFormat":"xlsx","saveName":"current_time","inputExcel":"","startFromExit":0,"containJudge":false,"desc":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e","inputParameters":[{"id":0,"name":"urlList_0","nodeId":1,"nodeName":"打开网页","value":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e","desc":"要采集的网址列表,多行以\\n分开","type":"text","exampleValue":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e"},{"id":1,"name":"inputText_1","nodeName":"输入文字","nodeId":2,"desc":"要输入的文本,如京东搜索框输入:电脑","type":"text","exampleValue":"12","value":"12"}],"outputParameters":[{"id":0,"name":"参数1_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"\n\t\t\t\t\t\t\t\t\n\t\t\t\t \t"},{"id":1,"name":"参数2_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"//item.jd.com/10080265235775.html"},{"id":2,"name":"参数3_图片地址","desc":"","type":"text","recordASField":1,"exampleValue":"//img10.360buyimg.com/n7/jfs/t1/211397/11/37712/151327/649ec23aF55dc129a/3af42aec4dda905b.jpg"},{"id":3,"name":"参数4_文本","desc":"","type":"text","recordASField":1,"exampleValue":"¥"},{"id":4,"name":"参数5_文本","desc":"","type":"text","recordASField":1,"exampleValue":"1699.00"},{"id":5,"name":"参数6_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"\n\t\t\t\t\t\t\t\t美的(Midea)滚筒式洗衣机变频家用 内衣羽绒全自动巴氏除菌洗衣服机 十公斤大容量一级能效节能 【可洗羽绒羊毛】柔拍净洗不结团MG133 123\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t"},{"id":6,"name":"参数7_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"//item.jd.com/10080265235775.html"},{"id":7,"name":"参数8_文本","desc":"","type":"text","recordASField":1,"exampleValue":"美的(Midea)滚筒式洗衣机变频家用内衣羽绒全自动巴氏除菌洗衣服机十公斤大容量一级能效节能【可洗羽绒羊毛】柔拍净洗不结团MG133"},{"id":8,"name":"参数9_文本","desc":"","type":"text","recordASField":1,"exampleValue":"123"},{"id":9,"name":"参数10_文本","desc":"","type":"text","recordASField":1,"exampleValue":"条评价"},{"id":10,"name":"参数11_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"0"},{"id":11,"name":"参数12_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"//item.jd.com/10080265235775.html#comment"},{"id":12,"name":"参数13_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"美的全屋智慧甄品旗舰店"},{"id":13,"name":"参数14_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"//mall.jd.com/index-12721035.html?from=pc"},{"id":14,"name":"参数15_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"对比"},{"id":15,"name":"参数16_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"javascript:;"},{"id":16,"name":"参数17_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"关注"},{"id":17,"name":"参数18_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"javascript:;"},{"id":18,"name":"参数19_链接文本","desc":"","type":"text","recordASField":1,"exampleValue":"加入购物车"},{"id":19,"name":"参数20_链接地址","desc":"","type":"text","recordASField":1,"exampleValue":"//cart.jd.com/gate.action?pid=10080265235775&pcount=1&ptype=1"},{"id":20,"name":"参数21_文本","desc":"","type":"text","recordASField":1,"exampleValue":"广告"},{"id":21,"name":"参数22_图片地址","desc":"","type":"text","recordASField":1,"exampleValue":""},{"id":22,"name":"参数23_图片地址","desc":"","type":"text","recordASField":1,"exampleValue":"//m.360buyimg.com/cc/jfs/t1/113659/27/28361/2962/62ecb1f0E6c5fc50c/b914680e87a2c8e9.png"},{"id":23,"name":"参数24_文本","desc":"","type":"text","recordASField":1,"exampleValue":"99元5件幼儿启蒙团购电话4006186622"},{"id":24,"name":"参数25_文本","desc":"","type":"text","recordASField":1,"exampleValue":"自营"},{"id":25,"name":"参数26_文本","desc":"","type":"text","recordASField":1,"exampleValue":"3件8.0折"},{"id":26,"name":"参数27_文本","desc":"","type":"text","recordASField":1,"exampleValue":"7.7-7.31"},{"id":27,"name":"参数28_图片地址","desc":"","type":"text","recordASField":1,"exampleValue":"//m.360buyimg.com/cc/jfs/t1/197706/29/27826/4384/63314bc6E21b4c3e9/8b4d5fc44efc5b3f.png"},{"id":28,"name":"参数29_文本","desc":"","type":"text","recordASField":1,"exampleValue":"每满200-20"},{"id":29,"name":"参数30_文本","desc":"","type":"text","recordASField":1,"exampleValue":"..."},{"id":30,"name":"参数31_文本","desc":"","type":"text","recordASField":1,"exampleValue":"满赠"}],"graph":[{"index":0,"id":0,"parentId":0,"type":-1,"option":0,"title":"root","sequence":[1,2,3,4],"parameters":{"history":1,"tabIndex":0,"useLoop":false,"xpath":"","wait":0,"waitType":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":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e","links":"http://localhost:8074/taskGrid/test_pages/iframe.html?address=https://search.jd.com/Search?keyword=123&enc=utf-8&wq=123&pvid=b0985cab50aa4f6ebd24fc0208bb718e","maxWaitTime":10,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"cookies":""}},{"id":2,"index":2,"parentId":0,"type":0,"option":4,"title":"输入文字","sequence":[],"isInLoop":false,"position":1,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"key\"]","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"value":"12","index":0,"allXPaths":["/html/body/div[3]/div[2]/div[1]/input[1]","//input[contains(., '')]","id(\"key\")","//INPUT[@class='text defcolor']","/html/body/div[last()-13]/div[last()-2]/div/input"]}},{"id":3,"index":3,"parentId":0,"type":0,"option":2,"title":"点击元素","sequence":[],"isInLoop":false,"position":2,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"//*[@id=\"J_crumbsBar\"]","iframe":false,"wait":2,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":"3","scrollCount":1,"scrollWaitTime":1,"clickWay":0,"maxWaitTime":10,"paras":[],"allXPaths":["/html/body/div[5]/div[1]","//div[contains(., '')]","id(\"J_crumbsBar\")","//DIV[@class='crumbs-bar']","/html/body/div[last()-11]/div[last()-1]"]}},{"id":4,"index":4,"parentId":0,"type":1,"option":8,"title":"循环","sequence":[5],"isInLoop":false,"position":3,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"/html/body/div[5]/div[2]/div[2]/div[1]/div[1]/div[2]/ul[1]/li/div[1]","iframe":false,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"scrollType":0,"scrollCount":1,"scrollWaitTime":1,"loopType":1,"pathList":"","textList":"","code":"","waitTime":0,"exitCount":0,"historyWait":2,"breakMode":0,"breakCode":"","breakCodeWaitTime":0,"allXPaths":["/html/body/div[5]/div[2]/div[2]/div[1]/div[1]/div[2]/ul[1]/li[1]/div[1]","//div[contains(., '')]","//DIV[@class='gl-i-wrap']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div"]}},{"id":5,"index":5,"parentId":4,"type":0,"option":3,"title":"提取数据","sequence":[],"isInLoop":true,"position":0,"parameters":{"history":5,"tabIndex":-1,"useLoop":false,"xpath":"","iframe":true,"wait":0,"waitType":0,"beforeJS":"","beforeJSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"waitElement":"","waitElementTime":10,"waitElementIframeIndex":0,"clear":0,"paras":[{"nodeType":1,"contentType":0,"relative":true,"name":"参数1_链接文本","desc":"","relativeXPath":"/div[1]/a[1]","allXPaths":["/div[1]/a[1]","//a[contains(., '')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-7]/a"],"exampleValues":[{"num":0,"value":"\n\t\t\t\t\t\t\t\t\n\t\t\t\t \t"}],"unique_index":"/div[1]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数2_链接地址","desc":"","relativeXPath":"/div[1]/a[1]","allXPaths":["/div[1]/a[1]","//a[contains(., '')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-7]/a"],"exampleValues":[{"num":0,"value":"//item.jd.com/10080265235775.html"}],"unique_index":"/div[1]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":4,"contentType":1,"relative":true,"name":"参数3_图片地址","desc":"","relativeXPath":"/div[1]/a[1]/img[1]","allXPaths":["/div[1]/a[1]/img[1]","//img[contains(., '')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-7]/a/img"],"exampleValues":[{"num":0,"value":"//img10.360buyimg.com/n7/jfs/t1/211397/11/37712/151327/649ec23aF55dc129a/3af42aec4dda905b.jpg"}],"unique_index":"/div[1]/a[1]/img[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数4_文本","desc":"","relativeXPath":"/div[2]/strong[1]/em[1]","allXPaths":["/div[2]/strong[1]/em[1]","//em[contains(., '¥')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-6]/strong/em"],"exampleValues":[{"num":0,"value":"¥"}],"unique_index":"/div[2]/strong[1]/em[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数5_文本","desc":"","relativeXPath":"/div[2]/strong[1]/i[1]","allXPaths":["/div[2]/strong[1]/i[1]","//i[contains(., '1699.00')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-6]/strong/i"],"exampleValues":[{"num":0,"value":"1699.00"}],"unique_index":"/div[2]/strong[1]/i[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数6_链接文本","desc":"","relativeXPath":"/div[3]/a[1]","allXPaths":["/div[3]/a[1]","//a[contains(., '美')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-5]/a"],"exampleValues":[{"num":0,"value":"\n\t\t\t\t\t\t\t\t美的(Midea)滚筒式洗衣机变频家用 内衣羽绒全自动巴氏除菌洗衣服机 十公斤大容量一级能效节能 【可洗羽绒羊毛】柔拍净洗不结团MG133 123\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t"}],"unique_index":"/div[3]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数7_链接地址","desc":"","relativeXPath":"/div[3]/a[1]","allXPaths":["/div[3]/a[1]","//a[contains(., '美')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-5]/a"],"exampleValues":[{"num":0,"value":"//item.jd.com/10080265235775.html"}],"unique_index":"/div[3]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数8_文本","desc":"","relativeXPath":"/div[3]/a[1]/em[1]","allXPaths":["/div[3]/a[1]/em[1]","//em[contains(., '美的(Midea)滚')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-5]/a/em"],"exampleValues":[{"num":0,"value":"美的(Midea)滚筒式洗衣机变频家用内衣羽绒全自动巴氏除菌洗衣服机十公斤大容量一级能效节能【可洗羽绒羊毛】柔拍净洗不结团MG133"}],"unique_index":"/div[3]/a[1]/em[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数9_文本","desc":"","relativeXPath":"/div[3]/a[1]/em[1]/font[1]","allXPaths":["/div[3]/a[1]/em[1]/font[1]","//font[contains(., '123')]","//FONT[@class='skcolor_ljg']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-5]/a/em/font"],"exampleValues":[{"num":0,"value":"123"}],"unique_index":"/div[3]/a[1]/em[1]/font[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数10_文本","desc":"","relativeXPath":"/div[4]/strong[1]","allXPaths":["/div[4]/strong[1]","//strong[contains(., '0条评价')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-4]/strong"],"exampleValues":[{"num":0,"value":"条评价"}],"unique_index":"/div[4]/strong[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数11_链接文本","desc":"","relativeXPath":"/div[4]/strong[1]/a[1]","allXPaths":["/div[4]/strong[1]/a[1]","//a[contains(., '0')]","id(\"J_comment_10080265235775\")","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-4]/strong/a"],"exampleValues":[{"num":0,"value":"0"}],"unique_index":"/div[4]/strong[1]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数12_链接地址","desc":"","relativeXPath":"/div[4]/strong[1]/a[1]","allXPaths":["/div[4]/strong[1]/a[1]","//a[contains(., '0')]","id(\"J_comment_10080265235775\")","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-4]/strong/a"],"exampleValues":[{"num":0,"value":"//item.jd.com/10080265235775.html#comment"}],"unique_index":"/div[4]/strong[1]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数13_链接文本","desc":"","relativeXPath":"/div[5]/span[1]/a[1]","allXPaths":["/div[5]/span[1]/a[1]","//a[contains(., '美的全屋智慧甄品旗舰')]","//A[@class='curr-shop hd-shopname']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-3]/span/a"],"exampleValues":[{"num":0,"value":"美的全屋智慧甄品旗舰店"}],"unique_index":"/div[5]/span[1]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数14_链接地址","desc":"","relativeXPath":"/div[5]/span[1]/a[1]","allXPaths":["/div[5]/span[1]/a[1]","//a[contains(., '美的全屋智慧甄品旗舰')]","//A[@class='curr-shop hd-shopname']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-3]/span/a"],"exampleValues":[{"num":0,"value":"//mall.jd.com/index-12721035.html?from=pc"}],"unique_index":"/div[5]/span[1]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数15_链接文本","desc":"","relativeXPath":"/div[7]/a[1]","allXPaths":["/div[7]/a[1]","//a[contains(., '对比')]","//A[@class='p-o-btn contrast J_contrast contrast']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-1]/a[last()-2]"],"exampleValues":[{"num":0,"value":"对比"}],"unique_index":"/div[7]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数16_链接地址","desc":"","relativeXPath":"/div[7]/a[1]","allXPaths":["/div[7]/a[1]","//a[contains(., '对比')]","//A[@class='p-o-btn contrast J_contrast contrast']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-1]/a[last()-2]"],"exampleValues":[{"num":0,"value":"javascript:;"}],"unique_index":"/div[7]/a[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数17_链接文本","desc":"","relativeXPath":"/div[7]/a[2]","allXPaths":["/div[7]/a[2]","//a[contains(., '关注')]","//A[@class='p-o-btn focus J_focus']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-1]/a[last()-1]"],"exampleValues":[{"num":0,"value":"关注"}],"unique_index":"/div[7]/a[2]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数18_链接地址","desc":"","relativeXPath":"/div[7]/a[2]","allXPaths":["/div[7]/a[2]","//a[contains(., '关注')]","//A[@class='p-o-btn focus J_focus']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-1]/a[last()-1]"],"exampleValues":[{"num":0,"value":"javascript:;"}],"unique_index":"/div[7]/a[2]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":1,"contentType":0,"relative":true,"name":"参数19_链接文本","desc":"","relativeXPath":"/div[7]/a[3]","allXPaths":["/div[7]/a[3]","//a[contains(., '加入购物车')]","//A[@class='p-o-btn addcart']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-1]/a"],"exampleValues":[{"num":0,"value":"加入购物车"}],"unique_index":"/div[7]/a[3]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":2,"contentType":0,"relative":true,"name":"参数20_链接地址","desc":"","relativeXPath":"/div[7]/a[3]","allXPaths":["/div[7]/a[3]","//a[contains(., '加入购物车')]","//A[@class='p-o-btn addcart']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/div[last()-1]/a"],"exampleValues":[{"num":0,"value":"//cart.jd.com/gate.action?pid=10080265235775&pcount=1&ptype=1"}],"unique_index":"/div[7]/a[3]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数21_文本","desc":"","relativeXPath":"/span[1]","allXPaths":["/span[1]","//span[contains(., '广告')]","//SPAN[@class='p-promo-flag']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/span"],"exampleValues":[{"num":0,"value":"广告"}],"unique_index":"/span[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":4,"contentType":1,"relative":true,"name":"参数22_图片地址","desc":"","relativeXPath":"/img[1]","allXPaths":["/img[1]","//img[contains(., '')]","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-29]/div/img"],"exampleValues":[{"num":0,"value":""}],"unique_index":"/img[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":4,"contentType":1,"relative":true,"name":"参数23_图片地址","desc":"","relativeXPath":"/div[3]/a[1]/em[1]/img[1]","allXPaths":["/div[3]/a[1]/em[1]/img[1]","//img[contains(., '')]","//IMG[@class='p-tag3']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-28]/div/div[last()-5]/a/em/img"],"exampleValues":[{"num":1,"value":"//m.360buyimg.com/cc/jfs/t1/113659/27/28361/2962/62ecb1f0E6c5fc50c/b914680e87a2c8e9.png"}],"unique_index":"/div[3]/a[1]/em[1]/img[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数24_文本","desc":"","relativeXPath":"/div[3]/a[1]/i[1]","allXPaths":["/div[3]/a[1]/i[1]","//i[contains(., '99元5件 幼儿启蒙')]","id(\"J_AD_12830944\")","//I[@class='promo-words']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-28]/div/div[last()-5]/a/i"],"exampleValues":[{"num":1,"value":"99元5件幼儿启蒙团购电话4006186622"}],"unique_index":"/div[3]/a[1]/i[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数25_文本","desc":"","relativeXPath":"/div[6]/i[1]","allXPaths":["/div[6]/i[1]","//i[contains(., '自营')]","//I[@class='goods-icons J-picon-tips J-picon-fix']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-28]/div/div[last()-2]/i"],"exampleValues":[{"num":1,"value":"自营"}],"unique_index":"/div[6]/i[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数26_文本","desc":"","relativeXPath":"/div[1]/a[1]/div[1]/div[1]","allXPaths":["/div[1]/a[1]/div[1]/div[1]","//div[contains(., '3件8.0折')]","//DIV[@class='sign-title ac']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-27]/div/div[last()-7]/a/div/div"],"exampleValues":[{"num":2,"value":"3件8.0折"}],"unique_index":"/div[1]/a[1]/div[1]/div[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数27_文本","desc":"","relativeXPath":"/div[1]/a[1]/div[1]/div[1]/span[1]","allXPaths":["/div[1]/a[1]/div[1]/div[1]/span[1]","//span[contains(., '7.7-7.31')]","//SPAN[@class='sign-date']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-27]/div/div[last()-7]/a/div/div/span"],"exampleValues":[{"num":2,"value":"7.7-7.31"}],"unique_index":"/div[1]/a[1]/div[1]/div[1]/span[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":4,"contentType":1,"relative":true,"name":"参数28_图片地址","desc":"","relativeXPath":"/div[5]/img[1]","allXPaths":["/div[5]/img[1]","//img[contains(., '')]","//IMG[@class='shop-tag fl']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-26]/div/div[last()-3]/img"],"exampleValues":[{"num":3,"value":"//m.360buyimg.com/cc/jfs/t1/197706/29/27826/4384/63314bc6E21b4c3e9/8b4d5fc44efc5b3f.png"}],"unique_index":"/div[5]/img[1]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数29_文本","desc":"","relativeXPath":"/div[6]/i[2]","allXPaths":["/div[6]/i[2]","//i[contains(., '每满200-20')]","//I[@class='goods-icons4 J-picon-tips']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-26]/div/div[last()-2]/i"],"exampleValues":[{"num":3,"value":"每满200-20"}],"unique_index":"/div[6]/i[2]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数30_文本","desc":"","relativeXPath":"/div[3]/a[1]/em[1]/font[2]","allXPaths":["/div[3]/a[1]/em[1]/font[2]","//font[contains(., '...')]","//FONT[@class='dot']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-10]/div/div[last()-5]/a/em/font"],"exampleValues":[{"num":19,"value":"..."}],"unique_index":"/div[3]/a[1]/em[1]/font[2]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0},{"nodeType":0,"contentType":1,"relative":true,"name":"参数31_文本","desc":"","relativeXPath":"/div[6]/i[3]","allXPaths":["/div[6]/i[3]","//i[contains(., '满赠')]","//I[@class='goods-icons4 J-picon-tips']","/html/body/div[last()-11]/div/div/div[last()-1]/div/div[last()-2]/ul/li[last()-9]/div/div[last()-2]/i"],"exampleValues":[{"num":20,"value":"满赠"}],"unique_index":"/div[6]/i[3]","iframe":true,"default":"","paraType":"text","recordASField":1,"beforeJS":"","beforeJSWaitTime":0,"JS":"","JSWaitTime":0,"afterJS":"","afterJSWaitTime":0,"downloadPic":0}],"loopType":1}}]} \ No newline at end of file diff --git a/ExecuteStage/.vscode/launch.json b/ExecuteStage/.vscode/launch.json index ce2c52f..91819c2 100644 --- a/ExecuteStage/.vscode/launch.json +++ b/ExecuteStage/.vscode/launch.json @@ -12,7 +12,7 @@ "justMyCode": false, // "args": ["--id", "[7]", "--read_type", "remote", "--headless", "0"] // "args": ["--id", "[9]", "--read_type", "remote", "--headless", "0", "--saved_file_name", "YOUTUBE"] - "args": ["--id", "[54]", "--headless", "0", "--user_data", "1", "--keyboard", "0"] + "args": ["--id", "[63]", "--headless", "0", "--user_data", "1", "--keyboard", "0"] } ] } \ No newline at end of file diff --git a/ExecuteStage/easyspider_executestage.py b/ExecuteStage/easyspider_executestage.py index aba29bd..3d058c9 100644 --- a/ExecuteStage/easyspider_executestage.py +++ b/ExecuteStage/easyspider_executestage.py @@ -427,9 +427,18 @@ class BrowserThread(Thread): bodyText = "" i = 0 while True: - # newBodyText = self.browser.page_source newBodyText = self.browser.find_element( - By.CSS_SELECTOR, "body", iframe=para["iframe"]).text + By.CSS_SELECTOR, "body", iframe=False).text + if para["iframe"]: # 如果标记了iframe + iframes = self.browser.find_elements( + By.CSS_SELECTOR, "iframe", iframe=False) + for iframe in iframes: + self.browser.switch_to.default_content() + self.browser.switch_to.frame(iframe) + iframe_text = super(self.browser.__class__, self.browser).find_element( + By.CSS_SELECTOR, "body").text # 用super调用父类的方法 + newBodyText += iframe_text + self.browser.switch_to.default_content() if newBodyText == bodyText: print("页面已检测不到新内容,停止滚动。") print( @@ -842,9 +851,20 @@ class BrowserThread(Thread): finished = False # newBodyText = self.browser.page_source # newBodyText = self.browser.find_element(By.XPATH, "//body").text - newBodyText = self.browser.find_element( - By.CSS_SELECTOR, "body", iframe=node["parameters"]["iframe"]).text if node["parameters"]["exitCount"] == 0: + newBodyText = self.browser.find_element( + By.CSS_SELECTOR, "body", iframe=False).text + if node["parameters"]["iframe"]: # 如果标记了iframe + iframes = self.browser.find_elements( + By.CSS_SELECTOR, "iframe", iframe=False) + for iframe in iframes: + self.browser.switch_to.default_content() + self.browser.switch_to.frame(iframe) + iframe_text = super(self.browser.__class__, self.browser).find_element( + By.CSS_SELECTOR, "body").text # 用super调用父类的方法 + newBodyText += iframe_text + self.browser.switch_to.default_content() + if newBodyText == bodyText: # 如果页面内容无变化 print("页面已检测不到新内容,停止循环。") print("No new content detected on the page, stop loop.")