Use the User model for foreign keys.
Closes no issue.
Short description
Previously foreign keys pointed at Member objects. This created some issues as autocomplete_fields (in Django 2.0) and raw_id_fields require an Admin for the models that a foreign key points to. As Member has no Admin this meant that we could not use raw_id_fields and autocomplete_fields for Member.
This MR fixes this issue by replacing all foreign keys to Member with foreign keys to User.
In particular this MR does the following things:
- The
events,pizzas,activemembers, andmailinglistapps now use theUsermodel for foreign keys. - The
Membermodel has been renamed toProfileto reflect that it is (mostly) used for storage of extra information. - A proxy to
UsercalledMemberhas been added. This allows us to overrideManagers and__str__onUser. Most methods that did not make sense inProfilehave been moved to the newMember.
Edited by Ghost User