-
Notifications
You must be signed in to change notification settings - Fork 11
/
types.js
55 lines (49 loc) · 1.16 KB
/
types.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
export type OrderTuple = [string, number];
export type FindParams = {
query?: Object,
page?: number,
perPage?: number,
order?: Array<OrderTuple>,
includeDeleted?: boolean
};
export type FindOneParams = {
query?: Object,
includeDeleted?: boolean
};
export type SaveParams = {
validation?: boolean,
getId?: Function,
hooks?: {
beforeSave?: boolean,
beforeUpdate?: boolean,
beforeCreate?: boolean,
afterSave?: boolean,
afterUpdate?: boolean,
afterCreate?: boolean,
__update?: boolean,
__beforeUpdate?: boolean,
__afterUpdate?: boolean,
__create?: boolean,
__beforeCreate?: boolean,
__afterCreate?: boolean,
__save?: boolean,
__beforeSave?: boolean,
__afterSave?: boolean,
}
};
export type DeleteParams = {
validation?: boolean,
permanent?: boolean,
getId?: Function,
events?: {
delete?: boolean,
beforeDelete?: boolean,
afterDelete?: boolean
}
};
export type AttributeOptions = {
refNameField?: string
};
export type EntitiesAttributeOptions = {
refNameField?: string
};