plugin method set is called for all plugin instances when one cell is opened for editing. Why ?
plugin method set is called for all plugin instances when one cell is opened for editing. Why ?
nampord
Posts: 5Questions: 3Answers: 0
I have a table with inline editing and I am using the select2 plugin for four columns.
Now when I click on one of the select2 cells, I see that the set function for all four select2 controls is called.
This is really not ideal, since my select2 is initialized via an server call. and I would like to do this only when the actual cell is opened.
Is this the expected behavior ? Or am i doing something wrong here.
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
That is expected since Editor will set itself up for editing the whole row by default, even if inline editing is being used (to allow for the API to be used to modify other values in the form).
If you don't want that behaviour and just want a single value to be used for editing, there is a
scope
option inform-options
which can be set to becell
.Allan
Thanks Allan, I very much appreciate your patience with people who have not (yet) read all of your excellent documentation!
To be honest, there is so much of it, I forget bits now and then myself. Can't realistically expect everyone to have a detailed knowledge of the software .
Thanks for the compliment on the docs though!
Allan