We have a page that displays the 3 most recent activities on files and have ids etc associated with each one. This list was created using a standard asp:repeater. How do we access the data on the element when clicking on a context menu item?
The html for the list above is as follows - the data is highlighted:
The code in the js to create the context menu is as follows:
$(document).ready(function () {
ej.base.enableRipple(true);
var menuItems = [
{
text: 'Edit'
},
{
text: 'Show in Files...'
},
{
separator: true
},
{
text: 'Delete'
}];
var menuOptions = {
target: ".activity-feed__item",
items: menuItems,
select: onContextMenuItemSelect,
beforeItemRender: onBeforeItemRender
};
// Initialize ContextMenu control.
var menuObj = new ej.navigations.ContextMenu(menuOptions, '#contextmenu');
});
Any help would be greatly appreciated.
James