chore: code clean-up
This commit is contained in:
parent
a27bbe628c
commit
87f6eda206
2 changed files with 1 additions and 46 deletions
|
|
@ -12,7 +12,7 @@ async function serialSigner(path) {
|
||||||
writer: null,
|
writer: null,
|
||||||
readableStreamClosed: null,
|
readableStreamClosed: null,
|
||||||
reader: null,
|
reader: null,
|
||||||
showAdvancedConfig: false,
|
|
||||||
receivedData: '',
|
receivedData: '',
|
||||||
config: {},
|
config: {},
|
||||||
hww: {
|
hww: {
|
||||||
|
|
|
||||||
|
|
@ -21,8 +21,6 @@ const watchOnly = async () => {
|
||||||
mixins: [windowMixin],
|
mixins: [windowMixin],
|
||||||
data: function () {
|
data: function () {
|
||||||
return {
|
return {
|
||||||
filter: '', // todo: remove?
|
|
||||||
|
|
||||||
scan: {
|
scan: {
|
||||||
scanning: false,
|
scanning: false,
|
||||||
scanCount: 0,
|
scanCount: 0,
|
||||||
|
|
@ -43,33 +41,6 @@ const watchOnly = async () => {
|
||||||
show: false
|
show: false
|
||||||
},
|
},
|
||||||
|
|
||||||
serial: {
|
|
||||||
selectedPort: null,
|
|
||||||
writableStreamClosed: null,
|
|
||||||
writer: null,
|
|
||||||
readableStreamClosed: null,
|
|
||||||
reader: null,
|
|
||||||
showAdvancedConfig: false,
|
|
||||||
receivedData: '',
|
|
||||||
config: {}
|
|
||||||
},
|
|
||||||
|
|
||||||
hww: {
|
|
||||||
password: null,
|
|
||||||
showPassword: false,
|
|
||||||
mnemonic: null,
|
|
||||||
showMnemonic: false,
|
|
||||||
authenticated: false,
|
|
||||||
showPasswordDialog: false,
|
|
||||||
showWipeDialog: false,
|
|
||||||
showRestoreDialog: false,
|
|
||||||
showConsole: false,
|
|
||||||
showSignedPsbt: false,
|
|
||||||
sendingPsbt: false,
|
|
||||||
signingPsbt: false,
|
|
||||||
psbtSent: false
|
|
||||||
},
|
|
||||||
|
|
||||||
qrCodeDialog: {
|
qrCodeDialog: {
|
||||||
show: false,
|
show: false,
|
||||||
data: null
|
data: null
|
||||||
|
|
@ -89,16 +60,6 @@ const watchOnly = async () => {
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
//################### CONFIG ###################
|
|
||||||
|
|
||||||
//################### WALLETS ###################
|
|
||||||
|
|
||||||
getWalletName: function (walletId) {
|
|
||||||
const wallet = this.walletAccounts.find(wl => wl.id === walletId)
|
|
||||||
return wallet ? wallet.title : 'unknown'
|
|
||||||
},
|
|
||||||
//################### ADDRESSES ###################
|
|
||||||
|
|
||||||
updateAmountForAddress: async function (addressData, amount = 0) {
|
updateAmountForAddress: async function (addressData, amount = 0) {
|
||||||
try {
|
try {
|
||||||
const wallet = this.g.user.wallets[0]
|
const wallet = this.g.user.wallets[0]
|
||||||
|
|
@ -184,9 +145,6 @@ const watchOnly = async () => {
|
||||||
el.sameTxItems = sameTxItems
|
el.sameTxItems = sameTxItems
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
showAddressHistoryDetails: function (addressHistory) {
|
|
||||||
addressHistory.expanded = true
|
|
||||||
},
|
|
||||||
|
|
||||||
//################### PAYMENT ###################
|
//################### PAYMENT ###################
|
||||||
|
|
||||||
|
|
@ -355,9 +313,6 @@ const watchOnly = async () => {
|
||||||
this[`${tab}Table`].filter = value
|
this[`${tab}Table`].filter = value
|
||||||
},
|
},
|
||||||
|
|
||||||
satBtc(val, showUnit = true) {
|
|
||||||
return satOrBtc(val, showUnit, this.config.data.sats_denominated)
|
|
||||||
},
|
|
||||||
updateAccounts: async function (accounts) {
|
updateAccounts: async function (accounts) {
|
||||||
this.walletAccounts = accounts
|
this.walletAccounts = accounts
|
||||||
// await this.refreshAddressesxx() // todo: automatic now?
|
// await this.refreshAddressesxx() // todo: automatic now?
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue