Yii Framework Forum: Complete User Management Module - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Complete User Management Module Users, role, premissions Rate Topic: -----

#1 User is online   Vimark 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 9
  • Joined: 13-October 13

Posted 07 December 2013 - 05:25 AM

UserAdmin module

Complete module for managing users, they premissions, tasks and roles

http://www.yiiframew...sion/useradmin/

Basic features:

  • Manage users. Can create, update, assign roles and allowed tasks
  • Manage roles. Can assign allowed tasks to role, can set home page for role (for redirect after login or registration)
  • Manage tasks (allowed routes).
  • Built-in login and registration system
  • Caching

0

#2 User is offline   Sserge 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 3
  • Joined: 02-October 12

Posted 24 December 2013 - 08:35 PM

Thanks, man! That's a thing which replaced yiiuser+Rights for me.
I don't think you need to add a profile like one in yii-user(just take a look if you haven't yet) - it's monstrous, like it should be if you want your product to fit all sizes^Wusers. One can add a profile according to his style.
But a thing I need - check if user can access specific page(e.g. in menu creating to show only links he can access), and you have this code as a private method in controller class.
Wouldn't it be better to put some method UWebUser::accessRoutes() which return all allowed routes and a UWebUser::canAccess($route), which can be used in UAccessController::_isRouteAllowed() to check if specific route is accessible? It's just about code architecture.
And yes, I can modify classes for my very own requests but someone else will need this someday perhaps.

p.s.: nice code style, easy-to-read-and-understand, thanks again.
0

#3 User is offline   Sserge 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 3
  • Joined: 02-October 12

Posted 24 December 2013 - 09:06 PM

This is just an example of how do I use it:
Attached File  UWebUser.php (7.78K)
Number of downloads: 19
Attached File  UAccessController.php (1.76K)
Number of downloads: 9
These both are your code, I've just moved methods metioned in a prev post .
0

#4 User is offline   Andrey G. 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 64
  • Joined: 25-August 09
  • Location:Russia

Posted 25 December 2013 - 10:14 AM

I have only ONE question?! Is there any real reason of re-inventing wheel?! Yii already has RBAC, and at first sight yii's version is much more flexible. I just puzzled...why you did it?!

It has just no any advantage. All that you need - add GUI for built-in RBAC or get extension that is doing it for you.

Replacing built-in RBAC with something that looks same and more hardcoded is very bad idea, for any real project. As for learning purposes and hobby - fine.
Just Do It!
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users