jquery-tabledit icon indicating copy to clipboard operation
jquery-tabledit copied to clipboard

Disable edit for certain row

Open matthers opened this issue 9 years ago • 7 comments

Hi,

Does anyone know if there's an option do prevent edit for a certain row, based on an identifier?

ex: if column "status" is "closed", do not show or do not allow edit.

matthers avatar Jun 04 '16 16:06 matthers

Hi. I need the same thing

DiegoJArg avatar Aug 10 '18 11:08 DiegoJArg

tableedit removes the internal span filled as dummy text. I need to prevent this

DiegoJArg avatar Aug 10 '18 11:08 DiegoJArg

this feature is really necessary! any workaround?

doohraf avatar Oct 26 '18 10:10 doohraf

how would you workaround it? If you need a row that is not meant to be edited but to highlight something that is to be seen by the operator. table-edit removes all innerhtml from the TD

DiegoJArg avatar Oct 27 '18 14:10 DiegoJArg

This feature is very much required. If any one has achieved this please let us know.

pdctpa avatar Oct 30 '18 21:10 pdctpa

i need it too,

milan-sahana avatar Sep 03 '20 15:09 milan-sahana

Hey folks, I just found a trick, the rows you need to skip just add "data-tabledit-done" attribute on these rows. For example:

<tr data-tabledit-done="1">
    <td>ID</td>
    <td>Name</td>
</tr>

I got it from the scipt actually, it always check rows where "data-tabledit-done" attr is not set.

var $td = $table.find('tbody tr:not([data-tabledit-done]) td:nth-child(' + (parseInt(settings.columns.editable[i][0]) + 1) + ')');

So, if I add this attribute in the required rows, it will simply skip this. I don't know javascript well, otherwise I would implement a method for this.

roy-sandip avatar Jan 27 '21 20:01 roy-sandip