API has changed to return all if pagesize is not specified. Here is corresponding UI change.

This commit is contained in:
Jessica Wang 2010-11-30 11:03:58 -08:00
parent b5f9ae0ef3
commit db3b75bda0
11 changed files with 26 additions and 26 deletions

View File

@ -30,7 +30,7 @@ function afterLoadDashboardJSP() {
//$("#menutab_dashboard_root, #menutab_vm, #menutab_networking_old, #menutab_networking, #menutab_templates, #menutab_events, #menutab_hosts, #menutab_storage, #menutab_accounts, #menutab_domain").hide();
$.ajax({
data: createURL("command=listZones&available=true"+maxPageSize),
data: createURL("command=listZones&available=true"),
dataType: "json",
async: false,
success: function(json) {
@ -165,7 +165,7 @@ function afterLoadDashboardJSP() {
$thisSection.find("#capacity_zone_select").bind("change", function(event) {
var zoneId = $(this).val();
$.ajax({
data: createURL("command=listPods&zoneId="+zoneId+maxPageSize),
data: createURL("command=listPods&zoneId="+zoneId),
dataType: "json",
async: false,
success: function(json) {

View File

@ -142,7 +142,7 @@ function domainToRightPanel2($leftmenuItem1) {
$.ajax({
cache: false,
data: createURL("command=listAccounts&domainid="+domainId+maxPageSize),
data: createURL("command=listAccounts&domainid="+domainId),
dataType: "json",
success: function(json) {
var accounts = json.listaccountsresponse.account;
@ -298,7 +298,7 @@ function listAdminAccounts(domainId) {
var accountType = (domainId==1)? 1: 2;
$.ajax({
cache: false,
data: createURL("command=listAccounts&domainid="+domainId+"&accounttype="+accountType+maxPageSize),
data: createURL("command=listAccounts&domainid="+domainId+"&accounttype="+accountType),
dataType: "json",
success: function(json) {
var items = json.listaccountsresponse.account;

View File

@ -39,7 +39,7 @@ function populateGlobalSettingGrid() {
$thisTab.find("#tab_spinning_wheel").show();
$.ajax({
data: createURL("command=listConfigurations"+maxPageSize),
data: createURL("command=listConfigurations"),
dataType: "json",
success: function(json) {
var items = json.listconfigurationsresponse.configuration;

View File

@ -370,7 +370,7 @@ function hostClearDetailsTab() {
function populateForUpdateOSDialog(oscategoryid) {
$.ajax({
data: createURL("command=listOsCategories"+maxPageSize),
data: createURL("command=listOsCategories"),
dataType: "json",
success: function(json) {
var categories = json.listoscategoriesresponse.oscategory;

View File

@ -1422,7 +1422,7 @@ function vmJsonToVolumeTab() {
$.ajax({
cache: false,
data: createURL("command=listVolumes&virtualMachineId="+jsonObj.id+maxPageSize),
data: createURL("command=listVolumes&virtualMachineId="+jsonObj.id),
dataType: "json",
success: function(json) {
var items = json.listvolumesresponse.volume;
@ -1487,7 +1487,7 @@ function vmJsonToRouterTab() {
$.ajax({
cache: false,
data: createURL("command=listRouters&domainid="+vmObj.domainid+"&account="+vmObj.account+maxPageSize),
data: createURL("command=listRouters&domainid="+vmObj.domainid+"&account="+vmObj.account),
dataType: "json",
success: function(json) {
var items = json.listroutersresponse.router;

View File

@ -35,7 +35,7 @@ function afterLoadIpJSP() {
//*** Acquire New IP (begin) ***
$.ajax({
data: createURL("command=listZones&available=true"+maxPageSize),
data: createURL("command=listZones&available=true"),
dataType: "json",
success: function(json) {
var zones = json.listzonesresponse.zone;

View File

@ -1457,7 +1457,7 @@ function submenuContentEventBinder(submenuContent, listFunction) {
var zoneSelect = submenuContent.find("#advanced_search #adv_search_zone");
if(zoneSelect.length>0) { //if zone dropdown is found on Advanced Search dialog
$.ajax({
data: createURL("command=listZones&available=true&response=json"+maxPageSize),
data: createURL("command=listZones&available=true&response=json"),
dataType: "json",
success: function(json) {
var zones = json.listzonesresponse.zone;
@ -1484,7 +1484,7 @@ function submenuContentEventBinder(submenuContent, listFunction) {
podLabel.css("color", "black");
podSelect.removeAttr("disabled");
$.ajax({
data: createURL("command=listPods&zoneId="+zoneId+"&response=json"+maxPageSize),
data: createURL("command=listPods&zoneId="+zoneId+"&response=json"),
dataType: "json",
async: false,
success: function(json) {
@ -1509,7 +1509,7 @@ function submenuContentEventBinder(submenuContent, listFunction) {
if(domainSelect.length>0 && isAdmin()) {
var domainSelect = domainSelect.empty();
$.ajax({
data: createURL("command=listDomains&available=true&response=json"+maxPageSize),
data: createURL("command=listDomains&available=true&response=json"),
dataType: "json",
success: function(json) {
var domains = json.listdomainsresponse.domain;
@ -1527,7 +1527,7 @@ function submenuContentEventBinder(submenuContent, listFunction) {
vmSelect.empty();
vmSelect.append("<option value=''></option>");
$.ajax({
data: createURL("command=listVirtualMachines&response=json"+maxPageSize),
data: createURL("command=listVirtualMachines&response=json"),
dataType: "json",
success: function(json) {
var items = json.listvirtualmachinesresponse.virtualmachine;

View File

@ -22,7 +22,7 @@ function buildZoneTree() {
var $zoneTree = $("#leftmenu_zone_tree").find("#tree_container").hide();
$.ajax({
data: createURL("command=listZones&available=true"+maxPageSize),
data: createURL("command=listZones&available=true"),
dataType: "json",
success: function(json) {
var items = json.listzonesresponse.zone;
@ -55,7 +55,7 @@ function buildZoneTree() {
$zoneContent.show();
$.ajax({
data: createURL("command=listPods&zoneid="+zoneObj.id+maxPageSize),
data: createURL("command=listPods&zoneid="+zoneObj.id),
dataType: "json",
async: false,
success: function(json) {
@ -126,7 +126,7 @@ function buildZoneTree() {
function refreshClusterUnderPod($podNode, newClusterName, existingClusterId, noClicking) {
var podId = $podNode.data("podId");
$.ajax({
data: createURL("command=listClusters&podid="+podId+maxPageSize),
data: createURL("command=listClusters&podid="+podId),
dataType: "json",
async: false,
success: function(json) {
@ -176,7 +176,7 @@ function zoneJSONToTreeNode(json, $zoneNode) {
zoneName.data("jsonObj", json);
$.ajax({
data: createURL("command=listPods&zoneid="+zoneid+maxPageSize),
data: createURL("command=listPods&zoneid="+zoneid),
dataType: "json",
async: false,
success: function(json) {
@ -624,7 +624,7 @@ function initAddZoneWizard() {
var domainDropdown = $addZoneWizard.find("#domain_dropdown").empty();
$.ajax({
data: createURL("command=listDomains"+maxPageSize),
data: createURL("command=listDomains"),
dataType: "json",
async: false,
success: function(json) {

View File

@ -120,7 +120,7 @@ function afterLoadTemplateJSP() {
if (isAdmin())
addTemplateZoneField.append("<option value='-1'>All Zones</option>");
$.ajax({
data: createURL("command=listZones&available=true"+maxPageSize),
data: createURL("command=listZones&available=true"),
dataType: "json",
success: function(json) {
var zones = json.listzonesresponse.zone;
@ -135,7 +135,7 @@ function afterLoadTemplateJSP() {
});
$.ajax({
data: createURL("command=listOsTypes&response=json"+maxPageSize),
data: createURL("command=listOsTypes&response=json"),
dataType: "json",
success: function(json) {
types = json.listostypesresponse.ostype;
@ -154,7 +154,7 @@ function afterLoadTemplateJSP() {
});
$.ajax({
data: createURL("command=listServiceOfferings&response=json"+maxPageSize),
data: createURL("command=listServiceOfferings&response=json"),
dataType: "json",
success: function(json) {
var items = json.listserviceofferingsresponse.serviceoffering;
@ -167,7 +167,7 @@ function afterLoadTemplateJSP() {
});
$.ajax({
data: createURL("command=listDiskOfferings&response=json"+maxPageSize),
data: createURL("command=listDiskOfferings&response=json"),
dataType: "json",
success: function(json) {
var items = json.listdiskofferingsresponse.diskoffering;

View File

@ -43,7 +43,7 @@ function afterLoadVolumeJSP() {
});
$.ajax({
data: createURL("command=listZones&available=true"+maxPageSize),
data: createURL("command=listZones&available=true"),
dataType: "json",
success: function(json) {
var zones = json.listzonesresponse.zone;
@ -773,7 +773,7 @@ function doRecurringSnapshot($actionLink, $detailsTab, $midmenuItem1) {
function populateVirtualMachineField(domainId, account, zoneId) {
$.ajax({
cache: false,
data: createURL("command=listVirtualMachines&state=Running&zoneid="+zoneId+"&domainid="+domainId+"&account="+account+maxPageSize),
data: createURL("command=listVirtualMachines&state=Running&zoneid="+zoneId+"&domainid="+domainId+"&account="+account),
dataType: "json",
success: function(json) {
var instances = json.listvirtualmachinesresponse.virtualmachine;
@ -785,7 +785,7 @@ function populateVirtualMachineField(domainId, account, zoneId) {
}
$.ajax({
cache: false,
data: createURL("command=listVirtualMachines&state=Stopped&zoneid="+zoneId+"&domainid="+domainId+"&account="+account+maxPageSize),
data: createURL("command=listVirtualMachines&state=Stopped&zoneid="+zoneId+"&domainid="+domainId+"&account="+account),
dataType: "json",
success: function(json) {
var instances = json.listvirtualmachinesresponse.virtualmachine;

View File

@ -374,7 +374,7 @@ function initAddVLANButton($button, $leftmenuItem1) {
dialogAddVlanForZone.find("#add_publicip_vlan_type_container").show();
var podSelect = dialogAddVlanForZone.find("#add_publicip_vlan_pod").empty();
$.ajax({
data: createURL("command=listPods&zoneId="+zoneObj.id+maxPageSize),
data: createURL("command=listPods&zoneId="+zoneObj.id),
dataType: "json",
async: false,
success: function(json) {