minor fixes
git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/gcube-ckan-datacatalog@129810 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
cd7ea087bf
commit
c57d8896ee
|
@ -20,6 +20,7 @@ import org.apache.http.HttpStatus;
|
|||
import org.gcube.application.framework.core.session.ASLSession;
|
||||
import org.gcube.application.framework.core.session.SessionManager;
|
||||
import org.gcube.common.scope.api.ScopeProvider;
|
||||
import org.gcube.datacatalogue.ckanutillibrary.CKanUtils;
|
||||
import org.gcube.datacatalogue.ckanutillibrary.CKanUtilsImpl;
|
||||
import org.gcube.portal.custom.scopemanager.scopehelper.ScopeHelper;
|
||||
import org.gcube.portlets.gcubeckan.gcubeckandatacatalog.client.GcubeCkanDataCatalogService;
|
||||
|
@ -73,7 +74,7 @@ public class GcubeCkanDataCatalogServiceImpl extends RemoteServiceServlet implem
|
|||
* Since it needs the scope, we need to check if it is null or not
|
||||
* @return
|
||||
*/
|
||||
private CKanUtilsImpl getCkanUtilsObj(){
|
||||
private CKanUtils getCkanUtilsObj(){
|
||||
|
||||
if(instance == null){
|
||||
synchronized(LOCK){
|
||||
|
@ -282,7 +283,7 @@ public class GcubeCkanDataCatalogServiceImpl extends RemoteServiceServlet implem
|
|||
|
||||
}else{
|
||||
|
||||
CKanUtilsImpl ckanUtils = getCkanUtilsObj();
|
||||
CKanUtils ckanUtils = getCkanUtilsObj();
|
||||
|
||||
// first of all, check if the user is a sysadmin in the catalog (in this case he can do everything)
|
||||
boolean isSysAdmin = ckanUtils.isSysAdmin(username, getUserCKanTokenFromSession());
|
||||
|
|
|
@ -10,7 +10,7 @@ import java.util.Map;
|
|||
import java.util.Map.Entry;
|
||||
|
||||
import org.gcube.application.framework.core.session.ASLSession;
|
||||
import org.gcube.datacatalogue.ckanutillibrary.CKanUtilsImpl;
|
||||
import org.gcube.datacatalogue.ckanutillibrary.CKanUtils;
|
||||
import org.gcube.datacatalogue.ckanutillibrary.models.RolesIntoOrganization;
|
||||
import org.gcube.datacatalogue.metadatadiscovery.DataCalogueMetadataFormatReader;
|
||||
import org.gcube.datacatalogue.metadatadiscovery.bean.MetadataType;
|
||||
|
@ -89,7 +89,7 @@ public class UserUtil {
|
|||
* @param groupName the current groupName
|
||||
* @param ckanUtils ckanUtils
|
||||
*/
|
||||
public static CkanRole getHighestRole(String currentScope, String username, String groupName, CKanUtilsImpl ckanUtils){
|
||||
public static CkanRole getHighestRole(String currentScope, String username, String groupName, CKanUtils ckanUtils){
|
||||
|
||||
// base role as default value
|
||||
CkanRole toReturn = CkanRole.MEMBER;
|
||||
|
@ -288,7 +288,7 @@ public class UserUtil {
|
|||
* @param ckanLicensesKey
|
||||
* @param ckanUtils
|
||||
*/
|
||||
public static void getLicenses(ASLSession session, String ckanLicensesKey, CKanUtilsImpl ckanUtils) {
|
||||
public static void getLicenses(ASLSession session, String ckanLicensesKey, CKanUtils ckanUtils) {
|
||||
|
||||
try{
|
||||
String username = session.getUsername();
|
||||
|
@ -312,7 +312,7 @@ public class UserUtil {
|
|||
* @param ckanUtils
|
||||
*/
|
||||
public static void getUserOrganizationsList(ASLSession session,
|
||||
String ckanOrganizationsPublishKey, CKanUtilsImpl ckanUtils, String token) {
|
||||
String ckanOrganizationsPublishKey, CKanUtils ckanUtils, String token) {
|
||||
|
||||
try{
|
||||
|
||||
|
@ -359,7 +359,7 @@ public class UserUtil {
|
|||
* @param ckanUtils
|
||||
*/
|
||||
public static void getMetadataProfilesList(ASLSession session,
|
||||
String ckanProfilesKey, CKanUtilsImpl ckanUtils) {
|
||||
String ckanProfilesKey, CKanUtils ckanUtils) {
|
||||
|
||||
try{
|
||||
|
||||
|
|
Loading…
Reference in New Issue