[Editor] editor dropping tr.id attribute after saving a row
[Editor] editor dropping tr.id attribute after saving a row
ajung
Posts: 14Questions: 5Answers: 0
Latest DT, latest Editor.
The initial table markup with two columns looks like this:
After editing a row and saving it back, the related <tr>
element has no longer an id
attribute which leads to the
" Unable to find row identifier For more information, please refer to https://datatables.net/tn/14" error.
I tried to add idSrc: "id"
to the editor configuration, which has the effect that I receive this error directly when clicking on a row.
Answers
I'm not seeing that problem in this example. Can you link to a page showing the issue please?
Allan
Different example with a row before editing and after saving:
Possibly the JSON response after editing doesn't have the
id
? Use the browser's network inspector to look at the JSON response after editing a row. If that doesn't help then we will need more information to help debug. A link to your page or test case showing the issue is the best option. You can PM Allan with a link if you don't want it public. If you can't do that then start by posting the JSON response from editing, Editor and Datatables configs.Kevin
The response contains an
id
:I will try to setup something on a public server.