Commit 6ad4ad2b authored by Ciarán Ainsworth's avatar Ciarán Ainsworth
Browse files

Merge branch '1289-channel-entry-covers' into 'develop'

Add prop for default cover

Closes #1289

See merge request !1253
parents 8fd0f899 804f9a7d
Changed default behaviour of channel entries to use channel artwork if no entry artwork available (#1289)
\ No newline at end of file
......@@ -5,7 +5,7 @@
<div v-if="isLoading" class="ui inverted active dimmer">
<div class="ui loader"></div>
<channel-entry-card v-for="entry in objects" :entry="entry" :key="" />
<channel-entry-card v-for="entry in objects" :default-cover="defaultCover" :entry="entry" :key="" />
<template v-if="count > limit">
<div class="ui hidden divider"></div>
<div class = "ui center aligned basic segment">
......@@ -38,6 +38,7 @@ export default {
props: {
filters: {type: Object, required: true},
limit: {type: Number, default: 10},
defaultCover: {type: Object},
components: {
......@@ -9,10 +9,11 @@
class="channel-image image"
v-if="cover && cover.urls.original"
@click="$router.push({name: 'library.tracks.detail', params: {id:}})"
class="channel-image image"
v-else-if="entry.artist.content_category === 'podcast'">#{{ entry.position }}</span>
v-else-if="entry.artist.content_category === 'podcast' && defaultCover != undefined"
@click="$router.push({name: 'library.tracks.detail', params: {id:}})"
......@@ -53,7 +54,7 @@ import { mapGetters } from "vuex"
export default {
props: ['entry'],
props: ['entry', 'defaultCover'],
components: {
......@@ -49,7 +49,7 @@
<div class="ui hidden divider"></div>
<channel-entries :key="String(episodesKey) + 'entries'" :limit='25' :filters="{channel: object.uuid, ordering: '-creation_date', page_size: '25'}">
<channel-entries :key="String(episodesKey) + 'entries'" :default-cover='object.artist.cover' :limit='25' :filters="{channel: object.uuid, ordering: '-creation_date', page_size: '25'}">
<h2 class="ui header">
<translate key="1" v-if="isPodcast" translate-context="Content/Channel/Paragraph">Latest episodes</translate>
<translate key="2" v-else translate-context="Content/Channel/Paragraph">Latest tracks</translate>
Supports Markdown
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