Related to role and permission control data tables, role permission Control Data

Source: Internet
Author: User

Related to role and permission control data tables, role permission Control Data

This project requires the role to be divided into regions. Each role corresponds to one or more third-level cities. You can only view the business opportunities in the region when logging on to the background.

First, create an account table. The fields include account id, role id, Logon account, logon password, account name, status, number of Logon errors, and account user information.

Next, the role table: Role id, parent role id, role name, role level, status, remarks, and others. Associate regions and permissions

Then, the role area table is: Region id, role id, first-level city code (provincial), second-level city code (municipal), third-level city code, first-level city name, second-level city name, and third-level city name. The region managed by the role is saved.

The following table lists the permissions of a role: Permission id, role id, permission id, permission status, and others. Save the permissions of the corresponding role.

Finally, permission table: Permission id, parent permission id, permission name, corresponding permission value (unique permission value), permission type, and permission status. The permission table stores all menu items. When you click the menu, verify that the current logon administrator has this permission.

Of course, the database has a table to store all provinces, cities, counties, and streets in China.

Process: you must add a role before saving all menu items to the permission table to add an account --> and select a region and assign permissions when adding a role.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.