diff --git a/leshan-server-demo/src/main/java/org/eclipse/leshan/server/demo/LeshanServerDemo.java b/leshan-server-demo/src/main/java/org/eclipse/leshan/server/demo/LeshanServerDemo.java index 2d5d0bbeae..6404df1368 100644 --- a/leshan-server-demo/src/main/java/org/eclipse/leshan/server/demo/LeshanServerDemo.java +++ b/leshan-server-demo/src/main/java/org/eclipse/leshan/server/demo/LeshanServerDemo.java @@ -591,7 +591,7 @@ public static void createAndStartServer(String webAddress, int webPort, String l aHolder.setInitParameter("resourceBase", LeshanServerDemo.class.getClassLoader().getResource("webapp2").toExternalForm()); aHolder.setInitParameter("pathInfoOnly", "true"); - root.addServlet(aHolder, "/v2/*"); + root.addServlet(aHolder, "/*"); // Configuration for old demo DefaultServlet bServlet = new DefaultServlet(); @@ -599,7 +599,7 @@ public static void createAndStartServer(String webAddress, int webPort, String l bHolder.setInitParameter("resourceBase", LeshanServerDemo.class.getClassLoader().getResource("webapp").toExternalForm()); bHolder.setInitParameter("pathInfoOnly", "true"); - root.addServlet(bHolder, "/*"); + root.addServlet(bHolder, "/old/*"); server.setHandler(root); /* **************************************************************** */ @@ -609,11 +609,11 @@ public static void createAndStartServer(String webAddress, int webPort, String l ServletHolder eventServletHolder = new ServletHolder(eventServlet); root.addServlet(eventServletHolder, "/event/*"); // Temporary code to be able to serve both UI root.addServlet(eventServletHolder, "/api/event/*"); - root.addServlet(eventServletHolder, "/v2/api/event/*"); // Temporary code to be able to serve both UI + root.addServlet(eventServletHolder, "/old/api/event/*"); // Temporary code to be able to serve both UI ServletHolder clientServletHolder = new ServletHolder(new ClientServlet(lwServer)); root.addServlet(clientServletHolder, "/api/clients/*"); - root.addServlet(clientServletHolder, "/v2/api/clients/*");// Temporary code to be able to serve both UI + root.addServlet(clientServletHolder, "/old/api/clients/*");// Temporary code to be able to serve both UI ServletHolder securityServletHolder; if (publicKey != null) { @@ -622,7 +622,7 @@ public static void createAndStartServer(String webAddress, int webPort, String l securityServletHolder = new ServletHolder(new SecurityServlet(securityStore, serverCertificateChain[0])); } root.addServlet(securityServletHolder, "/api/security/*"); - root.addServlet(securityServletHolder, "/v2/api/security/*");// Temporary code to be able to serve both UI + root.addServlet(securityServletHolder, "/old/api/security/*");// Temporary code to be able to serve both UI ServletHolder serverServletHolder; if (publicKey != null) { @@ -631,12 +631,12 @@ public static void createAndStartServer(String webAddress, int webPort, String l serverServletHolder = new ServletHolder(new ServerServlet(lwServer, serverCertificateChain[0])); } root.addServlet(serverServletHolder, "/api/server/*"); - root.addServlet(serverServletHolder, "/v2/api/server/*");// Temporary code to be able to serve both UI + root.addServlet(serverServletHolder, "/old/api/server/*");// Temporary code to be able to serve both UI ServletHolder objectSpecServletHolder = new ServletHolder( new ObjectSpecServlet(lwServer.getModelProvider(), lwServer.getRegistrationService())); root.addServlet(objectSpecServletHolder, "/api/objectspecs/*"); - root.addServlet(objectSpecServletHolder, "/v2/api/objectspecs/*");// Temporary code to be able to serve both UI + root.addServlet(objectSpecServletHolder, "/old/api/objectspecs/*");// Temporary code to be able to serve both UI // Register a service to DNS-SD if (publishDNSSdServices) { diff --git a/leshan-server-demo/src/main/resources/webapp/partials/client-list.html b/leshan-server-demo/src/main/resources/webapp/partials/client-list.html index 55a900b0f6..60df366f0f 100644 --- a/leshan-server-demo/src/main/resources/webapp/partials/client-list.html +++ b/leshan-server-demo/src/main/resources/webapp/partials/client-list.html @@ -1,13 +1,11 @@ - -
- -

A new version of Leshan Server Demo based on Vue.js is in development. - This version is already testable here. -
We strongly encourage you to test it and report us bug or feedback as it will be the default one soon. -

-

(If you want to contribute to it or understand this move : see #906)

-
+ +
+ +

This UI is now deprecated and will be removed very soon.

+

The new version of Leshan Server Demo based on Vue.js is now ready and available here.

+

(If you want to contribute to it or understand this move : see #906)

+

Connected clients: {{clients.length}}

diff --git a/leshan-server-demo/src/main/resources/webapp2/index.html b/leshan-server-demo/src/main/resources/webapp2/index.html index f4d72b6694..f2f4e86997 100644 --- a/leshan-server-demo/src/main/resources/webapp2/index.html +++ b/leshan-server-demo/src/main/resources/webapp2/index.html @@ -11,7 +11,7 @@ If you are in development phase and run leshan-server-demo from your ide, you probably missed to launch yarn serve and/or you are not using the right port - to access to the demo, try http://localhost:8088/v2/ + to access to the demo, try http://localhost:8088/
(see leshan-server-demo README for more details)
diff --git a/leshan-server-demo/webapp2/src/components/ClientInfo.vue b/leshan-server-demo/webapp2/src/components/ClientInfo.vue index 42c4c7574b..59b28219c0 100644 --- a/leshan-server-demo/webapp2/src/components/ClientInfo.vue +++ b/leshan-server-demo/webapp2/src/components/ClientInfo.vue @@ -50,9 +50,18 @@ export default { props: { registration: Object, - small: Boolean, - tooltipleft: Boolean, - tooltipbottom: Boolean, + small: { + type: Boolean, + default: false + }, + tooltipleft:{ + type: Boolean, + default: false + }, + tooltipbottom: { + type: Boolean, + default: false + }, }, }; diff --git a/leshan-server-demo/webapp2/src/views/About.vue b/leshan-server-demo/webapp2/src/views/About.vue index f86b35f441..831e2ace60 100644 --- a/leshan-server-demo/webapp2/src/views/About.vue +++ b/leshan-server-demo/webapp2/src/views/About.vue @@ -46,14 +46,14 @@ type="info" elevation="2" max-width="600" - icon="mdi-account-hard-hat" + icon="mdi-alert-decagram" > - This is a work in progress version of our new UI for Leshan Server - Demo. Lot of features are still missing and probably some bugs are - still hidden. If needed, you can still use the old version which - should be available - here. +

+ This is the new UI for Leshan Server Demo. If needed, you can still + use the old version which should be available + here but not for so long as + it will be removed very soon ! +

diff --git a/leshan-server-demo/webapp2/src/views/Clients.vue b/leshan-server-demo/webapp2/src/views/Clients.vue index 0f50ffc15f..fae5f3d3f5 100644 --- a/leshan-server-demo/webapp2/src/views/Clients.vue +++ b/leshan-server-demo/webapp2/src/views/Clients.vue @@ -1,52 +1,76 @@