Date widget, year problem

A place for users and developers of the Xataface to discuss and receive support.

Date widget, year problem

Postby umair » Sun Nov 27, 2011 4:32 pm

I have a really odd problem, In my table I have a two fields for date

fieldname type
YOB year(4)
Date Date

In my fields.ini I have

[YOB]
widget:label = "Year of Birth"
visibility:list = hidden
widget:type = date
widget:format = "Y"
widget:minYear = 1920
widget:maxYear = 1970
validators:required = true

[Date] //works fine
widget:label = "Join Date (DD-MM-YYYY)"
visibility:list = hidden
widget:type = date
widget:format = "d-m-Y"
widget:maxYear = 2020
validators:required = true

The YOB field acts in a very weird way, when adding a new record the year selected is saved just fine in the DB and shows correctly in the list and view modes. The problem occurs when you go to the edit tab, the pull down menu doesn't have the right year already selected, it either selects the lowest, highest or 1970(if its in the list) year, in this case it defaults to 1970. The problem seems to be pulling the data from the field for the edit tab only.

Just a note, the [Date] fields works fine including its year field.

So I was looking for any help or explanation for this weird bug.
umair
 
Posts: 9
Joined: Wed Nov 02, 2011 5:18 am

Return to Xataface Users

Who is online

Users browsing this forum: Google [Bot] and 17 guests

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved