Skip to content

Commit 55c6ecf

Browse files
committed
Add ability to delete phone number
1 parent d6ae47d commit 55c6ecf

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

web/pages/settings/index.vue

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@
8484
:icon="$vuetify.breakpoint.mdAndDown"
8585
small
8686
color="error"
87+
:disabled="deletingPhone"
8788
@click.prevent="deletePhone(phone.id)"
8889
>
8990
<v-icon small>mdi-delete</v-icon>
@@ -110,6 +111,7 @@ export default {
110111
data() {
111112
return {
112113
apiKeyShow: false,
114+
deletingPhone: false,
113115
}
114116
},
115117
computed: {
@@ -131,7 +133,10 @@ export default {
131133
132134
methods: {
133135
deletePhone(phoneId) {
134-
this.$store.dispatch('deletePhone', phoneId)
136+
this.deletingPhone = true
137+
this.$store.dispatch('deletePhone', phoneId).finally(() => {
138+
this.deletingPhone = false
139+
})
135140
},
136141
},
137142
}

0 commit comments

Comments
 (0)