Skip to content

[Ficus] sync custom forms fields on SSO registration - #142

Merged
melvinsoft merged 1 commit into
appsembler/ficus/developfrom
maxi/ficus-sso-sync-custom-form-fields
Jul 28, 2017
Merged

[Ficus] sync custom forms fields on SSO registration#142
melvinsoft merged 1 commit into
appsembler/ficus/developfrom
maxi/ficus-sso-sync-custom-form-fields

Conversation

@melvinsoft

@melvinsoft melvinsoft commented Jul 27, 2017

Copy link
Copy Markdown

This solution was designed for Trinity initially, but I could be useful for any customer using registration fields.

The problem:
When we are using SSO, in most of the cases, customers wants to use auto-registration, this means when a user clicks on sign in or register, is redirected to the Identity Provider (OAuth or SAML), after the user successfully logs in, is redirected back to edX with the auth request, and the user attributes. By default edX automatically populate only default registration fields. So when we are using Extra registration fields, there is no way to sync those attributes. Besides the problem of not have this fields in our database, if some of the extra fields are required, the auto-registration workflow will break.

The solution:
This PR adds a new settings: CUSTOM_SSO_FIELDS_SYNC by default in False, but is expected to be a dictionary, when we can list all the extra registration form fields that we want to map. The code changes are pretty small, basically they check if this dict isn't false, and maps the attributes using the same default logic.

@melvinsoft melvinsoft changed the title sync custom forms fields on SSO registration [Ficus] sync custom forms fields on SSO registration Jul 27, 2017
@melvinsoft

Copy link
Copy Markdown
Author

@tkeemon tkeemon left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@melvinsoft
melvinsoft merged commit 28db06e into appsembler/ficus/develop Jul 28, 2017
@melvinsoft
melvinsoft deleted the maxi/ficus-sso-sync-custom-form-fields branch July 28, 2017 20:55

@bryanlandia bryanlandia left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey Maxi, I know you already merged this, but this might be a good one to push upstream if some tests are added and you move the changes from envs/*_appsembler.py to envs/*.py

@melvinsoft

Copy link
Copy Markdown
Author

@bryanlandia Good idea, I'm going to create a card on the inbox to address this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants