ADD: Open Receive screen on push

This commit is contained in:
Marcos Rodriguez Vélez 2021-08-31 09:54:29 -04:00
parent 44a3eacda4
commit 16fe683ba4

24
App.js
View file

@ -219,16 +219,26 @@ const App = () => {
const walletID = wallet.getID();
fetchAndSaveWalletTransactions(walletID);
if (wasTapped) {
NavigationService.dispatch(
CommonActions.navigate({
name: 'WalletTransactions',
key: `WalletTransactions-${wallet.getID()}`,
if (payload.type !== 3 || wallet.chain === Chain.OFFCHAIN) {
NavigationService.dispatch(
CommonActions.navigate({
name: 'WalletTransactions',
key: `WalletTransactions-${wallet.getID()}`,
params: {
walletID,
walletType: wallet.type,
},
}),
);
} else {
NavigationService.navigate('ReceiveDetailsRoot', {
screen: 'ReceiveDetails',
params: {
walletID,
walletType: wallet.type,
address: payload.address,
},
}),
);
});
}
return true;
}