Placeholder Text DateTime not shown?

I'm trying to show a placeholder text when a datetime field is empty, but on the frontend it's not displaying (Chrome). The dateTime field is inside a dataview with Editable "Yes" and read-only style "control". Settings of the field itself are Editable "Never" and read-only style "Based on data view (control)". I already have a placeholder text on a decimal field with the exact same settings and that one is displaying correctly. The only difference is that this one is a datetime field (and it's inside a tab container but that shouldn't make any difference right?).  I've verified in the database that this field is indeed empty, and I've tried every possible combination of settings in terms of editabillity and read-only style.  Any suggestions anyone?
2 answers

Hi Reinout,

Placeholder is ment to give a suggestion to the user of what to enter in the field. So when you have your control not-editable it is not shown.

If you really want to show this you could create an extra attribute which is filled with the text you want to show when the data is empty and else with the date value. You could use a calculated field for this, but keep in mind that this is a performance braker for entities with a large number of objects because it's calculated every time you retrieve the object from the database. So you could also use a stored value for this which you calculate when committing the object in which there are several approaches available as well.



Thanks for your answer Corné!

I guess that makes sense, although I could think of a million situations where a placeholder can be useful for non-editable fields...

Plus, I do have a placeholder text showing up for another non-editable field.  That must be by accident then? 

Anyway, thanks again for your reply.