PsKs / jquery-datatables-editable

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

Need rowId passed to fnOnCellUpdated #38

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create an editable datatable
2. Attempt to define a custom fnOnCellUpdated to modify the value of a cell 
other than the one just updated...
3. There is no easy way to do this because rowId is not passed to 
fnOnCellUpdated.

I've modified my local copy of jquery.dataTable.editable.js to fix this as 
follows:

Changed this line:
   settings.fnOnCellUpdated(status, sValue, settings);
to
   settings.fnOnCellUpdated(status, sValue, aPos[0], settings);

If you can tell me a way to do what I need to without making this change, that 
would be even better, but after hours on the web looking for examples of people 
doing this, I could find no easy way.

The reasoning in my specific case is this: I have a row that includes an Author 
name. The Author name should change to the current user when any editable cell 
in the row is changed.

Thanks,
-Dave

Original issue reported on code.google.com by jesus2d...@gmail.com on 1 Jul 2011 at 11:31

GoogleCodeExporter commented 9 years ago
In the latest version of plugin is added both pos[0] and pos[2] row and column.

Original comment by joc...@gmail.com on 21 Aug 2011 at 3:30