mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/lyswhut/lx-music-desktop.git
synced 2026-09-20 08:04:00 +08:00
优化kw歌单列表数据显示
This commit is contained in:
@@ -145,22 +145,25 @@ export default {
|
||||
}))
|
||||
},
|
||||
filterList2(rawData) {
|
||||
// console.log(rawData)
|
||||
const list = []
|
||||
const allowedTypes = ['songlist', 'list', 'album']
|
||||
// digest: 5 = list, 8 = songlist, 13 = album, 4 = artist
|
||||
rawData.forEach(item => {
|
||||
if (!item.label) return
|
||||
list.push(...item.list.map(item => ({
|
||||
play_count: item.play_count && this.formatPlayCount(item.listencnt),
|
||||
id: `digest-${item.digest}__${item.id}`,
|
||||
author: item.uname,
|
||||
name: item.name,
|
||||
total: item.total,
|
||||
// time: item.publish_time,
|
||||
img: item.img,
|
||||
grade: item.favorcnt && item.favorcnt / 10,
|
||||
desc: item.desc,
|
||||
source: 'kw',
|
||||
})))
|
||||
item.list.forEach(item => {
|
||||
if (!allowedTypes.includes(item.type)) return
|
||||
list.push({
|
||||
play_count: item.play_count && this.formatPlayCount(item.listencnt),
|
||||
id: `digest-${item.digest}__${item.id}`,
|
||||
author: item.uname,
|
||||
name: item.name,
|
||||
total: item.total,
|
||||
// time: item.publish_time,
|
||||
img: item.img,
|
||||
grade: item.favorcnt && item.favorcnt / 10,
|
||||
desc: item.desc,
|
||||
source: 'kw',
|
||||
})
|
||||
})
|
||||
})
|
||||
return list
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user