Multilevel (Sub) Menus in Context-Menu in Grid

When i create a context menu, how do I achieve that on clicking it it opens another menu in Grid?


5 Replies

PS Pavithra Subramaniyam Syncfusion Team November 19, 2021 03:09 PM UTC

Hi Sebastian, 

Thanks for contacting Syncfusion support. 

You can achieve your requirement by using the multilevel nested custom context menu items. Please refer to the below code example, documentation and sample link for more information. 

contextMenuItems: [ 
    { 
      text: 'Copy with headers', 
      target: '.e-content', 
      id: 'copywithheader', 
    }, 
    { 
      text: 'Export', 
      target: '.e-content', 
      id: 'Export', 
      items: [ 
        { 
          text: 'ExcelEXport', 
          id: 'ExcelEXport', 
        }, 
        { 
          text: 'PdfExport', 
          id: 'PdfEXport', 
        }, 
      ], 
    }, 
  ], 


Sample               : https://stackblitz.com/edit/j26sog-wjse7l 

Please get back to us if you need further assistance on this. 

Regards, 
Pavithra S 



SG Sebastian Göhring November 29, 2021 01:48 PM UTC

When I use subMenuItems, i cant use args.rowInfo.rowData and index in "contextMenuItemClick" event anymore. It seems like it doesnt have access to those? Am I missing something? I set ".e-content" for the root menu items as target, and left it out for the submenus. 



PS Pavithra Subramaniyam Syncfusion Team November 30, 2021 01:05 PM UTC

Hi Sebastian, 

We have validated your query and we have confirmed it as a bug and logged the defect report Wrong row information while clicking the custom sub context menu items” for the same. Thank you for taking the time to report this issue and helping us improve our product. At Syncfusion, we are committed to fixing all validated defects (subject to technological feasibility and Product Development Life Cycle) and including the defect fix in our weekly release which is expected to be rolled out by the December 15th  , 2021.  
           
You can now track the current status of your request, review the proposed resolution timeline, and contact us for any further inquiries through this link.     


Regards, 
Pavithra S 



PS Pavithra Subramaniyam Syncfusion Team November 30, 2021 01:05 PM UTC

Hi Sebastian, 

We have validated your query and we have confirmed it as a bug and logged the defect report Wrong row information while clicking the custom sub context menu items” for the same. Thank you for taking the time to report this issue and helping us improve our product. At Syncfusion, we are committed to fixing all validated defects (subject to technological feasibility and Product Development Life Cycle) and including the defect fix in our weekly release which is expected to be rolled out by the December 15th  , 2021.  
           
You can now track the current status of your request, review the proposed resolution timeline, and contact us for any further inquiries through this link.     


Regards, 
Pavithra S 



PS Pavithra Subramaniyam Syncfusion Team December 16, 2021 11:19 AM UTC

Hi Sebastian, 

Thanks for your patience.  
  
We are glad to announce that our Essential Javascript2 patch release (v19.3.59) has been rolled out successfully and in that release we have added the fix of “Wrong row information while clicking the custom sub context menu items” issue. So please update your packages to this version to include the fix.  
  
We thank you for your support and appreciate your patience in waiting for this release. Please contact us if you would require any further assistance.  

Regards, 
Pavithra S 


Loader.
Up arrow icon