Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Issue with binding components from page fragments into managed bean when rendered as region

santiago_ncJun 9 2014 — edited Jun 9 2014

I have detected an issue when I binding a component into a managed bean from a page fragment which is a View of a TaskFlow exposed to JSF as a Region.


This issue happened when I exposed same TaskFlow as region two or more instances in the same JSF. The component which is binding only rendered in last Region.


Jdeveloper 12c (12.1.2.0) ADF12c.

This is the code:

Page Fragment:

<?xml version='1.0' encoding='UTF-8'?>

<ui:composition xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:af="http://xmlns.oracle.com/adf/faces/rich">

  <af:panelGroupLayout id="pgl1">

    <af:inputText label="Label 1" id="it1" binding="#{bindingComponentBean.inputText}"/>

    <af:button text="button 1" id="b1"/>

  </af:panelGroupLayout>

</ui:composition>

Managed Bean(in Request Scope)

package com.edisa.test.errors.view.backing;

import oracle.adf.view.rich.component.rich.input.RichInputText;

public class BindingComponentBean {

    private RichInputText inputText;

    public BindingComponentBean() {

    }

    public void setInputText(RichInputText inputText) {

        this.inputText = inputText;

    }

    public RichInputText getInputText() {

        return inputText;

    }

}

TaskFlow

<?xml version="1.0" encoding="UTF-8" ?>

<adfc-config xmlns="http://xmlns.oracle.com/adf/controller" version="1.2">

  <task-flow-definition id="TestTaskFlow">

    <default-activity>test_fragment</default-activity>

    <managed-bean id="__1">

      <managed-bean-name>bindingComponentBean</managed-bean-name>

      <managed-bean-class>com.edisa.test.errors.view.backing.BindingComponentBean</managed-bean-class>

      <managed-bean-scope>request</managed-bean-scope>

    </managed-bean>

    <view id="test_fragment">

      <page>/fragments/test_fragment.jsff</page>

    </view>

    <use-page-fragments/>

  </task-flow-definition>

</adfc-config>

JSF Page

<?xml version='1.0' encoding='UTF-8'?>

<!DOCTYPE html>

<f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich">

    <af:document title="index.jsf" id="d1">

        <af:form id="f1">

            <af:pageTemplate viewId="/oracle/templates/threeColumnTemplate.jspx" id="pt1">

                <f:facet name="center">

                    <af:panelGridLayout id="pgl1" inlineStyle="border: 1px solid #eee;">

                        <af:gridRow marginTop="5px" height="auto" marginBottom="5px" id="gr1">

                            <af:gridCell marginStart="5px" width="50%" id="gc1" inlineStyle="border: 1px solid #eee;"

                                         halign="stretch">

                                <af:panelBox text="Region 1" id="pb1">

                                    <f:facet name="toolbar"/>

                                    <af:region value="#{bindings.TestTaskFlow2.regionModel}" id="r2"/>

                                </af:panelBox>

                            </af:gridCell>

                            <af:gridCell marginStart="5px" width="50%" marginEnd="5px" id="gc2"

                                         inlineStyle="border: 1px solid #eee;" halign="stretch">

                                <af:panelBox text="Region 2" id="pb2">

                                    <f:facet name="toolbar"/>

                                    <af:region value="#{bindings.TestTaskFlow1.regionModel}" id="r1"/>

                                </af:panelBox>

                            </af:gridCell>

                        </af:gridRow>

                    </af:panelGridLayout>

                </f:facet>

                <f:facet name="header"/>

                <f:facet name="end"/>

                <f:facet name="start"/>

                <f:facet name="branding"/>

                <f:facet name="copyright"/>

                <f:facet name="status"/>

            </af:pageTemplate>

        </af:form>

    </af:document>

</f:view>

This post has been answered by Cvele_new_account on Jun 9 2014
Jump to Answer

Comments

Duncan Mills-Oracle

Are you calling refresh() on the table component after changing the datasource - if not , try that.

Kalyan Miriyala-Oracle

Explicit refresh is not required as datasource is already loaded to ko observableArray which worked earlier before upgrade.

We can see that oj-table-body tag visibility is shown as hidden. Not sure how it is being populated. By manipulating the DOM, issue can be fixed, but this occurs wherever this kind of functionality is present.

Somnath_IT2006

Hi
I am facing the same issue in Visual Builder while having interdependent tables in two different tabs.
Do we have any solution other than modifying the DOM exclusively?

Regards
Somnath

John JB Brock-Oracle

I'm going to guess that it is not the same issue. The poster was migrating from JET 4 to JET 8.
For Visual Builder related questions, please use their Community forum located at
https://community.oracle.com/customerconnect/categories/oci-visual-builder

1 - 4
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Jul 7 2014
Added on Jun 9 2014
1 comment
307 views