I've searched the archives and have found very little information on the
following:

If I want to get stuff from the pageContext in my decendant to
TableDecorator. Why is it that now matter what I do getPageContext()
(from TableDecorator) always returns null?

I've even tried this (in the JSP, before the table tag):

    boolean isAdminUser = false;
    if(Helper.isUserInRole(roles, UserRole.TRADER.toString())) {
        isAdminUser = true;
    }
    pageContext.setAttribute("isAdminUser", new Boolean(isAdminUser));


TableDecorator constructor:

        super();
        PageContext pc = getPageContext();
        logger.debug("************* PC: {0}", pc);
        isAdminUser =
((Boolean)pc.getAttribute("isAdminUser")).booleanValue();

pageContext is still null in the TableDecorator.

What I need is to pass entitlements so I can block rendering to stuff
that users not in the admin group should see. Like a clickable link to
an edit page.

It feels like a major hack to have to sent this boolean (or the actual
user name for the logged in user) in the model object used for rendering
the table rows! But that is probably what I have to do for now I
guess...

Any input?

Regards
Jonas




------------------------------------------------------------------------------
This message is intended only for the personal and confidential use of the 
designated recipient(s) named above.  If you are not the intended recipient of 
this message you are hereby notified that any review, dissemination, 
distribution or copying of this message is strictly prohibited.  This 
communication is for information purposes only and should not be regarded as an 
offer to sell or as a solicitation of an offer to buy any financial product, an 
official confirmation of any transaction, or as an official statement of Lehman 
Brothers.  Email transmission cannot be guaranteed to be secure or error-free.  
Therefore, we do not represent that this information is complete or accurate 
and it should not be relied upon as such.  All information is subject to change 
without notice.
This message is intended only for the personal and confidential use of the 
designated recipient(s) named above. If you are not the intended recipient of 
this message you are hereby notified that any review, dissemination, 
distribution or copying of this message is strictly prohibited. This 
communication is for information purposes only and should not be regarded as an 
offer to sell or as a solicitation of an offer to buy any financial product, an 
official confirmation of any transaction, or as an official statement of Lehman 
Brothers. Email transmission cannot be guaranteed to be secure or error-free. 
Therefore, we do not represent that this information is complete or accurate 
and it should not be relied upon as such. All information is subject to change 
without notice.

--------
IRS Circular 230 Disclosure:
Please be advised that any discussion of U.S. tax matters contained within this 
communication (including any attachments) is not intended or written to be used 
and cannot be used for the purpose of (i) avoiding U.S. tax related penalties 
or (ii) promoting, marketing or recommending to another party any transaction 
or matter addressed herein.






-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
displaytag-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/displaytag-user

Reply via email to