From d1ce3540edd9c4784efd5a081b61bded9239bdbd Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Fri, 31 Aug 2012 00:46:46 -0300 Subject: [PATCH] Fix messages locale display. Add Google Ads. --- .../ncontroller/MindmapController.java | 7 +++++- .../src/main/webapp/WEB-INF/app.properties | 7 +++++- .../src/main/webapp/jsp/mindmapList.jsp | 24 +++++++++++++++---- 3 files changed, 31 insertions(+), 7 deletions(-) diff --git a/wise-webapp/src/main/java/com/wisemapping/ncontroller/MindmapController.java b/wise-webapp/src/main/java/com/wisemapping/ncontroller/MindmapController.java index 5208ba7d..abbb92bf 100644 --- a/wise-webapp/src/main/java/com/wisemapping/ncontroller/MindmapController.java +++ b/wise-webapp/src/main/java/com/wisemapping/ncontroller/MindmapController.java @@ -130,7 +130,12 @@ public class MindmapController { @RequestMapping(value = "maps/") public String showListPage(@NotNull Model model) { final Locale locale = LocaleContextHolder.getLocale(); - model.addAttribute("locale", locale.toString().toLowerCase()); + // @Todo: This should be more flexible ... + String localeStr = locale.toString().toLowerCase(); + if ("es".equals(locale.getLanguage()) || "pt".equals(locale.getLanguage())) { + localeStr = locale.getLanguage(); + } + model.addAttribute("locale", localeStr); return "mindmapList"; } diff --git a/wise-webapp/src/main/webapp/WEB-INF/app.properties b/wise-webapp/src/main/webapp/WEB-INF/app.properties index 8444223c..e757b5ed 100755 --- a/wise-webapp/src/main/webapp/WEB-INF/app.properties +++ b/wise-webapp/src/main/webapp/WEB-INF/app.properties @@ -86,4 +86,9 @@ site.baseurl = http://localhost:8080 # Google Analytics Settings ################################################################################## google.analytics.enabled=false -google.analytics.account=UA-XXXX \ No newline at end of file +google.analytics.account=UA-XXXX + +################################################################################## +# Google Ads enable +################################################################################## +google.ads.enabled=false diff --git a/wise-webapp/src/main/webapp/jsp/mindmapList.jsp b/wise-webapp/src/main/webapp/jsp/mindmapList.jsp index 339be14a..db51127e 100644 --- a/wise-webapp/src/main/webapp/jsp/mindmapList.jsp +++ b/wise-webapp/src/main/webapp/jsp/mindmapList.jsp @@ -113,8 +113,24 @@ $('#pPageBtn').click(function () { $('#mindmapListTable_previous').click(); }); - }); + }); + + + +
+ +
+
@@ -123,7 +139,6 @@
-
@@ -213,9 +228,8 @@
- -
- +
+