I have a bean which contains an int variable.
I want to do something like this:
if(value==1)
<div class='abc'/>
else if(value==2)
<div class='mno'/>
else
<div class='xyz'/>
....
How do we do this in Primefaces since doesn’t work with datatable?
Could someone please tell me how to achieve this in any way?
Where your getStyle() method in Bean class, returns the desired value. In JSF, do not put logic on xhtml, code it in backing bean and bind it to the ui.