Project

General

Profile

Bug #7386

custom user fields appear on profile edit page even if not set as user_visible and editable

Added by Serghei Mihai over 4 years ago. Updated about 2 years ago.

Status:
Fermé
Priority:
Normal
Assignee:
Category:
-
Target version:
Start date:
27 May 2015
Due date:
% Done:

0%

Patch proposed:
Yes
Planning:
No

0001-fix-displaying-custom-user-attributes-in-forms-7386.patch View (904 Bytes) Serghei Mihai, 27 May 2015 06:22 PM

0001-fix-displaying-custom-user-attributes-in-forms-7386.patch View (2.73 KB) Serghei Mihai, 28 May 2015 12:11 PM

0001-fix-displaying-custom-user-attributes-in-forms-7386.patch View (2.12 KB) Serghei Mihai, 29 May 2015 02:43 PM

Associated revisions

Revision 53a7ce69 (diff)
Added by Serghei Mihai over 4 years ago

fix displaying custom user attributes in forms (#7386)

History

#1 Updated by Benjamin Dauvergne over 4 years ago

  • Assignee set to Serghei Mihai
  • Target version set to 2.2.0

#2 Updated by Serghei Mihai over 4 years ago

#4 Updated by Benjamin Dauvergne over 4 years ago

I'm not sure of that:

 self.assertFalse(set(form.fields), set(['national_number', 'custom']))

#5 Updated by Serghei Mihai over 4 years ago

If there are no other user fields to edit(like first and last name) the only possible fields to edit could be national_number and custom.
And in default config there are no other fields.

So I check if both fields do not appear if the form.

#6 Updated by Serghei Mihai over 4 years ago

After discussion with Benjamin I prefer check the fields presence with:

        self.assertNotIn('national_number', form.fields)
        self.assertNotIn('custom', form.fields)

#7 Updated by Serghei Mihai over 4 years ago

Finally one single assertEqual
Depends of #7391

#8 Updated by Serghei Mihai over 4 years ago

  • Status changed from Nouveau to Résolu (à déployer)
commit 53a7ce694e3215dcb872dccf52dbe84a870d172a
Author: Serghei Mihai <smihai@entrouvert.com>
Date:   Fri May 29 11:51:57 2015 +0200

    fix displaying custom user attributes in forms (#7386)

#9 Updated by Benjamin Dauvergne almost 4 years ago

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

#10 Updated by Benjamin Dauvergne about 2 years ago

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

Also available in: Atom PDF