-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathadvancedFilterSchema.schema.ts
126 lines (116 loc) · 2.8 KB
/
advancedFilterSchema.schema.ts
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
// @ts-ignore
import { gql } from "graphql-modules";
export const advancedFilterSchema = gql`
enum AdvancedFilterTypes {
id
text
date
number
selection
boolean
type
metadata_on_relation
}
enum AutocompleteSelectionOptions {
auto
checkboxlist
autocomplete
}
input AdvancedFilterInput {
lookup: LookupInput
type: AdvancedFilterTypes!
selectionOption: AutocompleteSelectionOptions
parent_key: String
key: JSON
value: JSON!
metadata_key_as_label: String
item_types: [String]
match_exact: Boolean
provide_value_options_for_key: Boolean
operator: String
aggregation: String
returnIdAtIndex: Int
}
input LookupInput {
from: String!
local_field: String!
foreign_field: String!
as: String!
}
type AdvancedFilter {
lookup: LookupInputType
type: AdvancedFilterTypes!
selectionOption: AutocompleteSelectionOptions
parentKey: String
key: JSON
itemTypes: [String]
label: String
isDisplayedByDefault: Boolean!
showTimeForDateFilter: Boolean
options: [DropdownOption!]!
advancedFilterInputForRetrievingOptions: [AdvancedFilterInputType!]
aggregation: String
defaultValue(value: JSON!): JSON!
doNotOverrideDefaultValue(value: Boolean): Boolean
hidden(value: Boolean): Boolean!
tooltip(value: Boolean): Boolean
min: Int
max: Int
unit: String
context: JSON
}
type AdvancedFilterInputType {
lookup: LookupInputType
type: AdvancedFilterTypes!
selectionOption: AutocompleteSelectionOptions
parent_key: String
key: JSON
value: JSON!
metadata_key_as_label: String
item_types: [String]
match_exact: Boolean
aggregation: String
returnIdAtIndex: Int
context: JSON
}
type AdvancedFilters {
advancedFilter(
lookup: LookupInput
type: AdvancedFilterTypes!
selectionOption: AutocompleteSelectionOptions
parentKey: String
key: JSON
itemTypes: [String]
label: String
isDisplayedByDefault: Boolean
showTimeForDateFilter: Boolean
advancedFilterInputForRetrievingOptions: [AdvancedFilterInput!]
aggregation: String
min: Int
max: Int
unit: String
context: JSON
): AdvancedFilter!
}
type FilterMatcherMap {
id: [String!]!
text: [String!]!
date: [String!]!
number: [String!]!
selection: [String!]!
boolean: [String!]!
type: [String!]!
metadata_on_relation: [String!]!
}
type LookupInputType {
from: String!
local_field: String!
foreign_field: String!
as: String!
}
type Query {
FilterMatcherMapping: FilterMatcherMap!
EntityTypeFilters(type: String!): Entity!
FilterOptions(input: [AdvancedFilterInput!]!, limit: Int!, entityType: String!): [DropdownOption!]!
}
`;