javascriptslickgridangular-slickgrid

Angular slickgrid - Select Dropdown Editor opens next line's editor once I select a value in first line


https://ghiscoding.github.io/Angular-Slickgrid/#/editor

editor: {
  model: Editors.SingleSelect,
  editorOptions: {
    maxHeight: 400
  } as MultipleSelectOption
}

I'm using this code to get single select dropdown as shown in above link. After I click on any cell in this column and select a value, it opens the next row's editor dropdown automatically.

Is this the default behaviour of slickgrid? How to disable this feature?

Even in the example link in slickgrid also works the same way. "% Complete" column


Solution

  • That is the default behavior of SlickGrid, you can change that behavior by enabling autoCommitEdit: true which will commit the change and remain in the same cell. That option is also available from the same demo page Example 3, just enable the "Auto Commit Edit" checkbox and you will see the difference. I also added a comment in this Editors Wiki for this.

    this.gridOptions = {
      autoCommitEdit: true,
      editable: true,
      // ...other options
    }