From 17dda62b6ade2dbb41a1139d779c15b3b552ac4a Mon Sep 17 00:00:00 2001 From: zhixin Date: Tue, 2 Jan 2018 23:42:02 +0800 Subject: [PATCH] Refs #3168: add to collapse-row --- src/bootstrap-table.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bootstrap-table.js b/src/bootstrap-table.js index 08ab55d19f..a1115acbda 100644 --- a/src/bootstrap-table.js +++ b/src/bootstrap-table.js @@ -1969,14 +1969,14 @@ // remove and update if ($tr.next().is('tr.detail-view')) { $this.find('i').attr('class', sprintf('%s %s', that.options.iconsPrefix, that.options.icons.detailOpen)); - that.trigger('collapse-row', index, row); + that.trigger('collapse-row', index, row, $tr.next()); $tr.next().remove(); } else { $this.find('i').attr('class', sprintf('%s %s', that.options.iconsPrefix, that.options.icons.detailClose)); $tr.after(sprintf('', $tr.find('td').length)); var $element = $tr.next().find('td'); var content = calculateObjectValue(that.options, that.options.detailFormatter, [index, row, $element], ''); - if($element.length === 1) { + if ($element.length === 1) { $element.append(content); } that.trigger('expand-row', index, row, $element);