diff --git a/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataValueObjectModel.java b/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataValueObjectModel.java index a266541..57f89d8 100644 --- a/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataValueObjectModel.java +++ b/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataValueObjectModel.java @@ -91,8 +91,7 @@ public class ConvertToDataValueObjectModel { public static final String TIME_FORMAT = "HH" + HOURS_MINUTES_SEPARATOR + "mm"; - public static List KEYSET_POSSIBLE_DATE = Arrays.asList("start", "end", "created", "updated", "inizio", - "fine", "creato", "aggiornato"); + public static List KEYSET_POSSIBLE_DATE = Arrays.asList("start", "end", "created", "updated", "inizio", "fine", "creato", "aggiornato"); /** * To use case descriptor DV. @@ -765,7 +764,7 @@ public class ConvertToDataValueObjectModel { return formatter.format(instant); } } catch (Exception e) { - LOG.warn("Date format error: ", e); + LOG.warn("Date format error: "+e.getMessage()); } return instantString; @@ -942,27 +941,6 @@ public class ConvertToDataValueObjectModel { Object value = document.get(key); String keyLower = key.toLowerCase(); -// String listAsStringValue = null; -// if(value instanceof LinkedHashMap) { -// LinkedHashMap toListView = (LinkedHashMap) value; -// for (String listValue : toListView.keySet()) { -// listAsStringValue+="" -// } -// -// } - - /* - * ObjectMapper objectMapper = new ObjectMapper(); JavaTimeModule javaTimeModule - * = new JavaTimeModule(); javaTimeModule.addDeserializer(LocalDateTime.class, - * new ParseDeserializer()); // javaTimeModule.addSerializer(LocalDate.class, - * new MyLocalDateSerializer()); objectMapper.registerModule(javaTimeModule); - * - * objectMapper.disable(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS); - * objectMapper.configure(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS, - * false); objectMapper.configure(SerializationFeature. - * WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS, false); - */ - // checking if the key is a Date for (String possibleDate : KEYSET_POSSIBLE_DATE) { if (keyLower.contains(possibleDate)) {