@topconsultnpm/sdkui-react 6.21.0-dev4.3 → 6.21.0-dev4.5
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.
|
@@ -1063,10 +1063,25 @@ const TMSearchResultGrid = ({ openInOffice, fromDTD, operationItems, allUsers, i
|
|
|
1063
1063
|
// Recupera gli elementi della DataList dalla cache
|
|
1064
1064
|
const dataListItems = dataListsCache.current.get(dataListID);
|
|
1065
1065
|
if (dataListItems && dataListItems.length > 0) {
|
|
1066
|
-
//
|
|
1066
|
+
// Raccoglie i valori unici presenti nei risultati di ricerca per questa colonna
|
|
1067
|
+
let valuesInResults;
|
|
1068
|
+
try {
|
|
1069
|
+
valuesInResults = new Set();
|
|
1070
|
+
searchResult?.dtdResult?.rows?.forEach(row => {
|
|
1071
|
+
const cellValue = row[index];
|
|
1072
|
+
if (cellValue != null) {
|
|
1073
|
+
valuesInResults.add(String(cellValue));
|
|
1074
|
+
}
|
|
1075
|
+
});
|
|
1076
|
+
}
|
|
1077
|
+
catch {
|
|
1078
|
+
// Fallback: mostra tutti i valori della DataList
|
|
1079
|
+
valuesInResults = undefined;
|
|
1080
|
+
}
|
|
1081
|
+
// Crea il datasource per l'headerFilter
|
|
1067
1082
|
headerFilterConfig = {
|
|
1068
1083
|
dataSource: dataListItems
|
|
1069
|
-
.filter(item => item.name != null && item.value != null)
|
|
1084
|
+
.filter(item => item.name != null && item.value != null && (valuesInResults === undefined || valuesInResults.has(String(item.value))))
|
|
1070
1085
|
.map(item => ({
|
|
1071
1086
|
text: item.name,
|
|
1072
1087
|
value: item.value
|
|
@@ -1079,10 +1094,28 @@ const TMSearchResultGrid = ({ openInOffice, fromDTD, operationItems, allUsers, i
|
|
|
1079
1094
|
// Recupera tutti gli utenti dalla cache
|
|
1080
1095
|
const users = Array.from(usersCache.current.values());
|
|
1081
1096
|
if (users.length > 0) {
|
|
1097
|
+
// Raccoglie gli ID utente presenti nei risultati di ricerca per questa colonna
|
|
1098
|
+
let userIdsInResults;
|
|
1099
|
+
try {
|
|
1100
|
+
userIdsInResults = new Set();
|
|
1101
|
+
searchResult?.dtdResult?.rows?.forEach(row => {
|
|
1102
|
+
const cellValue = row[index];
|
|
1103
|
+
if (cellValue != null) {
|
|
1104
|
+
const userId = Number(cellValue);
|
|
1105
|
+
if (userId > 0) {
|
|
1106
|
+
userIdsInResults.add(userId);
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
});
|
|
1110
|
+
}
|
|
1111
|
+
catch {
|
|
1112
|
+
// Fallback: mostra tutti gli utenti
|
|
1113
|
+
userIdsInResults = undefined;
|
|
1114
|
+
}
|
|
1082
1115
|
// Crea il datasource per l'headerFilter mostrando nome utente completo (dominio\nome)
|
|
1083
1116
|
headerFilterConfig = {
|
|
1084
1117
|
dataSource: users
|
|
1085
|
-
.filter(user => user.name != null && user.id != null)
|
|
1118
|
+
.filter(user => user.name != null && user.id != null && (userIdsInResults === undefined || userIdsInResults.has(user.id)))
|
|
1086
1119
|
.map(user => ({
|
|
1087
1120
|
text: user.domain ? `${user.domain}\\${user.name}` : user.name,
|
|
1088
1121
|
value: user.id
|
package/package.json
CHANGED
|
@@ -1,64 +1,64 @@
|
|
|
1
1
|
{
|
|
2
|
-
"name":
|
|
3
|
-
"version":
|
|
4
|
-
"description":
|
|
5
|
-
"scripts":
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
"author":
|
|
17
|
-
"license":
|
|
18
|
-
"devDependencies":
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
"main":
|
|
36
|
-
"types":
|
|
37
|
-
"module":
|
|
38
|
-
"files":
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
"dependencies":
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
"overrides":
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
2
|
+
"name": "@topconsultnpm/sdkui-react",
|
|
3
|
+
"version": "6.21.0-dev4.5",
|
|
4
|
+
"description": "",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
7
|
+
"clean": "node -e \"const fs=require('fs');fs.rmSync('lib',{recursive:true,force:true});fs.mkdirSync('lib')\"",
|
|
8
|
+
"copy-files": "cpx \"src/{assets/*.*,assets/ImageLibrary/*.*,assets/thumbnails/*.*,assets/IconsS4t/*.*,assets/Metadata/*.*,css/tm-sdkui.css}\" lib",
|
|
9
|
+
"tm-build": "npm run clean && tsc && npm run copy-files",
|
|
10
|
+
"tm-watch": "tsc -w",
|
|
11
|
+
"tm-publish": "npm publish --tag latest",
|
|
12
|
+
"tm-publish_wl": "npm publish",
|
|
13
|
+
"storybook": "storybook dev -p 6006",
|
|
14
|
+
"build-storybook": "storybook build"
|
|
15
|
+
},
|
|
16
|
+
"author": "TopConsult",
|
|
17
|
+
"license": "ISC",
|
|
18
|
+
"devDependencies": {
|
|
19
|
+
"@chromatic-com/storybook": "^5.1.2",
|
|
20
|
+
"@storybook/addon-docs": "^10.3.5",
|
|
21
|
+
"@storybook/addon-onboarding": "^10.3.5",
|
|
22
|
+
"@storybook/react-vite": "^10.3.5",
|
|
23
|
+
"@types/htmlparser2": "^3.10.7",
|
|
24
|
+
"@types/node": "^24.12.2",
|
|
25
|
+
"@types/react": "^18.3.3",
|
|
26
|
+
"@types/react-dom": "^18.3.3",
|
|
27
|
+
"cpx2": "^9.0.0",
|
|
28
|
+
"esbuild": "^0.25.0",
|
|
29
|
+
"react": "^18.3.1",
|
|
30
|
+
"react-dom": "^18.3.1",
|
|
31
|
+
"storybook": "^10.3.5",
|
|
32
|
+
"typescript": "^5.9.3",
|
|
33
|
+
"vite": "^6.1.1"
|
|
34
|
+
},
|
|
35
|
+
"main": "dist/cjs/index.js",
|
|
36
|
+
"types": "./index.d.ts",
|
|
37
|
+
"module": "lib/esm/index.js",
|
|
38
|
+
"files": [
|
|
39
|
+
"dist",
|
|
40
|
+
"lib"
|
|
41
|
+
],
|
|
42
|
+
"dependencies": {
|
|
43
|
+
"@topconsultnpm/sdk-ts": "6.21.0-dev4.2",
|
|
44
|
+
"@zip.js/zip.js": "2.8.26",
|
|
45
|
+
"buffer": "^6.0.3",
|
|
46
|
+
"devextreme": "^25.2.6",
|
|
47
|
+
"devextreme-exceljs-fork": "^4.4.10",
|
|
48
|
+
"devextreme-react": "^25.2.6",
|
|
49
|
+
"htmlparser2": "^10.0.0",
|
|
50
|
+
"pdf-lib": "^1.17.1",
|
|
51
|
+
"react-pdf": "^10.4.1",
|
|
52
|
+
"react-router-dom": "^6.15.0",
|
|
53
|
+
"styled-components": "^6.1.1"
|
|
54
|
+
},
|
|
55
|
+
"overrides": {
|
|
56
|
+
"esbuild": "^0.25.0",
|
|
57
|
+
"devextreme-exceljs-fork": {
|
|
58
|
+
"archiver": "^8.0.0"
|
|
59
|
+
},
|
|
60
|
+
"quill-delta": {
|
|
61
|
+
"lodash.isequal": "npm:fast-deep-equal@^3.1.3"
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
64
|
}
|