Merge pull request #799 from UnbreakCode/develop
move album genre under album name and add release year
This commit is contained in:
commit
2f4266ddd5
2 changed files with 16 additions and 2 deletions
|
@ -40,6 +40,7 @@
|
||||||
@change="editPlaylist"
|
@change="editPlaylist"
|
||||||
@keydown.enter="editPlaylist"/>
|
@keydown.enter="editPlaylist"/>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="playlist-time genre" style="margin: 0px;">{{getAlbumGenre()}}</div>
|
||||||
<div class="playlist-artist item-navigate"
|
<div class="playlist-artist item-navigate"
|
||||||
v-if="getArtistName(data) != '' && !useArtistChip"
|
v-if="getArtistName(data) != '' && !useArtistChip"
|
||||||
@click="data.attributes && data.attributes.artistName ? app.searchAndNavigate(data,'artist') : ''">
|
@click="data.attributes && data.attributes.artistName ? app.searchAndNavigate(data,'artist') : ''">
|
||||||
|
@ -168,7 +169,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="playlist-time genre">{{this.data.relationships.tracks.data[0].attributes.genreNames[0]}}</div>
|
|
||||||
<div class="playlist-time">
|
<div class="playlist-time">
|
||||||
{{getFormattedDate()}}
|
{{getFormattedDate()}}
|
||||||
</div>
|
</div>
|
||||||
|
@ -285,6 +285,13 @@
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
getAlbumGenre: function () {
|
||||||
|
if (this.data.type.includes('albums')) {
|
||||||
|
let date = this.data.attributes.releaseDate;
|
||||||
|
if (date == null || date === "") return "";
|
||||||
|
return `${this.data.relationships.tracks.data[0].attributes.genreNames[0]} · ${new Date(date).getFullYear()}`
|
||||||
|
}
|
||||||
|
},
|
||||||
async isInLibrary() {
|
async isInLibrary() {
|
||||||
if (this.data.type && !this.data.type.includes("library")) {
|
if (this.data.type && !this.data.type.includes("library")) {
|
||||||
// please keep using vars here
|
// please keep using vars here
|
||||||
|
|
|
@ -48,6 +48,7 @@
|
||||||
@change="editPlaylist"
|
@change="editPlaylist"
|
||||||
@keydown.enter="editPlaylist"/>
|
@keydown.enter="editPlaylist"/>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="playlist-time genre" style="margin: 0px;">{{getAlbumGenre()}}</div>
|
||||||
<div class="playlist-artist item-navigate"
|
<div class="playlist-artist item-navigate"
|
||||||
v-if="getArtistName(data) != '' && !useArtistChip"
|
v-if="getArtistName(data) != '' && !useArtistChip"
|
||||||
@click="data.attributes && data.attributes.artistName ? app.searchAndNavigate(data,'artist') : ''">
|
@click="data.attributes && data.attributes.artistName ? app.searchAndNavigate(data,'artist') : ''">
|
||||||
|
@ -179,7 +180,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="playlist-time genre">{{this.data.relationships.tracks.data[0].attributes.genreNames[0]}}</div>
|
|
||||||
<div class="playlist-time">
|
<div class="playlist-time">
|
||||||
{{getFormattedDate()}}
|
{{getFormattedDate()}}
|
||||||
</div>
|
</div>
|
||||||
|
@ -309,6 +309,13 @@
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
getAlbumGenre: function () {
|
||||||
|
if (this.data.type.includes('albums')) {
|
||||||
|
let date = this.data.attributes.releaseDate;
|
||||||
|
if (date == null || date === "") return "";
|
||||||
|
return `${this.data.relationships.tracks.data[0].attributes.genreNames[0]} · ${new Date(date).getFullYear()}`
|
||||||
|
}
|
||||||
|
},
|
||||||
async isInLibrary() {
|
async isInLibrary() {
|
||||||
if (this.data.type && !this.data.type.includes("library")) {
|
if (this.data.type && !this.data.type.includes("library")) {
|
||||||
// please keep using vars here
|
// please keep using vars here
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue