Skip to content

Commit

Permalink
Merge pull request #68 from agallou/cleanvalue
Browse files Browse the repository at this point in the history
add event to customize cleaning of cell values
  • Loading branch information
agallou committed Dec 6, 2015
2 parents 535ebb2 + ced6c37 commit b1903f3
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion jquery.highchartTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,16 @@
}
} else {
var cleanedCellValue = rawCellValue.replace(/\s/g, '').replace(/,/, '.');
cellValue = Math.round(parseFloat(cleanedCellValue) * column.scale * 100) / 100;
var eventOptions = {
value: cleanedCellValue,
rawValue: rawCellValue,
td: $td,
tr: $(row),
indexTd: indexTd,
indexTr: indexRow
}
$table.trigger('highchartTable.cleanValue', eventOptions);
cellValue = Math.round(parseFloat(eventOptions.value) * column.scale * 100) / 100;

var dataGraphX = $td.data('graph-x');

Expand Down

0 comments on commit b1903f3

Please sign in to comment.