Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User
    Join Date
    Mar 2011
    Posts
    11
    Vote Rating
    0
    gregoryextjs is on a distinguished road

      0  

    Default Datefield not working with format m/Y

    Datefield not working with format m/Y


    Hi,

    the datefield is not working with format m/Y

    Today is the 29 March 2011 (french) and i have a datefield with format: m/Y.

    I put the value : '02/2011' and the datefield changes my value to '03/2011' because the day is not defined and the datefield adds the day "29" to my value "02/2011". But because the 29/02/2011 does not exist, the datefield changes it to '29/03/2011' -> '03/2011'.

    I don't want the day in my datefield and I don't want the datefield to change my date. If there is a date problem, I just want an error message.

    Ext-js version : 3.1.1
    Sorry for my english.

    Thanks in advance,
    Greg

  2. #2
    Sencha User
    Join Date
    Apr 2009
    Posts
    3
    Vote Rating
    0
    losinggeneration is on a distinguished road

      0  

    Default


    I had just reported the same issue http://www.sencha.com/forum/showthre...no-day-is-used

  3. #3
    Sencha User
    Join Date
    Mar 2011
    Posts
    11
    Vote Rating
    0
    gregoryextjs is on a distinguished road

      0  

    Default


    I just saw it a minute ago

    Sorry

  4. #4
    Sencha User
    Join Date
    Apr 2009
    Posts
    3
    Vote Rating
    0
    losinggeneration is on a distinguished road

      0  

    Default


    Quite alright. I'm just glad someone else noticed it. You did give me a hint that allows me to work around the issue (though it works for me because each application is pretty self contained. For bigger projects this probably wouldn't work.) What I'm doing is setting the Date.default.d = 15 so it's not using todays date. This guarantees the day is in the current month.

  5. #5
    Sencha User
    Join Date
    Mar 2011
    Posts
    11
    Vote Rating
    0
    gregoryextjs is on a distinguished road

      0  

    Default


    I added this code to my prototype file :

    Ext.apply(Date.defaults, {
    d: 15 // default to first day of the month
    });

    and it works fine !!

    Thank you !!!!!!

    Greg

  6. #6
    Sencha User
    Join Date
    Feb 2011
    Posts
    28
    Vote Rating
    0
    optiplex is on a distinguished road

      0  

    Default


    don't worry
    i will try it.
    The Game is Over

Similar Threads

  1. Regarding format in datefield
    By roshniblr in forum Ext 3.x: Help & Discussion
    Replies: 18
    Last Post: 5 Nov 2009, 6:41 AM
  2. DateField format from IE and FF
    By kumo in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 4 Aug 2009, 8:01 AM
  3. datefield format
    By tomlobato in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 13 May 2009, 6:47 AM
  4. [2.1][FIXED] Datefield format bug? d-M-Y not working
    By seymores in forum Ext 2.x: Bugs
    Replies: 31
    Last Post: 13 Jul 2008, 11:07 PM
  5. [2.1][OPEN] TimeField format bug? H:i:s-value with H:i-format not working
    By codeworx in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 21 May 2008, 8:56 AM

Thread Participants: 2