DMehaffy
d656077399
add a few more bigint
2019-01-21 05:11:48 -07:00
Aurélien Georget
176aa52df0
Avoid duplicate loaders
2019-01-16 17:26:15 +01:00
Aurélien Georget
c8a0e51729
Fix where constraint in GraphQL query
2019-01-16 12:24:29 +01:00
Aurélien Georget
332cfdacab
Apply PR's feedback
2019-01-15 17:16:28 +01:00
Aurélien Georget
5df5933ec4
Fix loader name
2019-01-14 19:36:35 +01:00
Jim LAURIE
e41948de3f
Add setting for production environment
2019-01-09 14:19:39 +01:00
Aurélien Georget
b501e8bb1b
Resolve conflicts
2019-01-05 20:33:47 +01:00
Aurélien Georget
2df5ecae79
Reset loaders on every request to avoid wrong results coming from cache
2019-01-05 18:14:00 +01:00
Abdón Rodríguez Davila
a5dc07c0a5
Avoid write files if not development environment
2018-12-19 19:25:52 +01:00
Aurélien Georget
53b195c917
Avoid useless population
2018-12-06 19:12:31 +01:00
Aurélien Georget
ebf9cfdcaa
Handle one-to-many case
2018-12-06 18:23:56 +01:00
Aurélien Georget
e1ce257d2f
Revert codebase and apply limit, skip, start and sort parameters
2018-12-06 18:11:53 +01:00
Jim LAURIE
03c1e04d87
Revert filter PR
2018-12-04 17:05:03 +01:00
DMehaffy
2b38a92277
Add GraphQL limit settings
2018-11-29 03:46:30 -07:00
Aurélien Georget
b0aaae9f12
Resolve conflicts
2018-11-27 18:48:37 +01:00
Aurélien Georget
540e1bccf8
Allow private attribute into input definition
2018-11-27 14:59:28 +01:00
Aurélien Georget
143f92a338
Follow generated GraphQL input to return data
2018-11-26 18:32:35 +01:00
Aurélien Georget
6fd3319f18
Generate different input for edit mutation
2018-11-26 17:36:49 +01:00
Aurelsicoko
4e23e872ed
Support one-to-one relationship with DataLoader
2018-11-23 17:46:43 +01:00
Aurelsicoko
639c635885
Use the PK of referring model as an alias
2018-11-23 17:33:41 +01:00
Aurelsicoko
bdc9b4b0d8
Handle oneToMany relationship
2018-11-22 19:57:26 +01:00
Aurelsicoko
21d21dfc8f
Handle single fetch & allow override of default auto-population
2018-11-22 18:32:33 +01:00
Aurelsicoko
f833622e19
Filter undefined results
2018-11-22 17:33:51 +01:00
Aurelsicoko
0074ca6304
Refactoring loaders and put logic in a different file
2018-11-22 16:40:52 +01:00
Aurelsicoko
402d1fb4b6
Map result to retrieve data from loaders
2018-11-21 19:37:19 +01:00
Kamal Bennani Bouchiba
6482a6ec84
Merge branch 'master' into feature/allow-filtering-on-a-relation-attribute
2018-11-20 19:34:46 +01:00
Aurelsicoko
4320614721
Merge branch 'master' of github.com:strapi/strapi into issue/2228
2018-11-20 16:31:26 +01:00
Aurelsicoko
a30c7844a9
Generate generic dataloader for manyToMany relationships
2018-11-19 16:58:16 +01:00
Kamal Bennani
511ca55461
fix 1st level deep filter
2018-11-19 00:10:48 +01:00
Kamal Bennani
85eeb4aef2
Fix wrong rebase
2018-11-18 23:57:03 +01:00
Jim LAURIE
19ec6242f9
Merge branch 'master' into feature/allow-filtering-on-a-relation-attribute
2018-11-16 17:38:27 +01:00
Aurelsicoko
e28b69092d
Use primaryKey to associate correct related entry in manyToOne association
2018-11-15 17:47:17 +01:00
Jim LAURIE
08ababab42
Fix lint
2018-11-10 11:37:02 +01:00
Jim LAURIE
5188d70d91
Merge branch 'master' into fix-graphql-many-to-many-relations
2018-11-09 12:07:52 +01:00
Jim LAURIE
163f7e6533
Fix lint
2018-11-07 16:19:31 +01:00
Nick Verwymeren
87d41103a4
merged in master
2018-11-06 13:12:26 -06:00
Nick Verwymeren
7991f06294
Merge branch 'master' into fix-graphql-many-to-many-relations
2018-11-06 13:03:07 -06:00
Jim LAURIE
b8d8f7a297
Merge branch 'master' into fix/2213
2018-11-05 17:28:56 +01:00
cyril lopez
377da271e4
Fix lint from master
2018-11-05 11:31:36 +01:00
aissa-bouguern
cbf877074d
GraphQL many-to-many relations symmetry
...
Querying content types that share many-to-many relations do not return expected results.
Let's say we have a product content type and a category centent type. those two models share many-to-many relation, and when we are querying categories we have the expected result, Ex :
Query :
{
categories {
Name
products {
Name
}
}
}
Result :
{
"data": {
"categories": [
{
"Name": "Category 1",
"products": [
{
"Name": "Product 1"
}
]
},
{
"Name": "Category 2",
"products": [
{
"Name": "Product 1"
}
]
}
]
}
}
But when we're querying products, the categories array is empty!!
Query:
{
products {
Name
categories {
Name
}
}
}
Result:
{
"data": {
"products": [
{
"Name": "Product 1",
"categories": [ ]
}
]
}
}
categories should not be empty, it should be something like that :
...
"categories": [
{
"Name": "Category 1"
},
{
"Name": "Category 2"
}
]
....
I hope that was clear.
2018-10-29 22:36:39 +00:00
Kamal Bennani
15a41614fa
Don't populate relations in Graphql context
2018-10-28 23:42:22 +01:00
Kamal Bennani
9862705f8f
fix rebase issue
2018-10-28 23:42:21 +01:00
Kamal Bennani
2d1cf3591e
Split convertParams to multiple stage steps
2018-10-28 23:42:20 +01:00
Kamal Bennani
a84b640994
Make converQuery works also with array values
2018-10-28 23:42:20 +01:00
Kamal Bennani
382f52a2e8
Convert GraphQL params to one level-deep object
2018-10-28 23:42:19 +01:00
Nick Verwymeren
513558c8e9
Update GraphQL.js
2018-10-25 13:48:28 -05:00
Jim LAURIE
4ced536eaf
Remove logs Graphql
2018-10-18 14:33:08 +02:00
Ben Weller
1249909c46
re-add support for JSON graphql types
2018-10-12 13:29:18 -05:00
Jason Lei
3378403954
GraphQL Mutations, Aggregations, Decimals
...
Merging Mutations and Aggregations. Fixed Mongoose Hook to use Decimals (2 decimal places) and Floats (20 decimal places).
2018-09-10 16:05:00 +08:00
Nick Verwymeren
bd840d709e
Change comparison operator for array of id's
...
When there's an array of ID's present it looks like the Content Manager uses the '=' comparison which ends up returning an empty set. I think maybe the issue lies with the Content Manager plugin in that it should be using a 'IN' comparison if it detects an array. This is a workaround that seems to fix the issue. Although I'll be honest, I don't have enough knowledge of this plugin or the system to know if this will work for all edge cases.
2018-08-28 14:30:05 -04:00