1. #1
    Sencha User
    Join Date
    Oct 2009
    Posts
    95
    Answers
    3
    Vote Rating
    1
    Albareto is on a distinguished road

      0  

    Default Answered: One value from jsonResponse missing on my Grid

    Answered: One value from jsonResponse missing on my Grid


    Hi there,

    I have a grid with several columns and all of them show correctly the value except one that for some reason receives an undefined value, this is very weird and I have never seen it before.

    I have created my own columns extending from Ext.grid.column.XXX (depending on the column) and it works perfectly for other values but not for this one, it just gets lost somewhere and I cannot find where, I have debugged since the request is thrown until the renderer but I am still not able to find where this value is lost, has someone seen something like this?

    This is the definition of my column class:

    Code:
    Ext.define('BW.Column',
    {
        extend : 'Ext.grid.column.Column',
        alias : 'widget.bw-column',
        
        constructor : function(c)
        {
            Ext.apply(this, c);
            this.callParent();
        },
        
        renderer : function(value, metaData, record, rowIndex, colIndex, store)
        {
            if (typeof value === 'undefined') return 'value is undefined!'; //just for the example
            return BW.th.templates.plainText.apply({text: BW.exists(value.text) ? value.text : value});
        }
    });
    This is the column as I generate it in my JSP:

    Code:
    {
       "dataIndex": "implementationDate",
       "enableResize": true,
       "flex": 1,
       "text": "Implementation date",
       "hidden": false,
       "isOperation": false,
       "menuDisabled": false,
       "showColumn": true,
       "sortable": true,
       "xtype": "bw-column",
       "cls": "implementationDate "
    }
    Here you have a screenshot of my JSON response:

    jsonResponse.jpg

    where you can see that the implementationDate is present, and this is the output of the grid:

    grid_result.jpg

    Where you can see that for the "Implementation date" column the received value is undefined.

    For all the other values I have no problem but this specific one is just missing.

    Any idea of where my implementationDate value is would be highly appreciated

  2. You should check the store to see whether or not it is populated with data from server. What do your model and store look like?

  3. #2
    Sencha - Community Support Team
    Join Date
    Jan 2012
    Posts
    1,376
    Answers
    346
    Vote Rating
    113
    vietits is a name known to all vietits is a name known to all vietits is a name known to all vietits is a name known to all vietits is a name known to all vietits is a name known to all

      0  

    Default


    You should check the store to see whether or not it is populated with data from server. What do your model and store look like?

  4. #3
    Sencha User
    Join Date
    Oct 2009
    Posts
    95
    Answers
    3
    Vote Rating
    1
    Albareto is on a distinguished road

      0  

    Default


    You pushed the correct button, Sir. I had a missconfiguration on the Model. Solved now

    Thanks for your support!!

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