|
|
|
@ -5,10 +5,11 @@
|
|
|
|
|
|
|
|
|
|
<asp:Content ID="Content3" ContentPlaceHolderID="JavascriptContent" runat="server">
|
|
|
|
|
$(document).ready(function () {
|
|
|
|
|
setTimeout(MediaDetect(), 5000);
|
|
|
|
|
$("#Title").bind("click", MediaDetect);
|
|
|
|
|
$("#Mediabox").bind("click", MediaBoxClick);
|
|
|
|
|
setTimeout('MediaDetect();', 5000);
|
|
|
|
|
});
|
|
|
|
|
var Discovered = false;
|
|
|
|
|
|
|
|
|
|
function MediaDetect() {
|
|
|
|
|
$.ajax({
|
|
|
|
|
url: 'Series/MediaDetect',
|
|
|
|
@ -19,21 +20,34 @@
|
|
|
|
|
function MediaDetectCallback(data) {
|
|
|
|
|
Discovered=data.Discovered;
|
|
|
|
|
if(!Discovered)
|
|
|
|
|
setTimeout(MediaDetect(), 10000);
|
|
|
|
|
setTimeout('MediaDetect();', 10000);
|
|
|
|
|
else
|
|
|
|
|
LightUpMedia(data);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function LightUpMedia(data) {
|
|
|
|
|
|
|
|
|
|
$.ajax({
|
|
|
|
|
url: 'Series/LightUpMedia',
|
|
|
|
|
success: LightUpMediaSuccess
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
function LightUpMediaSuccess(data) {
|
|
|
|
|
$("#Mediabox").html(data.HTML);
|
|
|
|
|
}
|
|
|
|
|
function MediaBoxClick(args) {
|
|
|
|
|
$.ajax({
|
|
|
|
|
url: 'Series/ControlMedia',
|
|
|
|
|
data: "Action=" + args.target.className
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
</asp:Content>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
|
|
|
|
|
<div id="Title">Series</div>
|
|
|
|
|
Series
|
|
|
|
|
</asp:Content>
|
|
|
|
|
<asp:Content ID="Menue" ContentPlaceHolderID="ActionMenue" runat="server">
|
|
|
|
|
<div id="Mediabox"></div>
|
|
|
|
|
<%
|
|
|
|
|
Html.Telerik().Menu().Name("telerikGrid").Items(items => { items.Add().Text("View Unmapped Folders").Action("Unmapped", "Series"); })
|
|
|
|
|
.Items(items => items.Add().Text("Sync With Disk").Action("Sync", "Series"))
|
|
|
|
|