YiiBooster icon indicating copy to clipboard operation
YiiBooster copied to clipboard

X-Editable wont work if grid is empty.

Open alexiscps opened this issue 11 years ago • 1 comments

I have a grid (TbExtendedGridView or CGridView, tried with both). When the grid displays record already there, adding a new x-editable record function correctly. After insertion, and grid update, the record appears normally with "Empty Text" etc.

When the grid has no records on it, the exact same operation inserts a record, refreshes the grid, but only the id appears (not x-editable). Any other x-editable field appears empty and of course non-editable.

It seems that x-editable is not loading if it find a empty grid to begin with. This appears only if the grid has no previous records. If there is one record ore more, everything works fine.

Cause of this, it is impossible to use x-editable grids to insert new record to an empty table.

Any ideas? I found that i'm not the only one with this problem.

alexiscps avatar Aug 24 '14 14:08 alexiscps

maybe this can help you. http://x-editable.demopage.ru/index.php?r=site/components#EditableSaver and this http://vitalets.github.io/x-editable/docs.html#newrecord

Julian-B90 avatar Dec 23 '14 15:12 Julian-B90