1. #1
    Ext User
    Join Date
    Apr 2010
    Posts
    2
    Vote Rating
    0
    Roland D. is on a distinguished road

      0  

    Default store data from Store(Ext.data.JsonStore) in variable

    store data from Store(Ext.data.JsonStore) in variable


    Hi all. I'm new arround here...

    I need to retrieve data fom my Store and put one field into a variable...something like this:
    Code:
    initStores: function(){
     this.dslista_1 = new Ext.data.JsonStore({
     url: 'listar_L1.php',
       root: 'data',
       idProperty: 'num_controle',
       fields: [
          'id',
          'num_controle',
          'v_placa',
          'v_marca'
    ]
    })
    }
    and then get the value of the field 'v_placa' and put it into a variable:

    variable = store/store_field
    var placa = dslista_1.v_placa; <--- The question is...how can I do that?

    Thx

  2. #2
    Sencha User
    Join Date
    Jun 2009
    Location
    Colorado
    Posts
    51
    Vote Rating
    0
    Keylan will become famous soon enough

      0  

    Default


    You will need to access a specific record inside the store, at which point you can hit the data stored in the record directly. For example, if you knew you had 1 record in the store dslista_1:

    Code:
    var record = dslista_1.getAt(0);
    var placa = record.data.v_placa;

  3. #3
    Ext User
    Join Date
    Apr 2010
    Posts
    2
    Vote Rating
    0
    Roland D. is on a distinguished road

      0  

    Default


    Thanks Keylan.

    That helps

  4. #4
    Sencha User
    Join Date
    Jun 2009
    Location
    Colorado
    Posts
    51
    Vote Rating
    0
    Keylan will become famous soon enough

      0  

    Default


    Glad I could help =D

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar