diff --git a/html/wallet/js/wallet.api.js b/html/wallet/js/wallet.api.js
index 181f6c3..1304827 100644
--- a/html/wallet/js/wallet.api.js
+++ b/html/wallet/js/wallet.api.js
@@ -180,6 +180,7 @@ define(['mui', 'app', 'ajaxUtil', 'jsencrypt'], function(mui, app, ajaxUtil, jse
* @param {Object} coins
*/
function moduleType(type, coin) {
+ console.log(JSON.stringify(coin));
coin.moduleType = type;
coin.balance = app.formatValue(coin.balance);
coin.freeBalance = app.formatValue(coin.freeBalance);
diff --git a/lib/js/app.js b/lib/js/app.js
index bacc47a..dc020d2 100644
--- a/lib/js/app.js
+++ b/lib/js/app.js
@@ -678,23 +678,24 @@
val = -val;
}
if(val < 0.0001) {
- value = compute.Mul(value, 1e8, 8);
- value = compute.Div(value, 1e8, 8);
- value = value.toFixed(8);
+ val = compute.Mul(val, 1e8, 8);
+ val = compute.Div(val, 1e8, 8);
+ val = val.toFixed(8);
} else if(val < 0.1) {
- value = compute.Mul(value, 1e6, 6);
- value = compute.Div(value, 1e6, 6);
- value = value.toFixed(6);
+ val = compute.Mul(val, 1e6, 6);
+ val = compute.Div(val, 1e6, 6);
+ val = val.toFixed(6);
} else if(val < 10) {
- value = compute.Mul(value, 1e4, 4);
- value = compute.Div(value, 1e4, 4);
- value = value.toFixed(4);
+ val = compute.Mul(val, 1e4, 4);
+ val = compute.Div(val, 1e4, 4);
+ val = val.toFixed(4);
} else {
- value = compute.Mul(value, 1e2, 2);
- value = compute.Div(value, 1e2, 2);
- value = value.toFixed(2);
+ val = compute.Mul(val, 1e2, 2);
+ val = compute.Div(val, 1e2, 2);
+ val = val.toFixed(2);
+ console.log(val);
}
- return value;
+ return val;
}
/***