File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -164,10 +164,7 @@ class RealHumanBean(models.Model):
164164R.Human.CanBe(Human)
165165```
166166
167- # # Relay Support (WIP)
168- - [x] Node
169- - [x] Connection & Edges
170- - [ ] Mutations
167+ # # Relay Support
171168
172169At this point, Epoxy has rudimentary `relay` support. Enable support for `Relay` by mixing in the `RelayMixin` using
173170`TypeResolver.Mixin` .
@@ -206,6 +203,21 @@ class Query(R.ObjectType):
206203
207204```
208205
206+ # ## Mutations
207+ ```python
208+ class SimpleAddition(Relay.Mutation):
209+ class Input:
210+ a = R.Int
211+ b = R.Int
212+
213+ class Output:
214+ sum = R.Int
215+
216+ def execute(self , obj, input , info):
217+ return self .Output(sum = input .a + input .b)
218+
219+ ```
220+
209221# ## Adding some data!
210222Let' s add some pets to the `data_source` and query them!
211223
@@ -254,7 +266,7 @@ result = graphql(Schema, '''
254266```
255267
256268
257- # # Mutations (Coming Soon)
269+ # # Mutations
258270
259271Epoxy also supports defining mutations. Making a Mutation a Relay mutation is as simple as changing `R.Mutation` to
260272`Relay.Mutation` .
You can’t perform that action at this time.
0 commit comments