[jboss-user] [JBoss Seam] - Re: EL Enhancements
Post the stack trace. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4056238#4056238 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4056238 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements in Seam 1.2.1
This is not how doStuff(argument) works. What you are trying to do is a common error. Think about when #{projectPlanHome.edit(pp.id)} will be evaluated: During rendering of the page. However, if you check the source of the rendered HTML, you will see that pp.id has not been replaced with a value, it is still pp.id. So when you click the link, Seam will on the server call your projectPlanHome.edit() method and it will resolve pp.id as an argument to that method. At that time, pp is long gone. What you want is @DataModelSelection, see the Seam documentation and examples. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4044389#4044389 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4044389 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements in Seam 1.2.1
In other words, and as the documentation says, what you just wrote is equivalent to this: | | @In(#{pp.di}) | Long projectPlanId; | | public String edit() { | ... | } | That also doesn't work because at call time of edit(), no #{pp.id} can be resolved - pp is just the loop variable that is used during rendering of the previous page. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4044391#4044391 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4044391 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements in Seam 1.2.1
Thanks! Let me ask you another question related to the last one: What about if I don't have a dataTable? In other pages I have links like this one: | s:link id=ppPhase value=#{projectPlan.phases['i'].name} view=/phase.xhtml propagation=nest | f:param name=phaseId value=#{projectPlan.phases['i'].id}/ | /s:link | | which is trying to access other page with the information of an existing entityBean. I achieved this using seam-gen new-entity and all my pages are RESTful, but I'd like them to beheave with an action behaviour (or push-style). How can I do that? Can I keep the EntityHomes and tranform them to be push-style? Thanks for your time. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4044398#4044398 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4044398 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements in Seam 1.2.1
I've already tried what i was planning to do, and yeah, it works! Now, I understand the previous posts. It's needed an object in the scope of the conversation in order to evaluate the argument of the expression. Thanks! All of you, the staff of JBoss are very helpful. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4044432#4044432 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4044432 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL Enhancements dont work in facelets tag file
Anyone understands suggested workaround by Andrew Wheeler in bug comments? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4033890#4033890 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4033890 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL Enhancements dont work in facelets tag file
If you want to use action binding passed as parameter in facelets here is the article how to do that http://andrewfacelets.blogspot.com/2006/06/creating-composite-controls-with-jsf.html --MG View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4034036#4034036 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4034036 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL Enhancements dont work in facelets tag file
I am having similar problem. I am using facelets source tag: taglib.xml | facelet-taglib | namespacehttp://Test/namespace | tag | tag-nametest/tag-name | sourceTest.xhtml/source | /tag | /facelet-taglib Test.xhtml (source of test tag) | ui:composition xmlns=http://www.w3.org/1999/xhtml; ... | h:commandLink action=#{backingBean.test('123')} | testWithParam | /h:commandLink | h:commandLink action=#{backingBean.testNoParam} | testNoParam | /h:commandLink | /ui:composition | some xhtml file using test tag | ui:composition xmlns=http://www.w3.org/1999/xhtml; ... | xmlns:t=http://Test; |t:test backingBean=#{testBean}/ | /ui:composition Link testNoParam is working. Link testWithParam is NOT working. I get exception: 11:15:57,258 ERROR [ExceptionFilter] uncaught exception javax.servlet.ServletException: Error calling action method of component with id test:_id54 at javax.faces.webapp.FacesServlet.service(FacesServlet.java:152) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63) at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:60) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84) I am using seam 1.2.1GA, project was created using seam-gen. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4033634#4033634 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4033634 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL Enhancements dont work in facelets tag file
Complete stacktrace of exception: javax.faces.FacesException: Error calling action method of component with id orgUnitDetail:_id66 at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:79) at javax.faces.component.UICommand.broadcast(UICommand.java:106) at org.ajax4jsf.framework.ajax.AjaxViewRoot.processEvents(AjaxViewRoot.java:180) at org.ajax4jsf.framework.ajax.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:158) at org.ajax4jsf.framework.ajax.AjaxViewRoot.processApplication(AjaxViewRoot.java:329) at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343) at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63) at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:60) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:57) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:79) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:84) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:96) at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:220) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175) Caused by: java.lang.NullPointerException: at org.jboss.seam.ui.facelet.MethodExpressionHelper.findParamTypes(MethodExpressionHelper.java:146) at org.jboss.seam.ui.facelet.MethodExpressionHelper.invokeTheExpression(MethodExpressionHelper.java:98) at org.jboss.seam.ui.facelet.ParamMethodExpression.invoke(ParamMethodExpression.java:62) at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68) at com.sun.facelets.el.LegacyMethodBinding.invoke(LegacyMethodBinding.java:69) at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63) at javax.faces.component.UICommand.broadcast(UICommand.java:106) at org.ajax4jsf.framework.ajax.AjaxViewRoot.processEvents(AjaxViewRoot.java:180) at org.ajax4jsf.framework.ajax.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:158) at org.ajax4jsf.framework.ajax.AjaxViewRoot.processApplication(AjaxViewRoot.java:329) at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343) at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:137) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:63) at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:60) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49) at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45) at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:49)
[jboss-user] [JBoss Seam] - Re: EL Enhancements dont work in facelets tag file
I found that there is allready bug: http://jira.jboss.com/jira/browse/JBSEAM-668 View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4033654#4033654 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4033654 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements
Below is the log of the exception. Also, I have the following in my faces-config.xml: application | ... | view-handlerorg.jboss.seam.ui.facelet.SeamFaceletViewHandler/view-handler | /application javax.el.ELException: Error Parsing: #{compHome.done(x.id)} | at com.sun.el.lang.ExpressionBuilder.createNodeInternal(ExpressionBuilder.java:140) | at com.sun.el.lang.ExpressionBuilder.build(ExpressionBuilder.java:157) | at com.sun.el.lang.ExpressionBuilder.createValueExpression(ExpressionBuilder.java:201) | at com.sun.el.ExpressionFactoryImpl.createValueExpression(ExpressionFactoryImpl.java:74) | at org.jboss.seam.ui.facelet.SeamExpressionFactory.createValueExpression(SeamExpressionFactory.java:105) | at com.sun.facelets.el.ELText$ELTextVariable.apply(ELText.java:161) | at com.sun.facelets.el.ELText$ELTextComposite.apply(ELText.java:142) | at com.sun.facelets.compiler.TextInstruction.apply(TextInstruction.java:56) | at com.sun.facelets.compiler.UIInstructionHandler.apply(UIInstructionHandler.java:85) | at com.sun.facelets.tag.jsf.ComponentHandler.applyNextHandler(ComponentHandler.java:314) | at com.sun.facelets.tag.jsf.ComponentHandler.apply(ComponentHandler.java:169) | at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47) | at com.sun.facelets.tag.jsf.ComponentHandler.applyNextHandler(ComponentHandler.java:314) | at com.sun.facelets.tag.jsf.ComponentHandler.apply(ComponentHandler.java:169) | at com.sun.facelets.tag.jsf.ComponentHandler.applyNextHandler(ComponentHandler.java:314) | at com.sun.facelets.tag.jsf.ComponentHandler.apply(ComponentHandler.java:169) | at com.sun.facelets.tag.ui.DefineHandler.apply(DefineHandler.java:58) | at com.sun.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:128) | at com.sun.facelets.impl.DefaultFaceletContext$TemplateManager.apply(DefaultFaceletContext.java:306) | at com.sun.facelets.impl.DefaultFaceletContext.includeDefinition(DefaultFaceletContext.java:279) | at com.sun.facelets.tag.ui.InsertHandler.apply(InsertHandler.java:68) | at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47) | at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49) | at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47) | at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25) | at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:248) | at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:294) | at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:273) | at com.sun.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:143) | at com.sun.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:113) | at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49) | at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25) | Caused by: com.sun.el.parser.ParseException: Encountered ( at line 1, column 20. | Was expecting one of: | } ... | . ... | [ ... | ... | gt ... | ... | lt ... | = ... | ge ... | = ... | le ... | == ... | eq ... | != ... | ne ... | ... | and ... | || ... | or ... | * ... | + ... | - ... | ? ... | / ... | div ... | % ... | mod ... | | at com.sun.el.parser.ELParser.generateParseException(ELParser.java:1651) | at com.sun.el.parser.ELParser.jj_consume_token(ELParser.java:1531) | at com.sun.el.parser.ELParser.DeferredExpression(ELParser.java:134) | at com.sun.el.parser.ELParser.CompositeExpression(ELParser.java:61) | at com.sun.el.lang.ExpressionBuilder.createNodeInternal(ExpressionBuilder.java:103) | at com.sun.el.lang.ExpressionBuilder.build(ExpressionBuilder.java:157) | at com.sun.el.lang.ExpressionBuilder.createValueExpression(ExpressionBuilder.java:201) | at com.sun.el.ExpressionFactoryImpl.createValueExpression(ExpressionFactoryImpl.java:74) | at org.jboss.seam.ui.facelet.SeamExpressionFactory.createValueExpression(SeamExpressionFactory.java:105) | at com.sun.facelets.el.ELText$ELTextVariable.apply(ELText.java:161) | at com.sun.facelets.el.ELText$ELTextComposite.apply(ELText.java:142) | at com.sun.facelets.compiler.TextInstruction.apply(TextInstruction.java:56) | at com.sun.facelets.compiler.UIInstructionHandler.apply(UIInstructionHandler.java:85) | at com.sun.facelets.tag.jsf.ComponentHandler.applyNextHandler(ComponentHandler.java:314) | at com.sun.facelets.tag.jsf.ComponentHandler.apply(ComponentHandler.java:169)
[jboss-user] [JBoss Seam] - Re: EL enhancements
As mentioned in the docs you can only use the EL enhancement on method bindings, not value bindings (i.e. a get/is/set) View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4019243#4019243 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4019243 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements
What is the recommended method of executing a query for each line in a DataModel or list of entities on a page upon each load? I was thinking I could pass in the loop variable to a method that would go and execute a query. Since that's not possible, what should I do - I know how to use DataModel for doing things once you've selected an entity, but not how to do something for every entity, with regards to a list. Is there a good example of this I could check in the Seam examples? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4019384#4019384 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4019384 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements
Right, but that would only be evaluated when I click the link, whereas I would like the value to be shown when the list page is shown. For example, in a list of entities I'd like to show next to it the result of a query (i.e. that value isn't stored as a property of the entity, but is evaluated as a result of a query). I can't see how to get them all to display on the list page. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4019416#4019416 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4019416 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements
lightbulb432 wrote : What is the recommended method of executing a query for each line in a DataModel or list of entities on a page upon each load? You can't do it like this. You would have to preprocess the list in your factory method. Normally you can avoid doing this by getting the datamodel right. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4019425#4019425 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4019425 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements
Here's the type of thing I'm trying to do. The point is that there are a list of favorites, and within that list I want to specially mark those favorites of the logged in user. But of course, the enhanced EL expression I have in the view doesn't work. It seems like the most intuitive way to do it, but I guess I have to look for another option. Hopefully you can advise as to what I can do here. Thanks. @DataModel | private List favorites; | | @Factory | public void getFavorites() { | favorites = entityManager.createQuery(...).getResultList(); | } | | public String getStatus(int id) { | for (Favorite f : member.getFavorites()) { | if (member.getFavorite().getId() == id) return Your Favorite; | } | return Not Your Favorite; | } h:dataTable value=#{favorites} var=fave | h:column | #{fave.name} | /h:column | h:column | #{entityHome.status(fave.id)} | /h:column | /h:dataTable View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4019616#4019616 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4019616 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: EL enhancements
It is only for invocations, as far as I know. You can, however, create your own EL functions to deal with the type of thing you want to do. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3998369#3998369 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3998369 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user