use of org.ovirt.engine.core.common.queries.GetPermissionsForObjectParameters in project ovirt-engine by oVirt.
the class PermissionListModel method syncSearch.
@Override
protected void syncSearch() {
VdcObjectType objType = getObjectType();
GetPermissionsForObjectParameters tempVar = new GetPermissionsForObjectParameters();
tempVar.setObjectId(getEntityGuid());
tempVar.setVdcObjectType(objType);
tempVar.setDirectOnly(false);
tempVar.setRefresh(getIsQueryFirstTime());
tempVar.setAllUsersWithPermission(getAllUsersWithPermission());
super.syncSearch(QueryType.GetPermissionsForObject, tempVar);
}
use of org.ovirt.engine.core.common.queries.GetPermissionsForObjectParameters in project ovirt-engine by oVirt.
the class QuotaPermissionListModel method syncSearch.
@Override
protected void syncSearch() {
GetPermissionsForObjectParameters tempVar = new GetPermissionsForObjectParameters();
tempVar.setObjectId(getEntityGuid());
tempVar.setVdcObjectType(getObjectType());
tempVar.setDirectOnly(false);
tempVar.setRefresh(getIsQueryFirstTime());
tempVar.setRefresh(getIsQueryFirstTime());
Frontend.getInstance().runQuery(QueryType.GetPermissionsForObject, tempVar, new AsyncQuery<QueryReturnValue>(returnValue -> {
ArrayList<Permission> list = returnValue.getReturnValue();
ArrayList<Permission> newList = new ArrayList<>();
for (Permission permission : list) {
if (!permission.getRoleId().equals(ApplicationGuids.quotaConsumer.asGuid())) {
newList.add(permission);
}
}
setItems(newList);
}));
setIsQueryFirstTime(false);
}
Aggregations