upadte result jsp

This commit is contained in:
fanfuxiaoran 2014-06-26 17:15:29 +08:00
parent 5659b46cec
commit b008839121
13 changed files with 998 additions and 979 deletions

View File

@ -1,79 +0,0 @@
package org.bench4q.web.api;
import java.util.HashMap;
import java.util.Map;
import org.apache.log4j.Logger;
import org.bench4q.share.helper.MarshalHelper;
import org.bench4q.share.models.agent.RunScenarioModel;
import org.bench4q.share.models.master.OperateScriptServerResponseModel;
import org.bench4q.web.masterMessager.ScriptMessager;
import org.bench4q.web.model.ScenarioModel;
import org.bench4q.web.newapi.BaseController;
import org.bench4q.web.newservice.ScriptServiceNew;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.SessionAttributes;
@Controller
@SessionAttributes("accessToken")
public class DeviceController extends BaseController {
private Logger logger = Logger.getLogger(DeviceController.class);
private ScriptServiceNew scriptService;
private ScriptMessager scriptMessager;
public ScriptServiceNew getScriptService() {
return scriptService;
}
@Autowired
public void setScriptService(ScriptServiceNew scriptService) {
this.scriptService = scriptService;
}
public ScriptMessager getScriptMessager() {
return scriptMessager;
}
@Autowired
public void setScriptMessager(ScriptMessager scriptMessager) {
this.scriptMessager = scriptMessager;
}
@RequestMapping(value = "deviceScript", method = RequestMethod.POST)
@ResponseBody
public Map<String, Object> uploadPluginEditedScript(
@ModelAttribute("accessToken") String accessToken,
@RequestBody ScenarioModel script) {
Map<String, Object> map = new HashMap<String, Object>();
if (script.getUsePlugins() == null
|| script.getUsePlugins().size() == 0) {
fail(map, "empty use plugin");
}
if (script.getBehaviors() == null || script.getBehaviors().size() == 0) {
fail(map, "empty behaviors");
}
RunScenarioModel runScenarioModel = this.getScriptService()
.createRunScenarioModel(script.getUsePlugins(),
script.getBehaviors());
String scenarioModel = MarshalHelper.tryMarshal(runScenarioModel);
logger.info(scenarioModel);
OperateScriptServerResponseModel operateScriptServerResponseModel = this
.getScriptMessager().uploadScript(accessToken,
script.getName(), scenarioModel, null);
if (operateScriptServerResponseModel.isSuccess()) {
return success(map);
} else {
logger.info("fail:"
+ operateScriptServerResponseModel.getFailCauseString());
return fail(map,
operateScriptServerResponseModel.getFailCauseString());
}
}
}

View File

@ -1,166 +1,180 @@
login=login
sign=sign
loginwith=Please login with your Username and Password.
welcometo=Welcome to Bench4Q
creattestplan=Creat TestPlan
scriptmanagement=Script Management
testhistory=Test History
creat=Creat
testplan=TestPlan
script=Script
management=Management
test=Test
history=History
creattestplanhead=Here you can run testplans and get the result!
creattestplancontent1=1.Create new scripts or load scripts to organize a testplan.
creattestplancontent2=2.Config the address of the systems under test.
startTest=Start Test
scriptmanagementhead=Here you can manage the scripts!
scriptmanagementcontent1=1.Create a new script and save it.
scriptmanagementcontent2=2.Edit a script in the scripts pool.
scriptmanagementcontent3=3.Delete a script in the scripts pool.
testhistoryhead=Here are the test history!
testhistorycontent1=Select a record ,you can view the scripts it contains,
testhistorycontent2=and,view the test result of it.
poweredby=Powered by
registerhead=Register your account.
registerbutton=Register
topfullwidth=Top Full Width
home=Home
creatatest=creat a test
charts=Charts
main=MAIN
chartwithpoints=Chart with points
scriptname=Script Name
datecreated=Date created
actions=Actions
settings=Add Script
agentManage_jsp_addAgent=Add Agent
portManage_jsp_addPort=Add Port
configuredmessage=Here settings can be configured
startserver=Start Server
stopserver=Stop Server
savefile=Save File
editscript=Edit Script
savechanges=Save
cancel=Cancel
close=Close
viewscript=View Script
creatascript=Creat a script
loadascript=Load a script
startthetest=Start the test
configthecluster=Config the System Under Test
systemundertest=System under test
inputip=please input the ip
add=Add
submit=Submit
selectparams=Select params
choosethescriptrecorded=Please choose the scripts from your script library .
selectascript=Select a script
choose=choose
testplanrunid=TestPlanRunId
createdatetime=Create
agentmanagement=Agent Management
portmanagement=Port Management
agents=Agents
hostname=HostName
port=Port
status=Status
maxload=MaxLoad
remainload=RemainLoad
warning=Warning
warningcontent1=You need to have
warningcontent2=enabled to use this site
agentmanage=Agent Manage
portmanage=Port Manage
pluginmanage=Plug-in Manage
pluginManage_jsp_plugin=plug-in
pluginManage_jsp_pluginName=plug-in Name
pluginManage_jsp_createDate=Date created
pluginManage_jsp_action=Actions
pluginManage_jsp_addPlugin=Add Plug-in
pluginManage_jsp_uploadFile=File to upload
homepage=Homepage
changetheme=Change Theme / Skin
classic=Classic
cerulean=Cerulean
cyborg=Cyborg
journal=Journal
profile=Profile
logout=Logout
visitsite=Visit Site
testResult=TestResult
scipt=Script
sut=SUT
selectscripts=Select Script
selectedScripts=Selected Scripts
next=Next
add=Add
clear=Clear
number=Number
testQueue=TestPlan Task
name=Name
nameTest=Input Testplan Name
admin=admin
result=test result
validate=validate
uploadScript=upload script
latestTest=Latest Tests
testName=Test Plan Name
empty=Can not be empty!
testPlanConfig=Load test execution plan
allocation=Allocation
total=Total
sutIp=SUT IP
addScript=Add Script
addIp=Add IP
testPlanName=Test Plan Name
plugin_jsp_addNewPlugin=Add a new plug-in
plugin_jsp_chooseBehaviors=Choose the behaviors of plug-in
plugin_jsp_removeAll=Remove All
plugin_jsp_remove=Remove
plugin_jsp_cancel=Cancel
plugin_jsp_save=Save
plugin_jsp_submit=Submit
plugin_jsp_insert=Insert
plugin_jsp_finish=Finish
plugin_jsp_add=Add
plugin_jsp_plugins=Plug-ins
plugin_jsp_behavior=Behavior
plugin_jsp_addScriptName=Please add ScriptName
plugin_jsp_scriptName=Script Name:
plugin_jsp_insertBefore=Insert Before
plugin_jsp_insertAfter=Insert After
plugin_jsp_clear=Clear
script_jsp_makeScript=ScriptEdit
script_jsp_recordScript=RecordScript
script_jsp_refresh=RefreshPage
test_jsp_makeNewScript=NewScript
index_jsp_register=Register
index_jsp_login=Login
index_jsp_Bench4Q_as_a_Service=Bench4Q_as_a_Service is based on Bench4Q project. We re-implemented Bench4Q tool as a service which can be deployed on the application server. Bench4Q supports elasticity and multi-tenancy which are promised in cloud computing.
index_jsp_Bench4Q=Bench4Q is a very new methodology for QoS oriented the E-commerce benchmarking.Bench4Q has many features to deduce the controllable and flexible representation of complex session-based workloads,and to simulate authentic customer behavior.
index_jsp_FreeRegister=Free register, signing, load test, real-time monitoring, analysis report download, view history data and much more ...
index_jsp_Title=Bench4Q is A Cloud-based Load Testing Platform
register_jsp_Title=Bench4Q is A Cloud-based Load Testing Platform
index_jsp_registerAndSign=Register and Sign
index_jsp_weAreFree=We are free!
login_jsp_home=Home
login_jsp_register=Register
login_jsp_Title=Bench4Q is a new methodology for QoS benchmarking
login_jsp_welcome=Welcome to Bench4Q!
login_jsp_signIn=Sign in
login_jsp_username=Username
login_jsp_usernameWarnning=The username cannot be empty!
login_jsp_password=Password
login_jsp_passwordWarnning=The password cannot be empty!
login_jsp_admin=Admin
register_jsp_admin=Admin
register_jsp_register=Register
register_jsp_clear=Clear
script_edit_jsp_save=Save
script_edit_jsp_cancel=Cancel
script_edit_jsp_validate=Validate
register_jsp_username=Username
register_jsp_password=Password
register_jsp_retype=Retype Password
login=login
sign=sign
loginwith=Please login with your Username and Password.
welcometo=Welcome to Bench4Q
creattestplan=Creat TestPlan
scriptmanagement=Script Management
testhistory=Test History
creat=Creat
testplan=TestPlan
script=Script
management=Management
test=Test
history=History
creattestplanhead=Here you can run testplans and get the result!
creattestplancontent1=1.Create new scripts or load scripts to organize a testplan.
creattestplancontent2=2.Config the address of the systems under test.
startTest=Start Test
scriptmanagementhead=Here you can manage the scripts!
scriptmanagementcontent1=1.Create a new script and save it.
scriptmanagementcontent2=2.Edit a script in the scripts pool.
scriptmanagementcontent3=3.Delete a script in the scripts pool.
testhistoryhead=Here are the test history!
testhistorycontent1=Select a record ,you can view the scripts it contains,
testhistorycontent2=and,view the test result of it.
poweredby=Powered by
registerhead=Register your account.
registerbutton=Register
topfullwidth=Top Full Width
home=Home
creatatest=creat a test
charts=Charts
main=MAIN
chartwithpoints=Chart with points
scriptname=Script Name
datecreated=Date created
actions=Actions
settings=Add Script
agentManage_jsp_addAgent=Add Agent
portManage_jsp_addPort=Add Port
configuredmessage=Here settings can be configured
startserver=Start Server
stopserver=Stop Server
savefile=Save File
editscript=Edit Script
savechanges=Save
cancel=Cancel
close=Close
viewscript=View Script
creatascript=Creat a script
loadascript=Load a script
startthetest=Start the test
configthecluster=Config the System Under Test
systemundertest=System under test
inputip=please input the ip
add=Add
submit=Submit
selectparams=Select params
choosethescriptrecorded=Please choose the scripts from your script library .
selectascript=Select a script
choose=choose
testplanrunid=TestPlanRunId
createdatetime=Create
agentmanagement=Agent Management
portmanagement=Port Management
agents=Agents
hostname=HostName
port=Port
status=Status
maxload=MaxLoad
remainload=RemainLoad
warning=Warning
warningcontent1=You need to have
warningcontent2=enabled to use this site
agentmanage=Agent Manage
portmanage=Port Manage
pluginmanage=Plug-in Manage
pluginManage_jsp_plugin=plug-in
pluginManage_jsp_pluginName=plug-in Name
pluginManage_jsp_createDate=Date created
pluginManage_jsp_action=Actions
pluginManage_jsp_addPlugin=Add Plug-in
pluginManage_jsp_uploadFile=File to upload
homepage=Homepage
changetheme=Change Theme / Skin
classic=Classic
cerulean=Cerulean
cyborg=Cyborg
journal=Journal
profile=Profile
logout=Logout
visitsite=Visit Site
testResult=TestResult
scipt=Script
sut=SUT
selectscripts=Select Script
selectedScripts=Selected Scripts
next=Next
add=Add
clear=Clear
number=Number
testQueue=TestPlan Task
name=Name
nameTest=Input Testplan Name
admin=admin
result=test result
validate=validate
uploadScript=upload script
latestTest=Latest Tests
testName=Test Plan Name
empty=Can not be empty!
testPlanConfig=Load test execution plan
allocation=Allocation
total=Total
sutIp=SUT IP
addScript=Add Script
addIp=Add IP
testPlanName=Test Plan Name
plugin_jsp_addNewPlugin=Add a new plug-in
plugin_jsp_chooseBehaviors=Choose the behaviors of plug-in
plugin_jsp_removeAll=Remove All
plugin_jsp_remove=Remove
plugin_jsp_cancel=Cancel
plugin_jsp_save=Save
plugin_jsp_submit=Submit
plugin_jsp_insert=Insert
plugin_jsp_finish=Finish
plugin_jsp_add=Add
plugin_jsp_plugins=Plug-ins
plugin_jsp_behavior=Behavior
plugin_jsp_addScriptName=Please add ScriptName
plugin_jsp_scriptName=Script Name:
plugin_jsp_insertBefore=Insert Before
plugin_jsp_insertAfter=Insert After
plugin_jsp_clear=Clear
script_jsp_makeScript=ScriptEdit
script_jsp_recordScript=RecordScript
script_jsp_refresh=RefreshPage
test_jsp_makeNewScript=NewScript
index_jsp_register=Register
index_jsp_login=Login
index_jsp_Bench4Q_as_a_Service=Bench4Q_as_a_Service is based on Bench4Q project. We re-implemented Bench4Q tool as a service which can be deployed on the application server. Bench4Q supports elasticity and multi-tenancy which are promised in cloud computing.
index_jsp_Bench4Q=Bench4Q is a very new methodology for QoS oriented the E-commerce benchmarking.Bench4Q has many features to deduce the controllable and flexible representation of complex session-based workloads,and to simulate authentic customer behavior.
index_jsp_FreeRegister=Free register, signing, load test, real-time monitoring, analysis report download, view history data and much more ...
index_jsp_Title=Bench4Q is A Cloud-based Load Testing Platform
register_jsp_Title=Bench4Q is A Cloud-based Load Testing Platform
index_jsp_registerAndSign=Register and Sign
index_jsp_weAreFree=We are free!
login_jsp_home=Home
login_jsp_register=Register
login_jsp_Title=Bench4Q is a new methodology for QoS benchmarking
login_jsp_welcome=Welcome to Bench4Q!
login_jsp_signIn=Sign in
login_jsp_username=Username
login_jsp_usernameWarnning=The username cannot be empty!
login_jsp_password=Password
login_jsp_passwordWarnning=The password cannot be empty!
login_jsp_admin=Admin
register_jsp_admin=Admin
register_jsp_register=Register
register_jsp_clear=Clear
script_edit_jsp_save=Save
script_edit_jsp_cancel=Cancel
script_edit_jsp_validate=Validate
register_jsp_username=Username
register_jsp_password=Password
register_jsp_retype=Retype Password
register_title=please commit your information
success-register=Congratulations! You have registered successfully!
register-count=seconds later, you will enter the login page!
test-warmUp=WarmUp
test-load=Load
test-coldDown=ColdDown
test-excuteRange=ExcuteRange
test-createTopology=Create Topology
result-addGraph=Add Graph
result-deleteGraph=Delete Graph
result-testStatus=Test Status
result-vuser=VUs Active
result-request=Requests
result-loadingInfo=Please wait,loading result data...

View File

@ -1,167 +1,181 @@
login=\u767B\u5F55
sign=\u6CE8\u518C
loginwith=\u8BF7\u8F93\u5165\u7528\u6237\u540D\u548C\u5BC6\u7801\u767B\u5F55\u7CFB\u7EDF
welcometo=\u6B22\u8FCE\u4F7F\u7528Bench4Q
creattestplan=\u65B0\u5EFA\u6D4B\u8BD5\u8BA1\u5212
scriptmanagement=\u811A\u672C\u7BA1\u7406
testhistory=\u6D4B\u8BD5\u5386\u53F2\u8BB0\u5F55
creat=\u65B0\u5EFA
testplan=\u6D4B\u8BD5\u8BA1\u5212
script=\u811A\u672C
management=\u7BA1\u7406
test=\u6D4B\u8BD5
history=\u5386\u53F2\u8BB0\u5F55
creattestplanhead=\u53EF\u6267\u884C\u6D4B\u8BD5\u8BA1\u5212\u5E76\u5F97\u5230\u6D4B\u8BD5\u7ED3\u679C\uFF01
creattestplancontent1=1.\u65B0\u5EFA\u6216\u8F7D\u5165\u811A\u672C\u521B\u5EFA\u6D4B\u8BD5\u8BA1\u5212\u3002
creattestplancontent2=2.\u914D\u7F6E\u5F85\u6D4B\u7CFB\u7EDF\u5730\u5740\u3002
creattestplancontent3=3.\u6267\u884C\u6D4B\u8BD5\u8BA1\u5212\u5E76\u5F97\u5230\u6D4B\u8BD5\u7ED3\u679C\u3002
scriptmanagementhead=\u53EF\u7BA1\u7406\u6D4B\u8BD5\u811A\u672C\uFF01
scriptmanagementcontent1=1.\u65B0\u5EFA\u5E76\u4FDD\u5B58\u4E00\u4E2A\u811A\u672C\u3002
scriptmanagementcontent2=2.\u5728\u811A\u672C\u6C60\u4E2D\u7F16\u8F91\u811A\u672C\u3002
scriptmanagementcontent3=3.\u4ECE\u811A\u672C\u6C60\u4E2D\u5220\u9664\u811A\u672C\u3002
testhistoryhead=\u53EF\u6D4F\u89C8\u6D4B\u8BD5\u5386\u53F2\u8BB0\u5F55\uFF01
testhistorycontent1=\u9009\u62E9\u4E00\u6761\u8BB0\u5F55\uFF0C\u53EF\u6D4F\u89C8\u5176\u4E2D\u6240\u5305\u542B\u811A\u672C\uFF0C
testhistorycontent2=\u53CA\u76F8\u5E94\u6D4B\u8BD5\u7ED3\u679C\u3002
poweredby=\u6280\u672F\u652F\u6301
registerhead=\u6CE8\u518C\u4E2A\u4EBA\u8D26\u6237
registerbutton=\u6CE8\u518C
topfullwidth=\u5C55\u5F00\u9875\u9762\u9876\u90E8
home=\u4E3B\u9875
creatatest=\u65B0\u5EFA\u6D4B\u8BD5
charts=\u56FE\u8868
main=\u4E3B\u83DC\u5355
chartwithpoints=\u6563\u70B9\u56FE\u8868
scriptname=\u811A\u672C\u540D\u79F0
datecreated=\u521B\u5EFA\u65E5\u671F
actions=\u64CD\u4F5C
settings=\u6DFB\u52A0\u811A\u672C
agentManage_jsp_addAgent=\u6DFB\u52A0\u4EE3\u7406
portManage_jsp_addPort=\u6DFB\u52A0\u7AEF\u53E3
configuredmessage=\u5728\u8FD9\u91CC\u53EF\u4EE5\u914D\u7F6E
startserver=\u542F\u52A8\u670D\u52A1\u5668
stopserver=\u505C\u6B62\u670D\u52A1\u5668
savefile=\u4FDD\u5B58\u6587\u4EF6
editscript=\u7F16\u8F91\u811A\u672C
savechanges=\u4FDD\u5B58
cancel=\u53D6\u6D88
close=\u5173\u95ED
viewscript=\u6D4F\u89C8\u811A\u672C
creatascript=\u65B0\u5EFA\u811A\u672C
loadascript=\u52A0\u8F7D\u5DF2\u6709\u811A\u672C
startthetest=\u5F00\u59CB\u6D4B\u8BD5
configthecluster=\u914D\u7F6E\u5F85\u6D4B\u7CFB\u7EDF
systemundertest=\u88AB\u6D4B\u7CFB\u7EDF
inputip=\u8BF7\u8F93\u5165ip\u5730\u5740
add=\u589E\u52A0
submit=\u786E\u8BA4
selectparams=\u9009\u62E9\u53C2\u6570
choosethescriptrecorded=\u8BF7\u9009\u62E9\u811A\u672C
selectascript=\u9009\u62E9\u4E00\u4E2A\u811A\u672C
choose=\u9009\u62E9
testplanrunid=\u8FD0\u884CID
createdatetime=\u521B\u5EFA
agentmanagement=\u4EE3\u7406\u7BA1\u7406
portmanagement=\u7AEF\u53E3\u7BA1\u7406
agents=\u4EE3\u7406
hostname=\u4E3B\u673A\u540D
port=\u7AEF\u53E3
status=\u72B6\u6001
maxload=\u6700\u5927\u8D1F\u8F7D
remainload=\u5269\u4F59\u8D1F\u8F7D
warning=\u63D0\u793A
warningcontent1=\u9700\u8981\u652F\u6301
warningcontent2=\u4F7F\u7F51\u9875\u53EF\u4EE5\u6B63\u5E38\u663E\u793A
agentmanage=\u4EE3\u7406\u7BA1\u7406
portmanage=\u7AEF\u53E3\u7BA1\u7406
pluginmanage=\u63D2\u4EF6\u7BA1\u7406
pluginManage_jsp_plugin=\u63D2\u4EF6
pluginManage_jsp_pluginName=\u63D2\u4EF6\u540D\u79F0
pluginManage_jsp_createDate=\u521B\u5EFA\u65E5\u671F
pluginManage_jsp_action=\u64CD\u4F5C
pluginManage_jsp_addPlugin=\u6DFB\u52A0\u63D2\u4EF6
pluginManage_jsp_uploadFile=\u4E0A\u4F20\u6587\u4EF6
homepage=\u4E3B\u9875
changetheme=\u66F4\u6362\u4E3B\u9898\ / \u76AE\u80A4
classic=\u7ECF\u5178\u6837\u5F0F
cerulean=\u5929\u84DD\u8272
cyborg=\u7535\u5B50
journal=\u65E5\u5FD7
profile=\u5F62\u8C61
logout=\u6CE8\u9500
visitsite=\u8BBF\u95EE\u7AD9\u70B9
testResult=\u6D4B\u8BD5\u7ED3\u679C
script=\u811A\u672C
sut=\u5F85\u6D4B\u7CFB\u7EDF
selectscripts=\u9009\u62E9\u811A\u672C
selectedScripts=\u5DF2\u9009\u811A\u672C
next=\u4E0B\u4E00\u6B65
add=\u6DFB\u52A0
clear=\u6E05\u9664
number=\u5E8F\u53F7
testQueue=\u6D4B\u8BD5\u4EFB\u52A1
name=\u540D\u5B57
nameTest=\u8F93\u5165\u6D4B\u8BD5\u8BA1\u5212\u540D\u79F0
admin=\u7BA1\u7406\u5458
result=\u6D4B\u8BD5\u7ED3\u679C
validate=\u9A8C\u8BC1
uploadScript=\u4E0A\u4F20\u811A\u672C
latestTest=\u6700\u8FD1\u6D4B\u8BD5
testName=\u6D4B\u8BD5\u8BA1\u5212\u540D\u79F0
empty=\u4E0D\u80FD\u4E3A\u7A7A
testPlanConfig=\u914D\u7F6E\u6D4B\u8BD5\u8BA1\u5212
allocation=\u6BD4\u4F8B
total=\u603B\u5171
sutIp=\u5F85\u6D4B\u7CFB\u7EDFIP
addScript=\u6DFB\u52A0\u811A\u672C
addIp=\u6DFB\u52A0\IP
startTest=\u5F00\u59CB\u6D4B\u8BD5
testPlanName=\u6D4B\u8BD5\u540D\u79F0
plugin_jsp_addNewPlugin=\u6DFB\u52A0\u4E00\u4E2A\u65B0\u7684\u63D2\u4EF6
plugin_jsp_chooseBehaviors=\u9009\u62E9\u63D2\u4EF6\u7684\u52A8\u4F5C
plugin_jsp_removeAll=\u5168\u90E8\u79FB\u9664
plugin_jsp_remove=\u79FB\u9664
plugin_jsp_cancel=\u53D6\u6D88
plugin_jsp_save=\u4FDD\u5B58
plugin_jsp_submit=\u63D0\u4EA4
plugin_jsp_insert=\u5BFC\u5165\u63D2\u4EF6
plugin_jsp_finish=\u5B8C\u6210
plugin_jsp_add=\u6DFB\u52A0
plugin_jsp_plugins=\u63D2\u4EF6
plugin_jsp_behavior=\u52A8\u4F5C
plugin_jsp_addScriptName=\u8BF7\u8F93\u5165\u811A\u672C\u540D
plugin_jsp_scriptName=\u811A\u672C\u540D\uFF1A
plugin_jsp_insertBefore=\u524D\u5BFC\u5165
plugin_jsp_insertAfter=\u540E\u5BFC\u5165
plugin_jsp_clear=\u6E05\u7A7A
script_jsp_makeScript=\u811A\u672C\u7F16\u8F91
script_jsp_recordScript=\u5F55\u5236\u811A\u672C
script_jsp_refresh=\u5237\u65B0\u9875\u9762
test_jsp_makeNewScript=\u65B0\u5EFA\u811A\u672C
index_jsp_Bench4Q_as_a_Service=Bench4Q_as_a_Service \u662F\u57FA\u4E8EBench4Q\u9879\u76EE\u5B9E\u73B0\u7684\u3002\u6211\u4EEC\u91CD\u65B0\u5B9E\u73B0\u4E86Bench4Q\u5DE5\u5177\uFF0C\u4F7F\u5B83\u53EF\u4EE5\u4F5C\u4E3A\u4E00\u79CD\u670D\u52A1\u88AB\u90E8\u7F72\u5230\u5E94\u7528\u670D\u52A1\u5668\u4E0A\u3002Bench4Q\u652F\u6301\u4E91\u8BA1\u7B97\u6240\u63D0\u4F9B\u7684\u5F39\u6027\u548C\u591A\u79DF\u6237\u529F\u80FD\u3002
index_jsp_Bench4Q=Bench4Q\u5728\u8FD0\u7528\u4E91\u8BA1\u7B97\u6280\u672F\u7684\u540C\u65F6\uFF0C\u589E\u5F3A\u4E86\u5BF9\u4E8E\u8D1F\u8F7D\u6CE8\u5165\u4EE3\u7406\u6C60\u7684\u63A7\u5236\u548C\u7BA1\u7406\uFF0C\u52A0\u4E4B\u4EE5\u8D1F\u8F7D\u6CE8\u5165\u4EE3\u7406\u7684\u63D2\u4EF6\u5316\u7075\u6D3B\u6269\u5C55\uFF0C\u4F7F\u5F97\u5927\u89C4\u6A21\u6027\u80FD\u6D4B\u8BD5\u6210\u4E3A\u4EF7\u683C\u66F4\u4E3A\u4F4E\u5EC9\u3001\u66F4\u4E3A\u5B9E\u60E0\u7684\u9700\u6C42\u3002
index_jsp_FreeRegister=\u514D\u8D39\u6CE8\u518C\uFF0C\u8BA4\u8BC1\uFF0C\u4E0B\u8F7D\u6D4B\u8BD5\uFF0C\u5B9E\u65F6\u76D1\u63A7\uFF0C\u5206\u6790\u62A5\u544A\u4E0B\u8F7D\uFF0C\u67E5\u770B\u5386\u53F2\u6570\u636E...
index_jsp_Title=Bench4Q\u2014\u2014\u57FA\u4E8E\u4E91\u7684\u6D4B\u8BD5\u4E0B\u8F7D\u5E73\u53F0
register_jsp_Title=Bench4Q\u2014\u2014\u57FA\u4E8E\u4E91\u7684\u6D4B\u8BD5\u4E0B\u8F7D\u5E73\u53F0
index_jsp_register=\u6CE8\u518C
index_jsp_login=\u767B\u5F55
index_jsp_registerAndSign=\u6CE8\u518C\u5E76\u8BA4\u8BC1
index_jsp_weAreFree=\u6211\u4EEC\u662F\u514D\u8D39\u7684\u54DF\uFF01
login_jsp_home=\u4E3B\u9875
login_jsp_register=\u6CE8\u518C
login_jsp_Title=Bench4Q \u2014\u2014 QOS\u57FA\u51C6\u6D4B\u8BD5\u7684\u65B0\u65B9\u6CD5
login_jsp_welcome=\u6B22\u8FCE\u4F7F\u7528Bench4Q\uFF01
login_jsp_signIn=\u767B\u5F55
login_jsp_username=\u7528\u6237\u540D
login_jsp_usernameWarnning=\u7528\u6237\u540D\u4E0D\u80FD\u4E3A\u7A7A\uFF01
login_jsp_password=\u5BC6\u7801
login_jsp_passwordWarnning=\u5BC6\u7801\u4E0D\u80FD\u4E3A\u7A7A\uFF01
login_jsp_admin=\u7BA1\u7406\u5458
script_edit_jsp_save=\u4FDD\u5B58
script_edit_jsp_cancel=\u53D6\u6D88
script_edit_jsp_validate=\u786E\u8BA4
register_jsp_username=\u7528\u6237\u540D
register_jsp_password=\u5BC6 \u7801
register_jsp_retype=\u91CD \u8F93
register_jsp_admin=\u7BA1\u7406\u5458
register_jsp_register=\u6CE8\u518C
register_jsp_clear=\u6E05\u695A
login=\u767B\u5F55
sign=\u6CE8\u518C
loginwith=\u8BF7\u8F93\u5165\u7528\u6237\u540D\u548C\u5BC6\u7801\u767B\u5F55\u7CFB\u7EDF
welcometo=\u6B22\u8FCE\u4F7F\u7528Bench4Q
creattestplan=\u65B0\u5EFA\u6D4B\u8BD5\u8BA1\u5212
scriptmanagement=\u811A\u672C\u7BA1\u7406
testhistory=\u6D4B\u8BD5\u5386\u53F2\u8BB0\u5F55
creat=\u65B0\u5EFA
testplan=\u6D4B\u8BD5\u8BA1\u5212
script=\u811A\u672C
management=\u7BA1\u7406
test=\u6D4B\u8BD5
history=\u5386\u53F2\u8BB0\u5F55
creattestplanhead=\u53EF\u6267\u884C\u6D4B\u8BD5\u8BA1\u5212\u5E76\u5F97\u5230\u6D4B\u8BD5\u7ED3\u679C\uFF01
creattestplancontent1=1.\u65B0\u5EFA\u6216\u8F7D\u5165\u811A\u672C\u521B\u5EFA\u6D4B\u8BD5\u8BA1\u5212\u3002
creattestplancontent2=2.\u914D\u7F6E\u5F85\u6D4B\u7CFB\u7EDF\u5730\u5740\u3002
creattestplancontent3=3.\u6267\u884C\u6D4B\u8BD5\u8BA1\u5212\u5E76\u5F97\u5230\u6D4B\u8BD5\u7ED3\u679C\u3002
scriptmanagementhead=\u53EF\u7BA1\u7406\u6D4B\u8BD5\u811A\u672C\uFF01
scriptmanagementcontent1=1.\u65B0\u5EFA\u5E76\u4FDD\u5B58\u4E00\u4E2A\u811A\u672C\u3002
scriptmanagementcontent2=2.\u5728\u811A\u672C\u6C60\u4E2D\u7F16\u8F91\u811A\u672C\u3002
scriptmanagementcontent3=3.\u4ECE\u811A\u672C\u6C60\u4E2D\u5220\u9664\u811A\u672C\u3002
testhistoryhead=\u53EF\u6D4F\u89C8\u6D4B\u8BD5\u5386\u53F2\u8BB0\u5F55\uFF01
testhistorycontent1=\u9009\u62E9\u4E00\u6761\u8BB0\u5F55\uFF0C\u53EF\u6D4F\u89C8\u5176\u4E2D\u6240\u5305\u542B\u811A\u672C\uFF0C
testhistorycontent2=\u53CA\u76F8\u5E94\u6D4B\u8BD5\u7ED3\u679C\u3002
poweredby=\u6280\u672F\u652F\u6301
registerhead=\u6CE8\u518C\u4E2A\u4EBA\u8D26\u6237
registerbutton=\u6CE8\u518C
topfullwidth=\u5C55\u5F00\u9875\u9762\u9876\u90E8
home=\u4E3B\u9875
creatatest=\u65B0\u5EFA\u6D4B\u8BD5
charts=\u56FE\u8868
main=\u4E3B\u83DC\u5355
chartwithpoints=\u6563\u70B9\u56FE\u8868
scriptname=\u811A\u672C\u540D\u79F0
datecreated=\u521B\u5EFA\u65E5\u671F
actions=\u64CD\u4F5C
settings=\u6DFB\u52A0\u811A\u672C
agentManage_jsp_addAgent=\u6DFB\u52A0\u4EE3\u7406
portManage_jsp_addPort=\u6DFB\u52A0\u7AEF\u53E3
configuredmessage=\u5728\u8FD9\u91CC\u53EF\u4EE5\u914D\u7F6E
startserver=\u542F\u52A8\u670D\u52A1\u5668
stopserver=\u505C\u6B62\u670D\u52A1\u5668
savefile=\u4FDD\u5B58\u6587\u4EF6
editscript=\u7F16\u8F91\u811A\u672C
savechanges=\u4FDD\u5B58
cancel=\u53D6\u6D88
close=\u5173\u95ED
viewscript=\u6D4F\u89C8\u811A\u672C
creatascript=\u65B0\u5EFA\u811A\u672C
loadascript=\u52A0\u8F7D\u5DF2\u6709\u811A\u672C
startthetest=\u5F00\u59CB\u6D4B\u8BD5
configthecluster=\u914D\u7F6E\u5F85\u6D4B\u7CFB\u7EDF
systemundertest=\u88AB\u6D4B\u7CFB\u7EDF
inputip=\u8BF7\u8F93\u5165ip\u5730\u5740
add=\u589E\u52A0
submit=\u786E\u8BA4
selectparams=\u9009\u62E9\u53C2\u6570
choosethescriptrecorded=\u8BF7\u9009\u62E9\u811A\u672C
selectascript=\u9009\u62E9\u4E00\u4E2A\u811A\u672C
choose=\u9009\u62E9
testplanrunid=\u8FD0\u884CID
createdatetime=\u521B\u5EFA
agentmanagement=\u4EE3\u7406\u7BA1\u7406
portmanagement=\u7AEF\u53E3\u7BA1\u7406
agents=\u4EE3\u7406
hostname=\u4E3B\u673A\u540D
port=\u7AEF\u53E3
status=\u72B6\u6001
maxload=\u6700\u5927\u8D1F\u8F7D
remainload=\u5269\u4F59\u8D1F\u8F7D
warning=\u63D0\u793A
warningcontent1=\u9700\u8981\u652F\u6301
warningcontent2=\u4F7F\u7F51\u9875\u53EF\u4EE5\u6B63\u5E38\u663E\u793A
agentmanage=\u4EE3\u7406\u7BA1\u7406
portmanage=\u7AEF\u53E3\u7BA1\u7406
pluginmanage=\u63D2\u4EF6\u7BA1\u7406
pluginManage_jsp_plugin=\u63D2\u4EF6
pluginManage_jsp_pluginName=\u63D2\u4EF6\u540D\u79F0
pluginManage_jsp_createDate=\u521B\u5EFA\u65E5\u671F
pluginManage_jsp_action=\u64CD\u4F5C
pluginManage_jsp_addPlugin=\u6DFB\u52A0\u63D2\u4EF6
pluginManage_jsp_uploadFile=\u4E0A\u4F20\u6587\u4EF6
homepage=\u4E3B\u9875
changetheme=\u66F4\u6362\u4E3B\u9898\ / \u76AE\u80A4
classic=\u7ECF\u5178\u6837\u5F0F
cerulean=\u5929\u84DD\u8272
cyborg=\u7535\u5B50
journal=\u65E5\u5FD7
profile=\u5F62\u8C61
logout=\u6CE8\u9500
visitsite=\u8BBF\u95EE\u7AD9\u70B9
testResult=\u6D4B\u8BD5\u7ED3\u679C
script=\u811A\u672C
sut=\u5F85\u6D4B\u7CFB\u7EDF
selectscripts=\u9009\u62E9\u811A\u672C
selectedScripts=\u5DF2\u9009\u811A\u672C
next=\u4E0B\u4E00\u6B65
add=\u6DFB\u52A0
clear=\u6E05\u9664
number=\u5E8F\u53F7
testQueue=\u6D4B\u8BD5\u4EFB\u52A1
name=\u540D\u5B57
nameTest=\u8F93\u5165\u6D4B\u8BD5\u8BA1\u5212\u540D\u79F0
admin=\u7BA1\u7406\u5458
result=\u6D4B\u8BD5\u7ED3\u679C
validate=\u9A8C\u8BC1
uploadScript=\u4E0A\u4F20\u811A\u672C
latestTest=\u6700\u8FD1\u6D4B\u8BD5
testName=\u6D4B\u8BD5\u8BA1\u5212\u540D\u79F0
empty=\u4E0D\u80FD\u4E3A\u7A7A
testPlanConfig=\u914D\u7F6E\u6D4B\u8BD5\u8BA1\u5212
allocation=\u6BD4\u4F8B
total=\u603B\u5171
sutIp=\u5F85\u6D4B\u7CFB\u7EDFIP
addScript=\u6DFB\u52A0\u811A\u672C
addIp=\u6DFB\u52A0\IP
startTest=\u5F00\u59CB\u6D4B\u8BD5
testPlanName=\u6D4B\u8BD5\u540D\u79F0
plugin_jsp_addNewPlugin=\u6DFB\u52A0\u4E00\u4E2A\u65B0\u7684\u63D2\u4EF6
plugin_jsp_chooseBehaviors=\u9009\u62E9\u63D2\u4EF6\u7684\u52A8\u4F5C
plugin_jsp_removeAll=\u5168\u90E8\u79FB\u9664
plugin_jsp_remove=\u79FB\u9664
plugin_jsp_cancel=\u53D6\u6D88
plugin_jsp_save=\u4FDD\u5B58
plugin_jsp_submit=\u63D0\u4EA4
plugin_jsp_insert=\u5BFC\u5165\u63D2\u4EF6
plugin_jsp_finish=\u5B8C\u6210
plugin_jsp_add=\u6DFB\u52A0
plugin_jsp_plugins=\u63D2\u4EF6
plugin_jsp_behavior=\u52A8\u4F5C
plugin_jsp_addScriptName=\u8BF7\u8F93\u5165\u811A\u672C\u540D
plugin_jsp_scriptName=\u811A\u672C\u540D\uFF1A
plugin_jsp_insertBefore=\u524D\u5BFC\u5165
plugin_jsp_insertAfter=\u540E\u5BFC\u5165
plugin_jsp_clear=\u6E05\u7A7A
script_jsp_makeScript=\u811A\u672C\u7F16\u8F91
script_jsp_recordScript=\u5F55\u5236\u811A\u672C
script_jsp_refresh=\u5237\u65B0\u9875\u9762
test_jsp_makeNewScript=\u65B0\u5EFA\u811A\u672C
index_jsp_Bench4Q_as_a_Service=Bench4Q_as_a_Service \u662F\u57FA\u4E8EBench4Q\u9879\u76EE\u5B9E\u73B0\u7684\u3002\u6211\u4EEC\u91CD\u65B0\u5B9E\u73B0\u4E86Bench4Q\u5DE5\u5177\uFF0C\u4F7F\u5B83\u53EF\u4EE5\u4F5C\u4E3A\u4E00\u79CD\u670D\u52A1\u88AB\u90E8\u7F72\u5230\u5E94\u7528\u670D\u52A1\u5668\u4E0A\u3002Bench4Q\u652F\u6301\u4E91\u8BA1\u7B97\u6240\u63D0\u4F9B\u7684\u5F39\u6027\u548C\u591A\u79DF\u6237\u529F\u80FD\u3002
index_jsp_Bench4Q=Bench4Q\u5728\u8FD0\u7528\u4E91\u8BA1\u7B97\u6280\u672F\u7684\u540C\u65F6\uFF0C\u589E\u5F3A\u4E86\u5BF9\u4E8E\u8D1F\u8F7D\u6CE8\u5165\u4EE3\u7406\u6C60\u7684\u63A7\u5236\u548C\u7BA1\u7406\uFF0C\u52A0\u4E4B\u4EE5\u8D1F\u8F7D\u6CE8\u5165\u4EE3\u7406\u7684\u63D2\u4EF6\u5316\u7075\u6D3B\u6269\u5C55\uFF0C\u4F7F\u5F97\u5927\u89C4\u6A21\u6027\u80FD\u6D4B\u8BD5\u6210\u4E3A\u4EF7\u683C\u66F4\u4E3A\u4F4E\u5EC9\u3001\u66F4\u4E3A\u5B9E\u60E0\u7684\u9700\u6C42\u3002
index_jsp_FreeRegister=\u514D\u8D39\u6CE8\u518C\uFF0C\u8BA4\u8BC1\uFF0C\u4E0B\u8F7D\u6D4B\u8BD5\uFF0C\u5B9E\u65F6\u76D1\u63A7\uFF0C\u5206\u6790\u62A5\u544A\u4E0B\u8F7D\uFF0C\u67E5\u770B\u5386\u53F2\u6570\u636E...
index_jsp_Title=Bench4Q\u2014\u2014\u57FA\u4E8E\u4E91\u7684\u6D4B\u8BD5\u4E0B\u8F7D\u5E73\u53F0
register_jsp_Title=Bench4Q\u2014\u2014\u57FA\u4E8E\u4E91\u7684\u6D4B\u8BD5\u4E0B\u8F7D\u5E73\u53F0
index_jsp_register=\u6CE8\u518C
index_jsp_login=\u767B\u5F55
index_jsp_registerAndSign=\u6CE8\u518C\u5E76\u8BA4\u8BC1
index_jsp_weAreFree=\u6211\u4EEC\u662F\u514D\u8D39\u7684\u54DF\uFF01
login_jsp_home=\u4E3B\u9875
login_jsp_register=\u6CE8\u518C
login_jsp_Title=Bench4Q \u2014\u2014 QOS\u57FA\u51C6\u6D4B\u8BD5\u7684\u65B0\u65B9\u6CD5
login_jsp_welcome=\u6B22\u8FCE\u4F7F\u7528Bench4Q\uFF01
login_jsp_signIn=\u767B\u5F55
login_jsp_username=\u7528\u6237\u540D
login_jsp_usernameWarnning=\u7528\u6237\u540D\u4E0D\u80FD\u4E3A\u7A7A\uFF01
login_jsp_password=\u5BC6\u7801
login_jsp_passwordWarnning=\u5BC6\u7801\u4E0D\u80FD\u4E3A\u7A7A\uFF01
login_jsp_admin=\u7BA1\u7406\u5458
script_edit_jsp_save=\u4FDD\u5B58
script_edit_jsp_cancel=\u53D6\u6D88
script_edit_jsp_validate=\u786E\u8BA4
register_jsp_username=\u7528\u6237\u540D
register_jsp_password=\u5BC6 \u7801
register_jsp_retype=\u91CD \u8F93
register_jsp_admin=\u7BA1\u7406\u5458
register_jsp_register=\u6CE8\u518C
register_jsp_clear=\u6E05\u695A
register_title=\u8BF7\u586B\u5199\u6CE8\u518C\u4FE1\u606F
success-register=\u6CE8\u518C\u6210\u529F
register-count=\u6B63\u5728\u8DF3\u8F6C\u5230\u767B\u9646\u9875\u9762
test-warmUp=\u9884\u70ED\u65F6\u95F4
test-load=\u8D1F\u8F7D\u91CF
test-coldDown=\u51B7\u5374\u65F6\u95F4
test-excuteRange=\u6267\u884C\u65F6\u95F4
test-createTopology=\u65B0\u5EFA\u62D3\u6251
result-addGraph=\u6DFB\u52A0\u56FE
result-deleteGraph=\u5220\u9664\u56FE
result-testStatus=\u6D4B\u8BD5\u72B6\u6001
result-vuser=\u5E76\u53D1\u7528\u6237
result-request=\u53D1\u9001\u8BF7\u6C42
result-loadingInfo=\u8BF7\u7A0D\u7B49\uFF0C\u6B63\u5728\u52A0\u8F7D\u6570\u636E

View File

@ -1,6 +1,28 @@
addField=Add Field
removeField=Remove Field
addCol=addCol
removeCol=removeCol
save=Save
cancel=Cancel
addField=Add Field
removeField=Remove Field
addCol=addCol
removeCol=removeCol
save=Save
cancel=Cancel
agent-InIdle=InIdle
agent-InRunning=InRunning
agent-BackUp=BackUp
agent-BreakDown=BreakDown
delete=Delete
report=Report
test-loadSchedule=Load Schedule
result-testResult=Test Result
result-script=Script
result-scriptResult=Script Result
result-SUT=SUT
result-sutResult=SUT Result
test-NotStart=NotStart
test-ApplyForLoad=ApplyForLoad
test-DistributeScriptAndParams=DistributeScriptAndParams
test-InRunning=InRunning
test-PendingNoEnoughMaxLoad=PendingNoEnoughMaxLoad
test-PendingNoEnoughCurrentLoad=PendingNoEnoughCurrentLoad
test-Error=Error
test-ErrorInSubmitTask=ErrorInSubmitTask
test-ErrorInDistributeLoadForScript=ErrorInDistributeLoadForScript
test-Complete=Complete

View File

@ -1,6 +1,23 @@
addField=\u6DFB\u52A0\u57DF
removeField=\u79FB\u9664\u57DF
addCol=\u6DFB\u52A0\u884C
removeCol=\u79FB\u9664\u884C
cancel=\u53D6\u6D88
save=\u4FDD\u5B58
addField=\u6DFB\u52A0\u57DF
removeField=\u79FB\u9664\u57DF
addCol=\u6DFB\u52A0\u884C
removeCol=\u79FB\u9664\u884C
cancel=\u53D6\u6D88
save=\u4FDD\u5B58
agent-InIdle=\u7A7A\u95F2
agent-InRunning=\u6B63\u5728\u8FD0\u884C
agent-BackUp=\u5907\u4EFD
agent-BreakDown=\u5B95\u673A
delete=\u5220\u9664
report=\u62A5\u544A
test-loadSchedule=\u8D1F\u8F7D\u573A\u666F
test-NotStart=\u7B49\u5F85
test-ApplyForLoad=\u5206\u914D\u8D44\u6E90
test-DistributeScriptAndParams=\u51C6\u5907\u73AF\u5883
test-InRunning=\u8FD0\u884C
test-PendingNoEnoughMaxLoad=\u8D44\u6E90\u4E0D\u8DB3
test-PendingNoEnoughCurrentLoad=\u7B49\u5F85\u8D44\u6E90
test-Error=\u9519\u8BEF
test-ErrorInSubmitTask=\u63D0\u4EA4\u9519\u8BEF
test-ErrorInDistributeLoadForScript=\u5206\u53D1\u6587\u4EF6\u9519\u8BEF
test-Complete=\u5B8C\u6210

View File

@ -1,188 +1,206 @@
<!DOCTYPE html>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style type="text/css">
body {
padding-bottom: 40px;
}
.sidebar-nav {
padding: 9px 0;
}
</style>
<title>Bench4q 2013</title>
<link id="bs-css" href="lib/chrisma/css/bootstrap-cerulean.css"
rel="stylesheet">
<link href="lib/chrisma/css/charisma-app.css" rel="stylesheet">
<link
href="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.8.10/themes/redmond/jquery-ui.css"
rel="stylesheet">
<link href='css/result.css' rel='stylesheet'>
<link rel="shortcut icon" href="images/bench4q.png">
</head>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<body>
<fmt:bundle basename="i18n">
<jsp:include page="publiccontrol/navigatebar.jsp"></jsp:include>
<div class="container-fluid">
<div class="row-fluid">
<jsp:include page="publiccontrol/leftmenubar.jsp"></jsp:include>
<div id="content" class="span10 ">
<!-- content starts -->
<div>
<ul class="breadcrumb">
<li><a href="homepage.jsp"><fmt:message key="home" /></a> <span
class="divider">/</span></li>
<li><a href="test.jsp"><fmt:message key="creatatest" /></a><span
class="divider">/</span></li>
<li><a href="#"><fmt:message key="result" /></a></li>
</ul>
</div>
<div class="row-fluid" id="test">
<div class="span4 span-brief" id="status">
Test Status<br /> <br>
</div>
<div class="span4 span-brief" id="vu">
VUs active<br /> <br>
</div>
<div class="span4 span-brief-last" id="request">
Requests<br /> <br>
</div>
</div>
<div class="row-fluid">
<h4 class="pull-left">Charts</h4>
<div class="field-inline">
<button type="button" class="btn btn-primary " id="del-graph">Delete
Graph</button>
</div>
<div class="field-inline">
<button type="button" class="btn btn-primary " id="add-graph">Add
Graph</button>
</div>
</div>
<div class="app-container " id="chart"></div>
<div class="row-fluid">
<h4 class="pull-left">Pages</h4>
</div>
<div class="app-container">
<table id="page"
class="table table-striped table-bordered bootstrap-datatable datatable">
<thead>
<tr>
<th>Page</th>
<th>Script</th>
<th>Count</th>
<th>Test Min</th>
<th>Test Max</th>
<th>Average</th>
<th>Last</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
<div class="row-fluid">
<h4 class="pull-left">Urls</h4>
</div>
<div class="app-container dataTables_wrapper">
<table id="url"
class="table table-striped table-bordered bootstrap-datatable datatable">
<thead>
<tr>
<th></th>
<th>URL</th>
<th>Script</th>
<th>Successful</th>
<th>Total</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
<div class="app-container" id="url-distribution"></div>
</div>
</div>
</div>
<div class="modal hide fade" id="add-graph-modal">
<div class="modal-header">
<button type="button" id="myModal-close" class="close"
data-dismiss="modal">x</button>
<h3>Add Graph</h3>
</div>
<div class="modal-body" id="add-graph-list"></div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" id="add-graph-add"
data-dismiss="modal">add</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">cancel</button>
</div>
</div>
<div class="modal hide fade" id="del-graph-modal">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">x</button>
<h3>Delete Graph</h3>
</div>
<div class="modal-body" id="del-graph-list"></div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" id="del-graph-del"
data-dismiss="modal">delete</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">cancel</button>
</div>
</div>
<div class="modal hide fade" id="load">
<div class="modal-header">
<h3>Please wait,loading result data...</h3>
</div>
<div class="modal-body">
<div id="loading">
<div></div>
</div>
</div>
<div class="modal-footer">
<button type="button" id="cancelLoading" class="btn btn-primary ">cancel</button>
</div>
</div>
<hr>
<jsp:include page="publiccontrol/footer.jsp"></jsp:include>
<script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-2.1.0.js"></script>
<script
src="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.10.4/jquery-ui.min.js"></script>
<script src="lib/jqueryi18n/jquery.i18n.properties-1.0.9.js"></script>
<script src="lib/bootstrap/js/bootstrap-modal.js"></script>
<script
src="http://ajax.aspnetcdn.com/ajax/bootstrap/2.3.1/bootstrap.min.js"></script>
<script src="lib/chrisma/js/jquery.cookie.js"></script>
<script
src='http://ajax.aspnetcdn.com/ajax/jquery.dataTables/1.9.4/jquery.dataTables.js'></script>
<script src="lib/chrisma/js/theme.js"></script>
<script src="lib/chrisma/js/jquery.cookie.js"></script>
<script src="script/base.js"></script>
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="script/testResult/charts.js"></script>
<script src="script/testResult/testBriefResult.js"></script>
<script src="script/bench4q.table.js"></script>
<script src="script/testResult/behaviorAndPage.js"></script>
<script src="script/testResult/highChartTheme.js"></script>
<script src="script/testResult/result-tree.js"></script>
<script src="script/testResult/resultInfo.js"></script>
<script src="script/testResult/chartSelector.js"></script>
<script src="script/testResult/pieChart.js"></script>
<script src="script/testResult/result-load.js"></script>
<script src="script/testResult/result.js"></script>
</fmt:bundle>
</body>
<!DOCTYPE html>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style type="text/css">
body {
padding-bottom: 40px;
}
.sidebar-nav {
padding: 9px 0;
}
</style>
<title>Bench4q 2013</title>
<link id="bs-css" href="lib/chrisma/css/bootstrap-cerulean.css"
rel="stylesheet">
<link href="lib/chrisma/css/charisma-app.css" rel="stylesheet">
<link
href="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.8.10/themes/redmond/jquery-ui.css"
rel="stylesheet">
<link href='css/result.css' rel='stylesheet'>
<link rel="shortcut icon" href="images/bench4q.png">
</head>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<body>
<fmt:bundle basename="i18n">
<jsp:include page="publiccontrol/navigatebar.jsp"></jsp:include>
<div class="container-fluid">
<div class="row-fluid">
<jsp:include page="publiccontrol/leftmenubar.jsp"></jsp:include>
<div id="content" class="span10 ">
<!-- content starts -->
<div>
<ul class="breadcrumb">
<li><a href="homepage.jsp"><fmt:message key="home" /></a> <span
class="divider">/</span></li>
<li><a href="test.jsp"><fmt:message key="creatatest" /></a><span
class="divider">/</span></li>
<li><a href="#"><fmt:message key="result" /></a></li>
</ul>
</div>
<div class="row-fluid" id="test">
<div class="span4 span-brief" id="status">
<fmt:message key="result-testStatus" />
<br /> <br>
</div>
<div class="span4 span-brief" id="vu">
<fmt:message key="result-vuser" />
<br /> <br>
</div>
<div class="span4 span-brief-last" id="request">
<fmt:message key="result-request" />
<br /> <br>
</div>
</div>
<div class="row-fluid">
<h4 class="pull-left">Charts</h4>
<div class="field-inline">
<button type="button" class="btn btn-primary " id="del-graph">
<fmt:message key="result-deleteGraph" />
</button>
</div>
<div class="field-inline">
<button type="button" class="btn btn-primary " id="add-graph">
<fmt:message key="result-addGraph" />
</button>
</div>
</div>
<div class="app-container " id="chart"></div>
<div class="row-fluid">
<h4 class="pull-left">Pages</h4>
</div>
<div class="app-container">
<table id="page"
class="table table-striped table-bordered bootstrap-datatable datatable">
<thead>
<tr>
<th>Page</th>
<th>Script</th>
<th>Count</th>
<th>Test Min</th>
<th>Test Max</th>
<th>Average</th>
<th>Last</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
<div class="row-fluid">
<h4 class="pull-left">Urls</h4>
</div>
<div class="app-container dataTables_wrapper">
<table id="url"
class="table table-striped table-bordered bootstrap-datatable datatable">
<thead>
<tr>
<th></th>
<th>URL</th>
<th>Script</th>
<th>Successful</th>
<th>Total</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
<div class="app-container" id="url-distribution"></div>
</div>
</div>
</div>
< <div class="modal hide fade" id="add-graph-modal">
<div class="modal-header">
<button type="button" id="myModal-close" class="close"
data-dismiss="modal">x</button>
<h3>
<fmt:message key="result-addGraph" />
</h3>
</div>
<div class="modal-body" id="add-graph-list"></div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" id="add-graph-add"
data-dismiss="modal">
<fmt:message key="add" />
</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">
<fmt:message key="cancel" />
</button>
</div>
</div>
<div class="modal hide fade" id="del-graph-modal">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">x</button>
<h3>
<fmt:message key="result-deleteGraph" />
</h3>
</div>
<div class="modal-body" id="del-graph-list"></div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" id="del-graph-del"
data-dismiss="modal">
<fmt:message key="delete" />
</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">
<fmt:message key="cancel" />
</button>
</div>
</div>
<div class="modal hide fade" id="load">
<div class="modal-header">
<h3> <fmt:message key="result-loadingInfo" /></h3>
</div>
<div class="modal-body">
<div id="loading">
<div></div>
</div>
</div>
<div class="modal-footer">
<button type="button" id="cancelLoading" class="btn btn-primary "> <fmt:message key="cancel" /></button>
</div>
</div>
<hr>
<jsp:include page="publiccontrol/footer.jsp"></jsp:include>
<script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-2.1.0.js"></script>
<script
src="http://ajax.aspnetcdn.com/ajax/jquery.ui/1.10.4/jquery-ui.min.js"></script>
<script src="lib/jqueryi18n/jquery.i18n.properties-1.0.9.js"></script>
<script src="lib/bootstrap/js/bootstrap-modal.js"></script>
<script
src="http://ajax.aspnetcdn.com/ajax/bootstrap/2.3.1/bootstrap.min.js"></script>
<script src="lib/chrisma/js/jquery.cookie.js"></script>
<script
src='http://ajax.aspnetcdn.com/ajax/jquery.dataTables/1.9.4/jquery.dataTables.js'></script>
<script src="lib/chrisma/js/theme.js"></script>
<script src="lib/chrisma/js/jquery.cookie.js"></script>
<script src="script/base.js"></script>
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="script/testResult/charts.js"></script>
<script src="script/testResult/testBriefResult.js"></script>
<script src="script/bench4q.table.js"></script>
<script src="script/testResult/behaviorAndPage.js"></script>
<script src="script/testResult/highChartTheme.js"></script>
<script src="script/testResult/tree.js"></script>
<script src="script/testResult/Model.js"></script>
<script src="script/share/TestStatusMap.js"></script>
<script src="script/testResult/graphSelectorTree.js"></script>
<script src="script/testResult/pieChart.js"></script>
<script src="script/testResult/graphSelector.js"></script>
<script src="script/testResult/result-load.js"></script>
<script src="script/testResult/result.js"></script>
</fmt:bundle>
</body>
</html>

View File

@ -0,0 +1,33 @@
function testStatusMap(status) {
if (status == "NotStart") {
return $.i18n.prop('test-NotStart');
}
if(status=="Complete"){
return $.i18n.prop('test-Complete');
}
if (status == "ApplyForLoad") {
return $.i18n.prop('test-ApplyForLoad')
}
if (status == "DistributeScriptAndParams") {
return $.i18n.prop('test-DistributeScriptAndParams');
}
if (status == "InRunning") {
return $.i18n.prop('test-InRunning');
}
if (status == "PendingNoEnoughMaxLoad") {
return $.i18n.prop('test-PendingNoEnoughMaxLoad');
}
if (status == "PendingNoEnoughCurrentLoad") {
return $.i18n.prop('test-PendingNoEnoughCurrentLoad');
}
if (status == "Error") {
return $.i18n.prop('test-Error');
}
if (status == "ErrorInSubmitTask") {
return $.i18n.prop('test-ErrorInSubmitTask');
}
if (status == "ErrorInDistributeLoadForScript") {
return $.i18n.prop('test-ErrorInDistributeLoadForScript');
}
}

View File

@ -0,0 +1,36 @@
var Model = function() {
this.url = "";
this.series = "";
this.data = null;
this.intervalId = null;
this.axis = "";
this.time = 0;
};
Model.prototype.setUrl = function(pathValue, chartSelector) {
this.url = chartSelector.allTree.root.value;
if (pathValue == null)
return null;
if (pathValue.length <= 0)
return null;
replace(pathValue, chartSelector.replaceArray);
for ( var i = 0; i < pathValue.length; i++) {
this.url += "/" + pathValue[i];
}
};
Model.prototype.setSeries = function(pathValue) {
this.series = "";
if (pathValue == null)
return null;
if (pathValue.length <= 0)
return null;
this.series += pathValue[0];
for ( var i = 1; i < pathValue.length; i++) {
this.series += "_" + pathValue[i];
}
};
Model.prototype.setIntervalId = function(intervalId) {
this.intervalId = intervalId;
};

View File

@ -1,233 +0,0 @@
var ChartSelector = function(allTree, showTree, chart, addSelectorId,
deleteSelectorId, addButton, deleteButton,replaceArray,showTreePathValues) {
this.allTree = allTree;
this.showTree = showTree;
this.addSelectorId = addSelectorId;
this.deleteSelectorId = deleteSelectorId;
this.excessTree =this.getExcessTree(allTree, showTreePathValues);
this.addButton = addButton;
this.deleteButton = deleteButton;
this.createSelector($("#"+addSelectorId), this.excessTree.root);
this.chart = chart;
this.replaceArray=replaceArray;
this.addEventListener(this);
};
ChartSelector.prototype.getExcessTree=function(allTree,pathValues){
var excessTree=allTree.getClonedTree(allTree);
excessTree.deleteFromTree(pathValues);
return excessTree;
};
ChartSelector.prototype.addEventListener = function(chartSelector) {
this.addButton.click(function(e) {
e.preventDefault();
chartSelector.addGraph();
});
this.deleteButton.click(function(e) {
e.preventDefault();
chartSelector.deleteGraph();
});
};
ChartSelector.prototype.updateSelector = function(selectorId, updatedData, tree) {
var parentDomNode = $("#" + selectorId);
this.deleteChildSelector(parentDomNode,updatedData);
/*var pathValues = getSubDataArray(updatedData, this
.getSlectedVluesArray(selectorId));*/
/*var newShowTree = tree.getCloneTreeFromVlaue(valuePath);*/
var newShowTree=tree.getClondSubTreeByValue(updatedData);
if(newShowTree==null)
return;
this.createSelector(parentDomNode, newShowTree.root);
this.addSelectlistEvent();
};
ChartSelector.prototype.deleteChildSelector=function(parentDomNode,updatedData){
var selectArray=$("#"+parentDomNode.attr("id")+" select");
var divArray=$("#"+parentDomNode.attr("id")+" div");
parentDomNode.html("");
for(var i=0;i<selectArray.length;i++){
parentDomNode.append(divArray[i]);
if($(selectArray[i]).find("option:selected").text()==updatedData){
break;
}
}
};;
ChartSelector.prototype.createSelectorByValues = function(parentDomNode, treeNode,pathValues) {
var currentNode = treeNode;
if (currentNode == null)
return ;
var selectedNode;
if (currentNode.children != null && currentNode.children.length > 0) {
selectedNode=this.getSelectNodeByValue(currentNode,pathValues);
if(selectedNode==null)
selectedNode = currentNode.children[0];
var selectOptions = new Array();
for (var i = 0; i < currentNode.children.length; i++) {
selectOptions.push(currentNode.children[i].value);
}
parentDomNode.append(this.createSingleListDom(currentNode.childClassName,selectOptions));
this.createSelectorByValues(parentDomNode, selectedNode,pathValues);
}
};
ChartSelector.prototype.addSelectlistEvent=function(){
var chartSelector=this;
$("#" + this.deleteSelectorId+" select").change(function(event) {
var updatedData=$(this).find("option:selected").text();
chartSelector.updateSelector( chartSelector.deleteSelectorId, updatedData, chartSelector.showTree);
event.stopImmediatePropagation();
});
$("#" + this.addSelectorId+" select").change(function(event) {
var updatedData=$(this).find("option:selected").text();
chartSelector.updateSelector( chartSelector.addSelectorId, updatedData, chartSelector.excessTree);
event.stopImmediatePropagation();
});
};
ChartSelector.prototype.createSelector = function(parentDomNode, treeNode) {
var currentNode = treeNode;
if (currentNode == null)
return ;
var selectedNode;
if (currentNode.children != null && currentNode.children.length > 0) {
selectedNode = currentNode.children[0];
var selectOptions = new Array();
for (var i = 0; i < currentNode.children.length; i++) {
selectOptions.push(currentNode.children[i].value);
}
parentDomNode.append(this.createSingleListDom(currentNode.childClassName,selectOptions));
this.createSelector(parentDomNode, selectedNode);
}
};
ChartSelector.prototype.getSelectNodeByValue=function(parentNode,values){
for(var i=0;i<values.length;i++){
for(var j=0;j<parentNode.children.length;j++){
if(parentNode.children[j].value==values[i])
return parentNode.children[j];
}
}
return null;
};
ChartSelector.prototype.createSingleListDom = function(lableText, options) {
var div = $("<div></div>");
div.addClass("control-group");
var lable = $("<lable></lable>");
lable.addClass("control-label");
lable.text(lableText);
div.append(lable);
div.append("</br>");
var select = $("<select ></select>");
select.addClass("form-control");
for (var i = 0; i < options.length; i++) {
var option = $("<option></option>");
option.text(options[i]);
select.append(option);
}
div.append(select);
return div;
};
ChartSelector.prototype.getSlectedVluesArray = function(selectorId) {
var dataArray = new Array();
var selectArray = $("#" + selectorId + " select");
for (var i = 0; i < selectArray.length; i++) {
dataArray.push($(selectArray[i]).find("option:selected").text());
}
return dataArray;
};
ChartSelector.prototype.addGraphToTree = function( tree,selectorId) {
var pathValues = this.getSlectedVluesArray(selectorId);
var singlePathTree = this.allTree.getCloneTreeFromVlaue(pathValues);
if(tree==null)
tree=singlePathTree;
else
tree.insertToTree(tree.root, singlePathTree.root);
return tree;
};
ChartSelector.prototype.deleteGraphFromTree = function(tree, selectorId) {
if(tree==null)
return null;
var pathValues = this.getSlectedVluesArray(selectorId);
tree.deleteFromTree(pathValues);
return tree;
};
ChartSelector.prototype.addGraph = function() {
this.showTree=this.addGraphToTree(this.showTree, this.addSelectorId);
this.excessTree=this.deleteGraphFromTree(this.excessTree, this.addSelectorId);
var model = new Model();
model.setSeries(this.getSlectedVluesArray(this.addSelectorId));
model.setUrl(this.getSlectedVluesArray(this.addSelectorId),this);
model.axis=(model.series+"_Axis");
this.chart.addGraph(model);
};
ChartSelector.prototype.initChart=function(pathValues){
var model = new Model();
model.setSeries(pathValues);
model.setUrl(this.getSlectedVluesArray(this.addSelectorId),this);
model.axis=(model.series+"_Axis");
this.chart.addGraph(model);
};
ChartSelector.prototype.deleteGraph = function() {
this.showTree=this.deleteGraphFromTree(this.showTree, this.deleteSelectorId);
this.excessTree=this.addGraphToTree(this.excessTree, this.deleteSelectorId);
var model = new Model();
model.setSeries(this.getSlectedVluesArray(this.deleteSelectorId));
model.axis=(model.series+"_Axis");
this.chart.deleteGraph(model);
};
var Model = function() {
this.url = "";
this.series = "";
this.data = null;
this.intervalId = null;
this.axis="";
this.time=0;
};
Model.prototype.setUrl = function(pathValue,chartSelector) {
/* this.url = "/"+chartSelector.allTree.root.value;*/
this.url = chartSelector.allTree.root.value;
if (pathValue == null)
return null;
if (pathValue.length <= 0)
return null;
replace(pathValue,chartSelector.replaceArray);
for(var i=0;i<pathValue.length;i++){
this.url += "/" + pathValue[i];
}
};
Model.prototype.setSeries = function(pathValue) {
this.series = "";
if (pathValue == null)
return null;
if (pathValue.length <= 0)
return null;
this.series += pathValue[0];
for (var i = 1; i < pathValue.length; i++) {
this.series += "_" + pathValue[i];
}
};
Model.prototype.setIntervalId = function(intervalId) {
this.intervalId = intervalId;
};
function getSubDataArray(indexData, dataArray) {
var subDataArray = new Array();
for (var i = 0; i < dataArray.length; i++) {
subDataArray.push(dataArray[i]);
if (dataArray[i] == indexData) {
break;
}
}
return subDataArray;
}

View File

@ -0,0 +1,205 @@
var ChartSelector = function(allTree, showTree, chart, addSelectorId,
deleteSelectorId, addButton, deleteButton, replaceArray,
showTreePathValues) {
this.allTree = allTree;
this.showTree = showTree;
this.addSelectorId = addSelectorId;
this.deleteSelectorId = deleteSelectorId;
this.excessTree = this.getExcessTree(allTree, showTreePathValues);
this.addButton = addButton;
this.deleteButton = deleteButton;
this.createSelector($("#" + addSelectorId), this.excessTree.root);
this.chart = chart;
this.replaceArray = replaceArray;
this.addEventListener(this);
};
ChartSelector.prototype.getExcessTree = function(allTree, pathValues) {
var excessTree = allTree.getClonedTree(allTree);
excessTree.deleteFromTree(pathValues);
return excessTree;
};
ChartSelector.prototype.addEventListener = function(chartSelector) {
this.addButton.click(function(e) {
e.preventDefault();
chartSelector.addGraph();
});
this.deleteButton.click(function(e) {
e.preventDefault();
chartSelector.deleteGraph();
});
};
ChartSelector.prototype.updateSelector = function(selectorId, updatedData, tree) {
var parentDomNode = $("#" + selectorId);
this.deleteChildSelector(parentDomNode, updatedData);
var newShowTree = tree.getClondSubTreeByValue(updatedData);
if (newShowTree == null)
return;
this.createSelector(parentDomNode, newShowTree.root);
this.addSelectlistEvent();
};
ChartSelector.prototype.deleteChildSelector = function(parentDomNode,
updatedData) {
var selectArray = $("#" + parentDomNode.attr("id")).find("select");
var divArray = $("#" + parentDomNode.attr("id") + " div");
parentDomNode.html("");
for ( var i = 0; i < selectArray.length; i++) {
parentDomNode.append(divArray[i]);
if ($(selectArray[i]).find("option:selected").text() == updatedData) {
break;
}
}
};
//
// ChartSelector.prototype.createSelectorByValues = function(parentDomNode,
// treeNode, pathValues) {
// var currentNode = treeNode;
// if (currentNode == null)
// return;
// var selectedNode;
// if (currentNode.children != null && currentNode.children.length > 0) {
// selectedNode = this.getSelectNodeByValue(currentNode, pathValues);
// if (selectedNode == null)
// selectedNode = currentNode.children[0];
// var selectOptions = new Array();
// for ( var i = 0; i < currentNode.children.length; i++) {
// selectOptions.push(currentNode.children[i].value);
// }
// parentDomNode.append(this.createSingleListDom(
// currentNode.childClassName, selectOptions));
// this.createSelectorByValues(parentDomNode, selectedNode, pathValues);
// }
//
// };
ChartSelector.prototype.addSelectlistEvent = function() {
var chartSelector = this;
$("#" + this.deleteSelectorId).find("select").change(
function(event) {
var updatedData = $(this).find("option:selected").text();
chartSelector.updateSelector(chartSelector.deleteSelectorId,
updatedData, chartSelector.showTree);
event.stopImmediatePropagation();
});
$("#" + this.addSelectorId).find("select").change(
function(event) {
var updatedData = $(this).find("option:selected").text();
chartSelector.updateSelector(chartSelector.addSelectorId,
updatedData, chartSelector.excessTree);
event.stopImmediatePropagation();
});
};
ChartSelector.prototype.createSelector = function(parentDomNode, treeNode) {
var currentNode = treeNode;
if (currentNode == null)
return;
var selectedNode;
if (currentNode.children != null && currentNode.children.length > 0) {
selectedNode = currentNode.children[0];
var selectOptions = new Array();
for ( var i = 0; i < currentNode.children.length; i++) {
selectOptions.push(currentNode.children[i].value);
}
parentDomNode.append(this.createSingleListDom(
currentNode.childClassName, selectOptions));
this.createSelector(parentDomNode, selectedNode);
}
};
ChartSelector.prototype.getSelectNodeByValue = function(parentNode, values) {
for ( var i = 0; i < values.length; i++) {
for ( var j = 0; j < parentNode.children.length; j++) {
if (parentNode.children[j].value == values[i])
return parentNode.children[j];
}
}
return null;
};
ChartSelector.prototype.createSingleListDom = function(lableText, options) {
var div = $("<div></div>");
div.addClass("control-group");
var lable = $("<lable></lable>");
lable.addClass("control-label");
lable.text(lableText);
div.append(lable);
div.append("</br>");
var select = $("<select ></select>");
select.addClass("form-control");
for ( var i = 0; i < options.length; i++) {
var option = $("<option></option>");
$(option).val(options[i]);
option.text(options[i]);
select.append(option);
}
div.append(select);
return div;
};
ChartSelector.prototype.getSlectedVluesArray = function(selectorId) {
var dataArray = new Array();
var selectArray = $("#" + selectorId).find("select");
for ( var i = 0; i < selectArray.length; i++) {
dataArray.push($(selectArray[i]).find("option:selected").text());
}
return dataArray;
};
ChartSelector.prototype.addGraphToTree = function(tree, selectorId) {
var pathValues = this.getSlectedVluesArray(selectorId);
var singlePathTree = this.allTree.getCloneTreeFromVlaue(pathValues);
if (tree == null)
tree = singlePathTree;
else
tree.insertToTree(tree.root, singlePathTree.root);
return tree;
};
ChartSelector.prototype.deleteGraphFromTree = function(tree, selectorId) {
if (tree == null)
return null;
var pathValues = this.getSlectedVluesArray(selectorId);
tree.deleteFromTree(pathValues);
return tree;
};
ChartSelector.prototype.addGraph = function() {
this.showTree = this.addGraphToTree(this.showTree, this.addSelectorId);
this.excessTree = this.deleteGraphFromTree(this.excessTree,
this.addSelectorId);
var model = new Model();
model.setSeries(this.getSlectedVluesArray(this.addSelectorId));
model.setUrl(this.getSlectedVluesArray(this.addSelectorId), this);
model.axis = (model.series + "_Axis");
this.chart.addGraph(model);
};
ChartSelector.prototype.initChart = function(pathValues) {
var model = new Model();
model.setSeries(pathValues);
model.setUrl(this.getSlectedVluesArray(this.addSelectorId), this);
model.axis = (model.series + "_Axis");
this.chart.addGraph(model);
};
ChartSelector.prototype.deleteGraph = function() {
this.showTree = this.deleteGraphFromTree(this.showTree,
this.deleteSelectorId);
this.excessTree = this.addGraphToTree(this.excessTree,
this.deleteSelectorId);
var model = new Model();
model.setSeries(this.getSlectedVluesArray(this.deleteSelectorId));
model.axis = (model.series + "_Axis");
this.chart.deleteGraph(model);
};
function getSubDataArray(indexData, dataArray) {
var subDataArray = new Array();
for ( var i = 0; i < dataArray.length; i++) {
subDataArray.push(dataArray[i]);
if (dataArray[i] == indexData) {
break;
}
}
return subDataArray;
}

View File

@ -0,0 +1,107 @@
function getResultInfoTree(testPlanId) {
var tree = new Tree();
tree.createRoot("Test Result", testPlanId);
createScriptResultInfoTree(testPlanId, tree);
var sutResultInfo = new SutResult(testPlanId);
if (sutResultInfo.root != null)
tree.root.insertSingleNode(sutResultInfo.root);
return tree;
}
function createScriptResultInfoTree(testPlanId, tree) {
var scriptResultTree = new Tree();
scriptResultTree.createRoot("Script", "script");
$.ajax({
type : "POST",
url : testPlanId + "/runningScriptInfo",
dataType : "json",
async : false,
success : function(data) {
if (!data.success) {
return;
} else
data = data.scriptInfo;
createScriptTree(data, scriptResultTree);
tree.root.insertSingleNode(scriptResultTree.root);
}
});
}
function createScriptTree(scriptResultInfoList, tree) {
if (scriptResultInfoList == null)
return;
for ( var i = 0; i < scriptResultInfoList.length; i++) {
var node = new TreeNode("Script Result",
scriptResultInfoList[i].scriptName, null);
tree.root.insertSingleNode(node);
var nodeArray = insertResultList(scriptResultInfoList[i].childResults);
for ( var j = 0; j < nodeArray.length; j++) {
node.insertSingleNode(nodeArray[j]);
}
}
};
var SutResult = function(testPlanId) {
var sutResultInfo = this;
var scriptResultTree = new Tree();
$.ajax({
type : "POST",
url : testPlanId + "/sutInfo",
dataType : "json",
async : false,
success : function(data) {
if (!data.success) {
sutResultInfo.root = null;
return;
} else
data = data.sutInfo;
scriptResultTree.createRoot("SUT", "SUT");
sutResultInfo.root = scriptResultTree.root;
sutResultInfo.data = data;
sutResultInfo.createTree(data);
}
});
};
SutResult.prototype.createTree = function(sutResultInfoList) {
for ( var i = 0; i < sutResultInfoList.length; i++) {
var ipNode = new TreeNode("port", sutResultInfoList[i].ip, null);
this.root.insertSingleNode(ipNode);
var portNode = new TreeNode("sut result", sutResultInfoList[i].port,
null);
ipNode.insertSingleNode(portNode);
var nodeArray = insertResultList(sutResultInfoList[i].childResults);
for ( var j = 0; j < nodeArray.length; j++) {
portNode.insertSingleNode(nodeArray[j]);
}
}
}
function insertResultList(childResults) {
if (childResults == null)
return null;
else {
var nodeArray = new Array();
for ( var i = 0; i < childResults.length; i++) {
var node = new TreeNode(childResults[i].result,
childResults[i].result, null);
var childNode = insertResultList(childResults[i].childResults);
if (childNode !== null) {
for ( var j = 0; j < childNode.length; j++) {
node.insertSingleNode(childNode[j]);
}
}
nodeArray.push(node);
}
}
return nodeArray;
};

View File

@ -1,110 +0,0 @@
function getResultInfoTree(testPlanId){
var tree=new Tree();
tree.createRoot("Test Result",testPlanId);
createScriptResultInfoTree(testPlanId,tree);
/*this.SutResult=new SutResult(testPlanId);*/
var sutResultInfo=new SutResult(testPlanId);
if(sutResultInfo.root!=null)
tree.root.insertSingleNode(sutResultInfo.root);
return tree;
}
function createScriptResultInfoTree(testPlanId,tree){
var scriptResultTree=new Tree();
scriptResultTree.createRoot("Script","script");
$.ajax({
type:"POST",
url:testPlanId+"/runningScriptInfo",
dataType:"json",
async: false,
success: function(data){
if(!data.success){
return;
}
else data=data.data;
createScriptTree(data,scriptResultTree);
tree.root.insertSingleNode(scriptResultTree.root);
}
});
}
function createScriptTree(scriptResultInfoList,tree){
if(scriptResultInfoList==null)
return;
for(var i=0;i<scriptResultInfoList.length;i++){
var node=new TreeNode("Script Result",scriptResultInfoList[i].scriptName,null);
tree.root.insertSingleNode(node);
var nodeArray=insertResultList(scriptResultInfoList[i].childResults);
for(var j=0;j<nodeArray.length;j++){
node.insertSingleNode(nodeArray[j]);
}
}
};
var SutResult=function(testPlanId){
var sutResultInfo=this;
var scriptResultTree=new Tree();
$.ajax({
type:"POST",
url:testPlanId+"/sutInfo",
dataType:"json",
async: false,
success: function(data){
if(!data.success)
{
sutResultInfo.root=null;
return;
}
else data=data.data;
scriptResultTree.createRoot("SUT","SUT");
sutResultInfo.root=scriptResultTree.root;
sutResultInfo.data=data;
sutResultInfo.createTree(data);
}
});
};
SutResult.prototype.createTree=function(sutResultInfoList){
for(var i=0;i<sutResultInfoList.length;i++){
var ipNode=new TreeNode("port",sutResultInfoList[i].ip,null);
this.root.insertSingleNode(ipNode);
var portNode=new TreeNode("sut result",sutResultInfoList[i].port,null);
ipNode.insertSingleNode(portNode);
var nodeArray=insertResultList(sutResultInfoList[i].childResults);
for(var j=0;j<nodeArray.length;j++){
portNode.insertSingleNode(nodeArray[j]);
}
}
}
function insertResultList(childResults){
if(childResults==null)
return null;
else{
var nodeArray=new Array();
for(var i=0;i<childResults.length;i++){
var node=new TreeNode(childResults[i].result,childResults[i].result,null);
var childNode=insertResultList(childResults[i].childResults);
if(childNode!==null){
for(var j=0;j<childNode.length;j++){
node.insertSingleNode(childNode[j]);
}
}
nodeArray.push(node);
}
}
return nodeArray;
};

View File

@ -209,31 +209,6 @@ Tree.prototype.getClonedNode = function(node) {
}
return clonedNode;
};
/*
* Tree.prototype.getExcessTreeNodes = function(allTreeNode, showTreeNode) { var
* tree=this; if (allTreeNode == null) return null;
* if(allTreeNode.children==null) return null; var excessTreeNode = new
* TreeNode(allTreeNode.childClassName, allTreeNode.value, null); if
* (showTreeNode == null) { getClonedSubTree(allTreeNode, excessTreeNode);
* return excessTreeNode.children; } for ( var i = 0; i <
* allTreeNode.children.length; i++) { var flag = false; for ( var j = 0; j <
* showTreeNode.children.length; j++) { if (allTreeNode.children[i].value ==
* showTreeNode.children[j].value) { flag = true; var childrenExcessTree=tree.
* getExcessTreeNodes(allTreeNode.children[i], showTreeNode.children[j]); if
* (childrenExcessTree.children != null && childrenExcessTree.children.length >
* 0)
*
* excessTreeNode.insertNodes(childrenExcessTree); } } if (!flag) {
* excessTreeNode.insertSingleNode(allTree.children[i]); } } if
* (excessTree.children.length == 0) excessTree.children = null; return
* excessTree.children; }; Tree.prototype.getExcessTree = function(allTree,
* showTree) { if (showTree == null) { showTree = new Tree(); showTree.root =
* null; } var excessTree = new Tree();
* excessTree.createRoot(allTree.root.childClassName, allTree.root.value);
* excessTree.root.insertNodes(excessTree.getExcessTreeNodes(allTree.root,
* showTree.root)); return excessTree;
* }
*/
function getClonedSubTree(startNode, parentNode) {
if (startNode == null)
return null;