Jump to content

UnimDBListGrid satır özelleştirme


mehmet07

Recommended Posts

Merhabalar,

UnimDBListGrid bilesenin beforeinit özelliğine kod yazarak listgrid in her satirini kendime göre özelleştirerek 2 tane buton ekledim.

Amacım bu butonlara tiklandiğinda ajaxRequest oluşturmak ve bu isteği yakalamak. Ama bir türlü istediğimi başaramadım.

function beforeInit(sender, config)
{
    config.itemTpl=

 '<span id="aa"></span>'+
'<table style="width:100%">'+ 
 ' <tr> <td style="width:130px"><a href="#">{1}</a></td> <td style="width:20px">{2}</td><td style="width:20px"> <button type="button">+</button></td>'
 +'<td style="width:20px"> <button type="button" onclick="ajaxRequest(MainmForm, 'eksi_tiklandi', [])">-</button></td> </tr>'
  +
 '</table>';
}

post-962-0-46196900-1491481266_thumb.png

Link to comment
Share on other sites

Hi,

 

Try:

function beforeInit(sender, config) {
    config.itemTpl =

        '<span id="aa"></span>' +
        '<table style="width:100%">' +
        ' <tr> <td style="width:130px"><a href="#">{1}</a></td> <td style="width:20px">{2}</td><td style="width:20px"> <button type="button">+</button></td>' +
        '<td style="width:20px"> <button type="button" onclick="ajaxRequest(MainmForm.window, \'eksi_tiklandi\', [])">-</button></td> </tr>' +
        '</table>';
}

* Correct: MainmForm.window

 

Best regards.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...