richfaces

Disable button and show loading image while processing JSF

北城以北 提交于 2019-12-05 07:57:55
问题 I have this module in my webapp where i need to update come catalogs. The idea is to disable the h:commandButton and show a h:graphicImage , both actions are supposed to happen right after the button was clicked. Finally, when the update process has ended it should do the other way, hide the h:graphicImage , enable the h:commandButton but this time also show a label h:outputText that says either 'Update Success' or 'Update Failure'. The problem in my code is that the image and the label

RichFaces 3.3.3 with JSF 2.0 working example

蹲街弑〆低调 提交于 2019-12-05 06:25:29
I'm very new to JSF and i'm looking for a pure configuration of JSF 2.0 with RichFaces 3.3.3.Final. The documentation on JBoss website is for JSF 1.2. I also find this jboss article but the sample application has a lot of configurations. If you have successfully made RichFaces and JSF 2 work, please share you config. Thank you. mohamida You have to add the latest facelets , richfaces 3.3.3 and jsf 2.x libraries. this is my web.xml config i'm using for my project: <?xml version="1.0" encoding="UTF-8"?> <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org

Is that possible to combine Primefaces and Richfaces in one web application?

喜你入骨 提交于 2019-12-05 05:46:48
After reading RichFaces Vs PrimeFaces (for performance) , I was tempted to use both in my web application to get the maximum benefit from both. Do you think that is possible? What are the advantages and disadvantages? Both are great component libraries. You can definitely combine them. But it is not true that it's 1+1=2 here. It's more 1*1=1. You should really investigate the both component libraries more closely. What exactly do you need from RichFaces which PrimeFaces doesn't offer? What exactly do you need from PrimeFaces which RichFaces doesn't offer? You need to find the right balance

Using a commandButton in a jsf Page to download a file

浪子不回头ぞ 提交于 2019-12-05 03:50:46
Using a commandButton in a jsf Page to download a file. Using: JSF & Richfaces. I have a table (extends ExtendedDataModel implements Modifiable, Serializable) with some data and in each row a button "download". <a4j:commandButton id="getDownload" value="download" style="margin-left:10px;margin-right:10px;width:100px;" action="#{controller.download}" immediate="true" ajaxSingle="true"> <f:setPropertyActionListener target="#{controller.idString}" value="#{item.id}" /> </a4j:commandButton> I have to build the file in the controller: public void download(){ OutputStream out = null; ....

Rich TabPanel's getters invoked when tab content not rendered

此生再无相见时 提交于 2019-12-05 02:45:12
问题 I have a question about RichFace's (3.3.3) TabPanel. I have worked on two projects that have used the TabPanel. On each project, I have noticed that components that are on tabs that are not visible still have their "getter" methods called. For example, the first tab has a datatable on in and any time requests are made from any of the other tabs (including ajax requests) the bean that is bound to the datatable on the first tab still has its getter called. I assume this happens (even though the

RichFaces ExtendedTableDataModel: sorting columns retrieves all rows

耗尽温柔 提交于 2019-12-05 01:49:22
问题 We use the ExtendedTableDataModel for paging. This is done to retrieve a set of results with Hibernate and load the next set when another page is requested. All works fine, but if we sort columns by using rich:column sortBy within the rich:dataTable then RichFaces tries to load all rows. We can see this while debugging the getItemsByRange which we made for our custom DataProvider. After clicking sort once, RichFaces will continue to retrieve all rows from the database. This is of course not

Richfaces 4 a4j:commandLink action not firing in rich:popupPanel

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-05 00:24:10
问题 I seem to be having a problem where I have an a4j:commandLink on a rich:popupPanel but the action is not firing. The xhtml looks as follows: <rich:popupPanel id="rate-panel" modal="true" height="444" width="780" top="60" show="false" onmaskclick="#{rich:component('rate-panel')}.hide()" styleClass="cs-modal"> /**Some html here**/ <a4j:commandLink immediate="false" action="#{venueScore.up}" render="rate-panel" styleClass="rate love"> <span>Love it</span> </a4j:commandLink> /**Some more html

What is the a4j event sequence?

爷,独闯天下 提交于 2019-12-04 21:09:23
What is the event sequence of a a4j:commandLink or a4j:commandButton ? Is it right: onclick -> actionListner -> oncomplete -> reRender ? Is reRender comes before oncomplete ? When action happens? The onclick JavaScript is called the first when the enduser clicks the generated HTML element. When the JavaScript code does not return false , then all associated ActionListener implementations in the JSF side will be invoked, in the order of their association with the component. If the listeners haven't thrown any exception, then the real action will be invoked. When the action returns a successful

Possible to have an ApplicationScoped bean that skins a JSF 2 application with a richfaces skin?

风格不统一 提交于 2019-12-04 19:51:33
In production want the user to be able to write a properties file and upload that file to our production server. Once this is in place it will contain the properties needed for a richfaces skin. This file can be named whatever. In development I want the properties file to be read from inside WEB-INF/myprop.properties where all my other properties files are. This file can be named whatever. So far I have done this: @ManagedBean(name="myCustomSkin ") @ApplicationScoped public class MyCustomSkin extends SkinFactoryImpl { /* * In here I call * Skin s = this.buildSkin(context, "skin"); in my

rich:datatable rowspan issue

左心房为你撑大大i 提交于 2019-12-04 19:18:00
问题 I need to create a rich:dataTable (or even extended) with the following features: I have a class Company having a collection of Product objects. I want to show the following table: I still have not figured out how to do this with a subtable (in all the examples I found the subTable has the exact same columns as the master table). Presumably, I need to play with rowspans in the first two columns, but I still have not found the way. Could someone provide a pseudo-code for this? Cheers! UPDATE 1