1. #1
    Sencha User
    Join Date
    Nov 2011
    Posts
    10
    Vote Rating
    0
    rherwig is on a distinguished road

      0  

    Default RowEditor erronously marks NumberField setPropertyEditorType(Short.class) as modified

    RowEditor erronously marks NumberField setPropertyEditorType(Short.class) as modified


    When I define a NumberField and call setPropertyEditorType() using java.lang.Short.class the RowEditor ALWAYS marks the field as modified. However (comma) if I set it to Integer.class it works fine. Am I missing something here??

    Code that defines the RowEditor:
    ------------------------------------------------------------------------------------------------------
    private static NumberField getSmallintField(String allowNulls) {
    NumberField smallintField = new NumberField();
    // --- allow/disallow nulls
    if (MetadataColumnNullsMapper.SOR_COLUMN_ALLOW_NULLS.equals(allowNulls)) {
    smallintField.setAllowBlank(true);
    } else {
    smallintField.setAllowBlank(false);
    }
    // -- disallow decimals
    smallintField.setAllowDecimals(false);

    // --- define editorType (defaults to Double)
    smallintField.setPropertyEditorType(Integer.class);

    // QUESTION: for 'some' reason if I use Short.class here the RowEditor ALWAYS thinks the column has been modified?!?!
    //smallintField.setPropertyEditorType(Short.class);
    // --- range (-32,768 to +32,767)
    smallintField.setMinValue(Short.MIN_VALUE); // -2^15
    smallintField.setMaxValue(Short.MAX_VALUE); // 2^15 - 1

    // TODO: when attempting to enter a SMALLINT larger than +32,767 the RowEditor doesn't display an error, it just disables the 'Save' button; it should also display an error.

    return smallintField;
    }
    Attached Files

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..."