Commit 4af56117 authored by gj4210's avatar gj4210 👽
Browse files

ADD: "Remove all roles" button

parent 8545452c
Pipeline #114399 passed with stages
in 8 minutes and 30 seconds
......@@ -56,6 +56,9 @@
sticky-header/>
</b-popover>
</template>
<b-button v-if="new_account.roles.length > 0" variant="outline-danger" block class="mt-1" @click="removeAllRoles">
Alle Rollen entfernen
</b-button>
</h5>
</template>
</b-form-group>
......@@ -138,6 +141,9 @@
sticky-header/>
</b-popover>
</template>
<b-button v-if="new_account.roles.length > 0" variant="outline-danger" block class="mt-1" @click="removeAllRoles">
Alle Rollen entfernen
</b-button>
</h5>
</b-form-group>
</template>
......@@ -568,6 +574,8 @@ export default {
do_copy_roles: true,
roles: []
}
this.new_system = ''
this.new_role_name = ''
},
resetTokenData() {
this.new_token = {
......@@ -747,6 +755,10 @@ export default {
}
this.updateCanAddRole()
},
removeAllRoles() {
this.new_account.roles = []
this.updateCanAddRole()
},
updateCanAddRole() {
const new_role = this.new_system + '.' + this.new_role_name
if (!this.new_system || !this.new_role_name || !this.assignable_roles_by_fq_name[new_role]) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment