Skip to content
Snippets Groups Projects
Commit bdefa62d authored by Carlos Vega's avatar Carlos Vega
Browse files

removed log message and added call to get_object_or_404

parent 90aa2cc9
No related branches found
No related tags found
1 merge request!171Feature/daily availability
......@@ -41,8 +41,7 @@ def appointment_details(request, id):
def appointment_add(request, visit_id=None):
if visit_id is not None:
logger.warn(visit_id)
visit = Visit.objects.filter(id=int(visit_id))[0]
visit = get_object_or_404(Visit, id=visit_id)
visit_start = visit.datetime_begin.strftime("%Y-%m-%d")
visit_end = visit.datetime_end.strftime("%Y-%m-%d")
else:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment