A: Rights management system
- System Design
Idea: When the user clicks the hyperlink is to use the filter to intercept this request, check if there is no access permission, if there is the release, the contrary does not release
Difficulties: the management of permission data objects, the design of database tables and the relationship between tables
Database design:
Permission table (privilege): a permission corresponding to multiple resources, is a one-to-many relationship, in order to not lose the relationship, it is generally necessary to define a foreign key column in a multi-party
Resource table (Resource): Add categories, delete categories, modify categories, find categories
Role list: Can be understood as real-life identities, administrators, managers, etc.
User table: Can be understood as a person in real life
*用户角色表(user_role):用户和角色是多对多的关系,所以需要加一张用户角色表*角色权限表(role_privilege):权限和角色是多对多的关系,所以需要加一张角色权限表
- Table structure
Database construction of Rights management system