Author: sletellier Date: 2011-05-03 16:03:22 +0200 (Tue, 03 May 2011) New Revision: 16 Url: http://chorem.org/repositories/revision/vradi/16 Log: Use constant Modified: trunk/vradi-services/src/main/java/org/chorem/vradi/services/managers/TemplateManager.java Modified: trunk/vradi-services/src/main/java/org/chorem/vradi/services/managers/TemplateManager.java =================================================================== --- trunk/vradi-services/src/main/java/org/chorem/vradi/services/managers/TemplateManager.java 2011-05-03 13:49:28 UTC (rev 15) +++ trunk/vradi-services/src/main/java/org/chorem/vradi/services/managers/TemplateManager.java 2011-05-03 14:03:22 UTC (rev 16) @@ -81,6 +81,8 @@ /** Log. */ private static final Log log = LogFactory.getLog(TemplateManager.class); + public static final String TEMPLATE_DATE_FORMAT = "EEEE, d MMMM yyyy HH:mm:ss"; + protected ApplicationConfig config; protected XComponentContext context = null; @@ -301,7 +303,7 @@ if (value instanceof Date) { ApplicationConfig config = VradiServiceConfiguration.getConfig(); Locale locale = VradiServiceConfigurationHelper.getLocale(config); - DateFormat dateFormat = new SimpleDateFormat("EEEE, d MMMM yyyy HH:mm:ss", locale); + DateFormat dateFormat = new SimpleDateFormat(TEMPLATE_DATE_FORMAT, locale); value = dateFormat.format((Date) value); }