@shotleybuilder/svelte-gridlite-kit 0.4.2 → 0.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/GridLite.svelte +5 -4
- package/package.json +1 -1
package/dist/GridLite.svelte
CHANGED
|
@@ -219,8 +219,8 @@ async function rebuildGroupedQuery() {
|
|
|
219
219
|
try {
|
|
220
220
|
const usePagination = features.pagination !== false;
|
|
221
221
|
const topGroupConfig = cleanAgg(validGrouping[0]);
|
|
222
|
-
const
|
|
223
|
-
const groupSorting = sorting.filter((s) =>
|
|
222
|
+
const topColumnNames = [topGroupConfig.column];
|
|
223
|
+
const groupSorting = sorting.filter((s) => topColumnNames.includes(s.column));
|
|
224
224
|
const summaryQuery = buildGroupSummaryQuery({
|
|
225
225
|
...querySource,
|
|
226
226
|
grouping: [topGroupConfig],
|
|
@@ -279,6 +279,7 @@ async function rebuildGroupedQuery() {
|
|
|
279
279
|
await fetchGroupChildren(group);
|
|
280
280
|
}
|
|
281
281
|
}
|
|
282
|
+
storeState = { ...storeState, loading: false };
|
|
282
283
|
} catch (err) {
|
|
283
284
|
error = err instanceof Error ? err.message : String(err);
|
|
284
285
|
}
|
|
@@ -296,8 +297,8 @@ async function fetchGroupChildren(group) {
|
|
|
296
297
|
}));
|
|
297
298
|
if (nextDepth < validGrouping.length) {
|
|
298
299
|
const subGroupConfig = cleanAgg(validGrouping[nextDepth]);
|
|
299
|
-
const
|
|
300
|
-
const groupSorting = sorting.filter((s) =>
|
|
300
|
+
const subColumnNames = validGrouping.slice(0, nextDepth + 1).map((g) => g.column);
|
|
301
|
+
const groupSorting = sorting.filter((s) => subColumnNames.includes(s.column));
|
|
301
302
|
const summaryQuery = buildGroupSummaryQuery({
|
|
302
303
|
...querySource,
|
|
303
304
|
grouping: [subGroupConfig],
|