Skip to content

Commit d9f9891

Browse files
authored
Merge pull request #326 from flask-dashboard/custom-graphs-enddate
Include the selected date into the custom graph end date
2 parents ac344a7 + a24913d commit d9f9891

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

flask_monitoringdashboard/database/custom_graph.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
from datetime import timedelta
2+
13
from sqlalchemy.orm.exc import NoResultFound
24

35
from flask_monitoringdashboard.database import CustomGraph, CustomGraphData, row2dict
@@ -43,7 +45,7 @@ def get_graph_data(db_session, graph_id, start_date, end_date):
4345
.filter(
4446
CustomGraphData.graph_id == graph_id,
4547
CustomGraphData.time >= start_date,
46-
CustomGraphData.time <= end_date,
48+
CustomGraphData.time < end_date + timedelta(days=1),
4749
)
4850
.all()
4951
]

0 commit comments

Comments
 (0)