Developer forum

Forum » CMS - Standard features » Problem with item integer field type and the way they are presented to the editor

Problem with item integer field type and the way they are presented to the editor

Hans Ravnsfjall
Hans Ravnsfjall
Reply

See this image

https://www.screencast.com/t/X8HOn5tRrt

The problem is that this is a field where the editor enters a year (YYYY). This should be possible to present to the editor like 2016 and not 2,016 (no thousand seperator)

Now the reason we donĀ“t use a datetype field or a tekst field is, that this we run an index on this field where we have a filtereing where you can select a time span containing whole years. Eg. show all projects from 2010 - 2017

Like this:

https://www.screencast.com/t/HtmNcXqr

 

And I was informed by the support that we should use the integer field type.

Anyhow, it should be possible to choose eg the width of the input field that is presented to the editor, and also it should be possible to select if the field should show thousand seperator or not.

 

Br

 

Hans

 

 

 


Replies

 
Dynamicweb Employee
Carsten Boll
Reply

Integer fields are always going to be rendered as integer fields in the backend, I don't see how this can be any different?

I think, considering the risk of bad data when using a text field and the complexities of working with date or datetime fields in the index and in your templates, I agree with support that it's a relatively small UX tradeoff to have the thousand separator shown in the backend..

 

You must be logged in to post in the forum