FooTable icon indicating copy to clipboard operation
FooTable copied to clipboard

Append (loadRows) with problem in predraw (jQuery 3.x)

Open stenioanibal opened this issue 5 years ago • 0 comments

In case of append, with jQuery 3.x, footable makes a rewrite in existent rows.

I fixed this editing these lines:

load: function(data, append){
      var self = this, rows = $.map(data, function(r){
          return new F.Row(self.ft, self.ft.columns.array, r);
      });
      F.arr.each(append ? rows : this.array, function(row){
          row.predraw();
      });
      this.all = (F.is.boolean(append) ? append : false) ? this.all.concat(rows) : rows;
      this.array = this.all.slice(0);
      this.ft.draw();
},

stenioanibal avatar Sep 25 '19 13:09 stenioanibal