Skip to content

Commit cd2afe3

Browse files
committed
More DateTime stuff
1 parent 2a107bb commit cd2afe3

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

graphql-api-generator/utils/utils.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ def add_scalar_filters(schema: GraphQLSchema, config: dict):
473473
' _neq: Boolean ' \
474474
'} '
475475

476-
# Date
476+
# Date (behaves like a string?)
477477
if config.get('generation').get('generate_date'):
478478
manually_handled_scalars.append('Date')
479479
make += 'input _DateFilter {' \
@@ -487,7 +487,7 @@ def add_scalar_filters(schema: GraphQLSchema, config: dict):
487487
' _elt: Date ' \
488488
'} '
489489

490-
# DateTime
490+
# DateTime (behaves like a integer)
491491
if config.get('generation').get('generate_datetime'):
492492
manually_handled_scalars.append('DateTime')
493493
make += 'input _DateTimeFilter {' \
@@ -535,6 +535,7 @@ def add_type_filters(schema: GraphQLSchema, field_for_creation_date, field_for_l
535535
f' _not: _FilterFor{_type.name} '
536536

537537
for field_name, field in _type.fields.items():
538+
# This is a bit questionable
538539
if field_name[0] == '_' and not (field_for_creation_date and field_name == '_creationDate') and not (field_for_last_update_date and field_name == '_lastUpdateDate'):
539540
continue
540541

0 commit comments

Comments
 (0)