add editPlayListDescription
This commit is contained in:
parent
bea817df2d
commit
80f408a7aa
1 changed files with 15 additions and 0 deletions
|
@ -1349,6 +1349,21 @@ const app = new Vue({
|
||||||
self.refreshPlaylists(false, false)
|
self.refreshPlaylists(false, false)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
async editPlaylistDescription(id, name = app.getLz('term.newPlaylist')) {
|
||||||
|
let self = this
|
||||||
|
this.mk.api.v3.music(
|
||||||
|
`/v1/me/library/playlists/${id}`, {}, {
|
||||||
|
fetchOptions: {
|
||||||
|
method: "PATCH",
|
||||||
|
body: JSON.stringify({
|
||||||
|
attributes: { description: name }
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
).then(res => {
|
||||||
|
self.refreshPlaylists(false, false)
|
||||||
|
})
|
||||||
|
},
|
||||||
copyToClipboard(str) {
|
copyToClipboard(str) {
|
||||||
// if (navigator.userAgent.includes('Darwin') || navigator.appVersion.indexOf("Mac") != -1) {
|
// if (navigator.userAgent.includes('Darwin') || navigator.appVersion.indexOf("Mac") != -1) {
|
||||||
// this.darwinShare(str)
|
// this.darwinShare(str)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue