Page 1 of 1

Listit2 won't display time

Posted: Wed Sep 03, 2014 8:11 pm
by burlington
The title really says it all. Listit2 displays the date fine enough BUT when there is a time field, it shows a date instead.
Running CMSMS 1.11.9 and Listit2 version 1.4.1
Any ideas folks?
Thanks
Martin

Re: Listit2 won't display time

Posted: Thu Sep 04, 2014 8:01 am
by velden
The default summary template (and I guess the same for detail template) has this code:

Code: Select all

{elseif $fielddef.type == 'SelectDateTime'}
					{$fielddef.name}: {$fielddef.value|cms_date_format}<br />
The cms_date_format modifier probably has a default format for a date and not time, hence printing current date.

So, either remove it, of use a custom format for your demands, e.g:

Code: Select all

{$fielddef.value|cms_date_format:"%H:%M"}

Re: Listit2 won't display time

Posted: Thu Sep 04, 2014 12:29 pm
by burlington
Thanks Velden. Worked fine.

By the way, do you know what file controls the input template. I am getting huge boxes for each field I want to use. The maximum size allowed does not seem to affect the size of the entry boxes.

Martin

Re: Listit2 won't display time

Posted: Thu Sep 04, 2014 12:42 pm
by velden
This might help: http://docs.cmsmadesimple.org/customizi ... -templates

Though not sure if it's usable with ListIt2