protected boolean onSubmit(AjaxRequestTarget target, Component contents) { // cascade delete the whole selection GeoServerRoleStore gaStore = null; try { GeoServerRoleService gaService = GeoServerApplication.get().getSecurityManager().loadRoleService(roleServiceName); gaStore = new RoleStoreValidationWrapper(gaService.createStore()); for (GeoServerRole role : removePanel.getRoots()) { gaStore.removeRole(role); } gaStore.store(); } catch (IOException ex) { try {gaStore.load(); } catch (IOException ex2) {}; throw new RuntimeException(ex); } // the deletion will have changed what we see in the page // so better clear out the selection roles.clearSelection(); return true; }
protected boolean onSubmit(AjaxRequestTarget target, Component contents) { // cascade delete the whole selection GeoServerRoleStore gaStore = null; try { GeoServerRoleService gaService = GeoServerApplication.get().getSecurityManager().loadRoleService(roleServiceName); gaStore = new RoleStoreValidationWrapper(gaService.createStore()); for (GeoServerRole role : removePanel.getRoots()) { gaStore.removeRole(role); } gaStore.store(); } catch (IOException ex) { try {gaStore.load(); } catch (IOException ex2) {}; throw new RuntimeException(ex); } // the deletion will have changed what we see in the page // so better clear out the selection roles.clearSelection(); return true; }
protected boolean onSubmit( AjaxRequestTarget target, Component contents) { // cascade delete the whole selection GeoServerRoleStore gaStore = null; try { GeoServerRoleService gaService = GeoServerApplication.get() .getSecurityManager() .loadRoleService(roleServiceName); gaStore = new RoleStoreValidationWrapper(gaService.createStore()); for (GeoServerRole role : removePanel.getRoots()) { gaStore.removeRole(role); } gaStore.store(); } catch (IOException ex) { try { gaStore.load(); } catch (IOException ex2) { } ; throw new RuntimeException(ex); } // the deletion will have changed what we see in the page // so better clear out the selection roles.clearSelection(); return true; }