I need some content to be displayed inside a togglable fieldset, while its collapsed. Is it possible by now?
Related
I am developing an application in JSF. My page has been divided into 3 layouts. Menu bar will be displayed at left side and content will be shown at center of the page. I want menu bar in all pages throughout the application. Now i have achieved it using templates. But its reloading the entire page while clicking the menu items.
Is there any other option to display the content in the content area without reloading the entire page?
Thanks.
I have faced similar issues in my application. You have to use <f:ajax> within your menu item and render only the div you want refresh.
e.g.
<f:ajax render="idOfDivToRefresh" />
How can I achieve this layout in JSF (using richfaces)? I would basically like to use the rowSpan attribute of a rich:datatable, but use it for displaying components of a form (select menus, input boxes etc) instead of a collection.
I'm using the rich faces popup panel which contains the search criteria and the search results. I need to render the search results on click of he search button. I'm using <a4j:commandButton> for search button, on click of the button the results are not rendering.
<a4j:commandButton id="popupSearchButton" action="#{riskAreaSearchBean.search}"
styleClass="saveAsDraft" immediate="true" execute="areaPopupSearch"
value="#{riskLabel['customs.common.search']}" render="addAreaPopupPanel" />
"addAreaPopupPanel" is my popup panel id
If your addAreaPopupPanel is having rendered attribute set to false before onclick of your search button there is no chance of finding it in the DOM tree. Enclose it in a h:panelGroup or h:paneGrid which will always present in DOM and render that panelGroup or panelGrid.
*remove immediate=true as it will skip update modal values phase.
Hope this helps.
I have a Primefaces scrollpanel that has a datatable along with a Primefaces expandable Fieldset which is collapsed by default. My scrollpanel has fixed height. now the issue is whenever I Expand the Primefaces Fieldset,some of the Portion of Datatable that is present within the Scrollpanel gets cut off as the space is taken up by the expanded fieldset.
Can anyone tell me how can I get over this issue?
thanks in advance
I am using PrimeFaces 3.2 in my project. I wanted to know what is the difference between setting the rendered attribute of a <p:dialog> as against setting the visible attribute. When should I use either of these attributes?
The rendered attribute is server-side and the visible attribute is client-side. The rendered attribute tells whether JSF should generate the dialog's HTML representation or not. The visible attribute tells whether HTML/CSS/JS should immediately show the dialog on browser's page load or not.
If the dialog isn't rendered, then you won't be able to display it by for example JavaScript dialogWidgetVar.show() without reloading the page or ajax-updating one of the dialog's parent components that way so that the dialog's rendered condition evaluates to true. Also the visible attribute won't have any effect if the dialog is not rendered simply because there's nothing being rendered to the resulting HTML output which could be shown/hidden by JavaScript.
If the dialog is rendered, then it is by default hidden. You can set visible to true to force it to display the dialog immediately whenever the page is opened. Or you can invoke JavaScript dialogWidgetVar.show() in some onclick or oncomplete attribute to show it.
Use the rendered attribute if you don't want to render the dialog at all, for example because it wouldn't ever be used anyway in the currently requested page composition.
According to the documentation for those attributes, section 3.28:
rendered: Boolean value to specify the rendering of the component, when set to
false component will not be rendered [default value: TRUE]
visible: When enabled, dialog is visible by default [default value: FALSE]