From 5d51a6a915add774443002f059deacaa4a7d33bf Mon Sep 17 00:00:00 2001 From: Martin Fenner Date: Fri, 10 Apr 2020 12:40:31 +0200 Subject: [PATCH] allow datetime --- app/graphql/types/date_type.rb | 2 +- spec/graphql/types/date_type_spec.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/graphql/types/date_type.rb b/app/graphql/types/date_type.rb index 3087cbb15..48ebe890e 100644 --- a/app/graphql/types/date_type.rb +++ b/app/graphql/types/date_type.rb @@ -3,6 +3,6 @@ class DateType < BaseObject description "Information about dates" - field :date, GraphQL::Types::ISO8601Date, null: false, description: "Date information for this resource" + field :date, GraphQL::Types::ISO8601DateTime, null: false, description: "Date information for this resource" field :date_type, String, null: true, hash_key: "dateType", description: "The type of date" end diff --git a/spec/graphql/types/date_type_spec.rb b/spec/graphql/types/date_type_spec.rb index 8644a26e0..0920af426 100644 --- a/spec/graphql/types/date_type_spec.rb +++ b/spec/graphql/types/date_type_spec.rb @@ -5,6 +5,6 @@ subject { described_class } it { is_expected.to have_field(:dateType).of_type("String") } - it { is_expected.to have_field(:date).of_type("ISO8601Date!") } + it { is_expected.to have_field(:date).of_type("ISO8601DateTime!") } end end