File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes How to enable attributes in the JQuerygrid based on the user role ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "How to enable attributes in the JQuerygrid based on the user role ?" Watch "How to enable attributes in the JQuerygrid based on the user role ?" New topic
Author

How to enable attributes in the JQuerygrid based on the user role ?

Yuva Kumar
Greenhorn

Joined: Jul 18, 2008
Posts: 12
Hi

I am doing a web application, in which my backend is a struts2 based java server and the frontend I am using JQuerygrid for populating the data from mysql database. All these are working fine. What I am searching for is, depending upon the user's role, the attributes in the <sjg:grid> should be enabled.

For eg., for an Administrator with role ADMIN, I need the user to be able to Add / Modify / Delete / View data for a master, whereas for an user with role GUEST, I need to provide only VIEW option for the master data.

ie.,


I am using struts2 v2.2, JQuery v2.5, JSON v2.2. Can someone please advise, how I can get this. Please let me know if any more information is required.

Thanks and regards

Yuva
Gopakumar Naryanan
Ranch Hand

Joined: Jan 15, 2011
Posts: 72

Does it make any sense using jstl tags like <c:choose ></c:choose> TAGS?


Thanks & Regards
Gopakumar
Yuva Kumar
Greenhorn

Joined: Jul 18, 2008
Posts: 12
Gopakumar Naryanan wrote:Does it make any sense using jstl tags like <c:choose ></c:choose> TAGS?


Thanks for your reply, but can you give me an example please.

Regards

Yuva
Gopakumar Naryanan
Ranch Hand

Joined: Jan 15, 2011
Posts: 72


I am not sure whether you are expecting something internal to grid.
 
 
subject: How to enable attributes in the JQuerygrid based on the user role ?
 
Similar Threads
migration to Struts2
Struts 2 jquery grid delete option is not working
Struts2 Grid Plugin. Using my Insert record forms.
passing values from struts2 form to javascript
struts2 with Jquery javascript issue