diff --git a/src/views/WalletAccountDetail.vue b/src/views/WalletAccountDetail.vue index 9469c13e..b0ad742f 100644 --- a/src/views/WalletAccountDetail.vue +++ b/src/views/WalletAccountDetail.vue @@ -49,6 +49,18 @@ /> Transfer + + Transfer1 + @@ -213,7 +214,6 @@ export default { }) this.$http.getStakingDelegations(this.address).then(res => { this.delegations = res.delegation_responses - console.log(res) this.delegations.forEach(x => { if (x.delegation.validator_address === this.validatorAddress) { this.token = x.balance.denom diff --git a/src/views/components/OperationModal/components/Transfer.vue b/src/views/components/OperationModal/components/Transfer.vue new file mode 100644 index 00000000..53bc5d4c --- /dev/null +++ b/src/views/components/OperationModal/components/Transfer.vue @@ -0,0 +1,204 @@ + + + diff --git a/src/views/components/OperationModal/components/Unbond.vue b/src/views/components/OperationModal/components/Unbond.vue index 76c6b299..bf00902d 100644 --- a/src/views/components/OperationModal/components/Unbond.vue +++ b/src/views/components/OperationModal/components/Unbond.vue @@ -105,7 +105,6 @@ export default { vSelect, BInputGroupAppend, ValidationProvider, - }, props: { validatorAddress: { @@ -123,7 +122,6 @@ export default { selectedValidator: this.validatorAddress, token: '', amount: null, - balance: [], delegations: [], required, @@ -167,24 +165,16 @@ export default { modalTitle: 'Unbond Token', historyName: 'unbond', }) - this.loadBalance() + this.loadData() }, methods: { - printDenom() { - return formatTokenDenom(this.token) - }, - loadBalance() { + loadData() { if (this.address) { this.$http.getValidatorList().then(v => { this.validators = v }) } - this.$http.getBankBalances(this.address).then(res => { - if (res && res.length > 0) { - this.balance = res.reverse() - } - }) this.$http.getStakingDelegations(this.address).then(res => { this.delegations = res.delegation_responses this.delegations.forEach(x => { @@ -197,7 +187,9 @@ export default { }) }) }, - + printDenom() { + return formatTokenDenom(this.token) + }, }, } diff --git a/src/views/components/OperationModal/index.vue b/src/views/components/OperationModal/index.vue index ccb50702..22d5ef1c 100644 --- a/src/views/components/OperationModal/index.vue +++ b/src/views/components/OperationModal/index.vue @@ -155,6 +155,7 @@ import Delegate from './components/Delegate.vue' import Redelegate from './components/Redelegate.vue' import Withdraw from './components/Withdraw.vue' import Unbond from './components/Unbond.vue' +import Transfer from './components/Transfer.vue' export default { name: 'DelegateDialogue', @@ -184,6 +185,7 @@ export default { Redelegate, Withdraw, Unbond, + Transfer, }, directives: { Ripple,