ADF actionListener 不会在弹出窗口中的表格中触发 [英] ADF actionListener doesn't fire in table in a popup

查看:54
本文介绍了ADF actionListener 不会在弹出窗口中的表格中触发的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 af:popup 并且里面有一个 af:table.
在表中我有一个 af:commandImageLink.

I have a af:popup and have a af:table in it.
In the table I have a af:commandImageLink.

放在一列中;
这个 commandImageLink 有一个 actionListener 不会触发

It's placed in a column;
This commandImageLink has an actionListener that doesn't fire

<af:commandImageLink text="commandImageLink 1" 

    id="cil11" 
    icon="/resources/imatges/ver.jpg" 
    partialSubmit="true" 
    immediate="true" 
    actionListener="#{pageFlowScope.MyBean.setNameFilter}"/>

我尝试将 commandImageLink 单独放在 popup 中,而没有任何 table,它可以正常触发;

I tried puting the commandImageLink in the popup alone without any table, it fires fine;

确实很奇怪.

代码:

<af:popup id="cercaTercersCriteria" binding="#{pageFlowScope.myBean.p1}">
                            <af:panelWindow binding="#{pageFlowScope.myBean.pw2}"
                                            id="pw2"
                                            modal="true"
                                            contentHeight="700"
                                            contentWidth="700"
                                            stretchChildren="first">
                              <af:panelGroupLayout binding="#{pageFlowScope.myBean.pgl6}"
                                                   id="pgl6">
                                <af:panelHeader text="panelHeader 1"
                                                binding="#{pageFlowScope.myBean.ph4}"
                                                id="ph4">
                                  <f:facet name="context">
                                    <af:group binding="#{pageFlowScope.myBean.g2}"
                                              id="g2">
                                      <af:commandImageLink text="commandImageLink 1"

                                                           id="cil11"
                                                           icon="/resources/imatges/see.jpg"
                                                           partialSubmit="true"
                                                           immediate="true"
                                                           actionListener="#{pageFlowScope.myBean.setNomeFilter}"/>
                                      <af:panelGroupLayout layout="vertical"
                                                           binding="#{pageFlowScope.myBean.pgl7}"
                                                           id="pgl7">
                                        <af:panelHeader text="SearchTeachersVVO11"
                                                        binding="#{pageFlowScope.myBean.ph5}"
                                                        id="ph5">
                                          <af:query id="qryId5"
                                                    headerText="Search"
                                                    disclosed="true"
                                                    value="#{bindings.ImplicitViewCriteriaQuery2.queryDescriptor}"
                                                    model="#{bindings.ImplicitViewCriteriaQuery2.queryModel}"
                                                    queryListener="#{bindings.ImplicitViewCriteriaQuery2.processQuery}"
                                                    queryOperationListener="#{bindings.ImplicitViewCriteriaQuery2.processQueryOperation}"
                                                    resultComponentId="::resId5"
                                                    binding="#{pageFlowScope.myBean.qryId5}"/>
                                        </af:panelHeader>
                                        <af:table value="#{bindings.SearchTeachersVVO11.collectionModel}"
                                                  var="row"
                                                  rows="#{bindings.SearchTeachersVVO11.rangeSize}"
                                                  selectedRowKeys="#{bindings.SearchTeachersVVO11.collectionModel.selectedRow}"
                                                  selectionListener="#{bindings.SearchTeachersVVO11.collectionModel.makeCurrent}"
                                                  rowSelection="single" 
                                                  emptyText="#{bindings.SearchTeachersVVO11.viewable ? 'No data to display.' : 'Access Denied.'}"
                                                  fetchSize="#{bindings.SearchTeachersVVO11.rangeSize}"
                                                  rowBandingInterval="0"
                                                  id="resId5"
                                                  binding="#{pageFlowScope.myBean.resId5}">
                                          <af:column sortProperty="PefisIdFk"
                                                     sortable="false"
                                                     headerText="#{bindings.SearchTeachersVVO11.hints.PefisIdFk.label}"
                                                     id="resId5c1">
                                            <af:commandImageLink text="commandImageLink 2"
                                                                 id="cil1" icon="/resources/imatges/ver.jpg"
                                                                 binding="#{pageFlowScope.myBean.cil1}"
                                                           partialSubmit="true"
                                                           immediate="true"
                                                           actionListener="#{pageFlowScope.myBean.setNomeFilter}"/>
                                          </af:column>
                                          <af:column sortProperty="name"
                                                     sortable="false"
                                                     headerText="#{bindings.SearchTeachersVVO11.hints.name.label}"
                                                     id="resId5c2">
                                            <af:outputText value="#{row.name}"
                                                           id="ot1"/>
                                          </af:column>
                                        </af:table>
                                      </af:panelGroupLayout>
                                    </af:group>
                                  </f:facet>
                                  <f:facet name="menuBar"/>
                                  <f:facet name="toolbar"/>
                                  <f:facet name="legend"/>
                                  <f:facet name="info"/>
                                </af:panelHeader>
                              </af:panelGroupLayout>
                            </af:panelWindow>
                          </af:popup>

推荐答案

我做了以下事情来解决:

I did the following to resolve:

  1. 我从头开始创建了新的 ViewObject
  2. 我从头开始创建了一个 jspx 页面
  3. 我用表格实现了popup
  4. 用我的方法创建了一个 ManageBean 并在表的一列的 actionListener 中实现它
  1. I created new ViewObject from scretch
  2. I created a jspx page from scretch
  3. I implimented the popup with the table
  4. Created a ManageBean with my method and implimented it in the actionListener of a column of the table

它突然开始迷人地启动了这个事件.

And it suddenly started firing the event charmingly.

这篇关于ADF actionListener 不会在弹出窗口中的表格中触发的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆