added people pages

This commit is contained in:
Luke Pulverenti
2013-04-11 23:50:47 -04:00
parent c3e3b68bb2
commit 8fe7dfd4ce
7 changed files with 86 additions and 28 deletions

View File

@@ -1552,6 +1552,29 @@ MediaBrowser.ApiClient = function ($, navigator, JSON, WebSocket, setTimeout) {
});
};
/**
Gets people from an item
*/
self.getPeople = function (userId, options) {
if (!userId) {
throw new Error("null userId");
}
var parentId = options.parentId || "root";
// Don't put these on the query string
delete options.parentId;
var url = self.getUrl("Users/" + userId + "/Items/" + parentId + "/Persons", options);
return self.ajax({
type: "GET",
url: url,
dataType: "json"
});
};
/**
Gets studios from an item
*/