-
1. Re: Richfaces Calendar submitting and rerendering problem
stty Nov 4, 2008 4:41 AM (in response to stty)"one day late" - i mean "one selection late"
-
2. Re: Richfaces Calendar submitting and rerendering problem
ilya_shaikovsky Nov 4, 2008 5:21 AM (in response to stty)use onchanged event to rise request.
-
3. Re: Richfaces Calendar submitting and rerendering problem
stty Nov 4, 2008 10:40 AM (in response to stty)I have used "onchanged" and others events but if You write code like this:
<a4j:support event="onchanged" actionListener="#{tableBean.load}" reRender="panelTable" />
the situation is as described...
load() function uses the date selected in the calendar (value = "#{tableBean.date}") to load data from database needed to rerender view. -
4. Re: Richfaces Calendar submitting and rerendering problem
ilya_shaikovsky Nov 4, 2008 12:43 PM (in response to stty)With RF 3.2.2GA and 3.3.0 snapshots - onchanged event fired after the date selected. And we've test this many times.. So the value which is applied - the new value.
<h:form> <rich:calendar popup="false" id="cal"> <a4j:support event="onchanged" reRender="out"></a4j:support> </rich:calendar> <h:outputText id="out" value="#{rich:findComponent('cal').value}"/> </h:form>
This simple test updates value of output text after date selected.
So please send simple war in order to reproduce your case if it possible. -
5. Re: Richfaces Calendar submitting and rerendering problem
stty Nov 6, 2008 4:03 AM (in response to stty)Thank you for answers.
I'm not sure I understood - I'll try today to use value="#{rich:findComponent('cal').value}"/> to send a parameter included in <a4j:support>. Than I'll give you an answer.
I've got another question: how to wrap long descriptions of leafs in <rich:tree>? I searched the documentation but without effect. I think there is a simple way to do that (like in Tomahawk library) but I didn't find it :-) -
6. Re: Richfaces Calendar submitting and rerendering problem
ilya_shaikovsky Nov 6, 2008 5:33 AM (in response to stty)I'm not sure I understood - I'll try today to use value="#{rich:findComponent('cal').value}"/> to send a parameter included in <a4j:support>. Than I'll give you an answer.
findComponent should not become an answer for you.. I've used it only in order not to create bean but just get current component value. So my point was just that using this code you could see that actual value submitted.I've got another question: how to wrap long descriptions of leafs in <rich:tree>? I searched the documentation but without effect. I think there is a simple way to do that (like in Tomahawk library) but I didn't find it :-)
as it described in documentation - treeNode designed in order to define markup for concrete type of node. So you could create any markup inside and display the text as you need. -
7. Re: Richfaces Calendar submitting and rerendering problem
stty Nov 7, 2008 5:16 AM (in response to stty)ilya - thank you - your advice about calendar was very helpful. Code working perfectly for me:
(...)
value = "#{tableBean.date}">
<a4j:support event="onchanged" reRender="panelTable" />
and in tableBean function
public void setDate(Date date) {
this.date = date;
load();
}
I still have the problem with the tree... I tried to enclose the command link in mentioned code with div, span, table using CSS but leafs still doesn't wrap :-(
<r:treeNode>
<a4j:commandLink value="[+] " rendered="#{!project.fastList}"
actionListener="#{treeBean.fastListInsert}" reRender="panelTree">
<c:attribute name="project" value="#{project}" />
</a4j:commandLink>
(...) -
8. Re: Richfaces Calendar submitting and rerendering problem
stty Nov 7, 2008 9:57 AM (in response to stty)Just another question (i hope the last one :-) ) to this example:
http://livedemo.exadel.com/richfaces-demo/richfaces/calendar.jsf?tab=organizer
I try to send a list of objects into cell of calendar in many ways:List<Report> reports = reporter.getReports(user, dates); item.setData(reports); // or item.setData(serializer.deepSerialize(reports)); // JSON // or data = new HashMap(); data.put("reports", reports); item.setData(data); // or item.setData(serializer.deepSerialize(reports)); items = item;
and use them in calendar:<a4j:outputPanel id="cell" layout="block" style="height: 100%;"> <r:dataTable id="monthTable" styleClass="monthTable" width="75" value="{data}" var="report"> <r:column> <h:outputText value="xxx" /> </r:column> </r:dataTable> </a4j:outputPanel>
orvalue="{data.reports}"
but I've got:
org.apache.jasper.el.JspPropertyNotFoundException: (...)
'#{!report.fromJira}' Property 'fromJira' not found on type java.lang.String
What I'm doing wrong? -
9. Re: Richfaces Calendar submitting and rerendering problem
stty Nov 7, 2008 10:02 AM (in response to stty)Sorry - last post is with mistake...
<r:column> <h:outputText value="#{report.project.id}: #{report.task.name}" rendered="#{!report.fromJira}" /> <h:outputText value="#{report.project.id}: (Jira)" rendered="#{report.fromJira}" /> </r:column>
-
10. Re: Richfaces Calendar submitting and rerendering problem
nbelaevski Nov 7, 2008 7:33 PM (in response to stty)Hello,
Please look here: http://jboss.com/index.html?module=bb&op=viewtopic&t=144949