Small fixes.
This commit is contained in:
parent
71bf40fedc
commit
7858c20d21
2 changed files with 11 additions and 7 deletions
|
@ -44,6 +44,10 @@ public class DateHelper
|
|||
}
|
||||
else
|
||||
{
|
||||
System.out.println("============= " + time);
|
||||
System.out.println("============= " + time.get(Calendar.DAY_OF_MONTH));
|
||||
System.out.println("============= " + time.get(Calendar.MONTH) + 1);
|
||||
System.out.println("============= " + time.get(Calendar.YEAR));
|
||||
result = String.format (EUROPEAN_DATE_FORMAT, time.get(Calendar.DAY_OF_MONTH), time.get(Calendar.MONTH) + 1, time.get(Calendar.YEAR));
|
||||
}
|
||||
|
||||
|
@ -107,7 +111,7 @@ public class DateHelper
|
|||
}
|
||||
else
|
||||
{
|
||||
result = String.format (RAW_DATE_FORMAT, time.get(Calendar.MONTH), time.get(Calendar.DAY_OF_MONTH) + 1, time.get(Calendar.YEAR));
|
||||
result = String.format (RAW_DATE_FORMAT, time.get(Calendar.YEAR), time.get(Calendar.MONTH), time.get(Calendar.DAY_OF_MONTH) + 1);
|
||||
}
|
||||
|
||||
//
|
||||
|
|
|
@ -65,9 +65,9 @@ public class DateTimeHelper
|
|||
}
|
||||
else
|
||||
{
|
||||
result = String.format (ISO_DATE_FORMAT, time.get(Calendar.DAY_OF_MONTH),
|
||||
result = String.format (ISO_DATE_FORMAT, time.get(Calendar.YEAR),
|
||||
time.get(Calendar.MONTH) + 1,
|
||||
time.get(Calendar.YEAR),
|
||||
time.get(Calendar.DAY_OF_MONTH),
|
||||
time.get(Calendar.HOUR_OF_DAY),
|
||||
time.get(Calendar.MINUTE),
|
||||
time.get(Calendar.SECOND));
|
||||
|
@ -91,8 +91,8 @@ public class DateTimeHelper
|
|||
}
|
||||
else
|
||||
{
|
||||
result = String.format (AMERICAN_DATE_FORMAT, time.get(Calendar.DAY_OF_MONTH),
|
||||
time.get(Calendar.MONTH) + 1,
|
||||
result = String.format (AMERICAN_DATE_FORMAT, time.get(Calendar.MONTH) + 1,
|
||||
time.get(Calendar.DAY_OF_MONTH),
|
||||
time.get(Calendar.YEAR),
|
||||
time.get(Calendar.HOUR_OF_DAY),
|
||||
time.get(Calendar.MINUTE),
|
||||
|
@ -117,9 +117,9 @@ public class DateTimeHelper
|
|||
}
|
||||
else
|
||||
{
|
||||
result = String.format (RAW_DATE_FORMAT, time.get(Calendar.DAY_OF_MONTH),
|
||||
result = String.format (RAW_DATE_FORMAT, time.get(Calendar.YEAR),
|
||||
time.get(Calendar.MONTH) + 1,
|
||||
time.get(Calendar.YEAR),
|
||||
time.get(Calendar.DAY_OF_MONTH),
|
||||
time.get(Calendar.HOUR_OF_DAY),
|
||||
time.get(Calendar.MINUTE),
|
||||
time.get(Calendar.SECOND));
|
||||
|
|
Loading…
Reference in a new issue