Skip to content

Commit

Permalink
Merge pull request #984 from hackforla/mattyweb/issue976
Browse files Browse the repository at this point in the history
Mattyweb/issue976
  • Loading branch information
mattyweb authored Mar 2, 2021
2 parents 6d24617 + 4087309 commit f30321f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion server/api/code/lacity_data_api/routers/reports.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
'DOW',
ServiceRequest.created_date
).label('created_dow'),
"created_hour": db.extract(
'HOUR',
ServiceRequest.created_date
).label('created_hour'),
"created_date": cast(
ServiceRequest.created_date, DATE
).label('created_date'),
Expand All @@ -46,7 +50,7 @@ async def run_report(
field: Optional[List[str]] = Query(
["type_name", "created_date"],
description="ex. created_date",
regex="""(created_year|created_month|created_dow|created_date|council_name|type_name|agency_name|source_name)""" # noqa
regex="""(created_year|created_month|created_dow|created_hour|created_date|council_name|type_name|agency_name|source_name)""" # noqa
),
filter: Optional[List[str]] = Query(
[f"created_date>={str(datetime.date.today().year) + '-01-01'}"],
Expand Down

0 comments on commit f30321f

Please sign in to comment.