Results 1 to 2 of 2

Thread: Populating parent grid from editor combo

  1. #1

    Default Populating parent grid from editor combo

    have a grid in ext 3.4 having one of the columns with a combobox editor.

    {header: ' Facility', dataIndex: 'facility',editor: borrfacCombo}
    The underlying store of the grid has 2 fields (and more) - facility and facilityid
    The editor combo is loaded from a store which has a mapping of id and description(something similar to below):
    borrfacCombo=Ext.create('Ext.form.field.ComboBox', {     displayField: 'name',     valueField: 'id',     store: {      fields: ['id', 'name'],     data: [          {id: 'scheme2', name: 'Green Envy'},     ...              ]          }      });
    When a particular 'facility' is selected in the combo - I need the corresponding 'facilityid' to be populated in the selected row of the grid's store.
    i am trying the following on 'select' in the combo -
    listeners:{select:function(combo, record, index) { var val=record.get('id'); var grid=combo.ownerCt.floatParent; var selectedRecord = grid.getSelectionModel().getSelection()[0];.... } }
    But 'combo.ownerCt' always shows up as 'undefined'.
    How do I resolve this ?

  2. #2


    Not sure why ownerCt is not set up. Maybe the combo box is not set up correctly. As a work around you could fire a global event from your select function and just have your grid listen for it. Once the grid hears the event you can update what you need to in your grid. Good luck... You may want to read this thread and try var parent = combo.getEl().parent();got that from

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts