mirror of
https://github.com/silverstripe/silverstripe-frameworktest
synced 2024-10-22 11:06:02 +02:00
NEW GraphQL 4 Compatability (#72)
* Initial compat for graphql4 * Fix graphql config
This commit is contained in:
parent
fd800a3a79
commit
030208712a
59
_config/graphql-legacy.yml
Normal file
59
_config/graphql-legacy.yml
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
---
|
||||||
|
Name: frameworktestgraphql-legacy
|
||||||
|
After: '#graphqlconfig'
|
||||||
|
Except:
|
||||||
|
classexists: 'SilverStripe\GraphQL\Schema\Schema'
|
||||||
|
---
|
||||||
|
|
||||||
|
SilverStripe\Core\Injector\Injector:
|
||||||
|
SilverStripe\GraphQL\Manager.frameworktest:
|
||||||
|
class: SilverStripe\GraphQL\Manager
|
||||||
|
constructor:
|
||||||
|
identifier: frameworktest
|
||||||
|
SilverStripe\GraphQL\Controller.frameworktest:
|
||||||
|
class: SilverStripe\GraphQL\Controller
|
||||||
|
constructor:
|
||||||
|
manager: '%$SilverStripe\GraphQL\Manager.frameworktest'
|
||||||
|
|
||||||
|
SilverStripe\Control\Director:
|
||||||
|
rules:
|
||||||
|
'frameworktest/graphql':
|
||||||
|
Controller: '%$SilverStripe\GraphQL\Controller.frameworktest'
|
||||||
|
|
||||||
|
SilverStripe\GraphQL\Manager:
|
||||||
|
schemas:
|
||||||
|
frameworktest:
|
||||||
|
typeNames:
|
||||||
|
SilverStripe\FrameworkTest\Model\Company: Company
|
||||||
|
SilverStripe\FrameworkTest\Model\Employee: Employee
|
||||||
|
scaffolding:
|
||||||
|
types:
|
||||||
|
SilverStripe\FrameworkTest\Model\Company:
|
||||||
|
fields:
|
||||||
|
- ID
|
||||||
|
- Name
|
||||||
|
- Category
|
||||||
|
- Revenue
|
||||||
|
- CEO
|
||||||
|
operations:
|
||||||
|
read: true
|
||||||
|
update: true
|
||||||
|
create: true
|
||||||
|
delete: true
|
||||||
|
readOne: true
|
||||||
|
nestedQueries:
|
||||||
|
Employees: true
|
||||||
|
PastEmployees: true
|
||||||
|
SilverStripe\FrameworkTest\Model\Employee:
|
||||||
|
fields:
|
||||||
|
- ID
|
||||||
|
- Name
|
||||||
|
- Biography
|
||||||
|
- DateOfBirth
|
||||||
|
- Category
|
||||||
|
operations:
|
||||||
|
read: true
|
||||||
|
update: true
|
||||||
|
create: true
|
||||||
|
delete: true
|
||||||
|
readOne: true
|
@ -1,56 +1,55 @@
|
|||||||
---
|
---
|
||||||
Name: frameworktestgraphql
|
Name: frameworktestgraphql
|
||||||
After: '#graphqlconfig'
|
After: '#graphqlconfig'
|
||||||
|
Only:
|
||||||
|
classexists: 'SilverStripe\GraphQL\Schema\Schema'
|
||||||
---
|
---
|
||||||
|
|
||||||
SilverStripe\Core\Injector\Injector:
|
SilverStripe\Core\Injector\Injector:
|
||||||
SilverStripe\GraphQL\Manager.frameworktest:
|
SilverStripe\GraphQL\Schema\Schema.frameworktest:
|
||||||
class: SilverStripe\GraphQL\Manager
|
class: SilverStripe\GraphQL\Schema\Schema
|
||||||
constructor:
|
constructor:
|
||||||
identifier: frameworktest
|
schemaKey: frameworktest
|
||||||
SilverStripe\GraphQL\Controller.frameworktest:
|
SilverStripe\GraphQL\Controller.frameworktest:
|
||||||
class: SilverStripe\GraphQL\Controller
|
class: SilverStripe\GraphQL\Controller
|
||||||
constructor:
|
constructor:
|
||||||
manager: '%$SilverStripe\GraphQL\Manager.frameworktest'
|
schema: frameworktest
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
SilverStripe\Control\Director:
|
SilverStripe\Control\Director:
|
||||||
rules:
|
rules:
|
||||||
'frameworktest/graphql':
|
'frameworktest/graphql':
|
||||||
Controller: '%$SilverStripe\GraphQL\Controller.frameworktest'
|
Controller: '%$SilverStripe\GraphQL\Controller.frameworktest'
|
||||||
|
|
||||||
SilverStripe\GraphQL\Manager:
|
SilverStripe\GraphQL\Schema\Schema:
|
||||||
schemas:
|
schemas:
|
||||||
frameworktest:
|
frameworktest:
|
||||||
typeNames:
|
modelConfig:
|
||||||
|
type_mapping:
|
||||||
SilverStripe\FrameworkTest\Model\Company: Company
|
SilverStripe\FrameworkTest\Model\Company: Company
|
||||||
SilverStripe\FrameworkTest\Model\Employee: Employee
|
SilverStripe\FrameworkTest\Model\Employee: Employee
|
||||||
scaffolding:
|
models:
|
||||||
types:
|
|
||||||
SilverStripe\FrameworkTest\Model\Company:
|
SilverStripe\FrameworkTest\Model\Company:
|
||||||
fields:
|
fields:
|
||||||
- ID
|
ID: true
|
||||||
- Name
|
Name: true
|
||||||
- Category
|
Category: true
|
||||||
- Revenue
|
Revenue: true
|
||||||
- CEO
|
CEO: true
|
||||||
operations:
|
|
||||||
read: true
|
|
||||||
update: true
|
|
||||||
create: true
|
|
||||||
delete: true
|
|
||||||
readOne: true
|
|
||||||
nestedQueries:
|
|
||||||
Employees: true
|
Employees: true
|
||||||
PastEmployees: true
|
PastEmployees: true
|
||||||
SilverStripe\FrameworkTest\Model\Employee:
|
operations:
|
||||||
fields:
|
read: true
|
||||||
- ID
|
update: true
|
||||||
- Name
|
create: true
|
||||||
- Biography
|
delete: true
|
||||||
- DateOfBirth
|
readOne: true
|
||||||
- Category
|
SilverStripe\FrameworkTest\Model\Employee:
|
||||||
|
fields:
|
||||||
|
ID: true
|
||||||
|
Name: true
|
||||||
|
Biography: true
|
||||||
|
DateOfBirth: true
|
||||||
|
Category: true
|
||||||
operations:
|
operations:
|
||||||
read: true
|
read: true
|
||||||
update: true
|
update: true
|
||||||
|
Loading…
Reference in New Issue
Block a user