0

datebox: can't choose 2010-02/2010-04/2010-06/... if today is '2010-03-31' when format='yyyy-MM'

asked 2010-03-31 21:53:40 +0800

lovetide gravatar image lovetide
169 1 7

updated 2010-03-31 22:03:39 +0800

I encountered this strange behaviour when I try to adjust the value of a datebox.

it seems if datebox.format='yyyy-MM' then DAY_OF_MONTH will not changed when adjusting date.

tested on zk-3.6.4 & zk-5.0.1(live demo)

<datebox format='yyyy-MM' onCreate='self.value=new Date(2010-1900,03-1,31)'/>

delete flag offensive retag edit

1 Reply

Sort by ยป oldest newest

answered 2010-04-06 02:57:08 +0800

jimmyshiau gravatar image jimmyshiau
4921 5
http://www.zkoss.org/ ZK Team

updated 2010-04-06 02:58:02 +0800

Hi lovetide,
The getValue of the Datebox will parse the text in the input element ( like "2010-03"),
so the DAY_OF_MONTH always the same,
maybe you can post a feature request.

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2010-03-31 21:53:40 +0800

Seen: 325 times

Last updated: Apr 06 '10

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More