how put edit button in Child rows

how put edit button in Child rows

amir7shamir7sh Posts: 15Questions: 4Answers: 0

hi

how put and use edit button in Child rows ?

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin

    You would use a standard jQuery event listener and call the edit() method - passing in the parent row so that is the one that is edited.

    Allan

  • amir7shamir7sh Posts: 15Questions: 4Answers: 0

    Thank allan
    if is possible ,bring an example.

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Answer ✓

    Something as simple as this should do it:

    $('#myTable').on( 'click', '...edit-button-selector...', function () {
      editor.edit( $(this).closest('tr').prev()[0] );
    } );
    

    Updating the selector as required of course.

    Allan

  • amir7shamir7sh Posts: 15Questions: 4Answers: 0
    edited July 2015

    Thank u very much allan

This discussion has been closed.