mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
fix user role change modal
This commit is contained in:
parent
3d1eb2b939
commit
c08b5387c5
@ -27,7 +27,7 @@
|
||||
:title="modalTitle"
|
||||
:cancel-title="$t('overlay.cancel')"
|
||||
:ok-title="modalOkTitle"
|
||||
@ok="modalEvent"
|
||||
@ok="setUserRole(roleSelected, currentRole)"
|
||||
>
|
||||
<p class="my-4">{{ modalQuestion }}</p>
|
||||
</b-modal>
|
||||
@ -60,17 +60,9 @@ export default {
|
||||
modalTitle: '',
|
||||
modalQuestion: '',
|
||||
modalOkTitle: '',
|
||||
modalEvent: null,
|
||||
username: '',
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
// roleSelected(newRole, oldRole) {
|
||||
// if (newRole !== oldRole) {
|
||||
// // this.setUserRole(newRole, oldRole)
|
||||
// }
|
||||
// },
|
||||
},
|
||||
methods: {
|
||||
showModal() {
|
||||
this.username = `${this.item.firstName} ${this.item.lastName}`
|
||||
@ -80,7 +72,6 @@ export default {
|
||||
newRole: this.roleSelected, // TODO get the text:Administrator instead of admin
|
||||
})
|
||||
this.modalOkTitle = this.$t('overlay.changeUserRole.yes')
|
||||
this.modalEvent = this.setUserRole(this.roleSelected, this.currentRole)
|
||||
},
|
||||
setUserRole(newRole, oldRole) {
|
||||
this.$apollo
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user