myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Panzhin <jalex...@balticum-tv.lt>
Subject Re: Mixing JSTL and JSF(MyFaces)
Date Wed, 01 Mar 2006 22:37:51 GMT
Mike Kienenberger wrote:
> To do it in pure JSF:
>
> <h:commandLink action="#{ticketAccess.deleteTicket}"
> rendered="#{yourBean.adminUser}" .....
>
> Note that yourBean must be preserved across requests, so if yourBean
> is request-scoped, you'd need to use t:saveState on it or on its
> "isAdminUser()" value.
>
> On 3/1/06, Alexander Panzhin <jalexoid@balticum-tv.lt> wrote:
>   
>> Oh yeah.
>>  Here is the JSP code that puts it all together.
>>
>> <h:commandLink action="#{ticketAccess.deleteTicket}"
>> onclick="if(!confirm('?')){ return;}">
>>         <jmrp:preParam binding="#{ticketAccess.ticketIdParameter}"
>> name="ticketId" value="#{item.id}"/>
>>         <h:outputText value="X"/>
>> </h:commandLink>
>>
>> --
>>    Su pagarba,
>>       Aleksandr Panzin
>>       IT sistemu architektas.
>>
>>    With best regards,
>>       Alexander Panzhin
>>       IT systems architect
>>
>>
>>
>>
>>     
>
>   
Thank you.
I did think that my way is a hack.
But who knows maybe someone will need a f:param that will resolve the 
value in advance.
But the thing is now I need to output a text that says that you are not 
admin instad of my "button".
Any ideas how to do that? This approach will not work.

-- 
   Su pagarba,
      Aleksandr Panzin
      IT sistemu architektas.

   With best regards,
      Alexander Panzhin
      IT systems architect 


Mime
View raw message