hyfreefly 发表于 2012-7-25 11:18:38

求助关于参数化问题(新手上路,请多多关照)

web_submit_form("TtTaskCreateTypeSelect.jsf_2",
                "Snapshot=t187.inf",
                ITEMDATA,
                "Name=formId:taskType", "Value={NewParam}", ENDITEM,
                "Name=formId:nextstep", "Value=下一步", ENDITEM,
                EXTRARES,
                "Url=/dgsweb/js/ext-2.0/resources/images/default/button/btn-sprite.gif", "Referer=http://x.x.x.x:9080/dgsweb/pages/task/TtTaskCreateNew.jsf?action=add&taskType=6005&conversationId=7136", ENDITEM,
                "Url=/dgsweb/images/find.gif", "Referer=http://x.x.x.x:9080/dgsweb/pages/task/TtTaskCreateNew.jsf?action=add&taskType=6005&conversationId=7136", ENDITEM,
                "Url=/dgsweb/images/default/button/btn-sprite.gif", "Referer=http://x.x.x.x:9080/dgsweb/index.jsf?conversationId=7131", ENDITEM,
                LAST);

第二段:web_submit_data("TtTaskCreateNew.jsf",
                "Action=http://x.x.x.x:9080:9080/dgsweb/pages/task/TtTaskCreateNew.jsf",
                "Method=POST",
                "EncType=multipart/form-data",
                "RecContentType=text/html",
                "Referer=http://x.x.x.x:9080:9080/dgsweb/pages/task/TtTaskCreateNew.jsf?action=add&taskType=6005&conversationId=7136",
                "Snapshot=t189.inf",
                "Mode=HTML",
                ITEMDATA,
                "Name=taskType", "Value=6005", ENDITEM,
                "Name=formId:taskName", "Value=testaddtask1", ENDITEM,
                "Name=formId:StabdardHour", "Value=9", ENDITEM,
                "Name=formId:taskGropuName", "Value=RWZ2012032901", ENDITEM,
                "Name=formId:taskGroupId", "Value=1000035855", ENDITEM,
                "Name=formId:insertBtn", "Value=保存", ENDITEM,
                "Name=formId_SUBMIT", "Value=1", ENDITEM,
                "Name=formId:_link_hidden_", "Value=", ENDITEM,
                "Name=formId:_idcl", "Value=", ENDITEM,
                "Name=javax.faces.ViewState", "Value={rO0ABXVyABNbTGphdmEubGFuZy5PYmplY3Q7kM5YnxBzKWwCAAB4cAAAAAN0AAdfaWQ1MDU0cHQAHy9wYWdlcy90YXNrL1R0VGFza0NyZWF0ZU5ldy5qc2Y=}", ENDITEM,
                EXTRARES,
                "Url=/dgsweb/js/ext-2.0/resources/images/showimage/openhand_8_8.cur", "Referer=http://x.x.x.x:9080:9080/dgsweb/pages/task/TtTaskUpdate.jsf?bouid=1000040044&conversationId=7138", ENDITEM,
                "Url=/dgsweb/a4j_3_1_4.GAorg.richfaces.renderkit.html.GradientA/DATB/eAH7..3Tj2v7ABPtBXU_.jsf", "Referer=http://1x.x.x.x:/dgsweb/pages/task/TtTaskUpdate.jsf?bouid=1000040044&conversationId=7138", ENDITEM,
                LAST);

第一段中的Name=formId:taskType", "Value={NewParam}", 我进行了参数化(假如参数化值是A、B、C),然后第二段在显示的时候展现的"Name=taskType", "Value=6005", ENDITEM,这个Value=6005"显示的是前面ABC的代码(6005、6004、6003),这里的参数化该如果关联做了

melonboy 发表于 2012-7-26 17:46:31

把6005再建立一个参数,该参数每行与{NewParam}的各行对应,在LR的参数列表里面去关联!6005的参数选择跟随与{NewParam}同一行记录就可以了!

yubiao584521 发表于 2012-7-27 15:53:10

把Value={NewParam}", 的值取出来,参数化到第二个值中
页: [1]
查看完整版本: 求助关于参数化问题(新手上路,请多多关照)