jellyfin/MediaBrowser.Api/HttpHandlers/YearsHandler.cs
2012-08-14 12:06:46 -04:00

21 lines
539 B
C#

using System;
using MediaBrowser.Controller;
using MediaBrowser.Model.Entities;
namespace MediaBrowser.Api.HttpHandlers
{
public class YearsHandler : JsonHandler
{
protected override object ObjectToSerialize
{
get
{
Folder parent = ApiService.GetItemById(QueryString["id"]) as Folder;
Guid userId = Guid.Parse(QueryString["userid"]);
return Kernel.Instance.GetAllYears(parent, userId);
}
}
}
}