projects
/
MojoFacets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
26b0e0d
)
use index() to get cellIndex and rowIndex
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Mon, 21 Jan 2013 15:36:29 +0000
(16:36 +0100)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Mon, 21 Jan 2013 15:36:29 +0000
(16:36 +0100)
public/edit_table.js
patch
|
blob
|
history
diff --git
a/public/edit_table.js
b/public/edit_table.js
index
d3422eb
..
9914a3c
100644
(file)
--- a/
public/edit_table.js
+++ b/
public/edit_table.js
@@
-13,8
+13,13
@@
var cell_blur = function() {
*/
var _row_id = $(this).parent().parent().attr('title');
- var x = $(this).parent().attr('cellIndex');
- var y = $(this).parent().parent().attr('rowIndex');
+ var x = $(this).parent().index();
+ var y = $(this).parent().parent().index();
+
+ if ( ! x || ! y ) {
+ console.error('no x ', x, ' or y ', y, ' defined');
+ return;
+ }
var new_content = $(this).val();
// $(this).replaceWith( new_content );