Add managing subscription to namespace dropdown

This commit is contained in:
kolaente 2021-02-14 18:16:43 +01:00
parent b611f21c1d
commit 5de350c30d
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 18 additions and 0 deletions

View File

@ -33,6 +33,14 @@
>
Archive
</dropdown-item>
<task-subscription
class="dropdown-item has-no-shadow"
:is-button="false"
entity="namespace"
:entity-id="namespace.id"
:subscription="subscription"
@change="sub => subscription = sub"
/>
<dropdown-item
:to="{ name: 'namespace.settings.delete', params: { id: namespace.id } }"
icon="trash-alt"
@ -47,17 +55,27 @@
<script>
import Dropdown from '@/components/misc/dropdown'
import DropdownItem from '@/components/misc/dropdown-item'
import TaskSubscription from '@/components/misc/subscription'
export default {
name: 'namespace-settings-dropdown',
data() {
return {
subscription: null,
}
},
components: {
DropdownItem,
Dropdown,
TaskSubscription,
},
props: {
namespace: {
required: true,
},
},
mounted() {
this.subscription = this.namespace.subscription
},
}
</script>