Ejemplo n.º 1
0
 def _process(self):
     form = self._create_form()
     if form.validate_on_submit():
         if isinstance(form, AddLocalIdentityForm):
             self._handle_add_local_account(form)
         elif isinstance(form, EditLocalIdentityForm):
             self._handle_edit_local_account(form)
         return redirect(url_for('auth.accounts'))
     provider_titles = {name: provider.title for name, provider in multipass.identity_providers.iteritems()}
     return WPAuthUser.render_template('accounts.html', form=form, user=self.user, provider_titles=provider_titles)
Ejemplo n.º 2
0
 def _process(self):
     form = self._create_form()
     if form.validate_on_submit():
         if isinstance(form, AddLocalIdentityForm):
             self._handle_add_local_account(form)
         elif isinstance(form, EditLocalIdentityForm):
             self._handle_edit_local_account(form)
         return redirect(url_for('auth.accounts'))
     provider_titles = {name: provider.title for name, provider in multipass.identity_providers.iteritems()}
     return WPAuthUser.render_template('accounts.html', form=form, user=self.user, provider_titles=provider_titles)