Thank you for helping on this! I am designing an app with documents and posts sharing with Laravel. I tried to do it myself since two weeks but I am not sure what the best is. I've tried implementing many packages and used crud generators, but as a Laravel beginner it's difficult to find the good package and to mix them. What I want is a system like google docs sharing behaviour but for posts. You could write a post and set it as
So what is the best way to build that?
If anyone can direct me to a good tutorial or give me a good start structure for this tables to be efficient and secure.
Maybe I do not see all the complexity of this so I will enjoy any suggestions The problem for this is I want a more flexible rights management than wordpress one that provides user rights levels, the availability of data will be managed by simple subscribers for a lot of things(files, posts, maybe comments, groups and maybe more stuff).
You just need to create three tables roles
,permissions
and roles_permission
.The roles of the user goes in the table roles
table.the permission of a user are stored in the table permission
.You can map the roles and permission of a particular user in the roles_permission
table.However,for more flexible way to add role-based-permission use entrust package.In which,you can dynamically add/update/delete the roles and permissions in laravel.