fix => "Once async finishes for a VM action, we need to display the message if their current context is that VM without having to click on it again."

This commit is contained in:
Jessica Wang 2010-10-26 16:53:48 -07:00
parent dfda67cc65
commit 3fa6378874
1 changed files with 24 additions and 4 deletions

View File

@ -84,7 +84,12 @@ function afterLoadInstanceJSP() {
asyncJobResponse: "startvirtualmachineresponse",
afterActionSeccessFn: function(json, $midmenuItem1, id) {
var jsonObj = json.queryasyncjobresultresponse.jobresult.startvirtualmachineresponse;
vmToMidmenu(jsonObj, $midmenuItem1);
vmToMidmenu(jsonObj, $midmenuItem1);
if( ($("#right_panel_content #tab_content_details").length > 0)
&& ($("#right_panel_content #tab_content_details").data("jsonObj") != null )
&& (jsonObj.id == $("#right_panel_content #tab_content_details").data("jsonObj").id))
vmToRightPanel($midmenuItem1);
}
}
doActionForMidMenu(id, apiInfo, apiCommand);
@ -123,7 +128,12 @@ function afterLoadInstanceJSP() {
jsonObj = json.listvirtualmachinesresponse.virtualmachine[0];
}
});
vmToMidmenu(jsonObj, $midmenuItem1);
vmToMidmenu(jsonObj, $midmenuItem1);
if( ($("#right_panel_content #tab_content_details").length > 0)
&& ($("#right_panel_content #tab_content_details").data("jsonObj") != null )
&& (jsonObj.id == $("#right_panel_content #tab_content_details").data("jsonObj").id))
vmToRightPanel($midmenuItem1);
}
}
doActionForMidMenu(id, apiInfo, apiCommand);
@ -162,7 +172,12 @@ function afterLoadInstanceJSP() {
jsonObj = json.listvirtualmachinesresponse.virtualmachine[0];
}
});
vmToMidmenu(jsonObj, $midmenuItem1);
vmToMidmenu(jsonObj, $midmenuItem1);
if( ($("#right_panel_content #tab_content_details").length > 0)
&& ($("#right_panel_content #tab_content_details").data("jsonObj") != null )
&& (jsonObj.id == $("#right_panel_content #tab_content_details").data("jsonObj").id))
vmToRightPanel($midmenuItem1);
}
}
doActionForMidMenu(id, apiInfo, apiCommand);
@ -201,7 +216,12 @@ function afterLoadInstanceJSP() {
jsonObj = json.listvirtualmachinesresponse.virtualmachine[0];
}
});
vmToMidmenu(jsonObj, $midmenuItem1);
vmToMidmenu(jsonObj, $midmenuItem1);
if( ($("#right_panel_content #tab_content_details").length > 0)
&& ($("#right_panel_content #tab_content_details").data("jsonObj") != null )
&& (jsonObj.id == $("#right_panel_content #tab_content_details").data("jsonObj").id))
vmToRightPanel($midmenuItem1);
}
}
doActionForMidMenu(id, apiInfo, apiCommand);