Hello,
I'm trying to handle an angularjs function when the user click on the grid text.
For example:
$scope.myFunction = function () {
//Todo
};
//Inside Flexmonster customizeCell function
cell.text = '<a ng-click="myFunction()">Text</a>';
Is it possible?
Best regards,
Tiago
Hello, Tiago,
Thank you for posting on our forum.
Instead of embedding links directly in cells, we recommend using the cellclick event. It is triggered when a cell is clicked on the grid. You can invoke any handler after the dedicated cell is clicked. You can also configure what function is invoked and adjust it based on the information received from the handler.
Please let us know if it works for you.
Kind regards,
Illia
Hi, Illia,
Thanks for the reply.
Unfortunately i cant use the cellclick event because of the business rules, instead i need to trigger an event when the text inside the cell is clicked.
Best regards,
Tiago
Hello,
Thank you for your feedback.
If using the cellclick
event is not an option for you, embed a clickable element similar to your initial example. Please note that you will need to increase z-index
of this element to make it reachable.
Here is JSFiddle for demonstration: https://jsfiddle.net/flexmonster/720mk5bz/.
Please let us know if it works for you.
Kind regards,
Illia