Browse Source

native claim interest modal wrong addr in toaster fix

v0.25
pbca26 7 years ago
parent
commit
e44f9df57a
  1. 8
      react/src/components/dashboard/claimInterestModal/claimInterestModal.js
  2. 5
      react/src/components/dashboard/coinTile/coinTileItem.js

8
react/src/components/dashboard/claimInterestModal/claimInterestModal.js

@ -236,7 +236,7 @@ class ClaimInterestModal extends React.Component {
} else {
sendToAddressPromise(
this.props.ActiveCoin.coin,
this.state.selectedAddress, // this.state.transactionsList[0].address,
this.state.selectedAddress,
this.props.ActiveCoin.balance.transparent
).then((json) => {
if (json.error &&
@ -251,7 +251,7 @@ class ClaimInterestModal extends React.Component {
} else if (json.result && json.result.length && json.result.length === 64) {
Store.dispatch(
triggerToaster(
`${translate('TOASTR.CLAIM_INTEREST_BALANCE_SENT_P1')} ${this.state.transactionsList[0].address}. ${translate('TOASTR.CLAIM_INTEREST_BALANCE_SENT_P2')}`,
`${translate('TOASTR.CLAIM_INTEREST_BALANCE_SENT_P1')} ${this.state.selectedAddress}. ${translate('TOASTR.CLAIM_INTEREST_BALANCE_SENT_P2')}`,
translate('TOASTR.WALLET_NOTIFICATION'),
'success',
false
@ -349,8 +349,8 @@ class ClaimInterestModal extends React.Component {
render() {
if (this.props.ActiveCoin &&
this.props.ActiveCoin.coin /*&&
this.props.ActiveCoin.coin === 'KMD'*/) {
this.props.ActiveCoin.coin &&
this.props.ActiveCoin.coin === 'KMD') {
return ClaimInterestModalRender.call(this);
} else {
return null;

5
react/src/components/dashboard/coinTile/coinTileItem.js

@ -99,11 +99,11 @@ class CoinTileItem extends React.Component {
let _mode;
let _coin;
console.warn('allCoins', allCoins);
if (allCoins) {
modes.map((mode) => {
allCoins[mode].map((coin) => {
if (!_coinSelected && coin !== skipCoin) {
if (!_coinSelected &&
coin !== skipCoin) {
_coinSelected = true;
_coin = coin;
_mode = mode;
@ -123,7 +123,6 @@ class CoinTileItem extends React.Component {
});
setTimeout(() => {
console.warn('autoset active coin', _coin);
this._dashboardChangeActiveCoin(_coin, _mode, true);
}, 100);
}

Loading…
Cancel
Save