Skip to content

Commit

Permalink
update assignment graphql type to have the starts/ends on
Browse files Browse the repository at this point in the history
  • Loading branch information
fermion committed Feb 14, 2024
1 parent 02a6662 commit eb5079f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
7 changes: 7 additions & 0 deletions app/graphql/schema.graphql
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
type Assignment {
createdAt: ISO8601DateTime!
endsOn: ISO8601Date
id: ID!
project: Project!
startsOn: ISO8601Date
status: String!
updatedAt: ISO8601DateTime!
user: User!
Expand All @@ -28,6 +30,11 @@ type Company {
users: [User!]!
}

"""
An ISO 8601-encoded date
"""
scalar ISO8601Date @specifiedBy(url: "https://tools.ietf.org/html/rfc3339")

"""
An ISO 8601-encoded datetime
"""
Expand Down
2 changes: 2 additions & 0 deletions app/graphql/types/staff_plan/assignment_type.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ class AssignmentType < Types::BaseObject
field :user, Types::StaffPlan::UserType, null: false
field :project, Types::StaffPlan::ProjectType, null: false
field :status, String, null: false
field :starts_on, GraphQL::Types::ISO8601Date, null: true
field :ends_on, GraphQL::Types::ISO8601Date, null: true
field :created_at, GraphQL::Types::ISO8601DateTime, null: false
field :updated_at, GraphQL::Types::ISO8601DateTime, null: false

Expand Down

0 comments on commit eb5079f

Please sign in to comment.