Hi I am using jQGrid with React.
I am able to customize the cell with cellrenderer
However I am having a hard time figuring out how to implement an OnClick
let columns =
[
{ text: ‘Company Name’, datafield: ‘compName’, cellsalign: ‘center’,width: ‘auto’, align: ‘center’, cellsrenderer: function (ndex, datafield, value, defaultvalue, column, rowdata) {
return <a href="#" title="${'View '+rowdata.compName+' artifacts'}"><div style="text-align:center;" class="align-self-center align-middle"><button type="button" style="padding-top:0.1rem;" class="btn btn-link align-self-center"<strong> onClick={onloadCompData('${ndex}')}</strong>>${rowdata.compName}</button></div></a>
;
},… etc etc
I am able to change the onloadComp to a console.log but when i try to call a function I get an error.
Is there an example where this is implemented?\
I really appreciate any help you can provide