1. #1
    Sencha Premium Member koushlendr's Avatar
    Join Date
    Sep 2011
    Location
    Bangalore
    Posts
    10
    Vote Rating
    1
    koushlendr is on a distinguished road

      0  

    Question Unanswered: datefield formate error

    Unanswered: datefield formate error


    I have a date field in form, but I don't have any formate config but when i type 1/7/13 it give me below error msg.
    1/7/13 is not a valid date - it must be in the format m/d/y. But if i check same code with sencha online it works without any issue. What I'm doing wrong ?

    Code:
    {
    xtype : 'datefield', 
    fieldLabel : 'Effective Date',
    name : 'effectiveDate'
    }

  2. #2
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,927
    Answers
    656
    Vote Rating
    443
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    So the live API example here work as expected?
    http://docs.sencha.com/ext-js/4-1/#!...orm.field.Date

    Have you tried setting the format as shown in the Date Format Examples?

    Do any formats work?

    Scott.

  3. #3
    Sencha Premium Member koushlendr's Avatar
    Join Date
    Sep 2011
    Location
    Bangalore
    Posts
    10
    Vote Rating
    1
    koushlendr is on a distinguished road

      0  

    Default


    I don't want to define any format as i want to use default format(m/d/y) but default altFormate is getting overridden by local specific file (ext-lang-en.js)

    Ref:
    http://docs.sencha.com/ext-js/4-1/#!/api/Ext.form.field.Date-cfg-altFormats

    ext-lang-en.js // Extjs file from Sencha
    File has one override function to change the altFormats value for english user.

    Ext.define("Ext.locale.en.form.field.Date", {
    override: "Ext.form.field.Date",
    disabledDaysText: "Disabled",
    disabledDatesText: "Disabled",
    minText: "The date in this field must be after {0}",
    maxText: "The date in this field must be before {0}",
    invalidText: "{0} is not a valid date - it must be in the format {1}",
    format: "m/d/y",
    altFormats: "m/d/Y|m-d-y|m-d-Y|m/d|m-d|md|mdy|mdY|d|Y-m-d" // different then default value
    });

    While using the default altFormats provided in the definition of datefield it works fine.
    Why for english user default altformat is different ?

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi