Add REST endpoints to get/set default user preferences

GET on /config/server/preferences returns the default user preferences
while PUT on /config/server/preferences allows administrators to set
them.

These REST endpoints only support the options that are stored in the
All-Users repository. This means at the moment only for the 'My' menu
entries a default can be set.

Change-Id: I064dd8baaa798b979938be6cdc2a36ab249bb694
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
This commit is contained in:
Edwin Kempin
2014-04-09 08:28:41 +02:00
parent ecdc64f98b
commit a44a3193af
5 changed files with 151 additions and 41 deletions

View File

@@ -30,5 +30,7 @@ public class Module extends RestApiModule {
child(CONFIG_KIND, "capabilities").to(CapabilitiesCollection.class);
child(CONFIG_KIND, "top-menus").to(TopMenuCollection.class);
get(CONFIG_KIND, "version").to(GetVersion.class);
get(CONFIG_KIND, "preferences").to(GetPreferences.class);
put(CONFIG_KIND, "preferences").to(SetPreferences.class);
}
}