bacsa / jquery-datatables-editable

Automatically exported from code.google.com/p/jquery-datatables-editable
0 stars 0 forks source link

using aoColumns breaks editable functionality when used with row grouping #48

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I've had a ton of trouble trying to use this plugin in combination with row 
grouping, as copy-pasted from 
http://datatables.net/release-datatables/examples/advanced_init/row_grouping.htm
l . 

If I don't specify aoColumns it works fine, but if I use aoColumns, I can click 
on cells and it seems like I can edit them, but when I click away the text is 
not saved, and the sUpdateURL function is not performed.

See example file attached, where two tables have row grouping, one has 
makeEditable with no aoColumns, and one has aoColumns.

Original issue reported on code.google.com by brianna.laugher on 26 Jul 2011 at 7:56

Attachments:

GoogleCodeExporter commented 9 years ago
Hi,

Could you try with the row grouping plugin? On the page 
http://jquery-datatables-editable.googlecode.com/svn/trunk/rowGrouping.html I 
have shown that these are working togehter.

Regards,
Jovan

Original comment by joc...@gmail.com on 14 Sep 2011 at 10:26

GoogleCodeExporter commented 9 years ago
Hmmm... OK I figured out what the problem is. and indeed it doesn't have 
anything to do with row grouping.

It seems that the behaviour of the input and textarea widgets are slightly 
different. With an input, you can press Enter or click away from the item and 
it will be submitted. With textarea, if you press Enter, of course you get a 
newline as you would like. But clicking away from the item, instead of 
submitting it like the input does, seems to just be like "escape". To actually 
submit it, you need to specify in the aoColumns: 

 { type: 'textarea',
   submit  : 'OK',},

instead of just 

 { type: 'textarea', },

then you will get an "OK" button you can click to actually submit.

Frustrating. >:|

Original comment by brianna.laugher on 15 Sep 2011 at 12:58

GoogleCodeExporter commented 9 years ago
Hi,

I'm glad thatyou have found solution. I'm closing this one.

Regards,
Jovan

Original comment by joc...@gmail.com on 15 Sep 2011 at 9:27