@gisce/react-ooui 1.0.22-rc.0 → 1.0.23
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/context/ContentRootContext.d.ts.map +1 -1
- package/dist/react-ooui.es.js +234 -251
- package/dist/react-ooui.es.js.map +1 -1
- package/dist/react-ooui.umd.js +8 -8
- package/dist/react-ooui.umd.js.map +1 -1
- package/package.json +4 -2
- package/src/context/ContentRootContext.tsx +2 -19
- package/src/widgets/base/many2one/Many2one.tsx +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gisce/react-ooui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.23",
|
|
4
4
|
"files": [
|
|
5
5
|
"dist",
|
|
6
6
|
"src",
|
|
@@ -23,7 +23,9 @@
|
|
|
23
23
|
"access": "public"
|
|
24
24
|
},
|
|
25
25
|
"scripts": {
|
|
26
|
-
"
|
|
26
|
+
"preminor": "npm version preminor --preid rc",
|
|
27
|
+
"prepatch": "npm version prepatch --preid rc",
|
|
28
|
+
"premajor": "npm version premajor --preid rc",
|
|
27
29
|
"start": "vite build --watch --force",
|
|
28
30
|
"build:tailwind": "postcss src/tailwind.css -o src/tailwind.generated.css",
|
|
29
31
|
"build": "vite build",
|
|
@@ -95,9 +95,9 @@ const ContentRootProvider = (
|
|
|
95
95
|
return;
|
|
96
96
|
}
|
|
97
97
|
|
|
98
|
-
const { ids
|
|
98
|
+
const { ids } = datas || {};
|
|
99
99
|
|
|
100
|
-
let idsToExecute = ids;
|
|
100
|
+
let idsToExecute = ids || [];
|
|
101
101
|
|
|
102
102
|
const reportContextParsed =
|
|
103
103
|
typeof reportContext === "string"
|
|
@@ -108,23 +108,6 @@ const ContentRootProvider = (
|
|
|
108
108
|
})
|
|
109
109
|
: reportContext;
|
|
110
110
|
|
|
111
|
-
if (!idsToExecute) {
|
|
112
|
-
const results = await ConnectionProvider.getHandler().searchAllIds({
|
|
113
|
-
params: [],
|
|
114
|
-
model: datasource.model || model,
|
|
115
|
-
totalItems: 1,
|
|
116
|
-
context: { ...context, ...reportContextParsed },
|
|
117
|
-
});
|
|
118
|
-
|
|
119
|
-
if (results.length === 0) {
|
|
120
|
-
showErrorDialog("Nothing to print");
|
|
121
|
-
return;
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
idsToExecute = results;
|
|
125
|
-
datas.id = results[0];
|
|
126
|
-
}
|
|
127
|
-
|
|
128
111
|
try {
|
|
129
112
|
const newReportId = await ConnectionProvider.getHandler().createReport({
|
|
130
113
|
model,
|
|
@@ -86,11 +86,11 @@ export const Many2oneInput: React.FC<Many2oneInputProps> = (
|
|
|
86
86
|
const transformedDomain = useRef<any[]>([]);
|
|
87
87
|
const [searchDomain, setSearchDomain] = useState<any>([]);
|
|
88
88
|
|
|
89
|
-
const id =
|
|
89
|
+
const id = value && value[0];
|
|
90
90
|
const text = (value && value[1]) || "";
|
|
91
91
|
|
|
92
92
|
useEffect(() => {
|
|
93
|
-
if (!Array.isArray(value) && value) {
|
|
93
|
+
if (!Array.isArray(value) && !isNaN(value as any)) {
|
|
94
94
|
fetchNameAndUpdate(value as any);
|
|
95
95
|
}
|
|
96
96
|
}, [value]);
|