Extending VOs with attributes and creating new treetable columns

Hi,
I am relatively new to the ADF scene so please bear with if what I have in my mind is not even possible with ADF. I have searched hi and lo for a solution and now I thoughts it time to ask the community.
Anyways this is what I want to do. I have a simple DB Table that has a hierarchy i.e Trees with roots much like the Employee hierarchy. Except this table has ids for items that come from external systems ( via Web Services in my case ) and / or ids to items in a table that resides in the local schema. So basically this structure table of mine only has relationships and the detail items need to be joined via an association ( in ADF terminology ) in the treetable component somehow.
* Now creating the structure hierarchy is not a big issue. I have that part done already.
* I have the VO from WS ready that gets the items that I might need to show as detail columns in the tree table.
* Querying the local item Detail VO for detail rows might also be not that problematic.
* Merging the above 2 columns to create a consolidated row set is also not that challenging whereby each column header is premapped to internal and external fields. This mapping is configurable to add more fields as required by a user to the treetable.
What I am struggling with is that when I have this merged row set, how will I make it appear on the UI. The treetable seems to utterly not support this i.e. adding new columns at runtime. Following is what I have been able to establish till now.
* The addDynamicAttribute methods on the View Object are not meant for this purpose. While they do add the attributes and you can set and get them after using this method, they do not render and I can't find a way to dynmically rendering them somehow for tree table.
* Looked at the ADF dynamic components. They support only table and page. No go. Or do the whole tree thing somehow in the table component, Will look odd but might still work.
* Looked at this article ( http://one-size-doesnt-fit-all.blogspot.com/2007/05/back-to-programming-programmatic-adf.html ) . I found a comment in the forum regarding this that this might not be all that efficient. Not to mention the fact that it uses the deprecated TreeModels class in 11g.
** Just regarding this apporach what are the new 11g recommended TreeModel classes to be used instead of the deprecated one. I have read the follow-up post but that just points to the location of where the deprecated classes moved to in 11g under the apache contribution. And makes the example work under 11g. What was this TreeModel class replaced with. Anyone knows ?
** How could I access my VO objects in the TreeTableApater ? Can I declare my merged View object wrapped in a TreeItem POJO object. Theoretically it is on the view layer right ?
** If this approach is inefficient has anyone another solution that might work ?
Or just has anyone managed to extend the treetable in any different sort of way. Any tips/help pointers would be deeply appreciated.
Best Regards,

Hi,
So I had some time to look at this problem again. I created a ChildPropertyTreeModel and binded it to my treetable component and moved the generation of the columns to the jspx page. I got it mostly working but the columns generation part mostly escapes me still.
here is how the jspx page looks like that renders the treetable, and which works fine :
<af:treeTable rowBandingInterval="0" id="dynTTbl" var="row" expandAllEnabled="true"
binding="#{backingBeanScope.DynamicTreeTableBB.dynamicTreeTable}"
value="#{backingBeanScope.DynamicTreeTableModel}">
<f:facet name="nodeStamp">
<af:column sortable="false" headerText="Node Stamp" id="c1">
<af:outputText value="#{row.tableColumnVal[0]}" id="ot1"/>
</af:column>
</f:facet>
<af:forEach begin="1" end="2" varStatus="status">
<af:column>
<f:facet name="header">
<af:outputText value="#{status.index}"/>
</f:facet>
<af:inputText value="#{row.tableColumnVal[status.index]}"/>
</af:column>
</af:forEach>
</af:treeTable>
I want the forEach loop to look a bit differently like below :
<af:forEach items="row.tableColumnVal" var="columnVal" varStatus="status">
<af:column>
<f:facet name="header">
<af:outputText value="#{status.index}"/>
</f:facet>
<af:inputText value="#{columnVal}"/>
</af:column>
</af:forEach>
This should work for a list or array but evidently in my case it is not. I have a suspicion that the "items" attribute is unable to recognize the row.tableColumnVal attribute of mine. I have no way of checking this out or finding out if I am doing something wrong.
My sample project can be found here, if anyone quickly wants to run this on Jdev 11g
http://rapidshare.com/files/438880281/TreeTableTest.zip
P.S. I have tried to convert the tableColumnVal attribute to a List an array and a Map. The first forEach syntax works everytime but the second one fails always and I want the second one to work somehow.
Regards,

Similar Messages

  • Need help with opening and creating new card

    Does anyone know why when I try to create a new card, in PSE 6 that the file tries to open then shuts.  I have created cards before without any problem.  I don't know what has changed??????

    Does anyone know why when I try to create a new card, in PSE 6 that the file tries to open then shuts.  I have created cards before without any problem.  I don't know what has changed??????

  • What is the diffrence between extends and creating new object?

    HI ALL,
    what is the diffrence between extends and creating new object?
    meaning
    class base{
    class derived extends base{
    class base{
    class derived {
    derived(){
    base var = new base();
    can u people tell me diffence from the above examples.
    THANKS.
    ANANDA

    When you create a new object you have to supply the class to which that
    object belongs. A class can extend from another class. If it does so
    explicitly you can define the 'parent' class from which the class extends.
    If you don't explicitly mention anything, the class will implicitly extend
    from the absolute base class named 'Object'.
    Your example is a bit convoluted: when you create a Derived object,
    its constructor creates another object, i.e. an object from the class from
    which the Derived class extends.
    Extending from a class and creating an object don't have much in common.
    kind regards,
    Jos

  • I have a new email address. Changed this on my itunes account. On iPhone deleted old icloud account and created new with new email. I have set find my phone to on. When I download music it no longer goes to icloud an does not show up on my iphone.

    I have a new email address. Changed this on my itunes account. On iPhone deleted old icloud account and created new with new email. I have set find my phone to on. When I download music from itunes it no longer goes to icloud an does not show up on my iphone.

    I have the same problem - it is maddening. I rely on this iPad for work so this is not just an annoyance! The above solutions of changing the appleid on the device or on the website do not work.
    The old email address no longer exists - I haven't used it in a year probably and I no longer have the account.  I logged into the appleid website and there is no trace of the old email address so there is nothing that can be deleted or changed there.  On the iPad there is no trace of the old email address so nothing can be deleted there either. I have updated the iPad software and the same problem comes right back.  Every 2 seconds I am asked to log in using the old non-existent email.  The device is currently useless.
    The only recent change to anything was the addition of an Apple TV device, which was set up using the correct login and password.
    Does anyone have any ideas? The iPad has been backed up to the iCloud so presumably it now won't recognize the current iCloud account? So restoring may notbe an option?

  • How can I make the popup with empty fileds and create new record?

    I would like to use a popup to create new record.
    I created a af:popup by drag and drop a VO from data control to jsff. then, I created a button and place a af:showPopupBehavior. I was able to popup window by click the button.
    however, the window filled with the information from the 1st record. and when I select a record in table and click popup, the popup is filled with that record.
    How can I make the popup with empty fileds and create new record by saving the popup?
    Thanks

    You can have edit and new buttons, in the PopupFetchEvent identify button source (using popupFetchEvent.getLaunchSourceClientId()) if new button clicked clear the binding using below code.
    If you want to see empty fields, in the popup PopupFetchEvent clear the input component bindings.
    resetBindingValue("#{bindings.<componentid>.inputValue}", null);
        public static void resetBindingValue(String expression, Object newValue) {
            FacesContext ctx = FacesContext.getCurrentInstance();
            Application app = ctx.getApplication();
            ExpressionFactory elFactory = app.getExpressionFactory();
            ELContext elContext = ctx.getELContext();
            ValueExpression valueExp = elFactory.createValueExpression(elContext,expression,Object.class);
            Class bindClass = valueExp.getType(elContext);
            valueExp.setValue(elContext,newValue);
        }

  • With PS 7  create new  Place two objects on the new file  then you may cut copy and paste Cs2  create new  place two object on the new file Cut is not available how does one cut and paste in new file

    With PS 7
    create new
    Place two objects on the new file
    then you may cut copy and paste
    Cs2
    create new
    place two object on the new file
    Cut is not available how does one cut and paste in new file

    If your using File>Place then photoshop cs2 creates what's known as Smart Objects, which photoshop 7 didn't have.
    In photoshop cs2 you can rasterize the smart objects and that should make the Cut function available.
    Select both placed layers, right click on the area to the right of the tumbnail and select Rasterize Layers.
    If in photoshop cs2 you to Help>Photoshop Help and look under Layers>Smart Objects, that should give you a good overview of what smart objects are.

  • Copying home DVD videos, editing, and creating new DVDs

    Here is the situation:
    I have the 17" and this is my first Mac to own. I am computer literate with most my experience on Windows and Linux.
    That being said, I am trying to edit home videos; but they are already on DVDs. I got a LiteOn DVD/VCR combo recorder for my entertainment center. I have a camcorder that uses Hi-8 media and it is only able to use S-video/composite outputs (no USB or Firewire). I am using the LiteOn recorder to archive all my videos to DVDs because it has composite inputs. The LiteON has hardly any editing capability. So I want to take the "simple" DVDs I made, copy them to my HD, edit them (to cut out junk, create better menus, and give it as nice touch), and create new DVDs to distribute to my family and to get rid of old tapes.
    So in short, the process I want to do on the Mac is:
    1. Copy my family home DVDs
    2. Edit the video.
    3. Create more "creative" DVDs for my family.
    I have been looking around the website and reading posts and I don't see how to do this. I did try to create an image on disk utility, but it failed for whatever reason (maybe I am missing a step). How can I accomplish the three steps above?
    Please help.
    Thank you, Michael

    If these are true, standard video DVDs that the drive creates, there are a number of utilities that can extract and convert the videos for use in editing applications. A couple of utilities that people have reported success with are DVDxDV, Cinematize, and MPEG Streamclip (MPEG Streamclip is freeware but requires that you have Apple's QuickTime MPEG2 Playback Component), and there are no doubt others.
    Once extracted, you can use iMovie to edit the clips and iDVD to burn them to a new DVD. Then you can use Disk Image or a third-party application such as Roxio's Popcorn to make additional copies.
    Hope this helps.

  • Transfer assets collectively to new class and create new assets like ABUMN

    We need to change the account determination for a few Asset Classes that already have assets with postings.  As a result we must create new asset classes and assign a new account determination.
    Is there a program that would allow transfer assets collectively to a new asset class and create new assets automatically similar to ABUMN?  T-code ABUMN allows you to transfer multiple assets but you must create the new assets first.  ABUMN will transfer and create new asset but only does one asset at a time. 
    There are hundreds of assets with postings to be transferred from the old asset classes to the corresponding new asset classes.
    Appreciate whatever input you can provide.
    Tara

    download the asset master data(original) and create new asstes using lsmw or any third party tool also.

  • Reconfigure sales BOM deletes line item and creates new line item

    We are having issue with Sales BOM. Once sales BOM is reconfigure, line item is automatically deleted and creates new line item. These changes are not captured by reporting tool. Is it standard SAP behavior? if its not standard behavior, how to fix this issue?

    Hi,
    If i am not wrong, i assume you are using site instead of plant.   If it is plant , then "yes", we can have a order with same material being line item 10 and 20 with different plants.  Reg delivery, if the plants are configured to a same shipping point then you will have one delievery.  if the plants are configured for a different shipping point , then delivery will be split up.
    Reward if it helps,
    Thanks & regards,
    CLN

  • Dynamic Action-Delimiting a record and creating new record

    Hi ,
    My requirement is in dynamic Action I need to delimit all records in a Subtype of an Infotype and create New record for these records with BEGDA as ENDDA + 1 of the delimited records.
    Iam able to delimit all records in the Subtype but , Iam not able to create new records.
    My code for delimiting is as given below, in T588Z,
    9901     2          06     801     P     P9901-SUBTY='2'
    9901     2          06     802     P     PSYST-IOPER='MOD'
    9901     2          06     803     P     P9901-STATS='X'
    9901     2          06     804     P     P9901-PREAS='91'
    9901     2          06     805     F     DELIMIT_DTE(ZHSRAS_T588Z_9901)
    9901     2          06     806     W     P9901-ENDDA=RP50D-ZZDATE3
    9901     2          06     807     I     MOD,9901,3
    9901     3          06     808     P     SY-UCOMM='UPD'
    9901     3          06     809     F     DELIMIT_DTE(ZHSRAS_T588Z_9901)
    9901     3          06     810     W     P9901-ENDDA=RP50D-ZZDATE3
    The above code is working fine.
    My code for creating new record is as given below, even though the control is oing to the subroutine, INS statement is not working, and hence new record is not getting created.
    9901     3          06     811     P     SY-UCOMM='UPD'
    9901     3          06     812     P     PSAVE-ENDDA<>P9901-ENDDA
    9901     3          06     813     P     P9901-STATS<>'X'
    9901     3          06     814     I     INS,9901,3
    9901     3          06     815     F     BEGIN_DATE(ZHSRAS_T588Z_9901)
    9901     3          06     816     W     P9901-BEGDA=RP50D-ZZDATE3
    9901     3          06     817     W     P9901-ENDDA='99991231'
    Kindly help me on this.

    Hi shahana,
    1. I have not worked on this dynamic action.
    2. But instead of doing in 2 steps,
       it is usually done in 1 step only, manually.
    3. If we CREATE record from some date,
       then the OLD will AUTOMATICALLY get Delimited.
    (We don't have to do anything specially for delimiting
      the old record)
    regards,
    amit m.

  • Problem in Shrink my local disk C and create new partitions on it.

    I am trying to Shrink my local disk C (current boot volume) and create new partitions on it. But I am getting a Warning message that If I do so, I won't be able to boot from any volume excepet the the current boot Volume. 
    In case if I need to do the recovery for my computer what will happen. does it mean that I can't do the recovery from my hard disk?
    This question was solved.
    View Solution.

    Kaj_R wrote:
    I am trying to Shrink my local disk C (current boot volume) and create new partitions on it. But I am getting a Warning message that If I do so, I won't be able to boot from any volume excepet the the current boot Volume. 
    In case if I need to do the recovery for my computer what will happen. does it mean that I can't do the recovery from my hard disk?
    Hello Kaj_R.
    If you change the volumes it is quite likely that the recovery partition will not function.  I suggest you create a set of Recovery Media before messing with the partitions.
    This document can help you create the recovery media.
    Have a great day!
    Please click the white star under my name to give me Kudos as a way to say "Thanks!"
    Click the "Accept as Solution" button if I resolve your issue.

  • Id email address cancelled. how do I log in and create new password?

    id email address cancelled. how do I log in and create new password?

    This link tells you how to change your Adobe ID and password:
    http://helpx.adobe.com/x-productkb/policy-pricing/account-password-sign-faq.html
    And if it doesn't, there's a "Still Need Help?" link which leads you to web chat where you can talk with a person.

  • Error? on Example 16-7 XMLFOREST: Generating Elements with Attribute and Ch

    Error in example on page http://download-east.oracle.com/docs/cd/B19306_01/appdev.102/b14259/xdb13gen.htm#i1028612
    Example 16-7 XMLFOREST: Generating Elements with Attribute and Child Elements
    Example appears as
    SELECT XMLElement("Emp",
                      XMLAttributes(e.first_name ||' '|| e.last_name AS "name"),
                      XMLForest(e.hire_date, e.department AS "department"))
    AS "RESULT"
    FROM employees e WHERE e.department_id = 20;
    1. employees table not qualified as hr.employees
    2. e.department as "department" should be e.department_id as "department"
    corrected would be
    SELECT XMLElement("Emp",
                      XMLAttributes(e.first_name ||' '|| e.last_name AS "name"),
                      XMLForest(e.hire_date, e.department_id AS "department"))
    AS "RESULT"
    FROM hr.employees e WHERE e.department_id = 20;albert

    It was subreport-related, though I still do not know the exact root cause.
    I was having trouble with both the built-in export as well as a custom process.
    Removing the subreports as suggested, I isolated the failure to one of the three subs and rebuilt this subreport from scratch (it was only three fields) and now the report has no trouble with the pdf export. I am not sure if it had a resolvable technical issue or if it was just corrupted, as it is now working, I am not going to expend much energy on finding out.
    Thanks for the suggestion.

  • Does Production Premium CS6 work with Maverick and the new iMacs

    Does Production Premium CS6 work with Maverick and the new i Macs

    Thankx for your reply. I saw the Apple tech note but that's what Apple says. I just want to know from users who experienced the thing if it really works.
    It doesn't seem so simple if you believe what this site tells (sorry it's in French):
    http://www.macquebec.com/spip.php?article4146
    So: BootCamp worse than the Beta?

  • Forgot security questions, how do i delete old ones and create new ones

    forgot security questions on, how do i delete old ones and create new ones

    The following has instructions: If you forgot the answers to your Apple ID security questions

Maybe you are looking for

  • Scaning issue using iPhone AiO Remote app v4.3

    Following 4.3 update on iOS, scaning is no longer working using tray, the app conects to the scanner, it initiates the document feeder to scan, pages get scanned trough, but the application reports failure and displays message to check printers contr

  • Can I use a report item as a parameter in an html link.

    I have a report (build using the Query Wizard) that selects and shows data from a database on a seperate system (via a database link). The first column of the report gives an ID Number that I want to use as part of an html link to display the full de

  • How to retrieve the Line item Text

    Hello, I need to retrieve the Line item Text in the PO (Material PO text). Can anyone provide me a sample code? i need to display this in a smartform. I could not retrive it from the Function Module READ_TEXT. Can any one help me regarding this? Rega

  • IPhone 4S, AirPlay, and Apple TV conundrum

    So, the 4S records 1080p HD video, and you can stream these over AirPlay to your HD TV via Apple TV - but Apple TV only does 720p. Am I missing something here or does this mean that ATV will down-scale your 1080p videos to 720p (and then display them

  • Error Handling/Recovery Mechanism in ODI

    can u ps provide sum infor related to Error handling/recovery mechanism in ODI? say for instance a link breaks down while moving data from source to staging or/and staging to target..what will happen?? is it like that the processed records will be du