Event page, Alert page - implement refresh button on right panel to refresh only the right panel (i.e. only the selected item in middle menu).

This commit is contained in:
Jessica Wang 2011-02-11 15:44:12 -08:00
parent 673931dde4
commit b5ba7f07f8
2 changed files with 32 additions and 0 deletions

View File

@ -67,6 +67,22 @@ function alertJsonToDetailsTab() {
var $thisTab = $("#right_panel_content").find("#tab_content_details");
$thisTab.find("#tab_container").hide();
$thisTab.find("#tab_spinning_wheel").show();
//uncomment the following section when Bug 8577("listAlerts API, listEvents API doesn't take in id parameter correctly") is fixed
/*
$.ajax({
data: createURL("command=listAlerts&id="+jsonObj.id),
dataType: "json",
async: false,
success: function(json) {
var items = json.listalertsresponse.alert;
if(items != null && items.length > 0) {
jsonObj = items[0];
$midmenuItem1.data("jsonObj", jsonObj);
}
}
});
*/
$thisTab.find("#id").text(fromdb(jsonObj.id));
$thisTab.find("#type").text(toAlertType(jsonObj.type));

View File

@ -97,6 +97,22 @@ function eventJsonToDetailsTab() {
var $thisTab = $("#right_panel_content #tab_content_details");
$thisTab.find("#tab_container").hide();
$thisTab.find("#tab_spinning_wheel").show();
//uncomment the following section when Bug 8577("listAlerts API, listEvents API doesn't take in id parameter correctly") is fixed
/*
$.ajax({
data: createURL("command=listEvents&id="+jsonObj.id),
dataType: "json",
async: false,
success: function(json) {
var items = json.listeventsresponse.event;
if(items != null && items.length > 0) {
jsonObj = items[0];
$midmenuItem1.data("jsonObj", jsonObj);
}
}
});
*/
$thisTab.find("#id").text(fromdb(jsonObj.id));
$thisTab.find("#username").text(fromdb(jsonObj.username));