Project

General

Profile

Development #6950

Refactoring of all user editing views

Added by Benjamin Dauvergne almost 6 years ago. Updated about 3 years ago.

Status:
Fermé
Priority:
Normal
Category:
-
Target version:
Start date:
15 Apr 2015
Due date:
% Done:

100%

Estimated time:
Patch proposed:
No
Planning:

Description

There is too much ad-hoc code in profile edition form, admin user change form, manager user edit form and registration form.

They should all use a same base user form, with adaptations done using a variation on the modelform_factory() function. It should be possible to set the list of fields to show, their labels and which one are required.

Username and email can be set to be globally unique or only for users registered online.

Associated revisions

Revision 700fc9b2 (diff)
Added by Benjamin Dauvergne almost 6 years ago

Refactor all model forms on the User model (fixes #6950)

All forms have been rebased on a BaseUserForm using modelform_factory.
New settings are introduces:
- A2_USERNAME_IS_UNIQUE
- A2_EMAIL_IS_UNIQUE
- A2_REGISTRATION_USERNAME_IS_UNIQUE
- A2_REQUIRED_FIELDS

Beware that attributes settings using the Attribute model supersede the
settings; i.e. if an attribute has the ask_on_registration flag, it will always
be shown, A2_REGISTRATION_FIELDS will just change its order; required field are
also always shown.

History

#1

Updated by Benjamin Dauvergne almost 6 years ago

  • Description updated (diff)
  • Assignee set to Benjamin Dauvergne
  • Target version set to 2.2.0
#2

Updated by Benjamin Dauvergne almost 6 years ago

  • Status changed from Nouveau to Résolu (à déployer)
  • % Done changed from 0 to 100
#3

Updated by Benjamin Dauvergne about 5 years ago

  • Status changed from Résolu (à déployer) to Solution déployée
#4

Updated by Benjamin Dauvergne about 3 years ago

  • Status changed from Solution déployée to Fermé

Also available in: Atom PDF