aq-fe-framework 0.1.547 → 0.1.549

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.
@@ -261,15 +261,17 @@ function utils_list_sumField(list, field) {
261
261
  function utils_mantineReactTable_filterColumnsByVisibleKeys(allColumns, visibleFields) {
262
262
  if (!visibleFields || visibleFields.length === 0) return allColumns;
263
263
  return allColumns.filter((col) => {
264
- const key = typeof col.accessorKey === "string" ? col.accessorKey : col.id;
265
- return key && visibleFields.includes(key);
264
+ var _a;
265
+ const key = (_a = col.accessorKey) != null ? _a : col.id;
266
+ return typeof key === "string" && visibleFields.includes(key);
266
267
  });
267
268
  }
268
269
  function utils_mantineReactTable_sortColumnsByKeyOrder(columns, orderedKeys) {
269
- if (!orderedKeys) return columns;
270
+ if (!orderedKeys || orderedKeys.length === 0) return columns;
270
271
  return [...columns].sort((a, b) => {
271
- const aKey = a.accessorKey;
272
- const bKey = b.accessorKey;
272
+ var _a, _b;
273
+ const aKey = (_a = a.accessorKey) != null ? _a : a.id;
274
+ const bKey = (_b = b.accessorKey) != null ? _b : b.id;
273
275
  const aIndex = orderedKeys.indexOf(aKey);
274
276
  const bIndex = orderedKeys.indexOf(bKey);
275
277
  return (aIndex === -1 ? Infinity : aIndex) - (bIndex === -1 ? Infinity : bIndex);
@@ -4,7 +4,7 @@ import {
4
4
  utils_converter_enumToSelectOptions,
5
5
  utils_file_fileToAQDocumentType,
6
6
  utils_mantineReactTable_filterColumnsByVisibleKeys
7
- } from "../chunk-4UUENVGX.mjs";
7
+ } from "../chunk-RLLQWPGV.mjs";
8
8
  import {
9
9
  baseColumns
10
10
  } from "../chunk-7PUDC2WF.mjs";
@@ -52,7 +52,7 @@ declare function utils_list_hasEmptyField<T>(list: T[], field: keyof T): boolean
52
52
  declare function utils_list_sumField<T>(list: T[], field: keyof T): number;
53
53
 
54
54
  declare function utils_mantineReactTable_filterColumnsByVisibleKeys<T extends MRT_RowData>(allColumns: MRT_ColumnDef<T>[], visibleFields?: (keyof T | string)[]): MRT_ColumnDef<T>[];
55
- declare function utils_mantineReactTable_sortColumnsByKeyOrder<T extends MRT_RowData>(columns: MRT_ColumnDef<T>[], orderedKeys?: (keyof T)[]): MRT_ColumnDef<T>[];
55
+ declare function utils_mantineReactTable_sortColumnsByKeyOrder<T extends MRT_RowData>(columns: MRT_ColumnDef<T>[], orderedKeys?: (keyof T | string)[]): MRT_ColumnDef<T>[];
56
56
 
57
57
  interface I {
58
58
  crudType?: "delete" | "update" | "create" | "error" | "importSucess";
@@ -27,7 +27,7 @@ import {
27
27
  utils_time_getCurrentTimeString,
28
28
  utils_time_getHourMinuteFromString,
29
29
  utils_validator_validateCode
30
- } from "../chunk-4UUENVGX.mjs";
30
+ } from "../chunk-RLLQWPGV.mjs";
31
31
  import {
32
32
  U0DateToDDMMYYYString,
33
33
  utils_date_dateToDDMMYYYString,
package/package.json CHANGED
@@ -46,7 +46,7 @@
46
46
  "types": "./dist/coreService/index.d.mts"
47
47
  }
48
48
  },
49
- "version": "0.1.547",
49
+ "version": "0.1.549",
50
50
  "private": false,
51
51
  "files": [
52
52
  "dist"