[vlma-devel] commit: Add a message when there is no satellite/server to display. ( Adrien Grand )

git version control git at videolan.org
Sun Sep 14 17:01:19 CEST 2008


vlma | branch: master | Adrien Grand <jpountz at videolan.org> | Sun Sep 14 15:02:40 2008 +0200| [d6b89cce2e30113c78b508f413dec4e3d34e2b2a] | committer: Adrien Grand 

Add a message when there is no satellite/server to display.

> http://git.videolan.org/gitweb.cgi/vlma.git/?a=commit;h=d6b89cce2e30113c78b508f413dec4e3d34e2b2a
---

 vlma-webapp/src/main/resources/messages.properties |    2 ++
 .../src/main/resources/messages_fr.properties      |    2 ++
 .../WEB-INF/jsp/satellite/satellitelist_right.jsp  |   11 ++++++++++-
 .../webapp/WEB-INF/jsp/server/serverlist_right.jsp |   10 ++++++++++
 4 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/vlma-webapp/src/main/resources/messages.properties b/vlma-webapp/src/main/resources/messages.properties
index 07e5ab6..9e93a04 100644
--- a/vlma-webapp/src/main/resources/messages.properties
+++ b/vlma-webapp/src/main/resources/messages.properties
@@ -99,6 +99,7 @@ servers.adding = Serveur adding
 servers.list = Server list
 servers.graphs = Server graphs
 servers.details = Details...
+servers.empty = There is no server in the database.
 servers.remove = Remove
 servers.unreachable = Unreachable!
 servers.add.error.not-specified = Can't add a server with those parameters.
@@ -158,6 +159,7 @@ satellites.add = Add a satellite
 satellites.adding = Satellite adding
 satellites.list = Satellite list
 satellites.edit = Editing...
+satellites.empty = There is no satellite in the database.
 satellites.remove = Remove
 satellites.add.error.not-specified = Can't add a satellite with those parameters.
 satellites.add.error.existingname = A satellite with this name already exists.
diff --git a/vlma-webapp/src/main/resources/messages_fr.properties b/vlma-webapp/src/main/resources/messages_fr.properties
index 2662ec2..dd05c23 100644
--- a/vlma-webapp/src/main/resources/messages_fr.properties
+++ b/vlma-webapp/src/main/resources/messages_fr.properties
@@ -96,6 +96,7 @@ servers.adding = Ajout d'un serveur
 servers.list = Liste des serveurs
 servers.graphs = Graphs des serveurs
 servers.details = Détails...
+servers.empty = Il n'y a aucun serveur dans la base de données.
 servers.remove = Supprimer
 servers.unreachable = Pas accessible !
 servers.add.error.not-specified = Impossible d'ajouter un serveur avec ces paramètres.
@@ -155,6 +156,7 @@ satellites.add = Ajouter un satellite
 satellites.adding = Ajout d'un satellite
 satellites.list = Liste des satellites
 satellites.edit = Éditer...
+satellites.empty = Il n'y a aucun satellite dans la base de données.
 satellites.remove = Supprimer
 satellites.add.error.not-specified = Impossible d'ajouter un satellite avec ces paramètres.
 satellites.add.error.existingname = Un satellite de ce nom existe déjà.
diff --git a/vlma-webapp/src/main/webapp/WEB-INF/jsp/satellite/satellitelist_right.jsp b/vlma-webapp/src/main/webapp/WEB-INF/jsp/satellite/satellitelist_right.jsp
index 23e984f..d63d936 100644
--- a/vlma-webapp/src/main/webapp/WEB-INF/jsp/satellite/satellitelist_right.jsp
+++ b/vlma-webapp/src/main/webapp/WEB-INF/jsp/satellite/satellitelist_right.jsp
@@ -1,7 +1,13 @@
-
 <%@ include file="/WEB-INF/jsp/include.jsp" %>
 
 <h1><fmt:message key="satellites.list" /></h1>
+
+<c:choose>
+<c:when test="${empty satellites}">
+    <p><fmt:message key="satellites.empty" /></p>
+</c:when>
+<c:otherwise>
+
 <table width="80%">
     <c:forEach items="${satellites}" var="satellite">
     <tr>
@@ -21,3 +27,6 @@
     </tr>
     </c:forEach>
 </table>
+
+</c:otherwise>
+</c:choose>
\ No newline at end of file
diff --git a/vlma-webapp/src/main/webapp/WEB-INF/jsp/server/serverlist_right.jsp b/vlma-webapp/src/main/webapp/WEB-INF/jsp/server/serverlist_right.jsp
index a0ddeed..991b984 100644
--- a/vlma-webapp/src/main/webapp/WEB-INF/jsp/server/serverlist_right.jsp
+++ b/vlma-webapp/src/main/webapp/WEB-INF/jsp/server/serverlist_right.jsp
@@ -2,6 +2,13 @@
 <%@ include file="/WEB-INF/jsp/include.jsp" %>
 
 <h1><fmt:message key="servers.list" /></h1>
+
+<c:choose>
+<c:when test="${empty servers}">
+    <p><fmt:message key="servers.empty" /></p>
+</c:when>
+<c:otherwise>
+
 <table width="80%">
     <c:forEach items="${servers}" var="server">
     <c:url value="serverview.htm" var="serversViewUrl">
@@ -25,3 +32,6 @@
     </tr>
     </c:forEach>
 </table>
+
+</c:otherwise>
+</c:choose>
\ No newline at end of file



More information about the vlma-devel mailing list