Skip to content

Commit

Permalink
Allow HLS test page to filter recordings by Recording Group
Browse files Browse the repository at this point in the history
Use GetFilteredRecordedList and GetRecGroupList Dvr Service
endpoints.
  • Loading branch information
cpinkham committed Jun 14, 2013
1 parent c994ace commit 15ec588
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions mythtv/html/samples/hlstest.qsp
Expand Up @@ -259,10 +259,13 @@ function listFiles() {

function listRecordings() {
var filter = $("#recFilter").val().toLowerCase();
var recgroup = $("#recGroup").val();

$("#links").html("<i18n>Loading</i18n>...");
$.getJSON("/Dvr/GetRecordedList",
{ Descending: 1, StartIndex: 0, nCount: 20000 }, function(data) {
$.getJSON("/Dvr/GetFilteredRecordedList",
{ Descending: 1, StartIndex: 0, Count: 20000,
RecGroup: recgroup },
function(data) {
$("#links").html("");

var str = getFormStart();
Expand Down Expand Up @@ -330,6 +333,19 @@ function listRecordings() {
<div>
<b><i18n>Recordings:</i18n></b><br>
<i18n>Filter</i18n>: <input id='recFilter' size=20>&nbsp;
Recording Group: <select id='recGroup'>
<%
var dvr = new Dvr();
var recGroups = dvr.GetRecGroupList();

for (var i=0; i < recGroups.length; i++)
{
%>
<option value='<%= recGroups[i] %>'><%= recGroups[i] %></option>
<%
}
%>
</select>
<input type='button' onClick='javascript:listRecordings()' value='<i18n>List Recordings</i18n>'>
</div>
<div id="links"></div>
Expand Down

0 comments on commit 15ec588

Please sign in to comment.