I successfully followed the steps from this thread:
and installed the plugin from here:
But that ultimately just adds new fields which are mandatory. I’d like to
Change the wording of “Support education research by providing additional information” (to something more like “Help us provide better education by telling us about yourself”.)
Change the optional fields that are shown when someone clicks that “Support education research by providing additional information” area, to remove the request for address (I don’t want people’s home addresses in my data!) and add other fields like “age” instead of “date of birth” (which is too invasive.)
Make a “nationality” pull down menu where I let them select from a list of countries, rather than taking freeform text input.
Any pointers to how those things can be done? There doesn’t seem like there would be anything Tutor-specific about this, which is why I’m asking about it on these forums rather than those. The OpenCraft example is kind of too complicated for me to understand unfortunately.
But for the custom registration form options, and making the Nationality a pull down form, there’s no current examples in there that can be easily edited.
I tried to make a simple gender selector form by editing the template like:
Hi @knoise
The new Gender selector field is not getting displayed because ‘gender’ is already present in the registration extra fields. It should work if you make new ‘gender’ selector field as ‘gender2’ or something like that.
And actually just now when I was doing “tutor local quickstart” I got the following error related to presumably the gender2 entry, so I had to comment it back out
Traceback (most recent call last):
File “./manage.py”, line 123, in
execute_from_command_line([sys.argv[0]] + django_args)
File “/openedx/venv/lib/python3.8/site-packages/django/core/management/init.py”, line 381, in execute_from_command_line
utility.execute()
File “/openedx/venv/lib/python3.8/site-packages/django/core/management/init.py”, line 375, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File “/openedx/venv/lib/python3.8/site-packages/django/core/management/base.py”, line 323, in run_from_argv
self.execute(*args, **cmd_options)
File “/openedx/venv/lib/python3.8/site-packages/django/core/management/base.py”, line 364, in execute
output = self.handle(*args, **options)
File “/openedx/venv/lib/python3.8/site-packages/django/core/management/base.py”, line 83, in wrapped
res = handle_func(*args, **kwargs)
File “/openedx/venv/lib/python3.8/site-packages/django/core/management/commands/migrate.py”, line 87, in handle
executor = MigrationExecutor(connection, self.migration_progress_callback)
File “/openedx/venv/lib/python3.8/site-packages/django/db/migrations/executor.py”, line 18, in init
self.loader = MigrationLoader(self.connection)
File “/openedx/venv/lib/python3.8/site-packages/django/db/migrations/loader.py”, line 49, in init
self.build_graph()
File “/openedx/venv/lib/python3.8/site-packages/django/db/migrations/loader.py”, line 206, in build_graph
self.load_disk()
File “/openedx/venv/lib/python3.8/site-packages/django/db/migrations/loader.py”, line 108, in load_disk
migration_module = import_module(migration_path)
File “/opt/pyenv/versions/3.8.6/lib/python3.8/importlib/init.py”, line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 1014, in _gcd_import
File “”, line 991, in _find_and_load
File “”, line 975, in _find_and_load_unlocked
File “”, line 671, in _load_unlocked
File “”, line 779, in exec_module
File “”, line 916, in get_code
File “”, line 846, in source_to_code
File “”, line 219, in _call_with_frames_removed
File “/openedx/requirements/custom-form-app/custom_reg_form/migrations/0001_initial.py”, line 34
operations = [
^