basic meal plan working

This commit is contained in:
vabene1111
2020-01-17 17:47:23 +01:00
parent 7449380434
commit afa69c647d
3 changed files with 63 additions and 43 deletions

View File

@@ -121,7 +121,7 @@ class MealPlanCreate(LoginRequiredMixin, CreateView):
obj = form.save(commit=False)
obj.user = self.request.user
obj.save()
return HttpResponseRedirect(self.get_success_url())
return HttpResponseRedirect(reverse('view_plan'))
def get_context_data(self, **kwargs):
context = super(MealPlanCreate, self).get_context_data(**kwargs)