User Management In Play

205 views
Skip to first unread message

Rushen Aly

unread,
Oct 13, 2010, 7:00:52 AM10/13/10
to play-framework
Hi everybody,

Actually this is not a question regarding Play Framework totally. I am
a very rookie web developer and i am building applications in my spare
time. I am working at a totally different job. I am having fun with
web development.

My question is about user management in an application especially in
ones developed with play framework. In my project, the application can
be used by everybody without any signing in process but to manage
content i have three different user types.

1. Content Supplier : Supplies content.
2. Editor : Checks content and approve or reject it if approve then
content is published.
3. Admin : Superman, controls every function and permissions.

How can i model this application? By using different controllers and
different templates for every user type. That means repating many
things. Or is there any more compact way of this? Can you give me
examples and suggest me some references to learn something about this
process.

Thank you...
Rushen

Julien Tournay

unread,
Oct 13, 2010, 8:03:16 AM10/13/10
to play-fr...@googlegroups.com
If you have permissions, you need to "know" who is using the app, so you need some sort of signin process.

jto.


--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To post to this group, send email to play-fr...@googlegroups.com.
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.




--
Real Programmers don't need comments-- the code is obvious.

Rushen Aly

unread,
Oct 13, 2010, 9:51:40 AM10/13/10
to play-framework
I think i couldn't express my intention properly. There will be a
signing in process for these user types but i can not make my mind
clear about modeling signing in process and the processes after it.
> > play-framewor...@googlegroups.com<play-framework%2Bunsubscribe@go­oglegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/play-framework?hl=en.
>
> --
> Real Programmers don't need comments-- the code is obvious.- Alıntıyı gizle -
>
> - Alıntıyı göster -

Julien Tournay

unread,
Oct 13, 2010, 10:07:37 AM10/13/10
to play-fr...@googlegroups.com
Ok, I get it now :)

Typically, you'll have a "User" object, with a role field (possible values are admin, editor, etc.)
On each action, you'll check if this user can call this action by ckecking his role(s) (with a @Before for example). Have a look at samples play's folder, I think you'll find what you're looking for (or at least, find hints).

jto.

2010/10/13 Rushen Aly <rush...@gmail.com>
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.

For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.

green

unread,
Oct 13, 2010, 6:00:22 PM10/13/10
to play-fr...@googlegroups.com
You might want to take a look at http://www.playframework.org/documentation/1.1RC1/guide8

2010/10/14 Rushen Aly <rush...@gmail.com>
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages