richfaces

Including resources outside context root with JSF2

最后都变了- 提交于 2019-12-24 02:43:22
问题 I'm currently upgrading an application from JSF 1.2 and Richfaces 3.3 to JSF 2 and Richfaces 4. I'm having issues getting my application to include stylesheets using JSF2's new h:outputStylesheet component Here is my old code: <a4j:loadStyle src="resource:///com/testing/test/html/css/style.xcss" /> And here is what I have for my new code (Not working): <h:outputStylesheet library="resource:///com/testing/test/html/css/" name="style.xcss" /> I've tried various variations but none have worked.

How concerned should we be about thread safety with JSF managed beans?

浪尽此生 提交于 2019-12-24 02:14:29
问题 I'm working on a JSF 1.2 project which has AJAX functionality on it's pages (using RichFaces). My bean builds a list of objects to be edited and then has methods to support the editing and the bean is session-scoped. I will be using a a4j:queue so that only one AJAX call can happen at a time. I'm curious if it is wise to use synchronization (locks on objects, or perhaps collections from java.util.concurrent) in the managed bean. Is the extra work needed to implement synchronization/thread

Stop JSF Event Chain

折月煮酒 提交于 2019-12-24 02:10:00
问题 I'm working on modifying a jsf-1.2 application for use on a tablet pc. For that purpose I have made the rows of a table clickable to open the detail view of the rows contents, rather than have the user click on a link in that table (which is the case in the Desktop Version). It works fine so far. Each row can, however, contain two rich-buttons that open a different link. The contents of that link is opened in a new tab, like it's supposed to. My problem is, that the action event of the

How do I know which version of RichFaces I am running?

廉价感情. 提交于 2019-12-24 01:17:12
问题 Can you tell me how to find out which version of Richfaces I am running? I need to know if I have jQuery already installed so perhaps a way to test that would help as an answer as well. I am using Version: 2.1.0.GA of JBOSS Developer Studio.. if that helps. 回答1: This should help: http://mkblog.exadel.com/2010/03/getting-richfaces-version-in-runtime/ 回答2: In JBoss developer studio (which is based on Eclipse), right-click your project and choose Build Path > Configure Build Path There you have

Using a4j:repeat or ui:repeat inside rich:dataTable doesn't render radio buttons properly

与世无争的帅哥 提交于 2019-12-24 00:30:06
问题 While using <c:forEach> the items values is not substituted properly. If i use <a4j:repeat> or <ui:repeat> instead of <c:forEach> inside a <rich:dataTable >, radio button is not rendering properly. I also found reason for this in http://community.jboss.org/wiki/Cantusea4jrepeattoiteratethemenuItemstabsetc How do I resolve this issue? <f:selectItems> is working inside but i want to send a choice type to server <rich:dataTable var="answer" value="#{answers}"> <rich:column> <f:selectOneRadio

JSF View- returning null on actions do not update the view

怎甘沉沦 提交于 2019-12-23 22:17:06
问题 i have read the post that have same problem as mine JSF ViewScope - returning null on actions do not update the view but it haven't worked for me cause i already use the h:commandLink in another page and its works perfectly but in this page it doesn't . this is the request Bean public class AddSectionBean { public String delete(String id) { try { HttpSession session = SessionUtil.getSession(); UserVO userVOCreater = (UserVO) session.getAttribute("userVO"); SectionsDao.getInstance()

Binding events based on ID with JSF and jQuery

走远了吗. 提交于 2019-12-23 20:47:04
问题 I'm having an issue with JQuery and JSF/Richfaces. I have an inputText component inside a form component. <h:form id="myForm"> <h:inputText id="myInputField" value="#{myBean.sampleName}" /> I have the following jQuery code: MySite.supplier= function() { // Only attach event listener if the element exists on page if ( jQuery('#myInputField') ) { jQuery('#myInputField').bind('paste', MySite.common.handleMousePaste.bind(this)); } }; MySite.common.handleMousePaste = function(event) { // Need to

Skip validation on re-render and apply only on form submit

荒凉一梦 提交于 2019-12-23 19:28:23
问题 I have an input field where user enters some product name. Depending on an entered name particular details of this product should be shown. On input change I'm getting the product from data source by the current field value and re-render product details using AJAX . So far user can not see product details until he enters correct name. Here is the code sample: <h:form> <h:inputText id="product" value="#{myBean.product}" required="true" converter="productConverter"> <a4j:ajax event="change"

JSF2 Richfaces 4.1.0 Ajax partial rendering of tree

北战南征 提交于 2019-12-23 18:44:49
问题 I have a big tree structure (almost 6000 nodes and growing) that I display in my webapp as a Richfaces rich:tree. When a node is selected a handler-function in the backing-bean runs some logic and works some magic. One thing that happens is that the tree is re-rendered with an Ajax-call on every selection in the tree. This means that over 2MB is POSTed to the server every time the selection changes. As you might guess my problem here is that this is very slow. What I would like to do is only

Request-scoped beans and datamodel initialization?

六眼飞鱼酱① 提交于 2019-12-23 12:35:59
问题 UPDATE II: OK, I managed to narrow it down a little. I have a page with a datatable with sorting and filtering functionalities, both taking place in the DB. In other words, I do not use the embedded functionality of the rich:datatable I use, but rather let the DB do the work. I work with request-scoped beans. The only session-scoped beans contain the sorting and filtering of my interface. Filtering for each column is bound to the certain session bean fields. As such, it is actually updated