@vibeorm/schema 5.6.0 → 5.7.0
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/errors.d.ts +5 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +27 -2
- package/dist/index.js.map +5 -5
- package/dist/referential-actions.d.ts +11 -0
- package/package.json +1 -1
|
@@ -32,4 +32,15 @@ export declare function resolveReferentialActions(params: {
|
|
|
32
32
|
readonly onDelete: CascadeAction;
|
|
33
33
|
readonly onUpdate: CascadeAction;
|
|
34
34
|
};
|
|
35
|
+
/**
|
|
36
|
+
* The first to-one relation whose foreign key includes `field` and declares
|
|
37
|
+
* SET DEFAULT on delete or update: the database would then write that
|
|
38
|
+
* column's default, which for a tenant column can be another tenant's value.
|
|
39
|
+
* SET DEFAULT is never an implied action, so the declared one is the
|
|
40
|
+
* effective one.
|
|
41
|
+
*/
|
|
42
|
+
export declare function setDefaultRelationOf<Relation extends Pick<RelationIR, "fields" | "onDelete" | "onUpdate" | "isList">>(params: {
|
|
43
|
+
relations: readonly Relation[];
|
|
44
|
+
field: string;
|
|
45
|
+
}): Relation | undefined;
|
|
35
46
|
//# sourceMappingURL=referential-actions.d.ts.map
|