1
0
Fork 0

convert to trillions as well

This commit is contained in:
Andrew Tomaka 2016-05-24 13:07:13 -04:00
parent 4bc38236d0
commit d9361b60ff
1 changed files with 2 additions and 0 deletions

View File

@ -344,6 +344,8 @@ function convertToNumber(string) {
return Number(string.replace(/[^0-9\.]+/g, '')) * 1000000;
} else if(string.indexOf('B') > -1) {
return Number(string.replace(/[^0-9\.]+/g, '')) * 1000000000;
} else if(string.indexOf('T') > -1) {
return Number(string.replace(/[^0-9\.]+/g, '')) * 1000000000000;
} else {
return Number(string.replace(/[^0-9\.]+/g, ''));
}