Kullanıcı Kılavuzu

Save User

Save User

The Save User action is an idempotent operation used to create a user in the system or update an existing user; that is, when the same user information is sent again, the system does not create duplicate records, but updates the existing record. This action securely stores the user's basic information (name, email, username, password, etc.), their relationships with assigned roles, and application-specific settings such as the main screen they will be directed to upon first login. Technically, this process usually involves creating a record in the main table named Users or updating an existing record, while relational information such as roles is managed in related tables such as UserRoles or similar; application settings can be stored in separate tables such as UserSettings or Preferences, depending on the system design. The difference from the Create User action is that, unlike Create User, which focuses only on creating a new record, Save User has both creation and update capabilities, making it a more flexible and secure option for user management in repetitive scenarios.

Technical Features

  • User Information Update: Information such as user name, first name, last name, and phone number can be updated.
  • Create New User: A user who is not previously registered in the system can be created.
  • Role Assignment: One or more roles can be assigned to a user.
  • First Screen Redirection: The first screen to be displayed after login can be dynamically defined.
  • Notification and Security Settings: Email delivery and two-factor authentication preferences can be specified.
  • Web & Mobile Compatible: The Save User action works seamlessly on both web and mobile platforms.

Steps to Add a Save User Action

  1. Log in to the Kuika platform.
  2. Open the project you will be working on from the Apps screen.
  3. Go to the UI Design module.
  4. Open the Properties panel on the right side.
  1. + ADD ACTION menu, add the Authorisation > Save User action according to the trigger event you want (Initial Actions, OnClick, OnBlur, etc.).

Parameter Definitions

Required Parameters

  • User Name (String): The user's email address. Used for authentication.
  • First Name (String): The user's first name.
  • Last Name (String): The user's last name.
  • Role Names (Array of String): The roles the user has. Example: [‘Admin’, ‘User’]
  • Starting Screen ID (String): The ID number of the screen to be redirected to upon login.
  • Phone Number (String): The user's contact number.

Optional Parameters

  • Don't Send Email (Boolean): Prevents email notifications from being sent (true does not send).
  • Two Factor Authentication Type (Enum): Two-factor authentication options such as None, Email, SMS, Authenticator App.

Usage Scenario: Defining a New User from the Administrator Panel

An administrator wants to add a new user in the system administration screen. The user's basic information is entered via a form and the ‘Admin’ role is assigned to the user. When this user logs in to the system, they should be directed to the defined ‘Control Panel’ screen.

Application Flow

  • Form Fields: txtEmail, txtFirstName, txtLastName, txtPhone, lstRoles, txtScreenId
  • Button: ‘Save’
  • OnClick
  • → Authorisation → Save User action is added.
  • Parameter Assignments:
    • User Name: txtEmail.value
    • First Name: txtFirstName.value
    • Last Name: txtLastName.value
    • Phone Number: txtPhone.value
    • Role Names: lstRoles.selectedValues
    • Starting Screen ID: txtScreenId.value
    • Don’t Send Email: true
    • Two Factor Authentication Type: ‘Email’

Save User Action Advanced Customisations

  • Dynamic Role Assignment: Different roles can be assigned based on the user's selections in the registration form. For example, if the registration type is selected as ‘Trainer,’ the ‘Trainer’ role can be assigned.
  • Role-Based Start Screen Determination: Users can be directed to different screens after logging in based on their role. For example, users with the ‘Admin’ role are directed to the control panel, while users with the ‘User’ role are directed to the home page.
  • Post-Registration Notification Display: After the user information is saved, an additional Notify action can be executed to display a notification such as ‘User successfully registered.’
  • Post-Registration Additional Action Triggering: When the Save User action is completed, another action chain can be triggered. For example, sending a verification code to the user or updating the user list data.
  • Workflow Based on Two-Factor Authentication Type: Different steps can be initiated based on the user's preferred authentication method. For example, if ‘Authenticator App’ is selected, the user can be redirected to the URI creation screen.
  • Data Validation Pre-Checks: Information such as email format and phone number length can be checked before saving. If there is an incorrect entry, the user can be warned.
  • Sending Information Emails to Administrators: When a new user is created, the system administrator can be automatically notified by email.

Technical Risks and Precautions

  • Blank Fields: Registration should not be completed without filling in all required fields.
  • Invalid Roles: An error may occur if roles that are not defined in the system are assigned in the Role Names field.
  • Insufficient Access Permissions: If the assigned roles do not have application access permissions, users may not be able to access the system.
  • Data Format Mismatches: If the email and phone number formats are not compatible, a system error may occur.
  • Email Delivery Issues: If ‘Don't Send Email’ is configured incorrectly, users may not receive notifications.

The Save User action simplifies user management and allows you to effectively configure access controls within the application. New user registrations, role assignments, and screen redirects can be integrated into a single configuration. It offers a flexible and secure user management infrastructure with customisable security and notification options.

Other Related Content

No items found.

Glossary

No items found.

Alt Başlıklar