agenda: create acts on the fly in the validation view

This commit is contained in:
Benjamin Dauvergne 2013-01-06 02:09:41 +01:00
parent 8d70235e67
commit 2ea544113d
1 changed files with 2 additions and 1 deletions

View File

@ -205,7 +205,8 @@ class AgendaServiceActValidationView(TemplateView):
template_name = 'agenda/act-validation.html'
def acts_of_the_day(self):
return get_acts_of_the_day(self.date, self.service)
return [e.act for e in EventWithAct.objects.filter(patient__service=self.service)
.today_occurrences(self.date)]
def post(self, request, *args, **kwargs):
if 'unlock-all' in request.POST: