seam

Seam - ListSelectMenus with dependencies

Hi there, I'm trying to build some select boxes with dependencies on other select boxes. I'm fairly new to Seam - just to add this. Here is my JSF - for test purposes I'm trying to display a dataTable <f:facet name="header">Profil</f:facet> <a:form ajaxSubmit="true" reRender="testTable"> <s:decorate id="techTypeField" template="la...

How can I force a reload of an entity?

I'm using a ajax4jsf poller <a4j:poll> to check whether an entity has been updated in the database by another process. I want to reload the entity each time. How can I force a reload? Calling loadInstance() seems to have has no effect. (Polling works as expected) @Name("myComponentHome") public class MyComponentHome extends EntityHom...

Home page to be rendered according to user type.

I use the following code to redirect to my home page on login... now i want to go a step further and add a logic where it redirects to different page based on user type. for eg: if a user type is employee then i should redirect to employeehome.xhtml and so on ... is this possible ? <page xmlns="http://jboss.com/products/seam/pages" ...

Seam 3 modules - getting started

Hi all, I need help getting setup on Seam 3 modules. When I try to use the Seam 3 module, persistence, the JBoss Java EE 6 spec cannot be found. I was reading that I need to use maven 3 or declare the repository where that artifact can be found. I am using maven 3, but still no go. Walter ...

How to build a SOAP Web service Client in SEAM

Hi everyone! I've been looking all over for this question... How do I build a soap web service client in SEAM?? it seems like a straightforward question-answer but I cant seem to make it work no matter how I try... If anyone has an example of what should be done I'd really apreciate it because I need to consume a web service from a legac...

seam test fails when running with @Depends

I have a MDB marked with @Depends making it dependent on my war, when I deploy the application to the server it works ok, but when I try to run my tests the test fails...seams because of some wrong config...any hints to solve this? I guess that the embeded jboss handels this in some diferent way? I use: seam 2.2.1 jboss 5.1 testNG the ...

h:inputText data cached

Click "LINK1" --> modal popsup --> enter value in text-box --> click Submit/Process Click another link "update/cancel" --> same modal popsup --> I see the value in the text box (This is fine and if I reload the page and click the link again, the modal appears with values intact) Click "LINK1" --> same modal popsup --> I see the value ...

How to create dynamic JSF 1.2 form fields

Hi. We are using JSF 1.2 and Seam 2.2. I have found some similar questions like this one, however there are so many ways this can be done that it made me more confused. We are getting a XML file that we are reading. This XML contains information on some form fields that needs to be presented. So I created this custom DynamicField.ja...

Hibernate/JPA: Mapping entities to different databases

Hi guys, I have an application which manages 3 databases. I use hibernate with JPA on seam framework. So I have a persitence.xml file with three persitence-unit like this (I remove properties for db2 and db3): <persistence-unit name="db1" transaction-type="JTA" > <provider>org.hibernate.ejb.HibernatePersistence</provider> <jta...

How to create a Seam project for Intellij IDEA?

Can somebody tell me how can I create an Seam project for Intellij IDEA? I tried with Maven, but I do not have any success running it after and the plugin for Seam project in IDEA is rather old. Thanks ...

JSF, jQuery Plugin and fancy forms

Hi there, I'm building a small site at the moment and now I'm facing a problem: The customer wants his form element to look "fancy" so we have to hold on the design. I googled jqTransform which fully fits my/his needs. Now: I'm using seam and richfaces to build pages. I have to apply the jqTransform on my forms but I've got several sele...

Issue passing date type with f:param

I'm trying to filter a listPage by date and userid. From a datatable the selected userid and date value is passed to the listPage with the f:param tag. The list page shows an error that says "value must be a date" and the filter doesnt work. It works if its just filtered by userid without the date. What could I be doing wrong? or How ca...

Can Html5 drap&drop interact with RichFaces fileUpload component?

Hi, My App used JBoss Seam, RichFaces. In the upload photo page, I want to use "drag&drop" a photo from desktop. I have tried with html5 but don't not find a way to interact with richfaces upload file control. Have a way to automatic start richface uploadfile on "ondrop" event in html5? Thanks, Huy ...

SEAM: How to get EntityManager and Logger in a class that is loaded dynamically?

Hi, I have a background service that runs every 10 min. This service queries the DB for jobs to execute a will load a class with a different business logic according to the job (using Class.forName()). They implement the same Interface, of course. I declared those classes to be SEAM components but when I try to use the entityManager ...

Problem with interruption of ajax request in RichFaces

I use seam and RichFaces in the project. If user performs action to leave the page (i.e. clicks s:link) while a4j ajax request is still active then alert with error 599 appears (Request error, status : 599 Network error). I can found error logs only in <a4j:log> output: debug[17:56:32,419]: NEW AJAX REQUEST !!! with form: aforma d...

Use message bundle in Java class with Seam

Hi guys, I want to use my message bundle (messages_fr.properties) in a Java class with seam. In a jsf file, all work fine like this: <h2>#{msg.newCustomer}</h2> But in my Java class, I tried to do this: statusMessages.addToControlFromResourceBundle("refArbor", "#{messages['error_refArborDoesntExist']}"); or this: statusMessages....

How to avoid repeat evaluation of EL

Hi, I'm developing a web interface with seam/richfaces. Alot of the components has something akin to <h:panelGrid rendered="#{complexbean.heavyoperation()}"> ... </h:panelGrid> <h:panelGrid rendered="#{!complexbean.heavyoperation()}"> ... </h:panelGrid> In this case the #{!complexbean.heavyoperation()} gets evaluated twice....

h:selectOneRadio containing images

Hi, I have a h:selectOneRadio tag for displaying a number of radiobuttons: <h:selectOneRadio value="#{myBean.radioButtonSelection}"> <s:selectItems value="#{myBean.getPossibleRadioButtonSelections()}" var="rs" label="#{rs.toString}"/> </h:selectOneRadio> Now, instead of radiobuttons with string values (...

Do JBoss Seam applications have to be packages in an EAR?

Is it possible to package up a Seam application as a WAR file? I am trying to deploy a current Seam application that was running in JBoss to JBoss 6. It is packaged as a WAR file, but every example included with the Seam download seem to be packaged in an EAR with the Seam jar and application code, both deployed as EJBs ...

How do I display the message in a different locale

We have a requirement to show a certain page alone in a different locale. (e.g in a certain page if the topic of discussion is related to English then we pick up the messages from the messages_en.properties, but if the topic of discussion is in French or German we need to show the messages in the appropriate language. How to change the ...