Uploaded image for project: 'Moodle app'
  1. Moodle app
  2. MOBILE-1598

Enable users to sign up or register an account in the app

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.2
    • 3.1.3
    • Log in screen
    • Hide
      1. Run bower update in the console to update angular-translate and install angular-messages

      Configuring the site

      1. Login in Moodle web as admin.
      2. Go to Site administration > Users > Accounts > User profile fields and create at least one field of each type. Mark them all to display on signup page. Mark some of them as required. You can add default values if you want.
      3. Configure a sitepolicy and passwordpolicy in the site (Site administration > Security > Site policies).
      4. Configure a defaultcity and country (Site administration > Location > Location settings).
      5. Go to Site administration > Plugins > Authentication > Manage authentication and enable email-based self-registration.
      6. In registerauth drop-down, select email-based self-registration. You can also add some auth_instructions. Don't configure the captcha yet, we'll do that later.

      Testing in the app

      1. Install the app in a real device, click to add site, enter the siteurl and click Connect. In the credentials screen, check that you can see a "Create account" button at the bottom of the page. Also, if you supplied some auth_instructions you should be able to see them above the button.
      2. Click the "Create account" button. If you supplied some auth_instructions, check that you see a top right icon and clicking it opens a modal with the instructions.
      3. Check that all the profile fields created in point 2 of configuration are rendered and the required ones are marked with a red asterisk. Check that default values are loaded for the fields that have one.
      4. Check that you can see the site policy and no captcha is shown (since it wasn't configured yet).
      5. Check that clicking "Create my new account" with invalid data displays errors:
        • Leave empty required fields.
        • Don't mark a required checkbox.
        • Invalid email address.
        • Emails do not match.
      6. Now enter valid data (please make sure you have access to the mail) and submit the data. Check that you see a success message and you're back to credentials page.
      7. Now open the mail in the same device and click the confirm link. You will be asked to accept the site policy again. Once you do it, the app should open and you should be authenticated automatically with the new account.
      8. If the site had local_mobile enabled, disable the plugin and test again the sign-up removing first the site from the app.

      Recaptcha

      1. Now get a recaptcha public and private key here: https://www.google.com/recaptcha/intro/index.html (please, enter localhost as a valid domain if you are testing locally)
      2. In Moodle web as admin, go to Site administration > Plugins > Authentication > Manage authentication and enter captcha keys.
      3. Now click "Settings" next to "Email-based self-registration" and set "Enable reCAPTCHA element" to Yes.
      4. Back in the app, go to create a new account and check that you can see the captcha.
      5. Check that you can click the "Get another CAPTCHA" button to refresh the image.
      6. Check that leaving the captcha empty or submitting an invalid one shows an error.
      7. Submit the form with a valid captcha and check that the account is created.
      Show
      Run bower update in the console to update angular-translate and install angular-messages Configuring the site Login in Moodle web as admin. Go to Site administration > Users > Accounts > User profile fields and create at least one field of each type. Mark them all to display on signup page. Mark some of them as required. You can add default values if you want. Configure a sitepolicy and passwordpolicy in the site (Site administration > Security > Site policies). Configure a defaultcity and country (Site administration > Location > Location settings). Go to Site administration > Plugins > Authentication > Manage authentication and enable email-based self-registration. In registerauth drop-down, select email-based self-registration . You can also add some auth_instructions . Don't configure the captcha yet, we'll do that later. Testing in the app Install the app in a real device, click to add site, enter the siteurl and click Connect . In the credentials screen, check that you can see a "Create account" button at the bottom of the page. Also, if you supplied some auth_instructions you should be able to see them above the button. Click the "Create account" button. If you supplied some auth_instructions, check that you see a top right icon and clicking it opens a modal with the instructions. Check that all the profile fields created in point 2 of configuration are rendered and the required ones are marked with a red asterisk. Check that default values are loaded for the fields that have one. Check that you can see the site policy and no captcha is shown (since it wasn't configured yet). Check that clicking "Create my new account" with invalid data displays errors: Leave empty required fields. Don't mark a required checkbox. Invalid email address. Emails do not match. Now enter valid data (please make sure you have access to the mail) and submit the data. Check that you see a success message and you're back to credentials page. Now open the mail in the same device and click the confirm link. You will be asked to accept the site policy again. Once you do it, the app should open and you should be authenticated automatically with the new account. If the site had local_mobile enabled, disable the plugin and test again the sign-up removing first the site from the app. Recaptcha Now get a recaptcha public and private key here: https://www.google.com/recaptcha/intro/index.html (please, enter localhost as a valid domain if you are testing locally) In Moodle web as admin, go to Site administration > Plugins > Authentication > Manage authentication and enter captcha keys. Now click "Settings" next to " Email-based self-registration " and set " Enable reCAPTCHA element " to Yes. Back in the app, go to create a new account and check that you can see the captcha. Check that you can click the "Get another CAPTCHA" button to refresh the image. Check that leaving the captcha empty or submitting an invalid one shows an error. Submit the form with a valid captcha and check that the account is created.
    • MOODLE_31_STABLE
    • MOODLE_32_STABLE
    • Moodle Mobile 3.2

      Below is message that we received from Apple while trying to get it approved.

      We noticed that the user needs to go to Safari to register for an account, which provides a poor user experience.

      Next Steps

      Please revise your app to enable users to register an account in the app.

      We recommend implementing the Safari View Controller API to display web content within your app. The Safari View Controller allows the display of a URL and inspection of the certificate from an embedded browser in an app so that customers can verify the webpage URL and SSL certificate to confirm they are entering their sign in credentials into a legitimate page.

      Resources

      For additional information on the Safari View Controller API, please see the webpage, What’s New in Safari.

            dpalou Dani Palou
            modguru Jai Gupta
            Pau Ferrer Pau Ferrer
            Juan Leyva Juan Leyva
            Pau Ferrer Pau Ferrer
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 1 week, 2 hours, 30 minutes
                1w 2h 30m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 4 days, 4 hours Time Not Required
                4d 4h

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.