Update folder scanner and db to store LocalLibraryItem objects instead of LocalMediaItem objects, some ui fixes and audio player service binding fix

This commit is contained in:
advplyr 2022-04-05 19:44:14 -05:00
parent 77ef0c119b
commit 12de187b7a
22 changed files with 248 additions and 158 deletions

View file

@ -73,14 +73,14 @@ class DbService {
})
}
getLocalMediaItemsInFolder(folderId) {
getLocalLibraryItemsInFolder(folderId) {
if (isWeb) return []
return AbsDatabase.getLocalMediaItemsInFolder({ folderId }).then((data) => {
console.log('Loaded local media items in folder', JSON.stringify(data))
if (data.localMediaItems && typeof data.localMediaItems == 'string') {
return JSON.parse(data.localMediaItems)
return AbsDatabase.getLocalLibraryItemsInFolder({ folderId }).then((data) => {
console.log('Loaded local library items in folder', JSON.stringify(data))
if (data.localLibraryItems && typeof data.localLibraryItems == 'string') {
return JSON.parse(data.localLibraryItems)
}
return data.localMediaItems
return data.localLibraryItems
})
}