AnsweredAssumed Answered

Custom document Library Action with Tree

Question asked by thestorm on Feb 14, 2014
Dear all,

we try to create a custom doclib actions (type="javascript") and from that javascript we want to call a widget/modal/dialog whatever that contains an Alfresco.RepositoryDocListTree

We tried to create a YAHOO.widget.SimpleDialog and add the RepoTree to its body but that simply doesnt render for us. Our code is below. Would appreciate any suggestions

            var myDialog = new YAHOO.widget.SimpleDialog("prompt", {
                close: true,
                width: "50em",
                    effect: YAHOO.widget.ContainerEffect.FADE,
                    duration: 0.25
                fixedcenter: true,
                modal: true,
                visible: false,
                draggable: true
         myDialog.setBody('<div id="my-tree"></div>');     
            var tree = new Alfresco.RepositoryDocListTree("my-tree").setOptions({
                rootNode : 'alfresco:\/\/company\/home',
                evaluateChildFolders : true,
                maximumFolderCount : 10,
                setDropTargets : false
            }).setMessages({"header.library": "MyTree", "node.root": "Documents"});
            var select = function() {
            var close = function() {
            var actions = [
                { text: "toggle all", handler: select },
                { text:"close", handler: close}
            myDialog.cfg.queueProperty("buttons", actions);