Merge pull request #5740 from JDonadio/bug/import-qr
Fix import QR code from main scan button
This commit is contained in:
commit
b9fa8bcb21
2 changed files with 9 additions and 2 deletions
|
|
@ -328,7 +328,7 @@ angular.module('copayApp').config(function(historicLogProvider, $provide, $logPr
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.state('tabs.add.import', {
|
.state('tabs.add.import', {
|
||||||
url: '/import',
|
url: '/import/:code',
|
||||||
views: {
|
views: {
|
||||||
'tab-home@tabs': {
|
'tab-home@tabs': {
|
||||||
templateUrl: 'views/import.html',
|
templateUrl: 'views/import.html',
|
||||||
|
|
|
||||||
|
|
@ -220,8 +220,15 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat
|
||||||
data: data,
|
data: data,
|
||||||
type: 'privateKey'
|
type: 'privateKey'
|
||||||
});
|
});
|
||||||
} else {
|
} else if (data && ((data.substring(0, 2) == '1|') || (data.substring(0, 2) == '2|') || (data.substring(0, 2) == '3|'))) {
|
||||||
|
$state.go('tabs.home').then(function() {
|
||||||
|
$state.transitionTo('tabs.add.import', {
|
||||||
|
code: data
|
||||||
|
});
|
||||||
|
});
|
||||||
|
return true;
|
||||||
|
|
||||||
|
} else {
|
||||||
if ($state.includes('tabs.scan')) {
|
if ($state.includes('tabs.scan')) {
|
||||||
root.showMenu({
|
root.showMenu({
|
||||||
data: data,
|
data: data,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue