2018-12-15 09:56:09 +01:00
|
|
|
<template>
|
2025-02-09 17:52:45 +01:00
|
|
|
<modal-dialog-playable
|
|
|
|
:item="playable"
|
|
|
|
:show="show"
|
|
|
|
@close="$emit('close')"
|
|
|
|
/>
|
2018-12-15 09:56:09 +01:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
2025-02-09 11:13:23 +01:00
|
|
|
import ModalDialogPlayable from '@/components/ModalDialogPlayable.vue'
|
2018-12-15 09:56:09 +01:00
|
|
|
|
|
|
|
export default {
|
|
|
|
name: 'ModalDialogArtist',
|
2025-02-09 11:13:23 +01:00
|
|
|
components: { ModalDialogPlayable },
|
2024-03-26 03:13:17 +01:00
|
|
|
props: { item: { required: true, type: Object }, show: Boolean },
|
2022-02-19 07:05:59 +01:00
|
|
|
emits: ['close'],
|
2025-02-09 17:52:45 +01:00
|
|
|
computed: {
|
|
|
|
playable() {
|
|
|
|
return {
|
|
|
|
name: this.item.name,
|
2025-02-12 18:50:22 +01:00
|
|
|
handler: this.open,
|
2025-02-09 17:52:45 +01:00
|
|
|
properties: [
|
2025-02-12 18:50:22 +01:00
|
|
|
{ label: 'property.albums', value: this.item.album_count },
|
|
|
|
{ label: 'property.tracks', value: this.item.track_count },
|
2025-02-09 17:52:45 +01:00
|
|
|
{
|
2025-02-12 18:50:22 +01:00
|
|
|
label: 'property.type',
|
2025-02-09 17:52:45 +01:00
|
|
|
value: this.$t(`data.kind.${this.item.data_kind}`)
|
|
|
|
},
|
|
|
|
{
|
2025-02-12 18:50:22 +01:00
|
|
|
label: 'property.added-on',
|
2025-02-09 17:52:45 +01:00
|
|
|
value: this.$filters.datetime(this.item.time_added)
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2018-12-15 09:56:09 +01:00
|
|
|
methods: {
|
2024-03-26 03:13:17 +01:00
|
|
|
open() {
|
2024-03-26 01:17:07 +01:00
|
|
|
this.$emit('close')
|
|
|
|
this.$router.push({
|
|
|
|
name: 'music-artist',
|
2024-03-26 03:13:17 +01:00
|
|
|
params: { id: this.item.id }
|
2024-03-26 01:17:07 +01:00
|
|
|
})
|
2018-12-15 09:56:09 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|