Skip to content

Instantly share code, notes, and snippets.

@arnaldog
Created April 25, 2018 21:23
Show Gist options
  • Save arnaldog/8deec363a9610a4078b61da3b3cf0f30 to your computer and use it in GitHub Desktop.
Save arnaldog/8deec363a9610a4078b61da3b3cf0f30 to your computer and use it in GitHub Desktop.
carga plata en bancoestado
function cargarPlata() {
$div = $('#saldoContablebl');
saldo = parseInt($div.html().replace('.', ''))
step = 1;
setInterval(function(){
$div = $('#saldoContablebl');
saldo = parseInt($div.html().replace('.', ''))
saldo=saldo + Math.random()*(1000*step)
currency=saldo.toLocaleString('es-CL', { style: 'currency', currency: 'CLP' }).replace('CLP', '')
$div.html(currency)
step+=1;
}, 1000);
}
cargarPlata()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment