2 * Copyright (C) 2015 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
9 package eu
.etaxonomy
.cdm
.vaadin
.ui
;
18 import java
.util
.logging
.Logger
;
20 import javax
.servlet
.annotation
.WebServlet
;
22 import com
.vaadin
.annotations
.Theme
;
23 import com
.vaadin
.annotations
.Widgetset
;
24 import com
.vaadin
.navigator
.Navigator
;
25 import com
.vaadin
.server
.VaadinRequest
;
26 import com
.vaadin
.spring
.server
.SpringVaadinServlet
;
27 import com
.vaadin
.ui
.UI
;
29 import eu
.etaxonomy
.cdm
.vaadin
.component
.StatusComposite
;
33 @Widgetset("eu.etaxonomy.cdm.vaadin.AppWidgetSet")
34 public class StatusEditorUI
extends AbstractAuthenticatedUI
{
38 private static final String FIRST_VIEW
= "editstatus";
40 private final static Logger logger
=
41 Logger
.getLogger(StatusEditorUI
.class.getName());
43 * NOTE: I it necessary to map the URLs starting with /VAADIN/* since none of the
44 * @WebServlets is mapped to the root path. It is sufficient to configure one of the
45 * servlets with this path see BookOfVaadin 5.9.5. Servlet Mapping with URL Patterns
47 @WebServlet(value
= {"/app/editstatus/*", "/VAADIN/*"}, asyncSupported
= true)
48 public static class Servlet
extends SpringVaadinServlet
{
52 protected void doInit(VaadinRequest request
) {
53 // FIXME: remove this when testing is done
54 //setIgnoreAuthentication(true);
56 getPage().setTitle("Status Editor");
57 StatusComposite statusEditor
= new StatusComposite();
58 UI
.getCurrent().getNavigator().addView(FIRST_VIEW
, statusEditor
);
63 public String
getFirstViewName() {