Row Reorder dataSrc error
Row Reorder dataSrc error
OpticNectar
Posts: 4Questions: 1Answers: 0
I'm using dataSrc
in rowReorder
, but I keep getting the Uncaught Unknown field name - order
error. I'm using a field that isn't in the table itself, but is in each object returned from the server.
rowReorder: {
selector: 'tr',
dataSrc: 'order',
editor: editor
}
This discussion has been closed.
Answers
Seems like this might be a bug. @allan can confirm. According to the
rowReorder.dataSrc
docs:As a workaround you could add 'order' as a columns then use Datatables to hide it using
columns.visible
.Kevin
As far as I am aware there aren't any bugs there, but I might just not be aware of it. @OpticNectar - could you give me a link to your page so I can check it out please?
I have a feeling that you don't have an
order
field defined in your Editor field list, and the problem is that when reorder, Editor attempts to updates the data, and finds it can't. The ``-init rowReorder.dataSrc` option doesn't need to be in a column, but if you are using Editor, it does need to be in a field.Allan
That's why it didn't work for me when I did a quick test
Kevin