Kuika offers flexible and secure solutions for screen and element authorization in application development processes. Providing access control over screens and elements based on user roles increases the security of your application while guaranteeing that the right users have access to the right data. With Kuika's simple and powerful authorization tools, you can assign specific roles to each user so that certain screens or elements can only be viewed or edited by authorized people.
Authorization on elements is the process of controlling a specific user's right to access specific elements. It allows users to view and edit certain fields only in line with the roles assigned to them.
1.1. Creating a Role
Before assigning authorization to elements, roles must be created. For example, let's define two different roles such as “Administrator” and “Staff”.
The roles you created are stored in the KRole table in the Datasources module. Also, SQL queries can be written using the KUserRole table to find out which role users are in.
By calling these operations in the UI Design module, you can assign user roles or perform role-based authorization operations. For example, an Administrator can also have a Staff role. You can remove a role of the Administrator with the action OnClick → Authorization → Remove User From Role.
1.2. Element Visibility by Roles
Which user role can view the elements can also be set in the Authorization field. For example, a Row element can be made visible only to users with the Administrator role. In this case, a user who is not in the Administrator role will not be able to see this Row element.
To make an element viewable only, you can disable the Hide Switch for that element. In this case, users cannot make changes to this Row, but they can view it.
1.3. Start Screen Assignment by Roles
Depending on the user's role, it is possible to show different start screens when opening the application.
If you want all roles to view the same elements, you need to activate the All Roles Access Switch. However, if you want to provide anonymous access, you need to activate the Anonymous Access Switch.
Authorizing your app on a per-screen basis improves security by ensuring that users access only the required screens. The visibility of screens can be adjusted based on the roles you create.
For example, you can make the Department page visible only to users with the Administrator role. A user in the staff role cannot view this page.
2.1. Role Based Authorization on Screens
When authorizing screens, you can use the Authorization field in the Properties panel. To make the screen visible only to a specific role, you can set the visibility of that screen by adding that role.
2.2. Authorization in Preview Mode
When you preview the application you developed, you must activate the All Roles Access Switch so that users can log in. Thus, users can view the authorized screens by entering their e-mail and password on the login screen of the application.
If you want the screens to appear without requiring login, simply enable the Anonymous Access Switch. In this case, users can view the screens without the need to log in.
Authorization for screens and elements increases the security and functionality of the application by ensuring that users only access the areas that are appropriate for their role. Creating roles correctly and defining appropriate access rights for each element or screen improves user experience and efficiency.