Permalink
Browse files

Making possible using different parameters in the editGridRow for add…

… or edit. Also we support multiple grids in the same page
  • Loading branch information...
1 parent 84a657c commit 8cddf70ef3a34202ce0b92fb09a2e773fbb28255 @tonytomov committed Jul 4, 2011
Showing with 5 additions and 2 deletions.
  1. +5 −2 js/grid.formedit.js
View
@@ -8,6 +8,7 @@
* http://www.gnu.org/licenses/gpl-2.0.html
**/
/*global xmlJsonClass, jQuery, $ */
+var rp_ge_arr = {};
$.jgrid.extend({
searchGrid : function (p) {
p = $.extend({
@@ -309,7 +310,8 @@ $.jgrid.extend({
serializeEditData : null,
viewPagerButtons : true
}, $.jgrid.edit, p || {});
- var rp_ge = p;
+ rp_ge_arr[$(this)[0].p.id] = p;
+ var rp_ge = rp_ge_arr[$(this)[0].p.id];
return this.each(function(){
var $t = this;
if (!$t.grid || !rowid) { return; }
@@ -1427,7 +1429,8 @@ $.jgrid.extend({
serializeDelData : null,
useDataProxy : false
}, $.jgrid.del, p ||{});
- var rp_ge = p;
+ rp_ge_arr[$(this)[0].p.id] = p;
+ var rp_ge = rp_ge_arr[$(this)[0].p.id];
return this.each(function(){
var $t = this;
if (!$t.grid ) { return; }

0 comments on commit 8cddf70

Please sign in to comment.