@gisce/react-ooui 1.2.0-rc.67 → 1.2.0-rc.69
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/hooks/useExport.d.ts +6 -1
- package/dist/hooks/useExport.d.ts.map +1 -1
- package/dist/react-ooui.es.js +1 -1
- package/dist/react-ooui.es.js.map +1 -1
- package/dist/react-ooui.umd.js +1 -1
- package/dist/react-ooui.umd.js.map +1 -1
- package/dist/widgets/custom/Tag.d.ts.map +1 -1
- package/dist/widgets/views/Form.d.ts.map +1 -1
- package/package.json +5 -5
- package/src/hooks/useExport.ts +4 -3
- package/src/widgets/custom/Tag.tsx +2 -2
- package/src/widgets/views/Form.tsx +4 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tag.d.ts","sourceRoot":"","sources":["Tag.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Tag.d.ts","sourceRoot":"","sources":["Tag.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAItC,eAAO,MAAM,GAAG,UAAW,WAAW,gBAMrC,CAAC;AAEF,eAAO,MAAM,QAAQ,UAAW,GAAG,uBASlC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Form.d.ts","sourceRoot":"","sources":["Form.tsx"],"names":[],"mappings":"AAAA,OAAO,KAON,MAAM,OAAO,CAAC;AAkCf,OAAO,EAAE,QAAQ,EAAgB,MAAM,SAAS,CAAC;AAkBjD,oBAAY,SAAS,GAAG;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,MAAM,CAAC,EAAE,GAAG,CAAC;IACb,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,iBAAiB,CAAC,EAAE,OAAO,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,CAAC;IAC7B,UAAU,CAAC,EAAE,KAAK,GAAG,QAAQ,CAAC;IAC9B,eAAe,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,GAAG,EAAE,UAAU,CAAC,EAAE,GAAG,KAAK,IAAI,CAAC;IACxE,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,IAAI,CAAC;IACrC,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,GAAG,KAAK,IAAI,CAAC;IACvC,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC/C,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,aAAa,CAAC,EAAE,GAAG,CAAC;IACpB,YAAY,CAAC,EAAE,GAAG,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,aAAa,CAAC,EAAE,GAAG,CAAC;IACpB,YAAY,CAAC,EAAE,GAAG,CAAC;CACpB,CAAC;;AAq+BF,wBAAgC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gisce/react-ooui",
|
|
3
|
-
"version": "1.2.0-rc.
|
|
3
|
+
"version": "1.2.0-rc.69",
|
|
4
4
|
"files": [
|
|
5
5
|
"dist",
|
|
6
6
|
"src",
|
|
@@ -27,17 +27,17 @@
|
|
|
27
27
|
"prerelease": "npm version prerelease --preid rc",
|
|
28
28
|
"prepatch": "npm version prepatch --preid rc",
|
|
29
29
|
"premajor": "npm version premajor --preid rc",
|
|
30
|
-
"start": "while :; do vite build --watch --force; done",
|
|
30
|
+
"start": "while :; do tsc && vite build --watch --force; done",
|
|
31
31
|
"build:tailwind": "postcss src/tailwind.css -o src/tailwind.generated.css",
|
|
32
|
-
"build": "vite build",
|
|
32
|
+
"build": "tsc && vite build",
|
|
33
33
|
"test": "jest",
|
|
34
34
|
"storybook": "start-storybook -p 6006",
|
|
35
35
|
"build-storybook": "build-storybook"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@ant-design/plots": "^1.0.9",
|
|
39
|
-
"@gisce/ooui": "^0.19.1",
|
|
40
|
-
"@gisce/react-formiga-components": "^1.0.9-rc.
|
|
39
|
+
"@gisce/ooui": "^0.19.2-rc.1",
|
|
40
|
+
"@gisce/react-formiga-components": "^1.0.9-rc.20",
|
|
41
41
|
"@gisce/react-formiga-table": "^0.5.0",
|
|
42
42
|
"@monaco-editor/react": "^4.4.5",
|
|
43
43
|
"@tabler/icons-react": "^2.11.0",
|
package/src/hooks/useExport.ts
CHANGED
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
ExportOptions,
|
|
4
4
|
PredefinedExport,
|
|
5
5
|
PredefinedExportField,
|
|
6
|
-
} from "
|
|
6
|
+
} from "@gisce/react-formiga-components";
|
|
7
7
|
import { useCallback, useRef } from "react";
|
|
8
8
|
import { ConnectionProvider } from "..";
|
|
9
9
|
import showInfo from "@/ui/InfoDialog";
|
|
@@ -161,7 +161,7 @@ export const useExport = ({
|
|
|
161
161
|
|
|
162
162
|
// We create the lines
|
|
163
163
|
await Promise.all(
|
|
164
|
-
pExport.fields.map(async (field) => {
|
|
164
|
+
pExport.fields.map(async (field: any) => {
|
|
165
165
|
return await ConnectionProvider.getHandler().create({
|
|
166
166
|
model: "ir.exports.line",
|
|
167
167
|
values: {
|
|
@@ -367,7 +367,8 @@ const retrieveKeyFieldsForPredefinedExports = async ({
|
|
|
367
367
|
onGetFieldChilds: (key: string) => Promise<ExportField[]>;
|
|
368
368
|
}) => {
|
|
369
369
|
const allPredefinedExportKeys = predefinedExports.flatMap(
|
|
370
|
-
(exp: PredefinedExport) =>
|
|
370
|
+
(exp: PredefinedExport) =>
|
|
371
|
+
exp.fields.map((field: any) => field.key)
|
|
371
372
|
);
|
|
372
373
|
|
|
373
374
|
const keysWithoutChildsInFields = getKeysWithoutChildsInFields({
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
1
2
|
import Field from "@/common/Field";
|
|
2
3
|
import { WidgetProps } from "@/types";
|
|
3
4
|
import { Tag as AntdTag } from 'antd';
|
|
4
5
|
import { colorFromString } from "@/helpers/formHelper";
|
|
5
6
|
|
|
6
|
-
|
|
7
7
|
export const Tag = (props: WidgetProps) => {
|
|
8
8
|
return (
|
|
9
9
|
<Field {...props}>
|
|
@@ -12,7 +12,7 @@ export const Tag = (props: WidgetProps) => {
|
|
|
12
12
|
);
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
-
export const TagInput = (props) => {
|
|
15
|
+
export const TagInput = (props: any) => {
|
|
16
16
|
const {ooui, value} = props;
|
|
17
17
|
if (!value) {
|
|
18
18
|
return null
|
|
@@ -949,8 +949,10 @@ function Form(props: FormProps, ref: any) {
|
|
|
949
949
|
}
|
|
950
950
|
|
|
951
951
|
try {
|
|
952
|
-
|
|
953
|
-
|
|
952
|
+
if (formHasChanges()) {
|
|
953
|
+
await submitForm({ callOnSubmitSucceed: false });
|
|
954
|
+
}
|
|
955
|
+
|
|
954
956
|
if (type === "object") {
|
|
955
957
|
await runObjectButton({ action, context });
|
|
956
958
|
} else if (type === "workflow") {
|