markcell / jquery-tabledit

Inline editor for HTML tables compatible with Bootstrap.
http://markcell.github.io/jquery-tabledit/
MIT License
435 stars 208 forks source link

Edit button click renders all children of <tr> parent element editable #122

Open dedalus2019 opened 5 years ago

dedalus2019 commented 5 years ago

Hello,

clicking on the edit button renders all children of a parent element higher up the ancestor hierarchy editable, included those not on the same level as the edit element..

Proposed solution: Replace ($button.parents('tr') with ($button.closest('tr')

Thanks

         if (!activated) {
                    // Change to edit mode for all columns in reverse way.
                    _$($button.parents('tr').find('td.tabledit-view-mode').get().reverse()).each(function() {_
                        Mode.edit(this);
                    });
                }