@ruiapp/rapid-configure-tools 0.6.0 → 0.6.2

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/mod.js CHANGED
@@ -278,8 +278,8 @@ function convertSdRpdFieldTypeToTypeScriptType(field, entities) {
278
278
  return `${dataDictionary}[]`;
279
279
  case "relation":
280
280
  case "relation[]":
281
- const targetCode = lodash.find(entities, { singularCode: targetSingularCode })?.code;
282
- return relation === "one" ? `Partial<${targetCode}>` : `Partial<${targetCode}>[]`;
281
+ const targetType = lodash.find(entities, { singularCode: targetSingularCode })?.code || "any";
282
+ return relation === "one" ? `Partial<${targetType}>` : `Partial<${targetType}>[]`;
283
283
  case "file":
284
284
  case "image":
285
285
  return "FileOrImageFieldType";
@@ -764,6 +764,7 @@ function newModelUpdater(rapidConfigApi) {
764
764
  "derivedType",
765
765
  "derivedTypePropertyCode",
766
766
  "displayPropertyCode",
767
+ "defaultOrderBy",
767
768
  "indexes",
768
769
  "permissionPolicies",
769
770
  "softDelete",
@@ -848,6 +849,7 @@ function newPropertyUpdater(rapidConfigApi) {
848
849
  "maxLength",
849
850
  "relation",
850
851
  "targetSingularCode",
852
+ "targetTypeColumnName",
851
853
  "targetIdColumnName",
852
854
  "selfIdColumnName",
853
855
  "linkTableName",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ruiapp/rapid-configure-tools",
3
- "version": "0.6.0",
3
+ "version": "0.6.2",
4
4
  "description": "",
5
5
  "main": "dist/mod.js",
6
6
  "keywords": [],
@@ -20,8 +20,8 @@
20
20
  "axios-cookiejar-support": "^4.0.7",
21
21
  "lodash": "^4.17.21",
22
22
  "tough-cookie": "^4.1.3",
23
- "@ruiapp/rapid-extension": "^0.6.0",
24
- "@ruiapp/rapid-core": "^0.10.0"
23
+ "@ruiapp/rapid-core": "^0.10.4",
24
+ "@ruiapp/rapid-extension": "^0.6.8"
25
25
  },
26
26
  "dependencies": {},
27
27
  "scripts": {
@@ -34,8 +34,8 @@ function convertSdRpdFieldTypeToTypeScriptType(field: RapidField, entities: Rapi
34
34
  return `${dataDictionary}[]`;
35
35
  case "relation":
36
36
  case "relation[]":
37
- const targetCode = find(entities, { singularCode: targetSingularCode })?.code;
38
- return relation === "one" ? `Partial<${targetCode}>` : `Partial<${targetCode}>[]`;
37
+ const targetType = find(entities, { singularCode: targetSingularCode })?.code || "any";
38
+ return relation === "one" ? `Partial<${targetType}>` : `Partial<${targetType}>[]`;
39
39
  case "file":
40
40
  case "image":
41
41
  return "FileOrImageFieldType";
@@ -42,6 +42,7 @@ export function newModelUpdater(rapidConfigApi: AxiosInstance) {
42
42
  "derivedType",
43
43
  "derivedTypePropertyCode",
44
44
  "displayPropertyCode",
45
+ "defaultOrderBy",
45
46
  "indexes",
46
47
  "permissionPolicies",
47
48
  "softDelete",
@@ -49,6 +49,7 @@ export function newPropertyUpdater(rapidConfigApi: AxiosInstance) {
49
49
  "maxLength",
50
50
  "relation",
51
51
  "targetSingularCode",
52
+ "targetTypeColumnName",
52
53
  "targetIdColumnName",
53
54
  "selfIdColumnName",
54
55
  "linkTableName",