Topic: Mif.menu filed by JSON ?

Does it possible to fill submenu using JSON ?
Thank you

Re: Mif.menu filed by JSON ?

Please Moro give a tip to do this ...
I've added   onSelect  function  but  I can't be abble to load the subMenu on fly ...

Re: Mif.menu filed by JSON ?

updated tree and menu integration demo contains 'add sub menu on fly' example demo,    archive

onSelect: function(){
    if(this.childList) return;
    this.options.list={
        items: [
            {
                name: 'some item1'
            },
            {
                name: 'some item2'
            },
            {
                name: 'some item3'
            }
        ]
    };
    
    this.initChildList();
}

Re: Mif.menu filed by JSON ?

nice ! Thank you very much ...

Re: Mif.menu filed by JSON ?

I've just  test the code to  fill dynamically the menu.
What happens is that I need to refresh  the menu for each node.

So I've just  skip the "if(this.childList) return;" line

It works but if nothing is available to  fill the submenu  the item still selected (blue background).

How can I solve this ?

Re: Mif.menu filed by JSON ?

Could you give an hand on this problem?
I want to use context menu to handle common feature like  (cut/copy/paste,refresh, rename, delete) and "add" node.
In LDAP you shouldn't add any object anywhere. This is why I need something to let add only logical "objects" to a container. For example a  person should't be in Groups container ...

I will try to setup an LDAP demo.

Re: Mif.menu filed by JSON ?

wait while i'm rewrite Mif.Menu and implement add/replace/remove/set/load  items/lists support.

Re: Mif.menu filed by JSON ?

Any Roadmap and date for this ?

For my application I need to fill dynamically main and submenu ...
I've got somes actions different on each node  and should appear on 1st level of the context menu