@Override public List<ProjectPermission> listProjectPermissions(long projectId) { List<ProjectPermission> permissions = projectPermissionDao.selectByProjectId(projectId); // TODO performance tuning for (ProjectPermission permission : permissions) { fillProjectPermission(permission); } return permissions; }
@Override public void createProjectPermission(ProjectPermission permission) { projectPermissionDao.insert(permission); fillProjectPermission(permission); }
@Override public void removeProjectPermission(ProjectPermission permission) { projectPermissionDao.update(permission); fillProjectPermission(permission); }
@Override public ProjectPermission getProjectPermissioin(long permissionId) { ProjectPermission permission = projectPermissionDao.select(permissionId); return fillProjectPermission(permission); }