mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
. Changing default view after Login to the MyAlfresco dashboard for all users
- so new users see the helpful Getting Started page when logging in - this client config value can be changed if the sys admin does not want the MyAlfresco to be the default page . Add User Preference to change the default view after login - so users familiar with the system can change their default view back to Home Space or similar . Added client config to allow Guest user access to Configure Dashboard action (set to 'false' by default) git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@3652 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -40,7 +40,7 @@ public class ClientConfigElement extends ConfigElementAdapter
|
||||
private String editLinkType = "http";
|
||||
private String homeSpacePermission = null;
|
||||
private boolean ajaxEnabled = false;
|
||||
private String initialLocation = null;
|
||||
private String initialLocation = "myalfresco";
|
||||
|
||||
/**
|
||||
* Default Constructor
|
||||
|
@@ -37,6 +37,7 @@ public class DashboardsConfigElement extends ConfigElementAdapter
|
||||
|
||||
private Map<String, LayoutDefinition> layoutDefs = new LinkedHashMap<String, LayoutDefinition>(4, 1.0f);
|
||||
private Map<String, DashletDefinition> dashletDefs = new LinkedHashMap<String, DashletDefinition>(8, 1.0f);
|
||||
private boolean allowGuestConfig = false;
|
||||
|
||||
/**
|
||||
* Default constructor
|
||||
@@ -77,9 +78,24 @@ public class DashboardsConfigElement extends ConfigElementAdapter
|
||||
combinedElement.layoutDefs.putAll(this.layoutDefs);
|
||||
combinedElement.layoutDefs.putAll(newElement.layoutDefs);
|
||||
|
||||
if (newElement.allowGuestConfig != combinedElement.allowGuestConfig)
|
||||
{
|
||||
combinedElement.allowGuestConfig = newElement.allowGuestConfig;
|
||||
}
|
||||
|
||||
return combinedElement;
|
||||
}
|
||||
|
||||
/*package*/ void setAllowGuestConfig(boolean allow)
|
||||
{
|
||||
this.allowGuestConfig = allow;
|
||||
}
|
||||
|
||||
public boolean getAllowGuestConfig()
|
||||
{
|
||||
return this.allowGuestConfig;
|
||||
}
|
||||
|
||||
/*package*/ void addLayoutDefinition(LayoutDefinition def)
|
||||
{
|
||||
this.layoutDefs.put(def.Id, def);
|
||||
|
@@ -37,6 +37,7 @@ public class DashboardsElementReader implements ConfigElementReader
|
||||
public static final String ELEMENT_LAYOUT = "layout";
|
||||
public static final String ELEMENT_DASHLETS = "dashlets";
|
||||
public static final String ELEMENT_DASHLET = "dashlet";
|
||||
public static final String ELEMENT_GUESTCONFIG = "allow-guest-config";
|
||||
public static final String ATTR_ID = "id";
|
||||
public static final String ATTR_COLUMNS = "columns";
|
||||
public static final String ATTR_COLUMNLENGTH = "column-length";
|
||||
@@ -85,6 +86,13 @@ public class DashboardsElementReader implements ConfigElementReader
|
||||
configElement.addDashletDefinition(dashletDef);
|
||||
}
|
||||
}
|
||||
|
||||
Element guestConfigElement = element.element(ELEMENT_GUESTCONFIG);
|
||||
if (guestConfigElement != null)
|
||||
{
|
||||
boolean allow = Boolean.parseBoolean(guestConfigElement.getTextTrim());
|
||||
configElement.setAllowGuestConfig(allow);
|
||||
}
|
||||
}
|
||||
|
||||
return configElement;
|
||||
|
Reference in New Issue
Block a user