CLOUDSTACK-3016: listZones API - take in networktype instead of zonetype parameter to be consistent with networktype property in ZoneResponse.

This commit is contained in:
Jessica Wang 2013-06-19 10:18:52 -07:00
parent d66e9c7b51
commit d5d0142ed4
3 changed files with 6 additions and 7 deletions

View File

@ -245,8 +245,7 @@ public class ApiConstants {
public static final String IS_VOLATILE = "isvolatile";
public static final String VOLUME_ID = "volumeid";
public static final String ZONE_ID = "zoneid";
public static final String ZONE_NAME = "zonename";
public static final String ZONE_TYPE = "zonetype";
public static final String ZONE_NAME = "zonename";
public static final String NETWORK_TYPE = "networktype";
public static final String PAGE = "page";
public static final String PAGE_SIZE = "pagesize";

View File

@ -57,8 +57,8 @@ public class ListZonesByCmd extends BaseListCmd {
@Parameter(name=ApiConstants.NAME, type=CommandType.STRING, description="the name of the zone")
private String name;
@Parameter(name=ApiConstants.ZONE_TYPE, type=CommandType.STRING, description="the network type of the zone that the virtual machine belongs to")
private String zoneType;
@Parameter(name=ApiConstants.NETWORK_TYPE, type=CommandType.STRING, description="the network type of the zone that the virtual machine belongs to")
private String networkType;
@Parameter(name=ApiConstants.SHOW_CAPACITIES, type=CommandType.BOOLEAN, description="flag to display the capacity of the zones")
private Boolean showCapacities;
@ -83,8 +83,8 @@ public class ListZonesByCmd extends BaseListCmd {
return name;
}
public String getZoneType() {
return zoneType;
public String getNetworkType() {
return networkType;
}
public Boolean getShowCapacities() {

View File

@ -2208,7 +2208,7 @@ public class QueryManagerImpl extends ManagerBase implements QueryService {
Long id = cmd.getId();
String keyword = cmd.getKeyword();
String name = cmd.getName();
String networkType = cmd.getZoneType();
String networkType = cmd.getNetworkType();
Filter searchFilter = new Filter(DataCenterJoinVO.class, null, false, cmd.getStartIndex(), cmd.getPageSizeVal());
SearchCriteria<DataCenterJoinVO> sc = _dcJoinDao.createSearchCriteria();