diff --git a/ccm-core/src/main/java/com/arsdigita/ui/admin/applications/AdminApplicationCreator.java b/ccm-core/src/main/java/com/arsdigita/ui/admin/applications/AdminApplicationCreator.java deleted file mode 100644 index 9c6338ad2..000000000 --- a/ccm-core/src/main/java/com/arsdigita/ui/admin/applications/AdminApplicationCreator.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (C) 2015 LibreCCM Foundation. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, - * MA 02110-1301 USA - */ -package com.arsdigita.ui.admin.applications; - -import org.libreccm.web.ApplicationCreator; -import org.libreccm.web.ApplicationRepository; -import org.libreccm.web.ApplicationType; -import org.libreccm.web.CcmApplication; - -import javax.enterprise.context.RequestScoped; -import javax.inject.Inject; - -import static com.arsdigita.ui.admin.AdminUiConstants.*; - -/** - * - * @author Jens Pelzetter - */ -@RequestScoped -public class AdminApplicationCreator - implements ApplicationCreator { - - @Inject - private ApplicationRepository appRepository; - - @Override - public CcmApplication createInstance(final String primaryUrl, - final ApplicationType type) { - if (!ADMIN_PAGE_URL.equals(primaryUrl)) { - throw new IllegalArgumentException( - "CCM Admin is a singleton application" - + "which is mounted at /admin"); - } - - return appRepository.retrieveApplicationForPath(primaryUrl).get(); - } - - -} diff --git a/ccm-core/src/main/java/com/arsdigita/ui/admin/applications/AdminApplicationSetup.java b/ccm-core/src/main/java/com/arsdigita/ui/admin/applications/AdminApplicationSetup.java deleted file mode 100644 index b25a8acff..000000000 --- a/ccm-core/src/main/java/com/arsdigita/ui/admin/applications/AdminApplicationSetup.java +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (C) 2016 LibreCCM Foundation. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, - * MA 02110-1301 USA - */ -package com.arsdigita.ui.admin.applications; - -import java.util.UUID; - -import org.libreccm.modules.InstallEvent; -import org.libreccm.web.CcmApplication; -import org.libreccm.web.AbstractCcmApplicationSetup; - -import static com.arsdigita.ui.admin.AdminUiConstants.*; - -/** - * - * @author Jens Pelzetter - */ -public class AdminApplicationSetup extends AbstractCcmApplicationSetup { - - public static final String ADMIN_APP_NAME = "CcmAdmin"; - - public AdminApplicationSetup(final InstallEvent event) { - super(event); - } - - @Override - public void setup() { - final CcmApplication admin = new CcmApplication(); - admin.setUuid(UUID.randomUUID().toString()); - admin.setApplicationType(ADMIN_APP_TYPE); - admin.setPrimaryUrl(ADMIN_PAGE_URL); - - getEntityManager().persist(admin); - } - -} diff --git a/ccm-core/src/main/java/com/arsdigita/ui/admin/usersgroupsroles/UsersGroupsRolesTab.java b/ccm-core/src/main/java/com/arsdigita/ui/admin/usersgroupsroles/UsersGroupsRolesTab.java deleted file mode 100644 index 10b388c83..000000000 --- a/ccm-core/src/main/java/com/arsdigita/ui/admin/usersgroupsroles/UsersGroupsRolesTab.java +++ /dev/null @@ -1,197 +0,0 @@ -/* - * Copyright (C) 2016 LibreCCM Foundation. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, - * MA 02110-1301 USA - */ -package com.arsdigita.ui.admin.usersgroupsroles; - -import com.arsdigita.ui.admin.usersgroupsroles.users.UserAdmin; -import com.arsdigita.bebop.BoxPanel; -import com.arsdigita.bebop.Component; -import com.arsdigita.bebop.Label; -import com.arsdigita.bebop.List; -import com.arsdigita.bebop.Page; -import com.arsdigita.bebop.PageState; -import com.arsdigita.bebop.Resettable; -import com.arsdigita.bebop.list.ListModel; -import com.arsdigita.bebop.list.ListModelBuilder; -import com.arsdigita.globalization.GlobalizedMessage; -import com.arsdigita.toolbox.ui.LayoutPanel; -import com.arsdigita.ui.admin.usersgroupsroles.groups.GroupAdmin; -import com.arsdigita.ui.admin.usersgroupsroles.roles.RoleAdmin; -import com.arsdigita.util.Assert; -import com.arsdigita.util.LockableImpl; - -import java.util.ArrayList; - -import static com.arsdigita.ui.admin.AdminUiConstants.*; - -/** - * Root component of the administration UI for users, groups and roles. - * This class creates the menu on the left side and connects the menu with the - * specific UIs for users, groups and roles. - * - * @see UserAdmin - * @see GroupAdmin - * @see RoleAdmin - * - * @author Jens Pelzetter - */ -public class UsersGroupsRolesTab extends LayoutPanel { - - private final List sections; - private final java.util.List components = new ArrayList<>(); - private final java.util.List