bug 12624: fixed list public isos for regular user

status 12624: resolved fixed
This commit is contained in:
Alena Prokharchyk 2011-12-19 10:41:40 -08:00
parent 2bab7dc838
commit f3f752b5be
2 changed files with 3 additions and 2 deletions

View File

@ -1294,8 +1294,9 @@ public class ManagementServerImpl implements ManagementServer {
} else {
domain = _domainDao.findById(DomainVO.ROOT_DOMAIN);
}
List<HypervisorType> hypers = null;
if( ! isIso ) {
if(!isIso) {
hypers = _resourceMgr.listAvailHypervisorInZone(null, null);
}
Set<Pair<Long, Long>> templateZonePairSet = new HashSet<Pair<Long, Long>>();

View File

@ -575,7 +575,7 @@ public class VMTemplateDaoImpl extends GenericDaoBase<VMTemplateVO, Long> implem
}
} else if (templateFilter == TemplateFilter.all && caller.getType() == Account.ACCOUNT_TYPE_ADMIN) {
whereClause += attr;
} else if (caller.getType() != Account.ACCOUNT_TYPE_ADMIN) {
} else if (caller.getType() != Account.ACCOUNT_TYPE_ADMIN && !isIso) {
return templateZonePairList;
}