Skip to content

Commit

Permalink
contactEmail -> email
Browse files Browse the repository at this point in the history
  • Loading branch information
birm authored Oct 18, 2023
1 parent 72a66ff commit 9fb63ce
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions apps/registration/registration.js
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ $('#basic').alpaca({
'title': 'Last Name',
'required': true,
},
'contactEmail': {
'email': {
'type': 'string',
'title': 'Contact Email',
'format': 'email',
Expand Down Expand Up @@ -305,9 +305,9 @@ async function saveRegistration() {
Object.assign(registrationForm, basic, professional, certifications);
let userRegInfo = {}

userRegInfo.email = registrationForm.contactEmail;
userRegInfo.email = registrationForm.email;
userRegInfo.userType = "[]"
userRegInfo.creator = userRegInfo.contactEmail;
userRegInfo.creator = userRegInfo.email;
userRegInfo.registration = registrationForm;
userRegInfo.isAgreed = isConsent.checked;
let now_time = new Date;
Expand All @@ -319,14 +319,14 @@ async function saveRegistration() {
let kcUserInfo = {
"firstName": registrationForm.firstName,
"lastName": registrationForm.lastName,
"email": registrationForm.contactEmail,
"username": registrationForm.contactEmail,
"email": registrationForm.email,
"username": registrationForm.email,
"enabled": "true",
}
let kcRes = await addKcUser(kcUserInfo);
if (kcRes.username){
console.log("successful user add")
await requestResetPassword(registrationForm.contactEmail)
await requestResetPassword(registrationForm.email)
window.location = "./registration_success.html";
} else {
message.addError('Failed to add user to keycloak', 10000);
Expand Down

0 comments on commit 9fb63ce

Please sign in to comment.