# Agenda

- Configure Mailhost

This tutorial teaches how to configure wendelin to allow user registration.

Note: This feature is enabled only if wendelin configuration the Setup default data lake security model was checked.

# Configure Mailhost

Open https://YOUR_INSTANCE_URL/erp5/MailHost/manage_main to access the mail host configuration in the Zope interface (Wendelin is built on top of Zope).

Add a SMTP mailhost and login/password for the alias under which an email should be forwarded/sent.

Make sure the Port is also correctly set to your email provider's correct SMTP port.

Click Save Changes when done to continue.

# Register

Once the mailhost is configured users can register.

Open https://YOUR_INSTANCE_URL/erp5/web_site_module/default_wendelin_data_lake/ and on left side panel click on Register.

Note: Pay attention on / (slash) at the end of the url, it is mandatory.

Note: Registration works only if user is not logged in. Thus, before registering a new user make sure that you are not logged in with any user.

After filling the form and clicking on Register you will get an email to the specified email address with further instructions.

<test>

openAndWait | ${base_url}/logout |
openAndWait | ${base_url}/erp5/web_site_module/default_wendelin_data_lake/#/?page=register |
waitForElementPresent | //input[@name="your_first_name"] |
type | //input[@name="your_first_name"] | TestFirstName
type | //input[@name="your_last_name"] | TestLastName
type | //input[@name="your_email"] | test@example.com
type | //input[@name="your_reference"] | TestReference
type | //input[@name="your_password"] | TestPassword
type | //input[@name="your_confirm_password"] | TestPassword
click | //input[@type="submit" and @value="Register"] |
pause | 10000 |
assertTextPresent | Registration submitted. |
openAndWait | ${base_url}/login_form |
type | //input[@name="__ac_name"] | functional_test_username
type | //input[@name="__ac_password"] | secret
clickAndWait | //input[@name="logged_in:method"] |
openAndWait | ${base_url}/erp5/view |
pause | 20000 |
openAndWait | ${base_url}/erp5/portal_activities/ |
click | //table//tbody//tr[1]//td[2]//a |
pause | 2000 |
openAndWait | ${base_url}/erp5/event_module/ |
click | //th[@class="listbox-table-header-cell"][4]//button[@type="submit" and @title="Ascending Display"] |
click | //td[@class="listbox-table-data-cell"]//a[contains(@href,'/event_module/')] |
pause | 10000 |
store | javascript{ link = String(selenium.browserbot.getCurrentWindow().document.getElementsByTagName("pre")[0].innerText).match("(>https.*<)")[0]; link.substring(1, link.length-1); } | welcomelink
openAndWait | ${welcomelink} |
assertTextPresent | activated |
pause | 40000 |
openAndWait | ${base_url}/erp5/portal_activities/ |
click | //table//tbody//tr[1]//td[2]//a |
pause | 2000 |
openAndWait | ${base_url}/logout |
openAndWait | ${base_url}/login_form |
type | //input[@name="__ac_name"] | TestReference
type | //input[@name="__ac_password"] | TestPassword
clickAndWait | //input[@name="logged_in:method"] |
pause | 3000 |
openAndWait | ${base_url}/erp5/view |
assertTextPresent | TestReference |

</test>