From 1da7b7a1cb8f1ea1fdca3d88b8203a9525ccba21 Mon Sep 17 00:00:00 2001 From: ghiscoding Date: Sat, 19 May 2018 13:49:19 -0400 Subject: [PATCH] fix(grid): Support Row Selection & Inline Editors in 1 view - SlickGrid reference https://github.com/6pac/SlickGrid/pull/243 --- aurelia-slickgrid/package.json | 2 +- .../src/aurelia-slickgrid/global-grid-options.ts | 5 +++-- .../src/aurelia-slickgrid/models/gridOption.interface.ts | 6 ++++++ package.json | 2 +- 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/aurelia-slickgrid/package.json b/aurelia-slickgrid/package.json index 5e83498d1..e2f1a266f 100644 --- a/aurelia-slickgrid/package.json +++ b/aurelia-slickgrid/package.json @@ -39,7 +39,7 @@ "moment": "^2.19.1", "moment-mini": "^2.18.1", "nps": "^5.7.1", - "slickgrid": "^2.3.18", + "slickgrid": "~2.3.19", "text-encoding-utf-8": "^1.0.2" }, "peerDependencies": {}, diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/global-grid-options.ts b/aurelia-slickgrid/src/aurelia-slickgrid/global-grid-options.ts index 8d12064ff..7a8984cb8 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/global-grid-options.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/global-grid-options.ts @@ -79,16 +79,17 @@ export const GlobalGridOptions: GridOption = { showSortCommands: true }, headerRowHeight: 35, + showHeaderRow: false, multiColumnSort: true, numberedMultiColumnSort: true, tristateMultiColumnSort: false, - sortColNumberInSeparateSpan: true, pagination: { pageSizes: [10, 15, 20, 25, 30, 40, 50, 75, 100], pageSize: 25, totalItems: 0 }, rowHeight: 35, - showHeaderRow: false, + sortColNumberInSeparateSpan: true, + suppressActiveCellChangeOnEdit: true, topPanelHeight: 35 }; diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/models/gridOption.interface.ts b/aurelia-slickgrid/src/aurelia-slickgrid/models/gridOption.interface.ts index 9872d26b0..5e38403d0 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/models/gridOption.interface.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/models/gridOption.interface.ts @@ -298,6 +298,12 @@ export interface GridOption { /** Defaults to true, which leads to render a separate span for the number and styles it with css class slick-sort-indicator-numbered */ sortColNumberInSeparateSpan?: boolean; + /** + * Defaults to true, which leads to suppress the cell from becoming active when cell as an editor and is clicked. + * This flag should be enabled especially when mixing these 2 features (Row Selections & Inline Editors) + */ + suppressActiveCellChangeOnEdit?: boolean; + /** What is the top panel height in pixels (only type the number) */ topPanelHeight?: number; diff --git a/package.json b/package.json index 1dcea531c..606a2313c 100644 --- a/package.json +++ b/package.json @@ -85,7 +85,7 @@ "jquery-ui-dist": "^1.12.1", "moment": ">=2.18.1", "moment-mini": ">=2.18.1", - "slickgrid": "^2.3.18", + "slickgrid": "~2.3.18", "text-encoding-utf-8": "^1.0.2" }, "devDependencies": {