Skip to content

Instantly share code, notes, and snippets.

@hotienvu
Created March 3, 2019 07:00
Show Gist options
  • Save hotienvu/88efcc80f89a19ca4556e59e7bb4062e to your computer and use it in GitHub Desktop.
Save hotienvu/88efcc80f89a19ca4556e59e7bb4062e to your computer and use it in GitHub Desktop.
// debit
$jq.map($jq("td.cT-bodyTableColumn3 span.cT-line1.cM-numberCell"), function(r, i) { return parseFloat(r.innerHTML.replace(",", "").substring(4)); }).reduce(function(acc, x) { return acc + x; })
// credit
$jq.map($jq("td.cT-bodyTableColumn4 span.cT-line1.cM-numberCell"), function(r, i) { return parseFloat(r.innerHTML.replace(",", "").substring(4)); }).reduce(function(acc, x) { return acc + x; })
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment