Hi,
I have a row used render function to generate a hyper link to other page. Please have a look with my current js codes, and it works well.
{ title: "Line Item Status", width: 64,align: "center",editable: false,dataIndx: "status",
render: goPR
}
The goPR function:
var goPR = function(ui){
var rowData = ui.rowData
dataIndx = ui.dataIndx;
var val = rowData[dataIndx];
var pppId = rowData['Id'];
//var link1 = "<a href='#' onclick='goToPR("+pppId+");return false;'>"+val+"</a>";
var link2 = "<a href='/apex/PartnerPriceRequest?ppid="+encodeURIComponent(pppId)+"' >"+val+"</a>";
return link2;
}
As you see, if I return link2 which set a link in href directly, I can click my "val" value and go to the target page with parameter.
But if I change to link1 try to invoke another js function when I click this link, I got the error message like "pppId" value(like 0ax1212312) is not defined.
So do you know why this happened?
Thank you!