Threaded View

  1. #1
    Sencha User
    Join Date
    Sep 2011
    Posts
    64
    Answers
    2
    Vote Rating
    0
    punith.mailme is on a distinguished road

      0  

    Exclamation Answered: Data add from checkbox model grid to simple grid.

    Answered: Data add from checkbox model grid to simple grid.


    Hi All,

    'searchPanel grid[action=addtrimsSelect]': {
    select: function(model, record, index) {
    this.getSelectedTrimsStore().add(record);
    Ext.getCmp('selectedBodyTrimPanel').getView().refresh();
    },

    deselect: function(model, record, index) {
    this.getSelectedTrimsStore().remove(record);
    Ext.getCmp('selectedBodyTrimPanel').getView().refresh();
    }

    i have a scenario where i have a checkboxmodel grid on left and a simple grid model on the right.
    as i check the row in the checkboxmodel i have to add the selected row to the right grid.

    Both of the grid uses the same model.
    Ext.define('com.gm.vl.model.YMMModel', {
    extend: 'Ext.data.Model',
    fields: ['label','value']
    });


    but as above code as i add the data it is getting added in the store. but is not visible on the screen.
    i also did the refresh of grid view as above.


    kindly help

    Thanks
    Punith

  2. So you need to take a record from one store and add it to another?

Thread Participants: 1

Tags for this Thread