Welcome Guest, Not a member yet? Register   Sign In
Role Management
#11

[eluser]sYnr[/eluser]
Ok, i was extending Controller, I thought that using MX_Controller it automatically use the MX one, then if I have to extend the MX one, which is the point of naming it MX_ ?

I think i'm getting the final idea, what do you think?

Quote:+ Control if you can call a specific method depending on the role in the MX_Controller(). If not, redirect.
-The only way the user would have to get to a non linked Method would be typing the url.

Quote:+Overriding/editing/create new anchor() method that print one link or another depending on the role?
- If the user can't clic just echo the text/image/nothing/etc.
- If the user can go to a specific view print the link using the corresponding method.

Quote:Advantages:
-Easy maintenance, only two methods based.
-A lot of modules/view could be the same for several roles.

Quote:Disadvantages: would it increase too much the the anchor() method?

Quote:Ideas: make a own class like RoleManager that have to methods. LinkMgr() and MethodMgr(), those two should be invoked from anchor() method and Controller() constructor. Then we have all the logic in a single class.

Maybe you are bored of me, i'm just trying to develop a good role manager that i can use in comming projects.

Thanks




Theme © iAndrew 2016 - Forum software by © MyBB