cancel
Showing results for 
Search instead for 
Did you mean: 

WebDynpro table cell - Master column

PradeepBondla
Active Contributor
0 Kudos

Hi All,

I followed the blog by VS (/people/valery.silaev/blog/2005/06/13/master-of-columns-part-i) to show the KM files and folders in webdynpro table cell. Everything is fine, I could able to show the table with KM files and folders ( recursive with Master Column).

where if the user clicks on the arrow icon, table rows will be extended and user can see select child nodes.

Now the requirement is, I want the same functionality when clicked on the file names also ( tree expansion). Presently its working fine when clicked on arrow icon. I need to have a link to folder names when clicked on folder name, it should expand the tree structure and show the child nodes.

How could we do this????

(Note: this functionality is same as workset in a detail navigation of portal).

Thanks,

Pradeep

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

You could use the TreeByNestingTableColumn just for expanding/collapsing nodes and a TableColumn with LinkToAction as cell editor for the file names. By a parameter mapping ("nodeElement" -> "some action parameter") you can find out the node element for the row where the link has been clicked and you can call the same code as is done in the onLoadChildren event handler.

Armin

PradeepBondla
Active Contributor
0 Kudos

Hi Armin,

Thanks for your helpful response.

ISSUE 1

After Expanding the Folders, How to show documents (pdfs/wods/etc popup when clicked on documents).

Presently I am using Table Master column with LinkToURL as the table cell editor and passing the url of the document as the reference to it, so its showing documents when clicked on documents. But when I try to use LinkToAction as table cell editor how to show the documents (like giving reference in LinkToURL) ?

also when I table column with LinkToAction I am not able to write below code to get the selectedElement as I wrote for Master Column.

IWDLinkToAction action=(IWDLinkToAction)view.getElement("LinkToAcation");
action.mappingOfOnAction().addSourceMapping("path","selectedElement");

How to open leaf node (document) in above situation.

ISSUE 2

As alternate to Table with Master Column, (Now I dont have issue with above code)

I tried to create Tree so, now using Tree Action method I am able to load children, expand it, but

1) I am not able to show the documents when clicked.( as giving reference to LinkToAction).

2) when clicked on folder twice I can expand the folder, but when I clicked again on folder text to close the expansion its not closing as functionality of ARROW. ( its not closing the tree structure and also files inside are getting double).

Any Solution???

Thanks,

PradeeP

Edited by: pradeep bondla on Oct 15, 2009 4:27 AM

Former Member
0 Kudos

Ad 1: Why don't you still use LinkToURL if that solves your use-case?

Ad 2: There exists a "feaure" (some call it bug) of the Tree, that the path to the selected tree node is always expanded. I don't understand what you mean with "files are getting double".

Armin

PradeepBondla
Active Contributor
0 Kudos

Hi Armin,

Thanks again for your reply...

Ad1: by using linktoURL, I am not able to give the expanding action to the folder node text. That is the reason you suggested and i wanted to go with linktoaction. but as i explained i can not show the documents (leaf nodes) as i will get for linktourl.

Ad2: as the tree is always expanding, everytime I click on the tree node, its adding the elements again and again ( I think i forgot to invalidate the node at some place). but the issue with tree is its not collapsing, its only expands.

Thanks,

Pradeep

Former Member
0 Kudos

Ad 1: But how do you want to use the same link to expand the tree node and to open the document? Why not use an additional table column with LinkToURL top open the document?

Ad 2: When using a Tree you should implement the onLoadChildren action properly to add child nodes to an expanded node, and you should bind and set the "hasChidlren", "expanded" etc. properties correctly.

Armin

PradeepBondla
Active Contributor
0 Kudos

Hey Armin,

Thanks... I just want to reconfirm the following thing before closing this thread

Ad 1 : I can not use same link for expanding the tree and open the document. I need to use one LinkToAction for expaning and one LinkToURL for opening the document.

Ad 2: I can only expand the tree by clicking on the folder link, I can not collapse it by clicking on it again (as arrow works).

What I need to do to open the document in Tree??? do I need to use LinkToURL here also???

If above two points are correct then I need to re design my application.

Thanks,

PradeeP

Former Member
0 Kudos

You might also attach a menu to the link for opening the document. But in that case you also have to open the document from within an action handler. To do that you could open an external browser window with the document URL.

I don't understand your second question. In a Tree you cannot use a link as cell editor, the cell editor is fixed. But of course you can use the action of the cell editor to expand and collapse the tree node but you need some additional trigger for opening the document.

Armin

PradeepBondla
Active Contributor
0 Kudos

Hi Armin,

+I don't understand your second question. In a Tree you cannot use a link as cell editor, the cell editor is fixed. But of course you can use the action of the cell editor to expand and collapse the tree node but you need some additional trigger for opening the document.+

IN TREE:

I was just asking that if I use tree, how I need to open the document (as we open with LinkToURL in table) and as you said, in Action handler I need to open the document by sending the URL to the external browser. Is this correct / works for Tree also?

I am not able to collapse the tree by clcking on the expanded Tree folder node. I can do it by clicking on the ARROWs but I can not to the same thing with text ( when clicked on the text / link on opened folder node, its not closing / collapsing).

Thanks,

PradeeP

Answers (1)

Answers (1)

PradeepBondla
Active Contributor
0 Kudos

requirement dropped because of UI structure change. This can not be possible with present UI design and our client dont want to change the old UI design.

Thank you armin...