Commit 47e53ef7 authored by michael.simon's avatar michael.simon
Browse files

rename method

parent 9a48c133
......@@ -58,6 +58,6 @@ public interface RegistryDao extends BaseDao<RegistryEntity, Long> {
List<RegistryEntity> findRegistriesForDepro(String serviceShortName);
List<RegistryEntity> findByUserAndNotStatus(UserEntity user,
List<RegistryEntity> findByUserAndNotStatusAndNotHidden(UserEntity user,
RegistryStatus... status);
}
......@@ -235,7 +235,7 @@ public class JpaRegistryDao extends JpaBaseDao<RegistryEntity, Long> implements
}
@Override
public List<RegistryEntity> findByUserAndNotStatus(UserEntity user, RegistryStatus... status) {
public List<RegistryEntity> findByUserAndNotStatusAndNotHidden(UserEntity user, RegistryStatus... status) {
CriteriaBuilder builder = em.getCriteriaBuilder();
CriteriaQuery<RegistryEntity> criteria = builder.createQuery(RegistryEntity.class);
Root<RegistryEntity> root = criteria.from(RegistryEntity.class);
......
......@@ -54,7 +54,7 @@ public interface RegistryService extends BaseService<RegistryEntity, Long> {
List<RegistryEntity> findByServiceAndUserAndNotStatus(ServiceEntity service,
UserEntity user, RegistryStatus... status);
List<RegistryEntity> findByUserAndNotStatus(UserEntity user,
List<RegistryEntity> findByUserAndNotStatusAndNotHidden(UserEntity user,
RegistryStatus... status);
List<RegistryEntity> findRegistriesForDepro(String serviceShortName);
......
......@@ -98,8 +98,8 @@ public class RegistryServiceImpl extends BaseServiceImpl<RegistryEntity, Long> i
}
@Override
public List<RegistryEntity> findByUserAndNotStatus(UserEntity user, RegistryStatus... status) {
return dao.findByUserAndNotStatus(user, status);
public List<RegistryEntity> findByUserAndNotStatusAndNotHidden(UserEntity user, RegistryStatus... status) {
return dao.findByUserAndNotStatusAndNotHidden(user, status);
}
@Override
......
......@@ -69,7 +69,8 @@ public class UserIndexBean {
public void init() {
user = userService.findByIdWithStore(sessionManager.getUserId());
allServiceList = serviceService.findAllPublishedWithServiceProps();
userRegistryList = registryService.findByUserAndNotStatus(user, RegistryStatus.DELETED, RegistryStatus.DEPROVISIONED, RegistryStatus.PENDING);
userRegistryList = registryService.findByUserAndNotStatusAndNotHidden(
user, RegistryStatus.DELETED, RegistryStatus.DEPROVISIONED, RegistryStatus.PENDING);
pendingRegistryList = registryService.findByUserAndStatus(user, RegistryStatus.PENDING);
serviceAccessMap = new HashMap<ServiceEntity, String>(userRegistryList.size());
......
......@@ -162,7 +162,8 @@ public class AuthorizationBean implements Serializable {
}
start = System.currentTimeMillis();
userRegistryList = registryService.findByUserAndNotStatus(user, RegistryStatus.DELETED, RegistryStatus.DEPROVISIONED);
userRegistryList = registryService.findByUserAndNotStatusAndNotHidden(
user, RegistryStatus.DELETED, RegistryStatus.DEPROVISIONED);
end = System.currentTimeMillis();
logger.trace("registered servs loading took {} ms", (end-start));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment