[#3637] - 400 bad request - Unparseable date

Category:
Bug report
Priority:
Normal
Status:
New
Project: Severity:
Minor
Resolution:
Open
Component: Reproducibility:
Always
Assigned to:

Hi,

i cant create schedule when i use my start date paramters. i get this error back (firebug):

{"message":"Unable to unmarshal (to type [simple type, class java.lang.String]): Unparseable date: \"0NaN-NaN-NaN NaN:NaN\" (through reference chain: com.jaspersoft.jasperserver.jaxrs.job.ReportJobClientExtension[\"trigger\"]->com.jaspersoft.jasperserver.jaxrs.job.ReportJobSimpleTriggerClientExtension[\"startDate\"])","errorCode":"illegal.parameter.value.error"}

look at the attachment, there is a screenshot.

what could be the reason?

AttachmentSize
Image icon unbenannt.png12.44 KB
v5.5.0
erik.dittert's picture
Joined: Sep 20 2013 - 7:12am
Last seen: 1 month 10 hours ago

3 Comments:

#1
  • Assigned:nobody»

the problem is the german date for startDate: 22.05.2014 00:00

the scheduler trigger expected englisch format like 2014-05-22 00:00.

how can i fix it?

#2
  • Assigned:» anonymous

in file /opt/jasperreports-server-cp-5.5.0a/apache-tomcat/webapps/jasperserver/scripts/scheduler/model/job.js you have to change this:

row 5
from: var UI_DATE_PATTERN = "YYYY-MM-DD HH:mm";
to: var UI_DATE_PATTERN = "DD.MM.YYYY HH:mm";

row 766
from: data.trigger.startDate = moment(data.trigger.startDate).format(SERVICE_DATE_PATTERN);
to: data.trigger.startDate = moment(data.trigger.startDate,UI_DATE_PATTERN).format(SERVICE_DATE_PATTERN);

thats only a workaround

#3
  • Assigned:nobody»

On JasperServer 5.6.1
You can override this bug by changing the date by hand mettrent it in the format "YYYY-MM-DD HH:MM"

Feedback
randomness