From: Olivier Lamy Date: Mon, 26 Mar 2012 20:46:48 +0000 (+0000) Subject: fix autocomplete quick search box X-Git-Tag: archiva-1.4-M3~941 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=cc7dbe717b47ca88d62585f12d13c3b678ff2a62;p=archiva.git fix autocomplete quick search box git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1305569 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/java/org/apache/archiva/webapp/ui/services/api/DefaultRuntimeInfoService.java b/archiva-modules/archiva-web/archiva-webapp-js/src/main/java/org/apache/archiva/webapp/ui/services/api/DefaultRuntimeInfoService.java index c7408e0c3..5846057c3 100644 --- a/archiva-modules/archiva-web/archiva-webapp-js/src/main/java/org/apache/archiva/webapp/ui/services/api/DefaultRuntimeInfoService.java +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/java/org/apache/archiva/webapp/ui/services/api/DefaultRuntimeInfoService.java @@ -20,6 +20,7 @@ package org.apache.archiva.webapp.ui.services.api; import org.apache.archiva.web.runtime.ArchivaRuntimeInfo; import org.apache.archiva.webapp.ui.services.model.ApplicationRuntimeInfo; +import org.apache.commons.lang.StringUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.stereotype.Service; @@ -60,7 +61,8 @@ public class DefaultRuntimeInfoService applicationRuntimeInfo.setVersion( this.archivaRuntimeInfo.getVersion() ); applicationRuntimeInfo.setBaseUrl( getBaseUrl( httpServletRequest ) ); - SimpleDateFormat sfd = new SimpleDateFormat( "yyyy-MM-dd'T'HH:mm:ssz", new Locale( locale ) ); + SimpleDateFormat sfd = new SimpleDateFormat( "yyyy-MM-dd'T'HH:mm:ssz", + new Locale( StringUtils.isEmpty( locale ) ? "en" : locale ) ); applicationRuntimeInfo.setTimestampStr( sfd.format( new Date( archivaRuntimeInfo.getTimestamp() ) ) ); return applicationRuntimeInfo; diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html index 506772acb..2bbe2b921 100644 --- a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html @@ -10,14 +10,7 @@ - + @@ -56,19 +49,82 @@