Commit 5185ad8d authored by Charlie Jacomme's avatar Charlie Jacomme

[compte] Finalistion de creat avec redirections

parent 53aa6dc5
......@@ -12,6 +12,7 @@ urlpatterns = patterns('',
url('^chgpass/$', views.chgpass, name='chgpass'),
url('^chgpass/(?P<ptype>club)/(?P<uid>[0-9]+)/$', views.chgpass, name='chgpass'),
url('^chgpass/(?P<ptype>adh)/(?P<uid>[0-9]+)/$', views.chgpass, name='chgpass'),
url('^chgpass/(?P<ptype>adh)/(?P<uid>[0-9]+)/(?P<next>.*)/$', views.chgpass, name='chgpass'),
url('^redirection/$', views.redirection, name='redirection'),
url('^redirection/(?P<uid>[0-9]+)/$', views.redirection, name='redirection'),
url('^alias/$', views.alias, name='alias'),
......
......@@ -655,7 +655,8 @@ class CreateCompteView(CableurMixin, View):
elif res:
adherent.create()
messages.success(request, u"""Compte crée""")
return redirect(reverse('cablage:afficher'))
adh_url = reverse('compte:adhesion', args=(u'adh', adherent['aid'][0]))
return redirect(reverse('compte:chgpass', args=(u'adh', adherent['aid'][0], adh_url)))
return render(request, self.template_name, {'form1' : form1, 'form2' : form2, 'form3' : form3, 'confirm' : confirm})
create = CreateCompteView.as_view()
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