|
|
@@ -29,9 +29,7 @@ $hasOptions = "No";
|
|
|
foreach($dbOptions as $row) :
|
|
|
|
|
|
if (in_array("options", $row)) :
|
|
|
-
|
|
|
$hasOptions = "Yes";
|
|
|
-
|
|
|
endif;
|
|
|
|
|
|
endforeach;
|
|
|
@@ -57,7 +55,6 @@ endif;
|
|
|
if($hasOptions == "Yes") :
|
|
|
|
|
|
$resulto = $file_db->query('SELECT * FROM options');
|
|
|
-
|
|
|
foreach($resulto as $row) :
|
|
|
|
|
|
$title = isset($row['title']) ? $row['title'] : "Organizr";
|
|
|
@@ -88,7 +85,6 @@ $endDate = date('Y-m-d',strtotime("+".CALENDARENDDAY." days"));
|
|
|
<html lang="en" class="no-js">
|
|
|
|
|
|
<head>
|
|
|
-
|
|
|
<meta charset="UTF-8">
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
|
@@ -99,7 +95,6 @@ $endDate = date('Y-m-d',strtotime("+".CALENDARENDDAY." days"));
|
|
|
<link rel="stylesheet" href="bower_components/bootstrap/dist/css/bootstrap.min.css">
|
|
|
<link rel="stylesheet" href="bower_components/font-awesome/css/font-awesome.min.css">
|
|
|
<link rel="stylesheet" href="bower_components/malihu-custom-scrollbar-plugin/jquery.mCustomScrollbar.css">
|
|
|
-
|
|
|
<script src="js/menu/modernizr.custom.js"></script>
|
|
|
|
|
|
<link rel="stylesheet" href="bower_components/animate.css/animate.min.css">
|
|
|
@@ -112,7 +107,6 @@ $endDate = date('Y-m-d',strtotime("+".CALENDARENDDAY." days"));
|
|
|
<script src="bower_components/html5shiv/dist/html5shiv.min.js"></script>
|
|
|
<script src="bower_components/respondJs/dest/respond.min.js"></script>
|
|
|
<![endif]-->
|
|
|
-
|
|
|
<style>
|
|
|
sort {
|
|
|
display: none;
|
|
|
@@ -185,15 +179,12 @@ echo fread($file_handle, filesize($template_file));
|
|
|
fclose($file_handle);
|
|
|
echo "\n";
|
|
|
endif; ?>
|
|
|
-
|
|
|
</style>
|
|
|
-
|
|
|
</head>
|
|
|
|
|
|
<body class="scroller-body" style="padding: 0px;">
|
|
|
|
|
|
<div class="main-wrapper" style="position: initial;">
|
|
|
-
|
|
|
<div id="content" class="container-fluid">
|
|
|
<!-- <button id="numBnt">Numerical</button> -->
|
|
|
<br/>
|
|
|
@@ -202,7 +193,6 @@ endif; ?>
|
|
|
<sort>2</sort>
|
|
|
|
|
|
<div class="col-xs-12 col-md-12">
|
|
|
-
|
|
|
<div class="content-box">
|
|
|
|
|
|
<div class="tabbable panel with-nav-tabs panel-default">
|
|
|
@@ -218,11 +208,8 @@ endif; ?>
|
|
|
</a>
|
|
|
|
|
|
<a class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
|
|
|
-
|
|
|
<i class="fa fa-chevron-down"></i>
|
|
|
-
|
|
|
</a>
|
|
|
-
|
|
|
<ul id="downloaderSeconds" class="dropdown-menu" style="top: 32px !important">
|
|
|
|
|
|
<li data-value="5000"><a>Refresh every 5 seconds</a></li>
|
|
|
@@ -315,7 +302,6 @@ endif; ?>
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
-
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
@@ -324,7 +310,6 @@ endif; ?>
|
|
|
<?php endif; ?>
|
|
|
|
|
|
<div id="plexRow" class="row">
|
|
|
-
|
|
|
<sort>3</sort>
|
|
|
|
|
|
<?php
|
|
|
@@ -334,7 +319,6 @@ endif; ?>
|
|
|
if(PLEXRECENTMUSIC == "true"){ $plexSize++; }
|
|
|
if(PLEXPLAYINGNOW == "true"){ $plexSize++; }
|
|
|
if($plexSize >= 4){ $plexSize = 3; }elseif($plexSize == 3){ $plexSize = 4; }elseif($plexSize == 2){ $plexSize = 6; }elseif($plexSize == 1){ $plexSize = 12; }
|
|
|
-
|
|
|
if(PLEXRECENTMOVIE == "true"){ echo getPlexRecent("movie", $plexSize); }
|
|
|
if(PLEXRECENTTV == "true"){ echo getPlexRecent("season", $plexSize); }
|
|
|
if(PLEXRECENTMUSIC == "true"){ echo getPlexRecent("album", $plexSize); }
|
|
|
@@ -342,9 +326,7 @@ endif; ?>
|
|
|
?>
|
|
|
|
|
|
</div>
|
|
|
-
|
|
|
<div id="embyRow" class="row">
|
|
|
-
|
|
|
<sort>3</sort>
|
|
|
|
|
|
<?php
|
|
|
@@ -354,7 +336,6 @@ endif; ?>
|
|
|
if(EMBYRECENTMUSIC == "true"){ $embySize++; }
|
|
|
if(EMBYPLAYINGNOW == "true"){ $embySize++; }
|
|
|
if($embySize >= 4){ $embySize = 3; }elseif($embySize == 3){ $embySize = 4; }elseif($embySize == 2){ $embySize = 6; }elseif($embySize == 1){ $embySize = 12; }
|
|
|
-
|
|
|
if(EMBYRECENTMOVIE == "true"){ echo getEmbyRecent("movie", $embySize); }
|
|
|
if(EMBYRECENTTV == "true"){ echo getEmbyRecent("season", $embySize); }
|
|
|
if(EMBYRECENTMUSIC == "true"){ echo getEmbyRecent("album", $embySize); }
|
|
|
@@ -362,16 +343,11 @@ endif; ?>
|
|
|
?>
|
|
|
|
|
|
</div>
|
|
|
-
|
|
|
<?php if(SONARRURL != "" || RADARRURL != "" || HEADPHONESURL != "" || SICKRAGEURL != "") : ?>
|
|
|
<div id="calendarLegendRow" class="row" style="padding: 0 0 10px 0;">
|
|
|
-
|
|
|
<sort>1</sort>
|
|
|
-
|
|
|
<div class="col-lg-12 content-form form-inline">
|
|
|
-
|
|
|
<div class="form-group">
|
|
|
-
|
|
|
<select class="form-control" id="imagetype_selector" style="width: auto !important; display: inline-block">
|
|
|
|
|
|
<option value="all">View All</option>
|
|
|
@@ -385,30 +361,19 @@ endif; ?>
|
|
|
<span class="label label-danger well-sm">Unavailable</span>
|
|
|
<span class="label indigo-bg well-sm">Unreleased</span>
|
|
|
<span class="label light-blue-bg well-sm">Premier</span>
|
|
|
-
|
|
|
</div>
|
|
|
-
|
|
|
</div>
|
|
|
-
|
|
|
</div>
|
|
|
-
|
|
|
<div id="calendarRow" class="row">
|
|
|
-
|
|
|
<sort>1</sort>
|
|
|
-
|
|
|
<div class="col-lg-12">
|
|
|
-
|
|
|
<div id="calendar" class="fc-calendar box-shadow fc fc-ltr fc-unthemed"></div>
|
|
|
-
|
|
|
</div>
|
|
|
-
|
|
|
</div>
|
|
|
<?php endif; ?>
|
|
|
|
|
|
</div>
|
|
|
-
|
|
|
</div>
|
|
|
-
|
|
|
<!--Scripts-->
|
|
|
<script src="bower_components/jquery/dist/jquery.min.js"></script>
|
|
|
<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
|
|
|
@@ -418,16 +383,12 @@ endif; ?>
|
|
|
<script src="bower_components/malihu-custom-scrollbar-plugin/jquery.mCustomScrollbar.js"></script>
|
|
|
<script src="bower_components/jquery.nicescroll/jquery.nicescroll.min.js"></script>
|
|
|
<script src="bower_components/cta/dist/cta.min.js"></script>
|
|
|
-
|
|
|
<script src="bower_components/fullcalendar/dist/fullcalendar.js"></script>
|
|
|
|
|
|
<script src="js/jqueri_ui_custom/jquery-ui.min.js"></script>
|
|
|
<script src="js/jquery.mousewheel.min.js" type="text/javascript"></script>
|
|
|
-
|
|
|
<script>
|
|
|
-
|
|
|
$( document ).ready(function() {
|
|
|
-
|
|
|
$('.repeat-btn').click(function(){
|
|
|
var refreshBox = $(this).closest('div.content-box');
|
|
|
$("<div class='refresh-preloader'><div class='la-timer la-dark'><div></div></div></div>").appendTo(refreshBox).fadeIn(300);
|
|
|
@@ -446,60 +407,44 @@ endif; ?>
|
|
|
scrollspeed: 30,
|
|
|
mousescrollstep: 60
|
|
|
});
|
|
|
-
|
|
|
$(".table-responsive").niceScroll({
|
|
|
railpadding: {top:0,right:0,left:0,bottom:0},
|
|
|
scrollspeed: 30,
|
|
|
mousescrollstep: 60
|
|
|
});
|
|
|
-
|
|
|
/*$(".carousel-caption").niceScroll({
|
|
|
railpadding: {top:0,right:0,left:0,bottom:0},
|
|
|
scrollspeed: 30,
|
|
|
mousescrollstep: 60
|
|
|
});*/
|
|
|
-
|
|
|
// check if browser support HTML5 local storage
|
|
|
function localStorageSupport() {
|
|
|
return (('localStorage' in window) && window['localStorage'] !== null)
|
|
|
}
|
|
|
-
|
|
|
<?php if(($USER->authenticated && $USER->role == "admin") && (NZBGETURL != "" || SABNZBDURL != "")){ ?>
|
|
|
-
|
|
|
var downloaderSeconds = localStorage.getItem("downloaderSeconds");
|
|
|
var myInterval = undefined;
|
|
|
$("ul").find("[data-value='" + downloaderSeconds + "']").addClass("active");
|
|
|
-
|
|
|
if( downloaderSeconds === null ) {
|
|
|
localStorage.setItem("downloaderSeconds",'60000');
|
|
|
var downloaderSeconds = "60000";
|
|
|
}
|
|
|
-
|
|
|
$('#downloaderSeconds li').click(function() {
|
|
|
-
|
|
|
$('#downloaderSeconds li').removeClass("active");
|
|
|
$(this).addClass("active");
|
|
|
|
|
|
var newDownloaderSeconds = $(this).attr('data-value');
|
|
|
console.log('New Time is ' + newDownloaderSeconds + ' Old Time was ' + downloaderSeconds);
|
|
|
-
|
|
|
if (localStorageSupport) {
|
|
|
localStorage.setItem("downloaderSeconds",newDownloaderSeconds);
|
|
|
}
|
|
|
-
|
|
|
if(typeof myInterval != 'undefined'){ clearInterval(myInterval); }
|
|
|
refreshDownloader(newDownloaderSeconds);
|
|
|
-
|
|
|
});
|
|
|
-
|
|
|
<?php } ?>
|
|
|
-
|
|
|
-
|
|
|
<?php if(($USER->authenticated && $USER->role == "admin") && NZBGETURL != ""){ ?>
|
|
|
-
|
|
|
$("#downloaderHistory").load("downloader.php?downloader=nzbget&list=history");
|
|
|
$("#downloaderQueue").load("downloader.php?downloader=nzbget&list=listgroups");
|
|
|
-
|
|
|
refreshDownloader = function(secs){
|
|
|
myInterval = setInterval(function(){
|
|
|
$("#downloaderHistory").load("downloader.php?downloader=nzbget&list=history");
|
|
|
@@ -516,12 +461,9 @@ endif; ?>
|
|
|
});
|
|
|
|
|
|
<?php } ?>
|
|
|
-
|
|
|
<?php if(($USER->authenticated && $USER->role == "admin") && SABNZBDURL != ""){ ?>
|
|
|
-
|
|
|
$("#downloaderHistory").load("downloader.php?downloader=sabnzbd&list=history");
|
|
|
$("#downloaderQueue").load("downloader.php?downloader=sabnzbd&list=queue");
|
|
|
-
|
|
|
refreshDownloader = function(secs){
|
|
|
myInterval = setInterval(function(){
|
|
|
$("#downloaderHistory").load("downloader.php?downloader=sabnzbd&list=history");
|
|
|
@@ -538,13 +480,10 @@ endif; ?>
|
|
|
});
|
|
|
|
|
|
<?php } ?>
|
|
|
-
|
|
|
});
|
|
|
-
|
|
|
</script>
|
|
|
<?php if(SONARRURL != "" || RADARRURL != "" || HEADPHONESURL != "" || SICKRAGEURL != "") : ?>
|
|
|
<script>
|
|
|
-
|
|
|
$(function () {
|
|
|
|
|
|
var date = new Date();
|
|
|
@@ -553,37 +492,27 @@ endif; ?>
|
|
|
var y = date.getFullYear();
|
|
|
|
|
|
$('#calendar').fullCalendar({
|
|
|
-
|
|
|
eventLimit: false,
|
|
|
firstDay: <?php echo CALENDARSTART;?>,
|
|
|
-
|
|
|
height: "auto",
|
|
|
defaultView: '<?php echo CALENDARVIEW;?>',
|
|
|
-
|
|
|
header: {
|
|
|
-
|
|
|
left: 'prev,next,',
|
|
|
center: 'title',
|
|
|
right: 'today, month, basicDay,basicWeek,'
|
|
|
-
|
|
|
},
|
|
|
-
|
|
|
views: {
|
|
|
-
|
|
|
basicDay: { buttonText: '<?php echo $language->translate("DAY");?>', eventLimit: false },
|
|
|
basicWeek: { buttonText: '<?php echo $language->translate("WEEK");?>', eventLimit: false },
|
|
|
month: { buttonText: '<?php echo $language->translate("MONTH");?>', eventLimit: false },
|
|
|
today: { buttonText: '<?php echo $language->translate("TODAY");?>' },
|
|
|
-
|
|
|
},
|
|
|
-
|
|
|
events: [
|
|
|
<?php if(SICKRAGEURL != ""){ echo getSickrageCalendarWanted($sickrage->future()); echo getSickrageCalendarHistory($sickrage->history("100","downloaded")); } ?>
|
|
|
<?php if(SONARRURL != ""){ echo getSonarrCalendar($sonarr->getCalendar($startDate, $endDate)); } ?>
|
|
|
<?php if(RADARRURL != ""){ echo getRadarrCalendar($radarr->getCalendar($startDate, $endDate)); } ?>
|
|
|
<?php if(HEADPHONESURL != ""){ echo getHeadphonesCalendar(HEADPHONESURL, HEADPHONESKEY, "getHistory"); echo getHeadphonesCalendar(HEADPHONESURL, HEADPHONESKEY, "getWanted"); } ?>
|
|
|
],
|
|
|
-
|
|
|
eventRender: function eventRender( event, element, view ) {
|
|
|
return ['all', event.imagetype].indexOf($('#imagetype_selector').val()) >= 0
|
|
|
},
|
|
|
@@ -592,13 +521,10 @@ endif; ?>
|
|
|
droppable: false,
|
|
|
timeFormat: '<?php echo CALTIMEFORMAT; ?>',
|
|
|
});
|
|
|
-
|
|
|
});
|
|
|
-
|
|
|
$('#imagetype_selector').on('change',function(){
|
|
|
$('#calendar').fullCalendar('rerenderEvents');
|
|
|
})
|
|
|
-
|
|
|
var $divs = $("div.row");
|
|
|
|
|
|
$('#numBnt').on('click', function () {
|
|
|
@@ -607,7 +533,6 @@ endif; ?>
|
|
|
});
|
|
|
$("#content").html(numericallyOrderedDivs);
|
|
|
});
|
|
|
-
|
|
|
</script>
|
|
|
<?php endif; ?>
|
|
|
|