1. #1
    Sencha User
    Join Date
    Jan 2011
    Posts
    2
    Vote Rating
    0
    ryammanuru is on a distinguished road

      0  

    Default Unanswered: Array store not mapping raw data to fields

    Unanswered: Array store not mapping raw data to fields


    Hi,

    I just started on Ext JS and this is my first example with Arraystore. I have a servlet returning data as below.

    Code:
    [
      ["197_170",197,170,-18.4,-21.1,28,14.1,3.3,null,null,"1",null,5,7,"320.941_B",1]
    ]
    When I associate grid with store, I can only see zeroes. Can anyone help me in resolving this?

    Thanks,
    --Rajani

    Code:
    Ext.define('customData', {
        extend: 'Ext.data.Model',
        fields: [{
            name: 'deviceId',
            type: 'string'
        }, {
            name: 'XId100um',
            type: 'float'
        }, {
            name: 'YId100um',
            type: 'float'
        }, {
            name: 'XPosMm',
            type: 'float'
        }, {
            name: 'YPosMm',
            type: 'float'
        }, {
            name: 'RMm',
            type: 'float'
        }, {
            name: 'dieHeightMm',
            type: 'float'
        }, {
            name: 'dieWidthMm',
            type: 'float'
        }, {
            name: 'dieRow',
            type: 'int'
        }, {
            name: 'dieCol',
            type: 'int'
        }, {
            name: 'dieType',
            type: 'string'
        }, {
            name: 'barSuffix',
            type: 'string'
        }, {
            name: 'gridRow',
            type: 'int'
        }, {
            name: 'gridCol',
            type: 'int'
        }, {
            name: 'chipDesignId',
            type: 'string'
        }, {
            name: 'sectionNum',
            type: 'int'
        }] );
    
    var store = Ext.create('Ext.data.ArrayStore', {
        proxy: {
            type : 'ajax',
            url: 'diegrid.action'
        }, 
        model: 'customInfo'
    });
    
    Ext.create('Ext.grid.Panel', {
        title: 'customInfo',
        store: store,
        columns: [{
            header: 'deviceId',
            dataIndex: 'deviceId'
        }, {
            header: 'XId100um',
            dataIndex: 'XId100um'
        }, {
            header: 'YId100um',
            dataIndex: 'YId100um'
        }, {
            header: 'XPosMm',
            dataIndex: 'XPosMm'
        }, {
            header: 'YPosMm',
            dataIndex: 'YPosMm'
        }, {
            header: 'RMm',
            dataIndex: 'RMm'
        }, {
            header: 'dieHeightMm',
            dataIndex: 'dieHeightMm'
        }, {
            header: 'dieWidthMm',
            dataIndex: 'dieWidthMm'
        }, {
            header: 'dieRow',
            dataIndex: 'dieRow'
        }, {
            header: 'dieCol',
            dataIndex: 'dieCol'
        }, {
            header: 'dieType',
            dataIndex: 'dieType'
        }, {
            header: 'barSuffix',
            dataIndex: 'barSuffix'
        }, {
            header: 'gridRow',
            dataIndex: 'gridRow'
        }, {
            header: 'gridCol',
            dataIndex: 'gridCol'
        }, {
            header: 'chipDesignId',
            dataIndex: 'chipDesignId'
        }, {
            header: 'sectionNum',
            dataIndex: 'sectionNum'
        }],
        height: 500,
        renderTo: Ext.get('mygrid')
    });
                    
    store.load();
    Last edited by skirtle; 22 Dec 2011 at 10:10 PM. Reason: Added CODE tags

  2. #2
    Sencha Premium Member skirtle's Avatar
    Join Date
    Oct 2010
    Location
    UK
    Posts
    3,580
    Answers
    540
    Vote Rating
    314
    skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future

      0  

    Default


    Please use [CODE] tags when posting code.

    You've defined a model called customData but on the store your model config is set to customInfo.

Thread Participants: 1

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