datastake-daf 0.6.403 → 0.6.405

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.
@@ -14098,9 +14098,8 @@ const determineHasChildren = ({
14098
14098
 
14099
14099
  const sortByPosition = (items, getConfig) => {
14100
14100
  return items.sort((a, b) => {
14101
- var _getConfig, _getConfig2;
14102
- const positionA = ((_getConfig = getConfig(a)) === null || _getConfig === void 0 ? void 0 : _getConfig.position) || 0;
14103
- const positionB = ((_getConfig2 = getConfig(b)) === null || _getConfig2 === void 0 ? void 0 : _getConfig2.position) || 0;
14101
+ const positionA = getConfig(a)?.position || 0;
14102
+ const positionB = getConfig(b)?.position || 0;
14104
14103
  return positionA - positionB;
14105
14104
  });
14106
14105
  };
@@ -14117,7 +14116,7 @@ const resolveDynamicLabel = (labelConfig, item, defaultLabel) => {
14117
14116
  const parts = labelKey.split(' is ');
14118
14117
  if (parts.length === 2) {
14119
14118
  const [conditionKey, conditionValue] = parts;
14120
- if ((item === null || item === void 0 ? void 0 : item[conditionKey]) === conditionValue) {
14119
+ if (item?.[conditionKey] === conditionValue) {
14121
14120
  return labelConfig[labelKey];
14122
14121
  }
14123
14122
  }
@@ -46988,6 +46987,7 @@ const getDefaultActiveFilters = (params, selectFiltersConfig, defaultPageSize, d
46988
46987
  });
46989
46988
  return o;
46990
46989
  };
46990
+ const NEW_PAGINATION_APPS = ["nashiriki"];
46991
46991
  const filterParams = (value, module) => {
46992
46992
  const {
46993
46993
  activeFilters,
@@ -47003,9 +47003,10 @@ const filterParams = (value, module) => {
47003
47003
  ...filters
47004
47004
  } = activeFilters || {};
47005
47005
  const params = {};
47006
+ console.log(module, NEW_PAGINATION_APPS.includes(module), "new pagination");
47006
47007
  params.pagination = JSON.stringify({
47007
- [module === "nashirik" ? "skip" : "page"]: page,
47008
- [module === "nashirik" ? "take" : "pageSize"]: pageSize
47008
+ [NEW_PAGINATION_APPS.includes(module) ? "skip" : "page"]: page,
47009
+ [NEW_PAGINATION_APPS.includes(module) ? "take" : "pageSize"]: pageSize
47009
47010
  });
47010
47011
  if (search && searchParams) {
47011
47012
  params.search = JSON.stringify({
@@ -6095,6 +6095,7 @@ const getDefaultActiveFilters = (params, selectFiltersConfig, defaultPageSize, d
6095
6095
  });
6096
6096
  return o;
6097
6097
  };
6098
+ const NEW_PAGINATION_APPS = ["nashiriki"];
6098
6099
  const filterParams = (value, module) => {
6099
6100
  const {
6100
6101
  activeFilters,
@@ -6110,9 +6111,10 @@ const filterParams = (value, module) => {
6110
6111
  ...filters
6111
6112
  } = activeFilters || {};
6112
6113
  const params = {};
6114
+ console.log(module, NEW_PAGINATION_APPS.includes(module), "new pagination");
6113
6115
  params.pagination = JSON.stringify({
6114
- [module === "nashirik" ? "skip" : "page"]: page,
6115
- [module === "nashirik" ? "take" : "pageSize"]: pageSize
6116
+ [NEW_PAGINATION_APPS.includes(module) ? "skip" : "page"]: page,
6117
+ [NEW_PAGINATION_APPS.includes(module) ? "take" : "pageSize"]: pageSize
6116
6118
  });
6117
6119
  if (search && searchParams) {
6118
6120
  params.search = JSON.stringify({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "datastake-daf",
3
- "version": "0.6.403",
3
+ "version": "0.6.405",
4
4
  "dependencies": {
5
5
  "@ant-design/icons": "^5.2.5",
6
6
  "@antv/g2": "^5.1.1",
@@ -62,6 +62,7 @@ export const getDefaultActiveFilters = (
62
62
  return o;
63
63
  };
64
64
 
65
+ const NEW_PAGINATION_APPS = ["nashiriki"];
65
66
  export const filterParams = (value, module) => {
66
67
  const { activeFilters, ...rest } = value;
67
68
 
@@ -70,9 +71,10 @@ export const filterParams = (value, module) => {
70
71
 
71
72
  const params = {};
72
73
 
74
+ console.log(module, NEW_PAGINATION_APPS.includes(module), "new pagination");
73
75
  params.pagination = JSON.stringify({
74
- [module === "nashirik" ? "skip" : "page"]: page,
75
- [module === "nashirik" ? "take" : "pageSize"]: pageSize,
76
+ [NEW_PAGINATION_APPS.includes(module) ? "skip" : "page"]: page,
77
+ [NEW_PAGINATION_APPS.includes(module) ? "take" : "pageSize"]: pageSize,
76
78
  });
77
79
 
78
80
  if (search && searchParams) {