How to use Login patch?

Overview

To make secure app, we specify the users and add login page to app for authorization.

In Appspotr it’s very easy to authorize app.

Login patch accepts 2 inputs (email & password) and return either success or error based on that validity of the inputs provided. These credentials are verified against the users added in App.

Step 1: Create LoginView.

We need one view that takes Username/email address and password from user and set it as an outputs.

Something like below. email, password and GoLogin are 3 outputs. GoLogin is event that takes control to next patch when user click on Login button.

image

Step 2: Add user(s) to App/Users

  1. Go to Appspotr/your app

  2. Go to Users

  3. Select Manage

  4. Add users of your app.

Step 3: Connect in patchwork.

  1. Go to Patchwork

  2. Add LoginView patch to Patchwork

  3. Add Login patch to Patchwork

  4. Connect LoginView’s GoLogin to Login Patch.

  5. Map outputs with Login patch as shown in blow screenshot.

  6. Specify Error & Success views/messages.

image

Login block in above patchwork will verify email address and password passed by LoginView with the list of App Users.