added see all

This commit is contained in:
booploops 2022-03-16 19:32:38 -07:00
parent edc36fbe6c
commit 7359298aa9

View file

@ -9,6 +9,7 @@
</div> </div>
<div class="col-auto nopadding flex-center"> <div class="col-auto nopadding flex-center">
<button class="cd-btn-seeall" @click="seeAllHistory()">{{app.getLz('term.history')}}</button> <button class="cd-btn-seeall" @click="seeAllHistory()">{{app.getLz('term.history')}}</button>
<button class="cd-btn-seeall" @click="seeAllRecentlyPlayed()">{{app.getLz('term.seeAll')}}</button>
</div> </div>
</div> </div>
<div class="well artistfeed-well"> <div class="well artistfeed-well">
@ -127,6 +128,12 @@
} }
}, },
methods: { methods: {
async seeAllRecentlyPlayed() {
let hist = await app.mk.api.v3.music(`/v1/me/recent/played`, {
l: this.$root.mklang
})
app.showCollection(hist.data, app.getLz('home.recentlyPlayed'))
},
async seeAllHistory() { async seeAllHistory() {
let hist = await app.mk.api.v3.music(`/v1/me/recent/played/tracks`, { let hist = await app.mk.api.v3.music(`/v1/me/recent/played/tracks`, {
l: this.$root.mklang l: this.$root.mklang