Skip to content

Commit

Permalink
feat: update employees
Browse files Browse the repository at this point in the history
  • Loading branch information
JivusAyrus committed Sep 3, 2024
1 parent 17edcc3 commit 160a1dd
Show file tree
Hide file tree
Showing 6 changed files with 109 additions and 2 deletions.
10 changes: 10 additions & 0 deletions demos/go/pkg/subgraphs/employees/subgraph/employees.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ var employees = []*model.Employee{
Notes: strPtr("Jens notes resolved by employees"),
StartDate: "January 2020",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -90,6 +91,7 @@ var employees = []*model.Employee{
Notes: strPtr("Dustin notes resolved by employees"),
StartDate: "July 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -129,6 +131,7 @@ var employees = []*model.Employee{
Notes: strPtr("Stefan notes resolved by employees"),
StartDate: "June 2021",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -171,6 +174,7 @@ var employees = []*model.Employee{
Notes: strPtr("Björn notes resolved by employees"),
StartDate: "July 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
ID: 5,
Expand Down Expand Up @@ -211,6 +215,7 @@ var employees = []*model.Employee{
Notes: strPtr("Serigy notes resolved by employees"),
StartDate: "July 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -251,6 +256,7 @@ var employees = []*model.Employee{
Notes: strPtr("Suvij notes resolved by employees"),
StartDate: "September 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -291,6 +297,7 @@ var employees = []*model.Employee{
Notes: strPtr("Nithin notes resolved by employees"),
StartDate: "September 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -331,6 +338,7 @@ var employees = []*model.Employee{
Notes: strPtr("Eelco notes resolved by employees"),
StartDate: "November 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -373,6 +381,7 @@ var employees = []*model.Employee{
Notes: strPtr("Alexandra notes resolved by employees"),
StartDate: "November 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
{
Details: &model.Details{
Expand Down Expand Up @@ -413,6 +422,7 @@ var employees = []*model.Employee{
Notes: strPtr("David notes resolved by employees"),
StartDate: "December 2022",
UpdatedAt: "2021-09-01T00:00:00Z",
A: "a",
},
}

Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

91 changes: 90 additions & 1 deletion demos/go/pkg/subgraphs/employees/subgraph/generated/generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion demos/go/pkg/subgraphs/employees/subgraph/schema.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,15 @@ type Employee implements Identifiable @key(fields: "id") {
role: RoleType!
notes: String @shareable
updatedAt: String!
startDate: String! @requiresScopes(scopes: [["read:employee", "read:private"], ["read:all"]])
startDate: String!
@requiresScopes(scopes: [["read:employee", "read:private"], ["read:all"]])
currentMood: Mood! @external
derivedMood: Mood! @requires(fields: "currentMood")
# From the `availability` service. Only defined for use in @requires
isAvailable: Boolean! @external
rootFieldThrowsError: String @goField(forceResolver: true)
rootFieldErrorWrapper: ErrorWrapper @goField(forceResolver: true)
a: String!
}

type ErrorWrapper {
Expand Down
4 changes: 4 additions & 0 deletions demos/go/pkg/subgraphs/employees/subgraph/schema.resolvers.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 160a1dd

Please sign in to comment.