[Editor] Excluding certain cells from being updated/redrawn

[Editor] Excluding certain cells from being updated/redrawn

neilrao42neilrao42 Posts: 14Questions: 2Answers: 1

It seems that the Editor updates the DOM for the entire row after a edit, removing any bindings etc. that I have on elements in other cells. Is it possible to make the Editor exclude certain cells from being updated?

Answers

  • neilrao42neilrao42 Posts: 14Questions: 2Answers: 1
    edited November 2014

    This is especially difficult on mobile—it causes the device to hang for a few seconds while it updates the entire row (I have > 100 columns, 90 of which are hidden, and 10 of which modify the other 90+). The Editor posts all of the HTML (1000's of lines in total) in those 10 columns to the backend which I want to prevent. Right now I'm cloning the data array and manually nulling those columns with a custom ajax function before sending it to the backend, but there has to be a better way. I tried removing the columns I don't want updated from the Editor's fields[] array, but then when the row updates, my 10 columns of HTML is lost.

    Basically what I want to do is make the editor not update certain columns.

  • ksoldinkksoldink Posts: 5Questions: 1Answers: 0

    I'm running into the same issue: I only want to post information I know has been edited. To me, when using inline() or bubble(), this should be the case: I clicked on this specific field to edit, so only that field's data should be passed to the backend.

    It sounds like allan is working on addressing this issue in the next release, which is good news!

    I'm interested in how you're cloning your data array and nulling out specific values. Do you have an example I can see?

    Thanks!, _K

  • ksoldinkksoldink Posts: 5Questions: 1Answers: 0

    In case anyone else was looking for a method to do this, https://datatables.net/forums/discussion/comment/71750/#Comment_71750

    Cheers!, _K

  • allanallan Posts: 61,758Questions: 1Answers: 10,111 Site admin

    Yes, this is something that will be addressed in v1.5 :-)

    Allan

This discussion has been closed.