- Notifications
You must be signed in to change notification settings - Fork2
Commita10658b
feat: 🎸 ORN-1185 Add Filter AND/OR relation support, for nested taxonomy filtering (#19)
* feat: 🎸 Add flat filter behavior with AND/OR operatorThis is not PR-ready, and has MCs, Lint errs, etc✅ Closes: ORN-1185* test: add some tests for or / and behavior* test: update test names* refactor: return void for setupBeforeClass* feat: 🎸 Recursive filter and/or fn with limit depth of 10Recursive filter schema def & filter to recursive fn for wpQuerybuilding. Testsed successfully so far to a depth of 3 but yet to belinted or unit-tested* refactor: 💡 Refactor depth nesting limit for filter argsJust throwing a null when occurs now to break the recursive loop* refactor: 💡 Added catch for empty relation array & fix linting* refactor: 💡 Re-added like operator special behavior to filtersHad removed earlier as it appeared to be buggy but seems like my issueas everything looks fine now* refactor: 💡 Fixed/expanded broken nested filter unit tests* refactor: made sure to check if filter arg exists* refactor: 💡 Replace nulls at error-state filtering w/throwablesReplaced the return nulls at the following with throwable Exceptions,natively picked up by WPGrapqhQL response object* docs: ✏️ Prepend@throws Exception fn docs header comments w '\'* fix: 🐛 Rework problematic function for SQL Nested Limit RemovalAs per Dimi suggestion.* refactor: 💡 Fix for all PR Suggestion, except Page & Exceptions* test: update tests to include 20 more posts (#24)* test: add test for errors* refactor: 💡 Refactored filter err tests & Err/Exceptions & Lint* refactor: 💡 Fix comment typo* refactor: 💡 Removed leftover throws error annotation in commentCo-authored-by: Shane Daly <shane.daly@wpengine.com>1 parentc683432 commita10658b
File tree
5 files changed
+615
-54
lines changed- src
- tests/src
5 files changed
+615
-54
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | | - | |
| 145 | + | |
| 146 | + | |
146 | 147 | | |
147 | | - | |
| 148 | + | |
148 | 149 | | |
149 | 150 | | |
150 | 151 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 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 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| |||
57 | 57 | | |
58 | 58 | | |
59 | 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 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
60 | 159 | | |
61 | 160 | | |
62 | 161 | | |
63 | 162 | | |
64 | 163 | | |
65 | 164 | | |
66 | | - | |
| 165 | + | |
67 | 166 | | |
68 | | - | |
| 167 | + | |
69 | 168 | | |
70 | 169 | | |
71 | 170 | | |
72 | 171 | | |
73 | 172 | | |
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 | 173 | | |
111 | | - | |
112 | | - | |
113 | | - | |
| 174 | + | |
114 | 175 | | |
115 | | - | |
| 176 | + | |
116 | 177 | | |
| 178 | + | |
117 | 179 | | |
118 | 180 | | |
119 | | - | |
120 | 181 | | |
121 | 182 | | |
122 | 183 | | |
| |||
220 | 281 | | |
221 | 282 | | |
222 | 283 | | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
223 | 292 | | |
224 | 293 | | |
225 | 294 | | |
226 | 295 | | |
227 | 296 | | |
228 | 297 | | |
229 | | - | |
| 298 | + | |
230 | 299 | | |
231 | 300 | | |
232 | 301 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
47 | 60 | | |
48 | 61 | | |
49 | 62 | | |
| |||
223 | 236 | | |
224 | 237 | | |
225 | 238 | | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
226 | 243 | | |
227 | 244 | | |
228 | 245 | | |
| |||
232 | 249 | | |
233 | 250 | | |
234 | 251 | | |
235 | | - | |
236 | 252 | | |
237 | 253 | | |
238 | 254 | | |
| |||
316 | 332 | | |
317 | 333 | | |
318 | 334 | | |
319 | | - | |
| 335 | + | |
320 | 336 | | |
321 | 337 | | |
322 | 338 | | |
| |||
337 | 353 | | |
338 | 354 | | |
339 | 355 | | |
340 | | - | |
| 356 | + | |
341 | 357 | | |
342 | 358 | | |
343 | 359 | | |
| |||
599 | 615 | | |
600 | 616 | | |
601 | 617 | | |
602 | | - | |
| 618 | + | |
603 | 619 | | |
604 | 620 | | |
605 | 621 | | |
| |||
641 | 657 | | |
642 | 658 | | |
643 | 659 | | |
644 | | - | |
| 660 | + | |
645 | 661 | | |
646 | 662 | | |
647 | 663 | | |
| |||
0 commit comments
Comments
(0)