hii.
i am using entitymanger to presist Object as:
Customer cust;
em.presist(cust);
the id of customer is auto generated (in my case it is Oracle Sequence).
after presistance i want to get the id of the presisted Object. like
Customer cust;
em.presist(cust);
// Want to get the Id here;
This is how i have used oracle sequence.
sequenceName=CUSTOMER_SEQ: Is the name is the name of your database sequence.
name=CUSTOMER_SEQUENCE: U will use in Entity as i have used it with id
field.
/
@Entity
@Name(Customer)
@Scope(EVENT)
Thanks for your reply christian
well and injecting EntityManager like this in my action class
@PersistenceContext(unitName=myDatabase)
protected EntityManager em;
i think it will not allow me to use em.flush function as i think so i have
tried it before and it throughs exception.(As per my
Hi !!!
I am using paypal for my online transactions in me seam project.
when ever i submit my form and send request to paypal, some times it works fine
and most of the time it gives exception given below.
MESSAGE=Error: Paypal Exception occured: ; nested exception is:
org.w3c.dom.DOMException:
well i personly also thought that it does not have to do any think with seam ?
but just want to be confirmed that is this exception have to do any thing with
seam request processing life cycle or not. As from exception its seems that may
be some jsf component(which i thought it is refering as
hi
i am using to actions against one view-id in pages.xml i.e.
page view-id=/comm/genmailtemplate.xhtml
action=#{EmailTemplateGeneraterAction.loadEmailTemplate} /
page view-id=/comm/genmailtemplate.xhtml
action=#{CustomerLoginAction.loadPrivileges('GenerateMailTempSMItem')} /
i am using jboss seam the the scope of my bean is EVENT(request) and it should
do that as i have been doing it in other beans. may be i cannot understant
exactly what u have said.
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4039164#4039164
Reply to the
Hi.
i have readOnly inputText is JSF as
h:inputText id=emails value=#{myBean.emails}/ readonly=true
with backend getter and setter methods.
well when i submit form i do not have any value in my myBean.emails varaible. i
have searched and came to know that readOnly and disabled fields are not
I am queuing event when it is fired after Apply_Request_values phase for
Update_model_value phase but it is fired first time
during(Apply_Request_values) but not after Update_model_Values phase
public void changeMethod(ValueChangeEvent event)
{
PhaseId phaseId = event.getPhaseId();
Hii...
i am using Value change listener. this event is fired after AppyRequestValues
Phase of JSF. but i want it to be delayed and fired after UpdateModelValues. i
am using it in my code as given below...
h:selectOneMenu id= comid onchange=this.submit() value=...
i think immediate=true is issed to fire event with out delay(i mean in early
Phases). but however i have tried both immediate= true and immediate=false,
both options do not work. any other opton plz..
View the original post :
i am using seam-gen. i am trying to dowload a file or data from server as file.
my code is
FACELETS CODE:
h:commandButton value=donwload file
actionListener=#{ERegReportHandlerAction.downloadReportFile}/
Sessionbean Function:
public void downloadReportFile(){
Hii..
i am displaying a report in my page with datatable. i want to export the report
in to Excel. is there any tool or component to do that or any way around
thanks in advance..
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=4023004#4023004
Reply to the
i am using sem-gen. my facelets page has a -display tag library.
ui:composition xmlns=http://www.w3.org/1999/xhtml;
xmlns:d=http://displaytag.sf.net;
i used its compunent table as
d:table id=tableId
d:column title=ID123/d:column
i think, you can do it like this,
| page view-id=/page.xhtml
|navigation from-action=#{action.action}
|rule if-outcome=success
|redirect view-id=/viewA.xhtml
|/rule
| rule if-outcome=failed
|redirect
well i have my datatable binded to the DataModel and DataModelSelection. let me
explain my problem through example plz .
my datatable first shows the followinf record when i load the page...
1
2
3
4
5
i delete the record 1 and have on my page
2
3
4
5
now i press the back button of
I am using seam remoting for AJAX but when i call my ajax method from client it
given error
Seam.Remoting.displayLoadingMessage = function() {};
Seam.Remoting.hideLoadingMessage = function() {};
// Get the privilege Seam component
var RolePrivilegesAction =
i have also faces the same problem? i have to also go for a same solution
required=true instead of @NotNull. is it some thing wrong with this anotation
if not then for what exactly it is for...
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=3997950#3997950
well i have solved the problem. i was reducing the code to send you , and i
came to know that conflict was between the JSTL library and the seam pages.xml
action...
thanks a lot for your help..
View the original post :
thanks norman richards for help
i have tried the same thing as told by u but it has some problem
This is my entry in the page.xml
page view-id=/secretquestions.jsp
action=#{SecretQuestionsAction.checkLoggedIn} /
here is my checkLoggedIn function...
public String checkLoggedIn(){
i cannot understood hitting page directly . if you mean that i am accessing by
typing URL in the browser then it works fine it goes to login page(as i am not
logged in) but when a login and goes to admin page given below and try to
access the sceretquestion.jsp it still goes to login page.
i
i shall be trying to debug by making some dummy application and the proceeding
to my application hopefully reaching to the problem. But however thanks again
for your help norman richards.
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=3996669#3996669
Reply to
if (isLoggedIn){
System.out.println( Returing null);
return null; // Go to secretquestions.jsp.
}else{
return loginpage; // go to login page.
}
well i have Returing null String displayed on my console so i its abvious
that it is returning null output. i think i have
Ya i am sure because i have tried with no navigation rule in my
faces-config.xml and only one page action in my pages.xml so i think there
should be no other interfernces and i do not think that there is any other file
that is part of this process..
View the original post :
What i want is that whenever a user access a page by typing a direct url in the
browser e.g http://localhost:8080/myproject/mypage.jsp; , the page should
only be opened if user is loggedin else it should go to some other page. how
?
i have written the interceptor as given in booking
This is my SessionBean class where i am using it what i am trying to achive is
that if a user directly try to open the page by tying a URL e.g
http://localhost:8080/ereg/secretquestions.jsp; then the LoggedInIntercepter
should check first that user is logged in or not if not that return to some
I am developing a LoggedInInterceptor but problem with it is that when i
return the string it does not functon properly
Interceptor code is here:
--
@Interceptor(around={BijectionInterceptor.class, ValidationInterceptor.class,
ConversationInterceptor.class,
well i have understood the problem but cannot find solution for it.. well i
have
h:outputText in my JSF page as
h:inputText id=username value=#{customer.username}
which is mapped to the Entity bean
Entity
@Name(customer)
@Scope(SESSION)
@Table(name=ERegCustomer)
i want to download the source code of hibernate and in specific source code of
org.hibernate.validator package some one can help me plz
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=3995087#3995087
Reply to the post :
I want to have my own Hibernate annotaion validator.. named NotEmpty a
problem is that when after form submition the only initialize() method is
called. isValid() method does not executes..
below is the code and Thanks in advance for help..
- Annotation descriptor
No it do not have any value when form is submited and it POJO mapped attribute
contains (empty String) in it. i want to perform validation for this empty
String.
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=3995205#3995205
Reply to the post :
is it possible to perform validation on empty fields (fields which have
String)
View the original post :
http://www.jboss.com/index.html?module=bbop=viewtopicp=3995206#3995206
Reply to the post :
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3995206
i am working on registration form and i want that user cannot submit empty
fields. i have marked the corresponding fields with @NotNull annotation in the
Entity POJO but its not working. Other annotations @length etc are working
fine. when form is submitted with empty fields, the session bean
thanks Stephan for quick reply.
if i will add required=true to the form input components then it will be
checked by the JSF not by Jboss Seam or hibernate validators (in my case
@NotNull) i want the validation to be performed on server side through
annotations on my Entity bean.
View the
34 matches
Mail list logo