aboutsummaryrefslogtreecommitdiffstats
path: root/graphql/models/gen_models.go
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2018-08-01 19:24:19 +0200
committerMichael Muré <batolettre@gmail.com>2018-08-01 19:24:19 +0200
commit15f282421941b90e1f62912cf68b7556a8ce7b33 (patch)
tree085c77b22313f1bf4650901de3197f4f200aba28 /graphql/models/gen_models.go
parent5830dd88414608b5fc6f5f2b44293b079bce2829 (diff)
downloadgit-bug-15f282421941b90e1f62912cf68b7556a8ce7b33.tar.gz
graphql: simplify the requests with helpers
Diffstat (limited to 'graphql/models/gen_models.go')
-rw-r--r--graphql/models/gen_models.go20
1 files changed, 8 insertions, 12 deletions
diff --git a/graphql/models/gen_models.go b/graphql/models/gen_models.go
index aacb0d92..8a832b23 100644
--- a/graphql/models/gen_models.go
+++ b/graphql/models/gen_models.go
@@ -12,9 +12,10 @@ import (
type Authored interface{}
type BugConnection struct {
- Edges []BugEdge `json:"edges"`
- PageInfo PageInfo `json:"pageInfo"`
- TotalCount int `json:"totalCount"`
+ Edges []BugEdge `json:"edges"`
+ Nodes []bug.Snapshot `json:"nodes"`
+ PageInfo PageInfo `json:"pageInfo"`
+ TotalCount int `json:"totalCount"`
}
type BugEdge struct {
Cursor string `json:"cursor"`
@@ -22,6 +23,7 @@ type BugEdge struct {
}
type CommentConnection struct {
Edges []CommentEdge `json:"edges"`
+ Nodes []bug.Comment `json:"nodes"`
PageInfo PageInfo `json:"pageInfo"`
TotalCount int `json:"totalCount"`
}
@@ -29,21 +31,15 @@ type CommentEdge struct {
Cursor string `json:"cursor"`
Node bug.Comment `json:"node"`
}
-type ConnectionInput struct {
- After *string `json:"after"`
- Before *string `json:"before"`
- First *int `json:"first"`
- Last *int `json:"last"`
-}
-type Operation interface{}
type OperationConnection struct {
Edges []OperationEdge `json:"edges"`
+ Nodes []bug.Operation `json:"nodes"`
PageInfo PageInfo `json:"pageInfo"`
TotalCount int `json:"totalCount"`
}
type OperationEdge struct {
- Cursor string `json:"cursor"`
- Node Operation `json:"node"`
+ Cursor string `json:"cursor"`
+ Node bug.Operation `json:"node"`
}
type PageInfo struct {
HasNextPage bool `json:"hasNextPage"`