Adf : required="true" 与 <af:setActionListener的冲突
2015-01-26 15:41
330 查看
问题描述:同一个jsff页面中如果已有一个控件设置成required="true"属性的话,其他控件的<af:setActionListener 属性就会不好使。
看图:
Title设置成了required="true",co-creators后面的链接,点击的话,设置了传参方法<af:setActionListener from="#{row}" to="#{pageFlowScope.paperBuilder.editPaperBean.actor}"/>,结果出来的popup显示全是空的,参数值没有传过来。
title输入框部分的源码:
co-creator部分的源码:
解决办法:
去掉title的required="true",在后台写代码做必须填写的校验.
这样就好了:
看图:
Title设置成了required="true",co-creators后面的链接,点击的话,设置了传参方法<af:setActionListener from="#{row}" to="#{pageFlowScope.paperBuilder.editPaperBean.actor}"/>,结果出来的popup显示全是空的,参数值没有传过来。
title输入框部分的源码:
<af:inputText id="it2" value="#{pageFlowScope.paperBuilder.editPaperBean.paper.topic}" <span style="background-color: rgb(204, 51, 204);">required="true" </span>simple="true" rendered="#{(pageFlowScope.paperBuilder.editPaperBean.paper.status.name == 'In-Edit' || pageFlowScope.paperBuilder.editPaperBean.paper.status.name == 'Pending Re-Submission') && pageFlowScope.paperBuilder.editPaperBean.creator || pageFlowScope.paperBuilder.editPaperBean.paper.status.name == 'New'}" maximumLength="255" autoSubmit="true"/>
co-creator部分的源码:
<af:iterator id="i2" value="#{pageFlowScope.paperBuilder.editPaperBean.paper.coCreators}" var="row" rows="0"> <af:panelGroupLayout id="pgl21" inlineStyle="white-space:nowrap;"> <af:commandLink text="#{row.displayName}" partialSubmit="true" id="cl1" styleClass="link" inlineStyle="white-space:nowrap;"> <af:showPopupBehavior popupId="::p1" triggerType="click"/> <span style="color:#6633FF;"> <span style="background-color: rgb(102, 102, 204);"><span style="color:#000000;"><af:setActionListener from="#{row}" to="#{pageFlowScope.paperBuilder.editPaperBean.actor}"/></span></span></span> </af:commandLink>
解决办法:
去掉title的required="true",在后台写代码做必须填写的校验.
这样就好了:
相关文章推荐
- 1.Struts的<action unknown="true">:界面
- <!-- <s:action name="navAllFront" namespace="/nav" executeResult="true" flush="false"></s:action>
- 3.Struts的<action unknown="true">:web.xml
- 2.Struts的<action unknown="true">:struts-config.xml
- spring3 jsp页面使用<form:form modelAttribute="xxxx" action="xxxx">报错,附连接数据库的spring MVC annotation 案例
- System.ArgumentException: 回发或回调参数无效。在配置中使用 < pages enableEventValidation="true"/> 或在页面中使用 <% @ Page
- <form action="form_action.asp" method="get">
- ADF Issue: triggerType="action" blocks action and actionListener of parent
- 如何使用<identity impersonate="true"/>
- Struts2通配符映射/Struts <action name="/*/*" method="{2}" class="com.jxc.action.{1}Action"> <result
- <s:form action="login"...与<s:form action = "login.action"...的区别
- 4.Struts的<action input=""></action>:业务逻辑层
- <c:set var="root" value="${pageContext.request.contextPath}"></c:set>According to TLD or attribute d
- 2.Struts的<action input=""></action>:ActionForm
- 回发或回调参数无效。在配置中使用或在页面中使用 <%@ Page EnableEventValidation="true" %
- 3.Struts的<action forward="/login.jsp"></action>:web.xml
- 2.Struts的<action forward="/login.jsp"></action>:struts-config.xml
- 回发或回调参数无效。在配置中使用 <pages enableEventValidation="true"/> 或在页面中使用 <%@ Page EnableEventValidation="true"
- hdoj1707(set)(s[day][time].insert(name))(cout<<" "<<*it)
- 3.Struts的<action input=""></action>:Action