We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Multilevel in Radial Menu

Hello, I would like to make Radial Menu with multiple levels in JavaScript (like a tree type structure).
I use radial menu in mobile version of my web site because tree view are uneasy to use on smartphone.
I did not succeed to make more than one level in my radial menu, I used this example (http://js.syncfusion.com/demos/web/#!/bootstrap/radialmenu/nestedradialmenu)

And also, can I set dynamically the datas of this component by using a javascript object ?

Thank's for your help.
Cholet

5 Replies

AP Arun Palaniyandi Syncfusion Team March 1, 2017 12:57 PM UTC

Hi Cholet,

Thank you for helping us define this feature. We have added this “Multiple Nested levels in Radial Menu” to our feature request list, and it can be tracked through our Features Management System.

You can communicate with us regarding the open features at any time using the “Contact” option.

Regards,
Arun P.
 



CH Cholet March 1, 2017 04:59 PM UTC

Ok, thanks.
I have another question, how can I open the sub-category by clicking on the arrow around AND on the item ? (like in attached picture)
Because actually it work only by clicking on the arrow.

Thank's for your help.
Cholet

Attachment: radial_menu_521e80c8.zip


AP Arun Palaniyandi Syncfusion Team March 2, 2017 12:56 PM UTC

Hi Cholet, 
 
Thanks for your update. 
 
By default we don’t have the support to open the sub category by clicking on the item, hence it will be opened only by clicking the arrow. But, we can achieve it by using our private methods. Right now please use the below shared workaround for your scenario and if you still have any other queries, please lets us know immediately. So that we would analyze and help you out better. 
 
Code snippet: 
 
CSHTML: 
 
  Html.EJ().RadialMenu("nestedradialmenu").ImageClass("imageclass").BackImageClass("backimageclass").TargetElementId("radialtarget2").Items(items => 
{ 
    items.Add().Text("Copy").ImageURL(Url.Content("~/RadialMenu/copy.png")).Click("copy"); 
    items.Add().Text("Bold").ImageURL(Url.Content("~/RadialMenu/font.png")).Click("bold").Children(children => 
    { 
        children.Add().ImageURL(Url.Content("~/RadialMenu/f1.png")).Text("Italic").Click("italic"); 
        children.Add().ImageURL(Url.Content("~/RadialMenu/font.png")).Text("Bold").Click("bold1"); 
    }); 
 
 
<script>  
 
function bold(e) { 
        var rm = radialEle.ejRadialMenu("instance"); 
        if (!$(this._radialChildSVGDiv).hasClass("e-displaynone")) { 
            rm._ejMenuBaseItemsRemove(); 
            rm._renderRadialChildMenu(rm.model.items[e.index]); 
        } 
        else 
            rteObj.executeCommand("bold"); 
    } 
</script> 
 
 
 
 
Please find the sample below for your reference. 
 
If the provided sample and details does not meet your requirement, please don’t hesitate to get back us.  
 
Regards, 
Arun P. 



CH Cholet March 2, 2017 02:52 PM UTC

Hello, thanks it works, it open the sub-menu, but I need the variable e.childIndex in my function and in that case childIndex is not defined.
And e.index doesn't have the correct value.
Because i use a function on click like this:

radialEle.ejRadialMenu({
        radius: 150,
        click: selectionFunction
    });

function selectionFunction(e) {
       ...
}

And I make several action according to the e.index and e.childIndex value.
Edit: because I need index and childIndex to acces to a javascript array.

Thank's for your help.
Cholet



AP Arun Palaniyandi Syncfusion Team March 3, 2017 09:24 AM UTC

Hi Cholet,    
    
A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates. 
 
Please let us know if you have any queries. 
 
Regards, 
Arun P. 


Loader.
Live Chat Icon For mobile
Up arrow icon