Programatically adding command links in ADF Tree?

Hi,
I am using Build JDEVADF_11.1.1.3.PS2_GENERIC_100408.2356.5660. Can anyone please provide me some sample code for programatically adding dynamically generated ADF command links in the nodes of ADF Tree(Tree nodes in it are created using View Object - Drag & drop of data control). Now how can i add links in the nodes generated.
Thanks,
Vik

Hi,
try setting partialSubmit=true on the command link. Just in case it fires the action method before the context menu displays
Frank

Similar Messages

  • Command link used as tree node

    I'm using an ADF Tree where one of my nodes is a command link. I've given the link an id="myLink".
    When I run the page, the tree shows up fine with just one node.
    But the View Page source does not contain any entry that says id="mylink".
    Where could be the problem?
    Thanks
    RV

    Hi,
    I assume you use ADF Faces RC, because otherwise you would have posted this to the JDeveloper forum. If you add a command link t a node, then this command link is used for any node that is rendered for the tree (unless you implemented it in a way that only has exactly one command link component showing in the whole tree - which I don't think you have).
    In JSF you cannot have more than one component with a specific ID, which means that assigning an ID to a command link in a tree doesn't make much sense.
    In ADF Faces RC, trees are active components, which means they are created in the DOM and not HTML. So using a DOM inspector like Firebug you should see your tree and link components
    <a id="j_id___jsp_tag_ctru4:7:myLink" class="xdk" href="#" onclick="return false;">commandLink 1</a>
    Frank

  • Command Link in ADF table is not working/ PPR event not getting fired

    Hi All,
    I am having ADF Table, in that one column is with command link if click on command link, it is not navigating to corresponding page or method of a bean. If i give same command link out of the table it working fine, this issue i am facing is in IE9.
    if i use IE in compatibility mode the links works fine, even in IE8 version also.
    Browser: IE 9
    Jdev version: 11.1.1.5.0
    I tried all possible things, but nothing workout for me.
    showPopupBehavior not working in IE9 for af:table buttons (jdev11.1.1.5.0)
    Partial page rendering not working in ie9
    Command Link in ADF table is not working
    Thnks

    Hi,
    please file a bug if you have a customer support contract and provide a testcase
    Frank

  • Command link in adf pivot table

    Hi,
    I Created one View Object (WrkVOR) Based on below query
    Select Desc1,Desc2 ,Date,Sum(Amount) From populate_wrk Group by Desc1,Desc2 ,Date
    Based on View Object we created pivot table
    Rows - Desc1 ,Desc2
    Column - Date
    Amount will come under each date (Like Matrix report)
    Up to It is working fine
    i added a command link on data(Amount) when i click the command link i am getting below error
    DVT-2015 Slice 1 Exceeds boundary -3
    please help....
    Thanks
    shk

    Hi,
    the real problem of the original poster seems to be <af:commandLink text="#{row.GlobalDealId}" id="cl1" action="createMDM" immediate="true" partialSubmit="true"> having immediate set to true in which case the request goes from restore view to render response. You usually use immediate=true on a command item to cancel an action (bypassing all the other JSF lifecycle steps).
    Peter551059,
    you don't give us much information about your case. So if the problem is IE9 and you verified IE9 is supported for the version of JDeveloper you use, then - in case you have a support contract - my best advise is to file a service request and have support looking at it just in case you hit a defect that should be filed as a bug
    Frank

  • Command link in adf table is not working..

    Hi All,
    I am having ADF Table, in that one column is with command link and,if click on commnad link it is not going to coorsponding action or actionListener methods of bean. If i give same command link out side of the table it working fine.But i have to pass some perameters on click of button.
    I am getting same problem in many places , if i delete the page and page-def files again if i create some times it is working but some times not working. Is there any specific reason for this.Following is the code snippet...
    <af:column sortProperty="GlobalDealId" sortable="false"
    headerText="#{bindings.DsaDealsResultsVO1.hints.GlobalDealId.label}"
    id="c8">
    <af:commandLink text="#{row.GlobalDealId}" id="cl1" action="#{pageFlowScope.editProfileCompleteness.sample}" immediate="true" partialSubmit="true">
    <af:setActionListener from='"#{row.GlobalDealId}"'
    to='"#{pageFlowScope.globalDealId}"'/>
    <af:setActionListener from='"#{row.CustName}"'
    to='"#{pageFlowScope.custName}"'/>
    <af:setActionListener from='"#{row.IsSaDeal}"'
    to='"#{pageFlowScope.isSaDeal}"'/>
    </af:commandLink>
    </af:column>
    Even i tried with out immediate="true" partialSubmit="true" also.
    And i set ChangeventPolicy = ppr for Iterator in page defnation file.
    Awaiting for ur reply.

    Hi,
    the real problem of the original poster seems to be <af:commandLink text="#{row.GlobalDealId}" id="cl1" action="createMDM" immediate="true" partialSubmit="true"> having immediate set to true in which case the request goes from restore view to render response. You usually use immediate=true on a command item to cancel an action (bypassing all the other JSF lifecycle steps).
    Peter551059,
    you don't give us much information about your case. So if the problem is IE9 and you verified IE9 is supported for the version of JDeveloper you use, then - in case you have a support contract - my best advise is to file a service request and have support looking at it just in case you hit a defect that should be filed as a bug
    Frank

  • ADF Tree Command Link + Content Menu

    Hi,
    I am trying to build a tree, in which the nodes should have a command link and a context menu enabled. Using JDeveloper 11.1.1.6.0, however the context menu is not showing up, if the command link is enable for a particular node. If the command link option is not set for a node, then the menu option does shows up. Below is what my code looks like. Has anyone faced a similar issue/know of a solution?
    My Code is something like -
    *<f:facet name="contextMenu">*
    <af:popup id="p1" contentDelivery="lazyUncached">
    <af:menu text="Location Menu" id="m31"
    visible="#{pageFlowScope.TreeData.showLocationMenu}" contentDelivery="immediate">
    <af:commandMenuItem text="Add new Department"
    id="cmi2" partialSubmit="true" immediate="true"
    actionListener="#{pageFlowScope.TreeData.createDepartment}">
    <af:setPropertyListener from="#{node.viewType}"
    to="#{pageFlowScope.formView}"
    type="action"/>
    <f:attribute name="node" value="#{node}"/>
    </af:commandMenuItem>
    </af:menu>
    </facet>     
    <f:facet name="nodeStamp">
    *<af:commandLink text="#{node.key} #{node.text}"*
    *action="#{pageFlowScope.DynamicRegionBean.getDep}" id="cl1" partialSubmit="true" immediate="true"/>*
    *</f:facet>*
    Thanks
    Sachin

    Hi Timo,
    Yeah... adding an output text, shows the context menu on the text, however I was looking for something like one 'text' rendered and it doing the option of both.
    Something like what we can do for any hyper link, if click on it, it opens that link or else if I right click on the link, it gives me options like - Open in new Tab/Window etc.
    Any suggestions??
    Thanks
    Sachin

  • Programatically creating ADF Tree with nodes,child nodes & links?

    Hi,
    Currently I am using Build JDEVADF_11.1.1.3.PS2_GENERIC_100408.2356.5660. Please provide me detailed code for programatically creating ADF Tree with nodes, child nodes and links in it.
    Thanks,
    Vik

    You need to create a model for the tree. ADF has a build in model that you can use to build your own tree.
    This is what you need to write in your JSPX:
    <af:tree summary="Navigation" id="treeNav" value="#{pageFlowScope.treeNavigationBackingBean.model}"
               var="node" contextMenuSelect="true" rowSelection="single" fetchSize="30">   
           <f:facet name="nodeStamp">
          <af:outputText id="txtText" value="#{node.text}"/>
        </f:facet>
    </af:tree>This is the code to retreive the model:
      public TreeModel getModel() {
        if(model == null)
            model = new ChildPropertyTreeModel(instance,"children");
        return model;
      }instance contains the actual tree. I build it in the constructor of my managed bean:
        public BeanTreeNavigation() {
          ArrayList<TreeItem> rootItems = new ArrayList<TreeItem>();
          TreeItem node1 = new TreeItem("Root node");
             ArrayList<TreeItem> level1 = new ArrayList<TreeItem>();
             TreeItem level1Node1 = new TreeItem("Level1 Node1");
              level1.add(level1Node1);
           node1.setChildren(level1);
           rootItems.setChildren(node1); 
          this.setListInstance(rootItems);
          root = rootItems;
      public void setListInstance(List instance) {
        this.instance = instance;
        model = null;
      }The TreeItem class is not a default one. I created it myself. You can make of it whatever you want:
        public class TreeItem {
          private String text;
           private List<TreeItem> children = null;
           public TreeItem(String text){
            this.text = text;
            public void setText(String text) {
                this.text = text;
            public String getText() {
                return text;
            public void setChildren(List<TreeItem> children) {
                this.children = children;
            public List<TreeItem> getChildren() {
                return children;
            }I wrote the TreeItem as an inner class of the managed bean.
    The most important part is the getModel methode. There you need to specify an Object and the name of the getter that will return a List of the children.
    Hope this helps.
    Edited by: Yannick Ongena on Feb 22, 2011 7:30 AM

  • ADF tree with command link

    Hello,
    I have a menu build with a tree and a region. When I click a link from the tree the region populate a page with another dinamic tree based on a session variable that refresh each time that i click a link from the first tree. After click the link I have a flow that has an executewithparams method and the page that will show the second tree.
    My problem is that the second tree doesn't refresh its branches at my first click on the link but on the second yes and I receive :
    <NavigationPaneRenderer><_renderContent> Warning: There are no items to render for this level
    <FormRenderer><setupEncodingContext> Multiple forms detected on viewId: /pages/index.jspx. Rich client currently has some limitations in dealing with multiple forms.
    I have set the autorefresh for the iterator but I haven't success.
    Can anyone help me?
    Thank you.

    Hi Frank,
    It's true that my execute with params method accessthe session scope attribute directly but in my page fragmet i haven't af:form
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
    xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:c="http://java.sun.com/jsp/jstl/core">
    <!--oracle-jdev-comment:preferred-managed-bean-name:backing_doc-->
    <af:panelGroupLayout id="pgl2">
    <c:set var="viewcontrollerBundle"
    value="#{adfBundle['.main.view.ViewControllerBundleMain']}"/>
    <af:panelGroupLayout id="pgl1" layout="vertical">
    <af:panelBox text="#{sessionScope.OrgMeniuId eq 920 ? viewcontrollerBundle.1 : viewcontrollerBundle.2}"
    id="pb1" styleClass="AFStretchWidth"
    binding="#{backing_doc.pb1}">
    <f:facet name="toolbar"/>
    <af:tree value="#{bindings.DocVO2.treeModel}" var="node"
    selectionListener="#{bindings.DocVO2.treeModel.makeCurrent}"
    rowSelection="single" id="t1" binding="#{backing_doc.t1}"
    fetchSize="-1" styleClass="AFStretchWidth"
    inlineStyle="font-size:small;">
    <f:facet name="nodeStamp">
    <af:group id="g1" binding="#{backing_doc.g1}">
    <af:commandLink id="cl1"
    text="#{node.Desc}#{node.DescOp}"
    action="#{backing_doc.ActionIdLink}"
    actionListener="#{backing_doc.discloseItem}"
    binding="#{backing_doc.cl1}" immediate="true"
    partialTriggers="::pb1">
    <af:setActionListener from="#{node.IdOp != null ? node.IdOp : node.Id}"
    to="#{sessionScope.backing_doc.actionId}"/>
    <f:attribute name="node" value="#{node}"/>
    <af:setActionListener from="#{node.IdOp != null ? node.DescOp : node.Desc}"
    to="#{sessionScope.OrgDocDesc}"/>
    <af:clientListener method="onDownload" type="action"/>
    </af:commandLink>
    <af:resource type="javascript">
    function onDownload(evt){ evt.noResponseExpected(); }
    </af:resource>
    </af:group>
    </f:facet>
    </af:tree>
    </af:panelBox>
    </af:panelGroupLayout>
    </af:panelGroupLayout>
    </jsp:root>

  • Af:tree with command link

    hi experts,
    am using jdeveloper 11g version 11.1.1.5.0 - adfbc components - oracle db 10g.
    am trying some examples regards,
    af:tree with commandLink,
    here what i did:
    i achieved the af:tree with the help of some association between two tables and then i exposed in ui,
    you can see in this pics1 :
    http://www.4shared.com/photo/kGE2M1yl/pics1.html
    and then af:tree output can also seen in pics2:
    http://www.4shared.com/photo/GQTB9icb/pic2.html
    this is the code for af:tree
    <af:tree value="#{bindings.ApplBusFunSuiteView1.treeModel}"
                         var="node"
                         selectionListener="#{bindings.ApplBusFunSuiteView1.treeModel.makeCurrent}"
                         rowSelection="single" binding="#{backing_untitled1.t1}"
                         id="t1">
                  <f:facet name="nodeStamp">
                     <af:outputText value="#{node}"
                                     binding="#{backing_untitled1.ot1}" id="ot1"/>
                  </f:facet>
                </af:tree>ok thing which i did all are ok.
    but my need is :
    you may see in pics2.
    http://www.4shared.com/photo/GQTB9icb/pic2.html
    i make red mark on the on a child.
    here am going to explain my need
    in the picture you can see CRM as parent
    MKG as first child
    MKG3200 as last child.
    command link should be appeared.
    when i click that it will navigate to the corresponding page.
    for eg: if i click MKG3200 navigate to the MKG3200 page.
    how can i do this.? i need some guidance.
    sorry for my poor english.
    Edited by: Erp on Dec 1, 2011 4:34 AM

    hi am waiting for john
    retrieves the page IDhere the author get the node id.
    in my task n get the page id and navigate to it. as you said.
    http://andrejusb.blogspot.com/search/label/Tree
    thanks to andrejus and you(john)
    package view.backing;
    import java.util.Iterator;
    import java.util.List;
    import javax.el.ELContext;
    import javax.el.ExpressionFactory;
    import javax.el.MethodExpression;
    import javax.faces.application.Application;
    import javax.faces.application.FacesMessage;
    import javax.faces.context.FacesContext;
    import oracle.adf.controller.TaskFlowId;
    import oracle.adf.view.rich.component.rich.RichDocument;
    import oracle.adf.view.rich.component.rich.RichForm;
    import oracle.adf.view.rich.component.rich.data.RichTree;
    import oracle.adf.view.rich.component.rich.fragment.RichRegion;
    import oracle.adf.view.rich.component.rich.input.RichInputText;
    import oracle.adf.view.rich.component.rich.layout.RichPanelGroupLayout;
    import oracle.adf.view.rich.component.rich.layout.RichPanelSplitter;
    import oracle.adf.view.rich.component.rich.nav.RichCommandButton;
    import oracle.adf.view.rich.component.rich.nav.RichCommandLink;
    import oracle.adf.view.rich.component.rich.output.RichMessages;
    import oracle.jbo.Row;
    import oracle.jbo.uicli.binding.JUCtrlHierBinding;
    import oracle.jbo.uicli.binding.JUCtrlHierNodeBinding;
    import org.apache.myfaces.trinidad.component.UIXGroup;
    import org.apache.myfaces.trinidad.event.AttributeChangeEvent;
    import org.apache.myfaces.trinidad.event.SelectionEvent;
    import org.apache.myfaces.trinidad.model.CollectionModel;
    import org.apache.myfaces.trinidad.model.RowKeySet;
    import org.apache.myfaces.trinidad.model.TreeModel;
    public class Main1 {
        private RichForm f1;
        private RichDocument d1;
        private RichTree t1;
        private RichMessages m1;
        private RichCommandLink ot1;
        private String taskFlowId = "/WEB-INF/dummy-task-flow-definition.xml#dummy-task-flow-definition";
        private RichRegion r1;
        private UIXGroup g1;
        private RichCommandLink cl1;
        private RichPanelSplitter ps1;
        private RichPanelGroupLayout pgl1;
        private RichInputText it1;
        private RichCommandButton cb1;
        private String i1;
        public void setF1(RichForm f1) {
            this.f1 = f1;
        public RichForm getF1() {
            return f1;
        public void setD1(RichDocument d1) {
            this.d1 = d1;
        public RichDocument getD1() {
            return d1;
        public void setT1(RichTree t1) {
            this.t1 = t1;
        public RichTree getT1() {
            return t1;
        public void setM1(RichMessages m1) {
            this.m1 = m1;
        public RichMessages getM1() {
            return m1;
        public void setOt1(RichCommandLink ot1) {
            this.ot1 = ot1;
        public RichCommandLink getOt1() {
            return ot1;
        public TaskFlowId getDynamicTaskFlowId() {
            return TaskFlowId.parse(taskFlowId);
        public void setR1(RichRegion r1) {
            this.r1 = r1;
        public RichRegion getR1() {
            return r1;
        public String dynaminflow()
             taskFlowId = "/WEB-INF/supplier-task-flow-definition.xml#supplier-task-flow-definition";
              return null;
        public String mainflow1()
                taskFlowId = "/WEB-INF/dummy-task-flow-definition.xml#dummy-task-flow-definition";
              return null;
        public void setG1(UIXGroup g1) {
            this.g1 = g1;
        public UIXGroup getG1() {
            return g1;
        public void setCl1(RichCommandLink cl1) {
            this.cl1 = cl1;
        public RichCommandLink getCl1() {
            return cl1;
        public void setPs1(RichPanelSplitter ps1) {
            this.ps1 = ps1;
        public RichPanelSplitter getPs1() {
            return ps1;
        public void setPgl1(RichPanelGroupLayout pgl1) {
            this.pgl1 = pgl1;
        public RichPanelGroupLayout getPgl1() {
            return pgl1;
        public void setIt1(RichInputText it1) {
            this.it1 = it1;
        public RichInputText getIt1() {
            return it1;
        public void setCb1(RichCommandButton cb1) {
            this.cb1 = cb1;
        public RichCommandButton getCb1() {
            return cb1;
        public void setI1(String i1) {
            this.i1 = i1;
        public String getI1() {
            return i1;
        public String cb1_action() {
            // Add event code here...
          if(this.getI1().equalsIgnoreCase("SUP1000")  ) {
                         dynaminflow();
          else  if(this.getI1().equalsIgnoreCase("MAIN1000")  ) {
                               mainflow1();
          else{
                    FacesContext ctx = FacesContext.getCurrentInstance();
                    FacesMessage fm =
                        new FacesMessage(FacesMessage.SEVERITY_ERROR, "Page Not found",
                    ctx.addMessage(null, fm);
                    return null;
            return null;
        public void onTreeSelect(SelectionEvent selectionEvent) {
         /*   //original selection listener set by ADF
            //#{bindings.allDepartments.treeModel.makeCurrent}
            String adfSelectionListener = "#{bindings.ApplBusFunSuiteView2.treeModel.makeCurrent}";
            //make sure the default selection listener functionality is preserved.
            //you don't need to do this for multi select trees as the ADF binding
            //only supports single current row selection
            /* START PRESERVER DEFAULT ADF SELECT BEHAVIOR */
           /* FacesContext fctx = FacesContext.getCurrentInstance();
            Application application = fctx.getApplication();
            ELContext elCtx = fctx.getELContext();
            ExpressionFactory exprFactory = application.getExpressionFactory();
            MethodExpression me = null;
            me =  exprFactory.createMethodExpression(elCtx, adfSelectionListener, Object.class, new Class[] { SelectionEvent.class });
            me.invoke(elCtx, new Object[] { selectionEvent });
            /* END PRESERVER DEFAULT ADF SELECT BEHAVIOR */
          //  RichTree tree = (RichTree)selectionEvent.getSource();
          //  TreeModel model = (TreeModel)tree.getValue();
            //get selected nodes
         //   RowKeySet rowKeySet = selectionEvent.getAddedSet();
         //   Iterator rksIterator = rowKeySet.iterator(); */
            //for single select configurations, thi sonly is called once
         /*   while (rksIterator.hasNext())
                List key = (List)rksIterator.next();
                JUCtrlHierBinding treeBinding = null;
                CollectionModel collectionModel = (CollectionModel)tree.getValue();
                treeBinding = (JUCtrlHierBinding)collectionModel.getWrappedData();
                JUCtrlHierNodeBinding nodeBinding = treeBinding.findNodeByKeyPath(key);
                Row rw = nodeBinding.getRow();
                System.out.println(""+nodeBinding.getRow()); */
                //print first row attribute. Note that in a tree you have to determine the node
                //type if you want to select node attributes by name and not index           
            /*    String rowType = rw.getStructureDef().getDefName();
                System.out.println(""+rw.getStructureDef().getDefName());
                if(rowType.equalsIgnoreCase("SuplrDocHdView")){
                    System.out.println("This row is a department: " + rw.getAttribute("SuphdBu"));
                else if(rowType.equalsIgnoreCase("EmployeesView")){
                 System.out.println("This row is an employee: " + rw.getAttribute("EmployeeId"));
                else{
                    System.out.println("Huh ????");
                // ... do more usefuls stuff here
            RowKeySet selection = this.getT1().getSelectedRowKeys();
            if (selection != null && selection.getSize() > 0) {
                for (Object facesTreeRowKey : selection) {
                    this.getT1().setRowKey(facesTreeRowKey);
                    JUCtrlHierNodeBinding root = (JUCtrlHierNodeBinding) this.getT1().getRowData();
                    JUCtrlHierNodeBinding node = this.getFirstChild(root);
                    while (node != null)
                        System.out.println(node.getRow().getAttribute(0));
                        if(node.getRow().getAttribute(0).toString().equalsIgnoreCase("APM2010") )
                            dynaminflow();
                        else  if(node.getRow().getAttribute(0).toString().equalsIgnoreCase("APM2020")  ) {
                                             mainflow1();
                        //node.getRow().remove();
                        if ( node.getChildren() != null) {    
                            node = this.getFirstChild(node);
                        } else {
                            while (this.getNextSibling(node) == null && node != root)
                                node=node.getParent();
                            if(node != root) {
                                node = this.getNextSibling(node);
                            } else {
                                node = null;
                    System.out.println(root.getRow().getAttribute(0));
                    if(root.getRow().getAttribute(0).toString().equalsIgnoreCase("APM2010")  )
                        dynaminflow();
                    else  if(root.getRow().getAttribute(0).toString().equalsIgnoreCase("APM2020")  ) {
                                         mainflow1();
                    //root.getRow().remove();
        private JUCtrlHierNodeBinding getFirstChild(JUCtrlHierNodeBinding node) {
            if (node.getChildren() != null) {
                return (JUCtrlHierNodeBinding)node.getChildren().get(0);
            return null;
        private JUCtrlHierNodeBinding getNextSibling(JUCtrlHierNodeBinding node) {
            JUCtrlHierNodeBinding parent = node.getParent();
            int index = parent.getChildren().indexOf(node);
            index = ++index;
            if(index < parent.getChildren().size()) {
                return (JUCtrlHierNodeBinding)parent.getChildren().get(index);
            return null;       
    }i get my output. what i need.
    you must check whether am going correct?
    please suggest me.
    sorry : pulling this thread to up.

  • [SOLVED] Multiple Dynamic View Objects and View Links - ADF Tree Table

    Hi all,
    I've got a method that creates 3 dynamic viewobjects using this:
                ViewDefImpl Level1ViewDef = new ViewDefImpl("Level1View");
                Level1ViewDef.addViewAttribute("LevelDescription","LEVEL1_DESCRIPTION",String.class);
                Level1ViewDef.addViewAttribute("SetOfBooksId","SET_OF_BOOKS_ID",Number.class);
                Level1ViewDef.addViewAttribute("CodeCombinationId","CODE_COMBINATION_ID",Number.class);
                Level1ViewDef.addViewAttribute("Level1","LEVEL1",String.class);
                Level1ViewDef.addViewAttribute("AccountType","ACCOUNT_TYPE",String.class);
                Level1ViewDef.addViewAttribute("PeriodYear","PERIOD_YEAR",Number.class);
                Level1ViewDef.addViewAttribute("PeriodNum","PERIOD_NUM",Number.class);
                Level1ViewDef.addViewAttribute("PeriodName","PERIOD_NAME",String.class);
                Level1ViewDef.addViewAttribute("PtdActual","PTD_ACTUAL",Number.class);
                Level1ViewDef.addViewAttribute("YtdActual","YTD_ACTUAL",Number.class);
                Level1ViewDef.addViewAttribute("LtdActual","LTD_ACTUAL",Number.class);
                Level1ViewDef.addViewAttribute("BudgetName","BUDGET_NAME",String.class);
                Level1ViewDef.addViewAttribute("BudgetVersionId","BUDGET_VERSION_ID",Number.class);
                Level1ViewDef.addViewAttribute("PtdBudget","PTD_BUDGET",Number.class);
                Level1ViewDef.addViewAttribute("YtdBudget","YTD_BUDGET",Number.class);
                Level1ViewDef.addViewAttribute("LtdBudget","LTD_BUDGET",Number.class);
                Level1ViewDef.addViewAttribute("EncumbranceType","ENCUMBRANCE_TYPE",String.class);
                Level1ViewDef.addViewAttribute("EncumbranceTypeId","ENCUMBRANCE_TYPE_ID",Number.class);
                Level1ViewDef.addViewAttribute("PtdCommitment","PTD_COMMITMENT",Number.class);
                Level1ViewDef.addViewAttribute("YtdCommitment","YTD_COMMITMENT",Number.class);
                Level1ViewDef.addViewAttribute("LtdCommitment","LTD_COMMITMENT",Number.class);
                Level1ViewDef.setQuery(sql_level1);
                Level1ViewDef.setFullSql(true);
                Level1ViewDef.setBindingStyle(SQLBuilder.BINDING_STYLE_ORACLE_NAME);
                Level1ViewDef.resolveDefObject();
                Level1ViewDef.registerDefObject();
                ViewObject vo1 = createViewObject("Level1View",Level1ViewDef);I can create the view objects fine and create a single viewlink between two of them, however i'm getting problems with 2 view links.
    This is how I'm creating a view link:
                ViewLink Level2Level1FKLink = createViewLinkBetweenViewObjects("Level2Level1FKLink1",
                                                        "Level2View",
                                                        vo1,
                                                        new AttributeDef[]{
                                                          vo1.findAttributeDef("Level1")
                                                        vo2,
                                                        new AttributeDef[]{
                                                          vo2.findAttributeDef("Level1")
                                                        "LEVEL1 = :Bind_Level1");
                ViewLink Level3Level2FKLink = createViewLinkBetweenViewObjects("Level3Level2FKLink1",
                                                        "Level3View",
                                                        vo2,
                                                        new AttributeDef[]{
                                                          vo2.findAttributeDef("Level2")
                                                        vo3,
                                                        new AttributeDef[]{
                                                          vo3.findAttributeDef("Level2")
                                                        "LEVEL2 = :Bind_Level2");I can get the data to display on an adf tree table if i'm only using a single view link, but when i try and implement 2 view link (for 3 levels on the adf tree table) i'm getting problems displaying the data.
    I'm getting the following error:
    Aug 10, 2007 2:44:39 PM oracle.adfinternal.view.faces.renderkit.core.xhtml.PanelPartialRootRenderer encodeAll
    SEVERE: Error during partial-page rendering
    oracle.jbo.NoDefException: JBO-25058: Definition Level3View of type Attribute not found in Level2View_Level2Level1FKLink1_Level2ViewThe thing is, Level3View isn't in the Level2Level1FKLink viewlink.
    I've been reading about something similar here
    BC4J Master-Detail-Detail
    but I am still unsure of what the problem is.
    Thanks in advance.

    I found the answer here:
    http://radio.weblogs.com/0118231/stories/2004/06/10/correctlyImplementingMultilevelDynamicMasterDetail.html

  • ADF command link problem

    Hi All,
    I am using Jdeveloper 11g. I have a master-detail relationship tables Order and OrderItem. I have an Order edit page which has editable Order information and a ADF read-only table which contains a list of items associated with the current order. I have a ADF command link on the column LineItemId in the table. When I click the link, it will take me to the item edit page. The problem is, whenever I select any item in the table, I always got the first item loaded in the item edit page. Does anyone has any ideas what I did wrong?
    Here is the portion of the code related to the command link,
    <af:column sortProperty="LineItemId" sortable="false"
    headerText="#{bindings.OrderItemsView2.hints.LineItemId.label}"
    id="c4">
    <af:commandLink actionListener="#{bindings.setCurrentRowWithKeyValue.execute}"
    text="#{row.LineItemId}"
    disabled="#{!bindings.setCurrentRowWithKeyValue.enabled}"
    id="cl1" partialTriggers="::t1"
    action="goOrderItemDetail"/>
    </af:column>
    Thanks in advance,
    John
    Edited by: john wang on Aug 20, 2009 7:31 AM

    Hi Gurus,
    On a seeded page say Page1 one link is availabe which is specific to one Learning Path.
    When i click on that Learning Path's link it is redirecting me to a page say Page2 where it gives the list of different Learning Paths (including Learning Path of Page1) with a link for each Learning Path.
    If i click on that Learning Path's link it takes me to a page say Page3 where it gives the details of that perticular Learning Path.
    The requirement is , If I click on an Learning Path's link on Page1 ,it should redirect me directly to Page3 ( Skipping Page2 ).
    How can it be achieved?
    Please help!!!
    Thanks,
    Srinivas
    Edited by: ChandaS on Aug 20, 2009 8:02 AM
    Edited by: ChandaS on Aug 20, 2009 8:14 AM

  • COMMAND LINKS IN TREE TABLE DOESN'T ALLOW CONTEXT MENU TO SHOW UP

    I have a tree table with some columns, the "nodeStamp" facet has a column
    which has the tree with an image and a command link. when i try bringing up
    the context menu from anywhere on the table including the image the context
    menu comes up fine. But when i try bringing up the context menu from the
    command link it doesn't show/come up. Also it doesn't throw up any exception.
    I have my code used as shown below.
    Can anyone please let me know what could be the problem?
    <af:treeTable var="step" id="lpexec34" rowBandingInterval="0"
    columnStretching="blank" width="100%"
    value="#{pageFlowScope.loadPlanExecutionDetailBean.relationships.loadPlanSteps
    binding="#{pageFlowScope.loadPlanExecutionDetailBean.richTreeTable}"
    initiallyExpanded="true">
    <f:facet name="contextMenu">
    <af:popup id="lpeStepsPopup" contentDelivery="lazyUncached">
    <af:setPropertyListener
    from="#{pageFlowScope.loadPlanExecutionDetailBean.relationships.loadPlanSteps.
    rowData}"
    to="#{rowStepData}"
    type="popupFetch"/>
    <af:menu id="lpeStepsContextMenu">
    <af:commandMenuItem text="#{bundle.mark_as_complete}"
    id="cmei0b"
    actionListener="#{pageFlowScope.loadPlanExecutionDetailBean.actionPerformed}"
    rendered="#{rowStepData.markAsCompleteRendered}">
    <f:attribute name="lpiStepLog"
    value="#{step.loadPlanInstanceStepLog}"/>
    <f:attribute name="loadPlanInstance"
    value="#{step.loadPlanInstance}"/>
    </af:commandMenuItem>
    </af:menu>
    </af:popup>
    </f:facet>
    <f:facet name="nodeStamp">
    <af:column headerText="#{bundle.lp_steps_header_stepsHierarchy}"
    id="loadPlanexecDetail_hierarchy">
    <af:panelGroupLayout id="pledetail_pg10">
    <af:image source="/resources/images/loadplan/#{step.elementType}.png"
    inlineStyle="margin-right:3px; vertical-align:middle; height:16px;
    width:16px;"/>
    <af:commandLink id="lpcl0_lpe" text="#{step.name}"
    action="#{pageFlowScope.loadPlanExecutionDetailBean.relationships.stepClicked}
    ">
    <af:setPropertyListener from="#{step}"
    to="#{pageFlowScope.lpElement}" type="action"/>
    </af:commandLink>
    </af:panelGroupLayout>
    </af:column>
    </f:facet>

    Hi,
    try setting partialSubmit=true on the command link. Just in case it fires the action method before the context menu displays
    Frank

  • Adding to a Linked Complete Binary Tree

    Hi all,
    I am having major trouble trying to grasp the concept behind adding to a Complete Binary Tree (linked structure). It is part of a much larger assignment that uses a Heap Priority Queue and I am genuinely stuck. I have noticed that there seems to be some sort of strike going on so I wont expect a reply to this.
    I understand that Binary Tree's are useful because of their recursive nature, does the process of adding use recursion also. My mind is a mess at the moment so forgive the rambling. My problem exists when I go to add after a right child on a lower level(anything below level 3). I have come to the conclusion that I it is impossible to continue with my adding method and that I should scrap it. Can anyone point anything relevant out to me? I'd appreciate it, thank you.
    public class LinkedBT implements CompleteBT
         private BTNode root;          //a reference to the root node
         private BTNode current;          //a reference to the last inserted node
         private BTNode firstNodeInLevel; //a reference to the first node in the level
         private int size;               //keeps track of the size of the BT
         private int currentLevel;
         private int leafCount;
         public LinkedBT()
              root = null;     //instantiate instance variables
              current = null;
              size = 0;
              currentLevel = 0;     //indicates that there are no nodes
              leafCount = 0;
              firstNodeInLevel = null;
         public boolean isEmpty()     
              return (root==null);
         public int size()
              return size;
         public void add(Object obj, int priority)
              BTNode tempNode = new BTNode(obj, priority);
              tempNode.parent = current;                                   //set the parent of the node to current
              if(isEmpty())                                             //if the tree is empty then make a new BTNode and give it the root reference
                   root = tempNode;     
                   current = root;                                        //make current reference to the root node
                   size++;
                   currentLevel++;                //increments currentLevel
                   return;                          //return control to calling method
              if(current.childrenFull!=true)          //if the current node has available children positions then check left and right and add BTNode appropriately
                   if(current.leftChild==null)
                        if(leafCount==0)     //if this is the first node to be added on any given level then.....
                             firstNodeInLevel = tempNode;     //.....store a reference to it for future adding purposes
                        current.leftChild = tempNode;     //adds BTNode to left child
                        leafCount++;
                   else
                        current.rightChild = tempNode;          //add BTNode to right child
                        leafCount++;
                        current.childrenFull = true;          //after adding the right child set the childrenFull property true NECESSARY?????
                        if(Math.pow(2, currentLevel)==leafCount)     //IF THIS EVALS TO TRUE THEN THE MAX NUMBER OF LEAVES FOR THAT LEVEL IS REACHED
                             currentLevel++;     //increment the level
                             leafCount = 0;     //reset the leaf count
                             current = firstNodeInLevel;          //change current to the furthest leaf on the left
                        else     //ELSE NEED TO GO BACK UP AND FIND NEXT FEASIBLE POSITION
                             //while(current.parent.rightChild.leftChild.)----------------THIS DOESNT WORK WHEN THE TREE GETS BIGGER
                                  //current = current.parent; //set current to next feasible position
              size++;
         public Object getRoot()
              return root;
         public void heapSort()
         private class BTNode
              private Object value;
              private int key;
              private BTNode parent;
              private BTNode leftChild;
              private BTNode rightChild;
              private boolean childrenFull;      //initially false, when both children are occupied then change to true
              private BTNode(Object obj, int priority)     //constructor accepts the value and the priority key
                   value = obj;          
                   key = priority;
                   parent = null;
                   leftChild = null;
                   rightChild = null;
                   childrenFull = false;
              public boolean hasNoChildren()
                   return(leftChild==null && rightChild==null);     //returns true if the node has no children
    }

    Currently working on setting the Linked Servers Security properties. Added the SQLAgent in the" Local server login to remote server login mappings:". The SQLAgent is the only entry in the grid. The SQLAgent has the Remote User and Remote Password
    of the AS400. Then below have "Not be made" for "For a login not defined in the lst above, connections will:".
    So provided that the SQL Admin only gives SQL Job create, Job Alter and Alter Linked Server to user/groups that he wants to use the linked server the Admin can control access to the linked server.
    Any thoughts?

  • Confusion in ADF command link settings - *URGENT* pls help

    Hi All,
    I have a table named 'Action' in which, the first column is ActionId. I have turned the first column into a command link. On clicking this link, it will show a popup in which i can see the current action details.
    My code is as below.
    <af:table value="#{bindings.OePdActionView1.collectionModel}"
    var="row"
    rows="#{bindings.OePdActionView1.rangeSize}"
    emptyText="#{bindings.OePdActionView1.viewable ? 'No data to display.' : 'Access Denied.'}"
    fetchSize="#{bindings.OePdActionView1.rangeSize}"
    rowBandingInterval="0"
    filterModel="#{bindings.OePdActionView1Query.queryDescriptor}"
    queryListener="#{bindings.OePdActionView1Query.processQuery}"
    filterVisible="true" varStatus="vs"
    rowSelection="multiple" id="ActionTable"
    inlineStyle="color:Blue;" width="1000"
    partialTriggers="::RulesTable ::SaveButton ::deleteActionButton ::cb11 ::cb3 ::cb2"
    selectionListener="#{bindings.OePdActionView1.collectionModel.makeCurrent}">
    <af:column sortProperty="Actionid" filterable="true"
    sortable="true"
    headerText="#{bindings.OePdActionView1.hints.Actionid.label}"
    id="c16" width="105"
    inlineStyle="background-color:rgb(255,185,185);">
    <!-- required="#{bindings.OePdActionView1.hints.Actionid.mandatory}" -->
    *<af:commandLink text="#{row.bindings.Actionid.inputValue}" id="cl3">*
    <af:popup id="p3">
    <af:outputText value="Selected Action Details"
    id="ot26"
    inlineStyle="font-weight:bold; color:Blue;"/>
    <af:panelLabelAndMessage label="#{bindings.Actionid.hints.label}"
    id="plam18">
    <af:outputText value="#{bindings.Actionid.inputValue}"
    id="ot25"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Parentruleid.hints.label}"
    id="plam19">
    <af:outputText value="#{bindings.Parentruleid.inputValue}"
    id="ot15"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Actiontypecode1.hints.label}"
    id="plam14">
    <af:outputText value="#{bindings.Actiontypecode1.inputValue}"
    id="ot22"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Targetentitytype.hints.label}"
    id="plam17">
    <af:outputText value="#{bindings.Targetentitytype.inputValue}"
    id="ot17"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Targetentitysubtype.hints.label}"
    id="plam11">
    <af:outputText value="#{bindings.Targetentitysubtype.inputValue}"
    id="ot16"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Legacytargetid.hints.label}"
    id="plam20">
    <af:outputText value="#{bindings.Legacytargetid.inputValue}"
    id="ot18"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Legacytargetsubid.hints.label}"
    id="plam13">
    <af:outputText value="#{bindings.Legacytargetsubid.inputValue}"
    id="ot21"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Legacyparentid.hints.label}"
    id="plam12">
    <af:outputText value="#{bindings.Legacyparentid.inputValue}"
    id="ot23"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Versionnumber.hints.label}"
    id="plam16">
    <af:outputText value="#{bindings.Versionnumber.inputValue}"
    id="ot19">
    <af:convertNumber groupingUsed="false"
    pattern="#{bindings.Versionnumber.format}"/>
    </af:outputText>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Deletedflag.hints.label}"
    id="plam10">
    <af:outputText value="#{bindings.Deletedflag.inputValue}"
    id="ot20"/>
    </af:panelLabelAndMessage>
    <af:panelLabelAndMessage label="#{bindings.Seq.hints.label}"
    id="plam15">
    <af:outputText value="#{bindings.Seq.inputValue}"
    id="ot24"/>
    </af:panelLabelAndMessage>
    </af:popup>
    *<af:showPopupBehavior popupId="p3" triggerType="action"/>*
    </af:commandLink>
    </af:column>
    Now the problem is , I have a 'Create new Action' button , click on which , I can insert a new row to the 'Action' table. Since i have converted this 'ActionId' column into a command link, i couldnt enter any value in the newly created row. Whereas i can give values for the other columns and save the changes.
    Please tell me some idea, so that i could use the 'Actionid' field as command link and also support editing operations.
    Thanks in advance,
    Sabarisri. N

    Can i have one more issue..
    Its like..
    In the Actions Table, i have set my 'Actionid' column as mandatory.
    So when i click on 'create new row' button , it creates a new row. Whereas suppose if i wish to delete that row without entering any value, then its asking for some value to be entered in the mandatory field.
    So i wish to change the 'mandatory' property of that column at runtime, when the 'delete' button is clicked. So that viewObject.removeCurrentRow() will be done. Then again.. in the next statement, i wil reset the mandatory to true. pls see my code below.
    DCControlBinding cb =
    (DCControlBinding)getBindings().get("OePdActionView1");
    ViewObject vo = cb.getViewObject();
    // vo.<someSetHintForMandatory>("false");
    vo.removeCurrentRow();
    // vo.<someSetHintForMandatory>("false");
    This is my idea to solve the pbm. Please help me if there is some other solution. Or else, kindly tell me the way to change the 'mandatory' property at runtime.
    Thanks,
    Sabarisri. N

  • Adding an ADF Tree to an ADF Shuttle

    Does anyone know if there is a way to attach and ADF tree to a shuttle? So in the shuttle, instead of a list, I have a heirarchy of data I want to choose from.
    Thanks in advance.

    Referring to a few posts just to give you an idea people have not really managed to get it to work (You can try replying to these posts to see if they got a solution!) -
    https://kr.forums.oracle.com/forums/thread.jspa?threadID=916324
    Embedding tree in select many shuttle
    ADF Tree and Shuttle

Maybe you are looking for

  • How to spool file with a timestamp/seq_number in the file name

    Hi I try to write a test script that will have some kind of timestamp or seq_number in the spool output file's filename itself. so e.g. test_abc_20120425161616.txt I can do it on shell but is there a way I can do it all in sqlplus. I recall I see som

  • How do I get google contacts to actually sync in 10.9.2

    With a recent upgrade to an iPhone 5S, and consequent upgrade of the system on my iMac & laptop to 10.9.2 I cannot figure out how to get my Gmail contacts to sync with my phone, computer and iCloud. Correct me if I'm wrong, but it appears that: 1. th

  • SFTP using File Adapter 10.1.3.4

    I have installed the Cygwin in my windows machine and I am able to connect to my machine using WINSCP. We are using the FTP Adapter to connect to a SFTP Server. The Adapter has the properties      <connector-factory location="eis/Ftp/XXFtp" connector

  • Javacard.security and message SW1: 64, SW2: 44

    Hi, I have problem with initialization of my DES Keys in applet constructor. Firstly I declare a member variable for the keys like private DESKey desKey; private DESKey des3Key;Secondly, I initialize them desKey = (DESKey) KeyBuilder.buildKey(KeyBuil

  • Line-in mic for new iMac.

    I'm like 2-days new to mac-using so stay with me here. I just got the new iMac 24" 2.4ghz. I'm having a hard time getting my Logitech standard-in (non-USB) mic to work. The headphones work while plugged in, but the mic doesn't seem to be working. I c