Results 1 to 2 of 2

Thread: Adding new row in grid creates issue in selection model while editing

  1. #1
    Sencha User
    Join Date
    Oct 2012

    Default Adding new row in grid creates issue in selection model while editing


    1. i have created grid with editable cell using NumberField class.
    2. grid is been in set for SINGLE selection mode
    3. then i added KeyDownHandler for NumberField, in order to navigate from cell to cell setting their editing mode
    4. this all works fine for existing rows
    5. but when i add new rows dynamically and then do same editing and navigation, grid show selection of multiple row(for newly added rows only). Please check out screenshot.

    can any body suggest what could be wrong?
    Attached Images Attached Images

  2. #2
    Sencha User
    Join Date
    Feb 2009


    I've moved this out of the Bugs forum into Discussion, because while there might be a bug here, it seems more likely that the bug is in your code. When filing a bug, please use the template.

    When asking for help, please post the code you've tried to use - if there is a problem with your code, we won't be able to see it just from the steps you've listed.

    Selection model issues like this almost always relate to not having a unique key for each row in the ListStore. From ModelKeyProvider:
       * Gets a non-null key value that maps to this object. Keys must be consistent and
       * unique for a given model, as a database primary key would be used.
      String getKey(T item);
    Make sure each item is getting a unique key - the selection model uses that key to decide what is selected. If more than one item have the same key, then more than one item will be selected.

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