@budibase/types 2.15.7 → 2.16.1
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/documents/app/table/constants.d.ts +2 -2
- package/dist/documents/app/table/schema.d.ts +6 -6
- package/dist/index.js +17 -17
- package/dist/index.js.map +3 -3
- package/dist/index.js.meta.json +1 -1
- package/dist/sdk/events/auth.d.ts +1 -1
- package/dist/shared/typeUtils.d.ts +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -6,14 +6,14 @@ export declare enum RelationshipType {
|
|
|
6
6
|
export declare enum AutoReason {
|
|
7
7
|
FOREIGN_KEY = "foreign_key"
|
|
8
8
|
}
|
|
9
|
-
export declare enum
|
|
9
|
+
export declare enum AutoFieldSubType {
|
|
10
10
|
CREATED_BY = "createdBy",
|
|
11
11
|
CREATED_AT = "createdAt",
|
|
12
12
|
UPDATED_BY = "updatedBy",
|
|
13
13
|
UPDATED_AT = "updatedAt",
|
|
14
14
|
AUTO_ID = "autoID"
|
|
15
15
|
}
|
|
16
|
-
export declare enum
|
|
16
|
+
export declare enum FormulaType {
|
|
17
17
|
STATIC = "static",
|
|
18
18
|
DYNAMIC = "dynamic"
|
|
19
19
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FieldSubtype, FieldType } from "../row";
|
|
2
|
-
import {
|
|
2
|
+
import { AutoFieldSubType, AutoReason, FormulaType, RelationshipType } from "./constants";
|
|
3
3
|
export interface UIFieldMetadata {
|
|
4
4
|
order?: number;
|
|
5
5
|
width?: number;
|
|
@@ -12,7 +12,7 @@ interface BaseRelationshipFieldMetadata extends Omit<BaseFieldSchema, "subtype">
|
|
|
12
12
|
fieldName: string;
|
|
13
13
|
tableId: string;
|
|
14
14
|
tableRev?: string;
|
|
15
|
-
subtype?:
|
|
15
|
+
subtype?: AutoFieldSubType.CREATED_BY | AutoFieldSubType.UPDATED_BY;
|
|
16
16
|
}
|
|
17
17
|
type ManyToManyJunctionTableMetadata = {
|
|
18
18
|
through: string;
|
|
@@ -38,13 +38,13 @@ export type RelationshipFieldMetadata = ManyToManyRelationshipFieldMetadata | On
|
|
|
38
38
|
export interface AutoColumnFieldMetadata extends Omit<BaseFieldSchema, "subtype"> {
|
|
39
39
|
type: FieldType.AUTO;
|
|
40
40
|
autocolumn: true;
|
|
41
|
-
subtype?:
|
|
41
|
+
subtype?: AutoFieldSubType;
|
|
42
42
|
lastID?: number;
|
|
43
43
|
autoReason?: AutoReason;
|
|
44
44
|
}
|
|
45
45
|
export interface NumberFieldMetadata extends Omit<BaseFieldSchema, "subtype"> {
|
|
46
46
|
type: FieldType.NUMBER;
|
|
47
|
-
subtype?:
|
|
47
|
+
subtype?: AutoFieldSubType.AUTO_ID;
|
|
48
48
|
lastID?: number;
|
|
49
49
|
autoReason?: AutoReason.FOREIGN_KEY;
|
|
50
50
|
meta?: {
|
|
@@ -56,7 +56,7 @@ export interface DateFieldMetadata extends Omit<BaseFieldSchema, "subtype"> {
|
|
|
56
56
|
type: FieldType.DATETIME;
|
|
57
57
|
ignoreTimezones?: boolean;
|
|
58
58
|
timeOnly?: boolean;
|
|
59
|
-
subtype?:
|
|
59
|
+
subtype?: AutoFieldSubType.CREATED_AT | AutoFieldSubType.UPDATED_AT;
|
|
60
60
|
}
|
|
61
61
|
export interface LongFormFieldMetadata extends BaseFieldSchema {
|
|
62
62
|
type: FieldType.LONGFORM;
|
|
@@ -65,7 +65,7 @@ export interface LongFormFieldMetadata extends BaseFieldSchema {
|
|
|
65
65
|
export interface FormulaFieldMetadata extends BaseFieldSchema {
|
|
66
66
|
type: FieldType.FORMULA;
|
|
67
67
|
formula: string;
|
|
68
|
-
formulaType?:
|
|
68
|
+
formulaType?: FormulaType;
|
|
69
69
|
}
|
|
70
70
|
export interface BBReferenceFieldMetadata extends Omit<BaseFieldSchema, "subtype"> {
|
|
71
71
|
type: FieldType.BB_REFERENCE;
|
package/dist/index.js
CHANGED
|
@@ -33,7 +33,7 @@ __export(src_exports, {
|
|
|
33
33
|
AuditLogSystemUser: () => AuditLogSystemUser,
|
|
34
34
|
AuditedEventFriendlyName: () => AuditedEventFriendlyName,
|
|
35
35
|
AuthType: () => AuthType,
|
|
36
|
-
|
|
36
|
+
AutoFieldSubType: () => AutoFieldSubType,
|
|
37
37
|
AutoReason: () => AutoReason,
|
|
38
38
|
AutomationActionStepId: () => AutomationActionStepId,
|
|
39
39
|
AutomationCustomIOType: () => AutomationCustomIOType,
|
|
@@ -62,7 +62,7 @@ __export(src_exports, {
|
|
|
62
62
|
FieldType: () => FieldType,
|
|
63
63
|
FieldTypeSubtypes: () => FieldTypeSubtypes,
|
|
64
64
|
FilterType: () => FilterType,
|
|
65
|
-
|
|
65
|
+
FormulaType: () => FormulaType,
|
|
66
66
|
GroupType: () => GroupType,
|
|
67
67
|
Hosting: () => Hosting,
|
|
68
68
|
INTERNAL_TABLE_SOURCE_ID: () => INTERNAL_TABLE_SOURCE_ID,
|
|
@@ -934,19 +934,19 @@ var AutoReason = /* @__PURE__ */ ((AutoReason3) => {
|
|
|
934
934
|
AutoReason3["FOREIGN_KEY"] = "foreign_key";
|
|
935
935
|
return AutoReason3;
|
|
936
936
|
})(AutoReason || {});
|
|
937
|
-
var
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
return
|
|
944
|
-
})(
|
|
945
|
-
var
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
return
|
|
949
|
-
})(
|
|
937
|
+
var AutoFieldSubType = /* @__PURE__ */ ((AutoFieldSubType3) => {
|
|
938
|
+
AutoFieldSubType3["CREATED_BY"] = "createdBy";
|
|
939
|
+
AutoFieldSubType3["CREATED_AT"] = "createdAt";
|
|
940
|
+
AutoFieldSubType3["UPDATED_BY"] = "updatedBy";
|
|
941
|
+
AutoFieldSubType3["UPDATED_AT"] = "updatedAt";
|
|
942
|
+
AutoFieldSubType3["AUTO_ID"] = "autoID";
|
|
943
|
+
return AutoFieldSubType3;
|
|
944
|
+
})(AutoFieldSubType || {});
|
|
945
|
+
var FormulaType = /* @__PURE__ */ ((FormulaType3) => {
|
|
946
|
+
FormulaType3["STATIC"] = "static";
|
|
947
|
+
FormulaType3["DYNAMIC"] = "dynamic";
|
|
948
|
+
return FormulaType3;
|
|
949
|
+
})(FormulaType || {});
|
|
950
950
|
|
|
951
951
|
// src/documents/app/table/schema.ts
|
|
952
952
|
function isRelationshipField(field) {
|
|
@@ -1219,7 +1219,7 @@ var ServiceType = /* @__PURE__ */ ((ServiceType2) => {
|
|
|
1219
1219
|
AuditLogSystemUser,
|
|
1220
1220
|
AuditedEventFriendlyName,
|
|
1221
1221
|
AuthType,
|
|
1222
|
-
|
|
1222
|
+
AutoFieldSubType,
|
|
1223
1223
|
AutoReason,
|
|
1224
1224
|
AutomationActionStepId,
|
|
1225
1225
|
AutomationCustomIOType,
|
|
@@ -1248,7 +1248,7 @@ var ServiceType = /* @__PURE__ */ ((ServiceType2) => {
|
|
|
1248
1248
|
FieldType,
|
|
1249
1249
|
FieldTypeSubtypes,
|
|
1250
1250
|
FilterType,
|
|
1251
|
-
|
|
1251
|
+
FormulaType,
|
|
1252
1252
|
GroupType,
|
|
1253
1253
|
Hosting,
|
|
1254
1254
|
INTERNAL_TABLE_SOURCE_ID,
|