Self hosted FLOSS fitness/workout, nutrition and weight tracker
Fixing style
Harlene Samra17557c8c6fd9
diff --git a/wger/nutrition/forms.py b/wger/nutrition/forms.pyindex a2ab136c3..84c837b0e 100644--- a/wger/nutrition/forms.py+++ b/wger/nutrition/forms.py@@ -260,21 +260,22 @@ class MealLogItemForm(MealItemForm):'weight_unit','amount']+class IngredientForm(forms.ModelForm):class Meta:model = Ingredientfields = ['name',- 'energy',- 'protein',- 'carbohydrates',- 'carbohydrates_sugar',- 'fat',- 'fat_saturated',- 'fibres',- 'sodium',- 'license',- 'license_author']-+ 'energy',+ 'protein',+ 'carbohydrates',+ 'carbohydrates_sugar',+ 'fat',+ 'fat_saturated',+ 'fibres',+ 'sodium',+ 'license',+ 'license_author']+def __init__(self, *args, **kwargs):super(IngredientForm, self).__init__(*args, **kwargs)self.helper = FormHelper()@@ -296,4 +297,4 @@ class IngredientForm(forms.ModelForm):'sodium','license','license_author'- )\ No newline at end of file+ )diff --git a/wger/nutrition/views/ingredient.py b/wger/nutrition/views/ingredient.pyindex 07526c138..6747ed718 100644--- a/wger/nutrition/views/ingredient.py+++ b/wger/nutrition/views/ingredient.py@@ -46,7 +46,7 @@ from django.views.generic import ()# wger-from wger.nutrition.forms import (+from wger.nutrition.forms import (UnitChooserForm,IngredientForm,)@@ -187,7 +187,7 @@ class IngredientCreateView(WgerFormMixin, CreateView):if request.user.userprofile.is_temporary:return HttpResponseForbidden()return super(IngredientCreateView, self).dispatch(request, *args, **kwargs)-+def get_context_data(self, **kwargs):context = super(IngredientCreateView, self).get_context_data(**kwargs)context['extend_template'] = 'base.html'