Support editing email and registration type on registrations
authorMagnus Hagander <magnus@hagander.net>
Sat, 17 Nov 2018 17:34:59 +0000 (18:34 +0100)
committerMagnus Hagander <magnus@hagander.net>
Sat, 17 Nov 2018 17:34:59 +0000 (18:34 +0100)
Per experience from pgconfeu, this should not be limited to just
superusers. People make mistakes...

postgresqleu/confreg/backendforms.py

index e4d674cce6158e87000a339775d046196ed87ebf..636cb7107feb1f3d2d761f9c2795214d9c0f62df 100644 (file)
@@ -239,15 +239,16 @@ class BackendRegistrationForm(BackendForm):
        helplink = "registrations"
        class Meta:
                model = ConferenceRegistration
-               fields = ['firstname', 'lastname', 'company', 'address', 'country', 'phone',
+               fields = ['firstname', 'lastname', 'email', 'company', 'address', 'country', 'phone',
                                  'shirtsize', 'dietary', 'twittername', 'nick', 'shareemail',
-                                 'additionaloptions']
+                                 'regtype', 'additionaloptions']
 
        def fix_fields(self):
                if self.instance.payconfirmedat:
                        self.warning_text = "WARNING! This registration has already been completed! Edit with caution!"
 
                self.fields['additionaloptions'].queryset = ConferenceAdditionalOption.objects.filter(conference=self.conference)
+               self.fields['regtype'].queryset = RegistrationType.objects.filter(conference=self.conference)
                if not self.conference.askfood:
                        del self.fields['dietary']
                if not self.conference.asktshirt: