Editor, keytable and inline edit, not allow the first column to be edited, Bug?
Editor, keytable and inline edit, not allow the first column to be edited, Bug?
Busteren
Posts: 52Questions: 17Answers: 4
Hey, I have a datable with an editor. The inline option is set to not allow the first column to be edited, however with keytables, you can actually edit this if you navigate to it.
//Inline editor setting
$("#editor").on('click', 'tbody td:not(:first-child)', function (e) {
editor.inline();
});
table = $('#editor').DataTable({
keys: {
editor: editor
}
});
Had to remove some settings, but mainly, how can I not allow keytables to navigate to the first column?
edit:
This explains how to do this
then I change it to :not(:first-child)
But it is still not working for me
Edit2:
Tried the exact examples in the link above, none of them are working.
This discussion has been closed.
Replies
Edit 3:
It works now, unsure why as I didn't change anything that should have made it work. Noticed now that when the I navigate or click on the different rows for the first time the editor will think that I edit the cells:
So for example I click on a cell in the first row, when i change this to another cell in another row without editing the cell, it still shows background colour which indicates that something has been edited.
Probs something wrong on my end. Please mark as closed
Thanks for posting back. Good to hear you've got it working now.
Allan