Skip to content

Commit

Permalink
SendAmount: Change precision and limit fiat decimals
Browse files Browse the repository at this point in the history
  • Loading branch information
etharner committed Aug 8, 2019
1 parent 5e8171b commit 7683d26
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/pages/mobile/SendAmount.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
v-model="amount"
v-validate="{
required: true,
decimal: MAGNITUDE,
decimal: swapped ? 2 : MAGNITUDE,
min_value_exclusive: 0,
max_value: max,
}"
Expand Down Expand Up @@ -82,8 +82,8 @@ import DetailsAmountCurrency from '../../components/mobile/DetailsAmountCurrency
import AeButton from '../../components/AeButton.vue';
import { MAGNITUDE } from '../../lib/constants';
const toCurrency = (value, rate) => value.multipliedBy(rate).precision(18, BigNumber.ROUND_FLOOR);
const toAe = (value, rate) => value.dividedBy(rate).precision(18, BigNumber.ROUND_FLOOR).toFixed();
const toCurrency = (value, rate) => value.multipliedBy(rate).precision(17, BigNumber.ROUND_FLOOR);
const toAe = (value, rate) => value.dividedBy(rate).precision(17, BigNumber.ROUND_FLOOR).toFixed();
export default {
components: {
Expand Down

0 comments on commit 7683d26

Please sign in to comment.