Browse Source

Add ChildCount to playlists

master
jeffvli 3 years ago
committed by Jeff
parent
commit
9c379c3ed8
  1. 4
      src/api/jellyfinApi.ts

4
src/api/jellyfinApi.ts

@ -127,7 +127,7 @@ const normalizePlaylist = (item: any) => {
export const getPlaylist = async (options: { id: string }) => { export const getPlaylist = async (options: { id: string }) => {
const { data } = await jellyfinApi.get(`/Items`, { const { data } = await jellyfinApi.get(`/Items`, {
params: { ids: options.id, UserId: auth.username, fields: 'DateCreated' }, params: { ids: options.id, UserId: auth.username, fields: 'DateCreated, ChildCount' },
}); });
const { data: songData } = await jellyfinApi.get(`/Playlists/${options.id}/Items`, { const { data: songData } = await jellyfinApi.get(`/Playlists/${options.id}/Items`, {
@ -147,7 +147,7 @@ export const getPlaylists = async () => {
sortBy: 'SortName', sortBy: 'SortName',
sortOrder: 'Ascending', sortOrder: 'Ascending',
includeItemTypes: 'Playlist', includeItemTypes: 'Playlist',
fields: 'DateCreated', fields: 'DateCreated, ChildCount',
recursive: true, recursive: true,
}, },
}); });

Loading…
Cancel
Save