View Issue Details

IDProjectCategoryView StatusLast Update
0026906mantisbtbugtrackerpublic2020-05-18 16:04
Reportersandyj Assigned Todregad  
Status closedResolutionduplicate 
Summary0026906: Due_date_default setting is not populating when specific normal_date_format configured

When configuring a due date default value, the default due date value is not appearing when creating new tickets.

Testing shows that this only occurs when the normal_date_format has been configured to include "D" or "M" denoting textual representation of day or month.

Steps To Reproduce

Configure due_date_default to any value (e.g. 'today', '+4 days')
configure normal_date_format to include 'D' or 'M' (e.g. d-M-Y H:i)
report an issue - you will see due date default is not populated i.e. due date is blank
configure normal_date_format removing 'D' and/or 'M' (e.g. d-m-Y H:i)
report an issue - this field is now populated.

TagsNo tags attached.


duplicate of 0022558 assignedsyncguru Problem with datepicker and custom date format 




2020-04-22 09:51

developer   ~0063890

I can reproduce this on my dev box.



2020-04-22 10:24

developer   ~0063891

@sandyj Did you set $g_datetime_picker_format as appropriate to match the $g_normal_date_format config ?



2020-04-22 21:59

reporter   ~0063896

Last edited: 2020-04-22 21:59

@dregad no, but tested it just now. If I set:

  1. date_picker_format to be same as normal_date_format without an "M" then this breaks and due date default does NOT populate
  2. date_picker_format to be the same at normal_date_format including an "M" then due date default does NOT populate
  3. date_picker_format to contain "M" and normal_date_format without an "M" then due date default does NOT populate (this worked previous to adding date_picker config)
  4. date_picker_format without an "M" and normal_date_format including an "M" then due date default does NOT populate.

So looks like date_picker config does not fix the issue and breaks the working condition. Date setting I was using to test is d-M-Y H:i or d-m-Y H:i



2020-04-23 05:00

developer   ~0063899

Last edited: 2020-04-23 05:00

Not sure you're aware that $g_datetime_picker_format uses moment.js format, not the PHP standard used for our other date formats.

In your case, PHP M (3 letter month) should be MMM, so the following config works for me:

$g_normal_date_format = 'd-M-Y H:i';
$g_datetime_picker_format = 'D-MMM-Y HH:mm';

Closing as duplicate of 0022558.