get aoColumns data

get aoColumns data

merihmerih Posts: 24Questions: 0Answers: 0
edited March 2012 in General
Hi all,

I wanna set a link last column of the table.
I use { "sDefaultContent": "TEST"} in aoColumns and It works fine.
But I also would like to add parameter in the link so I need to get value of the first cell of the row..

I tried to use fnRender in aoColumns but It says "undefined" for the oObj.aData[0] .

Is there a way to do this?

[code]

"aoColumns": [

{ "mDataProp": "systemId"},
{ "mDataProp": "leftEntityIdentity"},
{ "mDataProp": "leftEntityName"},
{ "mDataProp": "rightEntityIdentity"},
{ "mDataProp": "rightEntityName"},
{ "mDataProp": "startOfUse"},
{ "mDataProp": "dateModified"},
{ "fnRender": function(oObj) {
var cId = oObj.aData[0];
return ''+cId+'';} }
]

[/code]

Replies

  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    But the looks of things you don't have a property '0' on the data object, do you actually want to use oObj.aData.systemId?

    Allan
  • merihmerih Posts: 24Questions: 0Answers: 0
    edited March 2012
    Thank you Allan,

    You are right ;) this is what I would like.. It works right now..
This discussion has been closed.