Commit 3f7331e4 authored by Bryan  BRANCOTTE's avatar Bryan BRANCOTTE
Browse files

302 on success

parent e794d03c
Pipeline #61375 passed with stage
in 1 minute and 17 seconds
...@@ -232,11 +232,7 @@ def account_detail(request): ...@@ -232,11 +232,7 @@ def account_detail(request):
)(instance=pref, data=request.POST if is_posted else None) )(instance=pref, data=request.POST if is_posted else None)
if is_posted and form_prefs.is_valid(): if is_posted and form_prefs.is_valid():
form_prefs.save() form_prefs.save()
form_prefs = forms.modelform_factory( return redirect(reverse("basetheme_bootstrap:account"))
klass,
fields=list(pref.get_allowed_fields()),
widgets=widgets_dict,
)(instance=klass.get_for_user(user=request.user))
# dirty patch for time field (don't know why django doesn't express the correct type by default) # dirty patch for time field (don't know why django doesn't express the correct type by default)
for f in form_prefs.fields.values(): for f in form_prefs.fields.values():
if isinstance(f.widget, widgets.TimeInput): if isinstance(f.widget, widgets.TimeInput):
......
...@@ -7,7 +7,7 @@ readme = open('README.rst').read() ...@@ -7,7 +7,7 @@ readme = open('README.rst').read()
setup( setup(
name='django-basetheme-bootstrap', name='django-basetheme-bootstrap',
version='0.2.63', version='0.2.64',
description='Django Basetheme Bootstrap', description='Django Basetheme Bootstrap',
long_description=readme, long_description=readme,
author='Bryan Brancotte', author='Bryan Brancotte',
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment