@bento-core/paginated-table 1.0.1-ccdihub.95 → 1.0.1-ccdihub.97
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/wrapper/WrapperService.js +1 -1
- package/dist/wrapper/components/AddAllFiles/AddAllView.js +6 -3
- package/dist/wrapper/components/AddSelectedFiles/AddSelectedFilesController.js +4 -3
- package/dist/wrapper/components/DownloadManifestBtn.js +1 -1
- package/package.json +2 -2
- package/src/wrapper/WrapperService.js +1 -1
- package/src/wrapper/components/AddAllFiles/AddAllView.js +6 -3
- package/src/wrapper/components/AddSelectedFiles/AddSelectedFilesController.js +4 -3
- package/src/wrapper/components/DownloadManifestBtn.js +1 -1
|
@@ -14,7 +14,7 @@ function _toPrimitive(input, hint) { if (typeof input !== "object" || input ===
|
|
|
14
14
|
*/
|
|
15
15
|
const getQueryVariables = variables => {
|
|
16
16
|
const queryVariables = _objectSpread({}, variables);
|
|
17
|
-
queryVariables.first =
|
|
17
|
+
queryVariables.first = 200000;
|
|
18
18
|
return queryVariables;
|
|
19
19
|
};
|
|
20
20
|
exports.getQueryVariables = getQueryVariables;
|
|
@@ -82,8 +82,11 @@ const AddAllFilesComponent = props => {
|
|
|
82
82
|
variables: activeFilters,
|
|
83
83
|
query: addFileQuery
|
|
84
84
|
});
|
|
85
|
+
const upperLimit = 200000;
|
|
85
86
|
const cartCount = cartFiles.length;
|
|
86
|
-
|
|
87
|
+
console.log(cartCount);
|
|
88
|
+
console.log(fileCount);
|
|
89
|
+
if (fileCount <= upperLimit && cartCount < upperLimit) {
|
|
87
90
|
fileIds().then(response => {
|
|
88
91
|
const data = response[responseKeys[0]];
|
|
89
92
|
if (data && data.length > 0) {
|
|
@@ -97,12 +100,12 @@ const AddAllFilesComponent = props => {
|
|
|
97
100
|
return acc;
|
|
98
101
|
}, []);
|
|
99
102
|
const ids = [...new Set(idsInitial)];
|
|
100
|
-
if (cartCount + ids.length <=
|
|
103
|
+
if (cartCount + ids.length <= upperLimit) {
|
|
101
104
|
setOpen(true);
|
|
102
105
|
setAddFilesId(ids);
|
|
103
106
|
} else {
|
|
104
107
|
const duplicate = checkDuplicate(cartFiles, ids);
|
|
105
|
-
if (cartCount + ids.length - duplicate <=
|
|
108
|
+
if (cartCount + ids.length - duplicate <= upperLimit) {
|
|
106
109
|
setOpen(true);
|
|
107
110
|
setAddFilesId(ids);
|
|
108
111
|
} else {
|
|
@@ -61,14 +61,15 @@ const AddSelectedFilesController = props => {
|
|
|
61
61
|
const idsInitial = response[responseKeys[0]] || [];
|
|
62
62
|
const ids = [...new Set(idsInitial)];
|
|
63
63
|
const fileCount = ids.length;
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
const upperLimit = 200000;
|
|
65
|
+
if (fileCount <= upperLimit && cartCount < upperLimit) {
|
|
66
|
+
if (cartCount + fileCount <= upperLimit) {
|
|
66
67
|
addFiles(ids);
|
|
67
68
|
setOpenSnackbar(true);
|
|
68
69
|
dispatch((0, _Actions.onRowSeclect)([]));
|
|
69
70
|
} else {
|
|
70
71
|
const duplicate = checkDuplicate(cartFiles, ids);
|
|
71
|
-
if (cartCount + fileCount - duplicate <=
|
|
72
|
+
if (cartCount + fileCount - duplicate <= upperLimit) {
|
|
72
73
|
addFiles(ids);
|
|
73
74
|
setOpenSnackbar(true);
|
|
74
75
|
dispatch((0, _Actions.onRowSeclect)([]));
|
|
@@ -37,7 +37,7 @@ const DownloadManifestView = props => {
|
|
|
37
37
|
const getQueryVeriables = queryVariables => {
|
|
38
38
|
const variables = _objectSpread({}, queryVariables);
|
|
39
39
|
variables.offset = 0;
|
|
40
|
-
variables.first =
|
|
40
|
+
variables.first = 200000;
|
|
41
41
|
return variables;
|
|
42
42
|
};
|
|
43
43
|
const client = (0, _client.useApolloClient)();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bento-core/paginated-table",
|
|
3
|
-
"version": "1.0.1-ccdihub.
|
|
3
|
+
"version": "1.0.1-ccdihub.97",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "npm run lint && cross-env-shell rm -rf dist && NODE_ENV=production BABEL_ENV=es babel src --out-dir dist --copy-files",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
18
|
"@bento-core/cart": "1.0.1-ccdihub.7",
|
|
19
|
-
"@bento-core/table": "1.0.1-ccdihub.
|
|
19
|
+
"@bento-core/table": "1.0.1-ccdihub.73",
|
|
20
20
|
"@bento-core/tool-tip": "^1.0.0",
|
|
21
21
|
"@bento-core/util": "^1.0.0"
|
|
22
22
|
},
|
|
@@ -76,8 +76,11 @@ const AddAllFilesComponent = (props) => {
|
|
|
76
76
|
variables: activeFilters,
|
|
77
77
|
query: addFileQuery,
|
|
78
78
|
});
|
|
79
|
+
const upperLimit = 200000;
|
|
79
80
|
const cartCount = cartFiles.length;
|
|
80
|
-
|
|
81
|
+
console.log(cartCount);
|
|
82
|
+
console.log(fileCount);
|
|
83
|
+
if (fileCount <= upperLimit && cartCount < upperLimit) {
|
|
81
84
|
fileIds().then((response) => {
|
|
82
85
|
const data = response[responseKeys[0]];
|
|
83
86
|
if (data && data.length > 0) {
|
|
@@ -91,12 +94,12 @@ const AddAllFilesComponent = (props) => {
|
|
|
91
94
|
return acc;
|
|
92
95
|
}, []);
|
|
93
96
|
const ids = [...new Set(idsInitial)];
|
|
94
|
-
if (cartCount + ids.length <=
|
|
97
|
+
if (cartCount + ids.length <= upperLimit) {
|
|
95
98
|
setOpen(true);
|
|
96
99
|
setAddFilesId(ids);
|
|
97
100
|
} else {
|
|
98
101
|
const duplicate = checkDuplicate(cartFiles, ids);
|
|
99
|
-
if (cartCount + ids.length - duplicate <=
|
|
102
|
+
if (cartCount + ids.length - duplicate <= upperLimit) {
|
|
100
103
|
setOpen(true);
|
|
101
104
|
setAddFilesId(ids);
|
|
102
105
|
} else {
|
|
@@ -52,14 +52,15 @@ const AddSelectedFilesController = (props) => {
|
|
|
52
52
|
const idsInitial = response[responseKeys[0]] || [];
|
|
53
53
|
const ids = [...new Set(idsInitial)];
|
|
54
54
|
const fileCount = ids.length;
|
|
55
|
-
|
|
56
|
-
|
|
55
|
+
const upperLimit = 200000;
|
|
56
|
+
if (fileCount <= upperLimit && cartCount < upperLimit) {
|
|
57
|
+
if (cartCount + fileCount <= upperLimit) {
|
|
57
58
|
addFiles(ids);
|
|
58
59
|
setOpenSnackbar(true);
|
|
59
60
|
dispatch(onRowSeclect([]));
|
|
60
61
|
} else {
|
|
61
62
|
const duplicate = checkDuplicate(cartFiles, ids);
|
|
62
|
-
if (cartCount + fileCount - duplicate <=
|
|
63
|
+
if (cartCount + fileCount - duplicate <= upperLimit) {
|
|
63
64
|
addFiles(ids);
|
|
64
65
|
setOpenSnackbar(true);
|
|
65
66
|
dispatch(onRowSeclect([]));
|