| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255 |
- <?php
- //homepage order
- function homepageOrder(){
- $homepageOrder = array(
- "homepageOrdercustomhtml" => $GLOBALS['homepageOrdercustomhtml'],
- "homepageOrdernotice" => $GLOBALS['homepageOrdernotice'],
- "homepageOrderplexsearch" => $GLOBALS['homepageOrderplexsearch'],
- "homepageOrderspeedtest" => $GLOBALS['homepageOrderspeedtest'],
- "homepageOrdernzbget" => $GLOBALS['homepageOrdernzbget'],
- "homepageOrdersabnzbd" => $GLOBALS['homepageOrdersabnzbd'],
- "homepageOrderplexnowplaying" => $GLOBALS['homepageOrderplexnowplaying'],
- "homepageOrderplexrecent" => $GLOBALS['homepageOrderplexrecent'],
- "homepageOrderplexplaylist" => $GLOBALS['homepageOrderplexplaylist'],
- "homepageOrderembynowplaying" => $GLOBALS['homepageOrderembynowplaying'],
- "homepageOrderembyrecent" => $GLOBALS['homepageOrderembyrecent'],
- "homepageOrderombi" => $GLOBALS['homepageOrderombi'],
- "homepageOrdercalendar" => $GLOBALS['homepageOrdercalendar'],
- "homepageOrdernoticeguest" => $GLOBALS['homepageOrdernoticeguest'],
- "homepageOrdertransmission" => $GLOBALS['homepageOrdertransmission'],
- "homepageOrderqBittorrent" => $GLOBALS['homepageOrderqBittorrent'],
- "homepageOrderdeluge" => $GLOBALS['homepageOrderdeluge'],
- );
- asort($homepageOrder);
- return $homepageOrder;
- }
- function buildHomepage(){
- $homepageOrder = homepageOrder();
- $homepageBuilt = '';
- foreach ($homepageOrder as $key => $value) {
- $homepageBuilt .= buildHomepageItem($key);
- }
- return $homepageBuilt;
- }
- function buildHomepageItem($homepageItem){
- $item = '<div id="'.$homepageItem.'">';
- switch ($homepageItem) {
- case 'homepageOrderplexsearch':
- break;
- case 'homepageOrdercustomhtml':
- break;
- case 'homepageOrdernotice':
- break;
- case 'homepageOrdernoticeguest':
- break;
- case 'homepageOrderspeedtest':
- break;
- case 'homepageOrderqBittorrent':
- if($GLOBALS['homepageqBittorrentEnabled']){
- $item .= '
- <script>
- // homepageOrderqBittorrent
- homepageDownloader("qBittorrent", "'.$GLOBALS['homepageDownloadRefresh'].'");
- // End homepageOrderqBittorrent
- </script>
- ';
- }
- break;
- case 'homepageOrderdeluge':
- if($GLOBALS['homepageDelugeEnabled']){
- $item .= '
- <script>
- // Deluge
- homepageDownloader("deluge", "'.$GLOBALS['homepageDownloadRefresh'].'");
- // End Deluge
- </script>
- ';
- }
- break;
- case 'homepageOrdertransmission':
- if($GLOBALS['homepageTransmissionEnabled']){
- $item .= '
- <script>
- // Transmission
- homepageDownloader("transmission", "'.$GLOBALS['homepageDownloadRefresh'].'");
- // End Transmission
- </script>
- ';
- }
- break;
- case 'homepageOrdernzbget':
- if($GLOBALS['homepageNzbgetEnabled']){
- $item .= '
- <script>
- // NZBGet
- homepageDownloader("nzbget", "'.$GLOBALS['homepageDownloadRefresh'].'");
- // End NZBGet
- </script>
- ';
- }
- break;
- case 'homepageOrdersabnzbd':
- if($GLOBALS['homepageSabnzbdEnabled']){
- $item .= '
- <script>
- // SabNZBd
- homepageDownloader("sabnzbd", "'.$GLOBALS['homepageDownloadRefresh'].'");
- // End SabNZBd
- </script>
- ';
- }
- break;
- case 'homepageOrderplexnowplaying':
- if($GLOBALS['homepagePlexStreams']){
- $item .= '
- <script>
- // Plex Stream
- homepageStream("plex", "'.$GLOBALS['homepageStreamRefresh'].'");
- // End Plex Stream
- </script>
- ';
- }
- break;
- case 'homepageOrderplexrecent':
- if($GLOBALS['homepagePlexRecent']){
- $item .= '
- <script>
- // Plex Recent
- homepageRecent("plex", "'.$GLOBALS['homepageRecentRefresh'].'");
- // End Plex Recent
- </script>
- ';
- }
- break;
- case 'homepageOrderplexplaylist':
- break;
- case 'homepageOrderembynowplaying':
- if($GLOBALS['homepageEmbyStreams']){
- $item .= '
- <script>
- // Emby Stream
- homepageStream("emby", "'.$GLOBALS['homepageStreamRefresh'].'");
- // End Emby Stream
- </script>
- ';
- }
- break;
- case 'homepageOrderembyrecent':
- if($GLOBALS['homepageEmbyRecent']){
- $item .= '
- <script>
- // Emby Recent
- homepageRecent("emby", "'.$GLOBALS['homepageRecentRefresh'].'");
- // End Emby Recent
- </script>
- ';
- }
- break;
- case 'homepageOrderombi':
- break;
- case 'homepageOrdercalendar':
- $item .= '
- <div id="calendar" class="fc fc-ltr"></div>
- <script>
- // Calendar
- homepageCalendar("'.$GLOBALS['calendarRefresh'].'");
- // End Calendar
- </script>
- ';
- break;
- default:
- # code...
- break;
- }
- return $item.'</div>';
- }
- function getHomepageList(){
- $groups = groupSelect();
- $time = array(
- array(
- 'name' => '5',
- 'value' => '5000'
- ),
- array(
- 'name' => '10',
- 'value' => '10000'
- ),
- array(
- 'name' => '15',
- 'value' => '15000'
- ),
- array(
- 'name' => '30',
- 'value' => '30000'
- ),
- array(
- 'name' => '60 [1 Minute]',
- 'value' => '60000'
- ),
- array(
- 'name' => '300 [5 Minutes]',
- 'value' => '300000'
- ),
- array(
- 'name' => '900 [15 Minutes]',
- 'value' => '900000'
- ),
- array(
- 'name' => '1800 [30 Minutes]',
- 'value' => '1800000'
- ),
- array(
- 'name' => '3600 [1 Hour]',
- 'value' => '3600000'
- ),
- );
- $limit = array(
- array(
- 'name' => '1 Item',
- 'value' => '1'
- ),
- array(
- 'name' => '2 Items',
- 'value' => '2'
- ),
- array(
- 'name' => '3 Items',
- 'value' => '3'
- ),
- array(
- 'name' => '4 Items',
- 'value' => '4'
- ),
- array(
- 'name' => '5 Items',
- 'value' => '5'
- ),
- array(
- 'name' => '6 Items',
- 'value' => '6'
- ),
- array(
- 'name' => '7 Items',
- 'value' => '7'
- ),
- array(
- 'name' => '8 Items',
- 'value' => '8'
- ),
- array(
- 'name' => 'Unlimited',
- 'value' => '1000'
- ),
- );
- $day = array(
- array(
- 'name' => 'Sunday',
- 'value' => '0'
- ),
- array(
- 'name' => 'Monday',
- 'value' => '1'
- ),
- array(
- 'name' => 'Tueday',
- 'value' => '2'
- ),
- array(
- 'name' => 'Wednesday',
- 'value' => '3'
- ),
- array(
- 'name' => 'Thursday',
- 'value' => '4'
- ),
- array(
- 'name' => 'Friday',
- 'value' => '5'
- ),
- array(
- 'name' => 'Saturday',
- 'value' => '6'
- )
- );
- $calendarDefault = array(
- array(
- 'name' => 'Month',
- 'value' => 'month'
- ),
- array(
- 'name' => 'Day',
- 'value' => 'basicDay'
- ),
- array(
- 'name' => 'Week',
- 'value' => 'basicWeek'
- )
- );
- $timeFormat = array(
- array(
- 'name' => '6p',
- 'value' => 'h(:mm)t'
- ),
- array(
- 'name' => '6:00p',
- 'value' => 'h:mmt'
- ),
- array(
- 'name' => '6:00',
- 'value' => 'h:mm'
- ),
- array(
- 'name' => '18',
- 'value' => 'H(:mm)'
- ),
- array(
- 'name' => '18:00',
- 'value' => 'H:mm'
- )
- );
- $qBittorrentSortOptions = array(
- array(
- 'name' => 'Hash',
- 'value' => 'hash'
- ),
- array(
- 'name' => 'Name',
- 'value' => 'name'
- ),
- array(
- 'name' => 'Size',
- 'value' => 'size'
- ),
- array(
- 'name' => 'Progress',
- 'value' => 'progress'
- ),
- array(
- 'name' => 'Download Speed',
- 'value' => 'dlspeed'
- ),
- array(
- 'name' => 'Upload Speed',
- 'value' => 'upspeed'
- ),
- array(
- 'name' => 'Priority',
- 'value' => 'priority'
- ),
- array(
- 'name' => 'Number of Seeds',
- 'value' => 'num_seeds'
- ),
- array(
- 'name' => 'Number of Seeds in Swarm',
- 'value' => 'num_complete'
- ),
- array(
- 'name' => 'Number of Leechers',
- 'value' => 'num_leechs'
- ),
- array(
- 'name' => 'Number of Leechers in Swarm',
- 'value' => 'num_incomplete'
- ),
- array(
- 'name' => 'Ratio',
- 'value' => 'ratio'
- ),
- array(
- 'name' => 'ETA',
- 'value' => 'eta'
- ),
- array(
- 'name' => 'State',
- 'value' => 'state'
- ),
- array(
- 'name' => 'Category',
- 'value' => 'category'
- )
- );
- return array(
- array(
- 'name' => 'Plex',
- 'enabled' => true,
- 'image' => 'plugins/images/tabs/plex.png',
- 'category' => 'Media Server',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepagePlexEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepagePlexEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepagePlexAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepagePlexAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'plexURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['plexURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'plexToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['plexToken']
- ),
- array(
- 'type' => 'input',
- 'name' => 'plexID',
- 'label' => 'Plex Machine',
- 'value' => $GLOBALS['plexID']
- )
- ),
- 'Active Streams' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepagePlexStreams',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepagePlexStreams']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepagePlexStreamsAuth',
- 'label' => 'Minimum Authorization',
- 'value' => $GLOBALS['homepagePlexStreamsAuth'],
- 'options' => $groups
- ),
- array(
- 'type' => 'switch',
- 'name' => 'homepageShowStreamNames',
- 'label' => 'User Information',
- 'value' => $GLOBALS['homepageShowStreamNames']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageShowStreamNamesAuth',
- 'label' => 'Minimum Authorization',
- 'value' => $GLOBALS['homepageShowStreamNamesAuth'],
- 'options' => $groups
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageStreamRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageStreamRefresh'],
- 'options' => $time
- ),
- ),
- 'Recent Items' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepagePlexRecent',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepagePlexRecent']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepagePlexRecentAuth',
- 'label' => 'Minimum Authorization',
- 'value' => $GLOBALS['homepagePlexRecentAuth'],
- 'options' => $groups
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageRecentRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageRecentRefresh'],
- 'options' => $time
- ),
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'input',
- 'name' => 'plexTabName',
- 'label' => 'Plex Tab Name',
- 'value' => $GLOBALS['plexTabName'],
- 'placeholder' => 'Only use if you have Plex in a reverse proxy'
- ),
- array(
- 'type' => 'input',
- 'name' => 'plexTabURL',
- 'label' => 'Plex Tab WAN URL',
- 'value' => $GLOBALS['plexTabURL'],
- 'placeholder' => 'http(s)://hostname:port'
- )
- )
- )
- ),
- array(
- 'name' => 'Emby',
- 'enabled' => true,
- 'image' => 'plugins/images/tabs/emby.png',
- 'category' => 'Media Server',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageEmbyEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageEmbyEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageEmbyAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageEmbyAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'embyURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['embyURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'embyToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['embyToken']
- )
- ),
- 'Active Streams' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageEmbyStreams',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageEmbyStreams']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageEmbyStreamsAuth',
- 'label' => 'Minimum Authorization',
- 'value' => $GLOBALS['homepageEmbyStreamsAuth'],
- 'options' => $groups
- ),
- array(
- 'type' => 'switch',
- 'name' => 'homepageShowStreamNames',
- 'label' => 'User Information',
- 'value' => $GLOBALS['homepageShowStreamNames']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageShowStreamNamesAuth',
- 'label' => 'Minimum Authorization',
- 'value' => $GLOBALS['homepageShowStreamNamesAuth'],
- 'options' => $groups
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageStreamRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageStreamRefresh'],
- 'options' => $time
- ),
- ),
- 'Recent Items' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageEmbyRecent',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageEmbyRecent']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageEmbyRecentAuth',
- 'label' => 'Minimum Authorization',
- 'value' => $GLOBALS['homepageEmbyRecentAuth'],
- 'options' => $groups
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageRecentRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageRecentRefresh'],
- 'options' => $time
- ),
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'input',
- 'name' => 'embyTabName',
- 'label' => 'Emby Tab Name',
- 'value' => $GLOBALS['embyTabName'],
- 'placeholder' => 'Only use if you have Plex in a reverse proxy'
- ),
- array(
- 'type' => 'input',
- 'name' => 'embyTabURL',
- 'label' => 'Emby Tab WAN URL',
- 'value' => $GLOBALS['embyTabURL'],
- 'placeholder' => 'http(s)://hostname:port'
- )
- )
- )
- ),
- array(
- 'name' => 'SabNZBD',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/sabnzbd.png',
- 'category' => 'Downloader',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageSabnzbdEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageSabnzbdEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageSabnzbdAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageSabnzbdAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'sabnzbdURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['sabnzbdURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'sabnzbdToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['sabnzbdToken']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'select',
- 'name' => 'homepageDownloadRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageDownloadRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'NZBGet',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/nzbget.png',
- 'category' => 'Downloader',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageNzbgetEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageNzbgetEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageNzbgetAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageNzbgetAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'nzbgetURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['nzbgetURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'nzbgetUsername',
- 'label' => 'Username',
- 'value' => $GLOBALS['nzbgetUsername']
- ),
- array(
- 'type' => 'password',
- 'name' => 'nzbgetPassword',
- 'label' => 'Password',
- 'value' => $GLOBALS['nzbgetPassword']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'select',
- 'name' => 'homepageDownloadRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageDownloadRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'Transmission',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/transmission.png',
- 'category' => 'Downloader',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageTransmissionEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageTransmissionEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageTransmissionAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageTransmissionAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'transmissionURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['transmissionURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'transmissionUsername',
- 'label' => 'Username',
- 'value' => $GLOBALS['transmissionUsername']
- ),
- array(
- 'type' => 'password',
- 'name' => 'transmissionPassword',
- 'label' => 'Password',
- 'value' => $GLOBALS['transmissionPassword']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'switch',
- 'name' => 'transmissionHideSeeding',
- 'label' => 'Hide Seeding',
- 'value' => $GLOBALS['transmissionHideSeeding']
- ),array(
- 'type' => 'switch',
- 'name' => 'transmissionHideCompleted',
- 'label' => 'Hide Completed',
- 'value' => $GLOBALS['transmissionHideCompleted']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageDownloadRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageDownloadRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'qBittorrent',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/qBittorrent.png',
- 'category' => 'Downloader',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageqBittorrentEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageqBittorrentEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageqBittorrentAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageqBittorrentAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'qBittorrentURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['qBittorrentURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'qBittorrentUsername',
- 'label' => 'Username',
- 'value' => $GLOBALS['qBittorrentUsername']
- ),
- array(
- 'type' => 'password',
- 'name' => 'qBittorrentPassword',
- 'label' => 'Password',
- 'value' => $GLOBALS['qBittorrentPassword']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'switch',
- 'name' => 'qBittorrentHideSeeding',
- 'label' => 'Hide Seeding',
- 'value' => $GLOBALS['qBittorrentHideSeeding']
- ),array(
- 'type' => 'switch',
- 'name' => 'qBittorrentnHideCompleted',
- 'label' => 'Hide Completed',
- 'value' => $GLOBALS['qBittorrentHideCompleted']
- ),
- array(
- 'type' => 'select',
- 'name' => 'qBittorrentSortOrder',
- 'label' => 'Order',
- 'value' => $GLOBALS['qBittorrentSortOrder'],
- 'options' => $qBittorrentSortOptions
- ),array(
- 'type' => 'switch',
- 'name' => 'qBittorrentReverseSorting',
- 'label' => 'Reverse Sorting',
- 'value' => $GLOBALS['qBittorrentReverseSorting']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageDownloadRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageDownloadRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'Deluge',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/deluge.png',
- 'category' => 'Downloader',
- 'settings' => array(
- 'custom' => '
- <div class="row">
- <div class="col-lg-12">
- <div class="panel panel-info">
- <div class="panel-heading">
- <span lang="en">Notice</span>
- </div>
- <div class="panel-wrapper collapse in" aria-expanded="true">
- <div class="panel-body">
- <ul class="list-icons">
- <li><i class="fa fa-chevron-right text-danger"></i> <a href="https://github.com/idlesign/deluge-webapi/raw/master/dist/WebAPI-0.2.0-py2.7.egg" target="_blank">Download Plugin</a></li>
- <li><i class="fa fa-chevron-right text-danger"></i> Open Deluge Web UI, go to "Preferences -> Plugins -> Install plugin" and choose egg file.</li>
- <li><i class="fa fa-chevron-right text-danger"></i> Activate WebAPI plugin </li>
- </ul>
- </div>
- </div>
- </div>
- </div>
- </div>
- ',
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageDelugeEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageDelugeEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageDelugeAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageDelugeAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'delugeURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['delugeURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'password',
- 'name' => 'delugePassword',
- 'label' => 'Password',
- 'value' => $GLOBALS['delugePassword']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'switch',
- 'name' => 'delugeHideSeeding',
- 'label' => 'Hide Seeding',
- 'value' => $GLOBALS['delugeHideSeeding']
- ),array(
- 'type' => 'switch',
- 'name' => 'delugeHideCompleted',
- 'label' => 'Hide Completed',
- 'value' => $GLOBALS['delugeHideCompleted']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageDownloadRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['homepageDownloadRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'Sonarr',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/sonarr.png',
- 'category' => 'PVR',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageSonarrEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageSonarrEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageSonarrAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageSonarrAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'sonarrURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['sonarrURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'sonarrToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['sonarrToken']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'input',
- 'name' => 'calendarStart',
- 'label' => '# of Days Before',
- 'value' => $GLOBALS['calendarStart'],
- 'placeholder' => ''
- ),
- array(
- 'type' => 'input',
- 'name' => 'calendarEnd',
- 'label' => '# of Days After',
- 'value' => $GLOBALS['calendarEnd'],
- 'placeholder' => ''
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarFirstDay',
- 'label' => 'Start Day',
- 'value' => $GLOBALS['calendarFirstDay'],
- 'options' => $day
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarDefault',
- 'label' => 'Default View',
- 'value' => $GLOBALS['calendarDefault'],
- 'options' => $calendarDefault
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarTimeFormat',
- 'label' => 'Time Format',
- 'value' => $GLOBALS['calendarTimeFormat'],
- 'options' => $timeFormat
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarLimit',
- 'label' => 'Items Per Day',
- 'value' => $GLOBALS['calendarLimit'],
- 'options' => $limit
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['calendarRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'Radarr',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/radarr.png',
- 'category' => 'PVR',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageRadarrEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageRadarrEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageRadarrAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageRadarrAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'radarrURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['radarrURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'radarrToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['radarrToken']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'input',
- 'name' => 'calendarStart',
- 'label' => '# of Days Before',
- 'value' => $GLOBALS['calendarStart'],
- 'placeholder' => ''
- ),
- array(
- 'type' => 'input',
- 'name' => 'calendarEnd',
- 'label' => '# of Days After',
- 'value' => $GLOBALS['calendarEnd'],
- 'placeholder' => ''
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarFirstDay',
- 'label' => 'Start Day',
- 'value' => $GLOBALS['calendarFirstDay'],
- 'options' => $day
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarDefault',
- 'label' => 'Default View',
- 'value' => $GLOBALS['calendarDefault'],
- 'options' => $calendarDefault
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarTimeFormat',
- 'label' => 'Time Format',
- 'value' => $GLOBALS['calendarTimeFormat'],
- 'options' => $timeFormat
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarLimit',
- 'label' => 'Items Per Day',
- 'value' => $GLOBALS['calendarLimit'],
- 'options' => $limit
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['calendarRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'CouchPotato',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/couchpotato.png',
- 'category' => 'PVR',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageCouchpotatoEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageCouchpotatoEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageCouchpotatoAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageCouchpotatoAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'couchpotatoURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['couchpotatoURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'couchpotatoToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['couchpotatoToken']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'select',
- 'name' => 'calendarFirstDay',
- 'label' => 'Start Day',
- 'value' => $GLOBALS['calendarFirstDay'],
- 'options' => $day
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarDefault',
- 'label' => 'Default View',
- 'value' => $GLOBALS['calendarDefault'],
- 'options' => $calendarDefault
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarTimeFormat',
- 'label' => 'Time Format',
- 'value' => $GLOBALS['calendarTimeFormat'],
- 'options' => $timeFormat
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarLimit',
- 'label' => 'Items Per Day',
- 'value' => $GLOBALS['calendarLimit'],
- 'options' => $limit
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['calendarRefresh'],
- 'options' => $time
- )
- )
- )
- ),
- array(
- 'name' => 'SickRage',
- 'enabled' => false,
- 'image' => 'plugins/images/tabs/sickrage.png',
- 'category' => 'PVR',
- 'settings' => array(
- 'Enable' => array(
- array(
- 'type' => 'switch',
- 'name' => 'homepageSickrageEnabled',
- 'label' => 'Enable',
- 'value' => $GLOBALS['homepageSickrageEnabled']
- ),
- array(
- 'type' => 'select',
- 'name' => 'homepageSickrageAuth',
- 'label' => 'Minimum Authentication',
- 'value' => $GLOBALS['homepageSickrageAuth'],
- 'options' => $groups
- )
- ),
- 'Connection' => array(
- array(
- 'type' => 'input',
- 'name' => 'sickrageURL',
- 'label' => 'URL',
- 'value' => $GLOBALS['sickrageURL'],
- 'placeholder' => 'http(s)://hostname:port'
- ),
- array(
- 'type' => 'input',
- 'name' => 'sickrageToken',
- 'label' => 'Token',
- 'value' => $GLOBALS['sickrageToken']
- )
- ),
- 'Misc Options' => array(
- array(
- 'type' => 'select',
- 'name' => 'calendarFirstDay',
- 'label' => 'Start Day',
- 'value' => $GLOBALS['calendarFirstDay'],
- 'options' => $day
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarDefault',
- 'label' => 'Default View',
- 'value' => $GLOBALS['calendarDefault'],
- 'options' => $calendarDefault
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarTimeFormat',
- 'label' => 'Time Format',
- 'value' => $GLOBALS['calendarTimeFormat'],
- 'options' => $timeFormat
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarLimit',
- 'label' => 'Items Per Day',
- 'value' => $GLOBALS['calendarLimit'],
- 'options' => $limit
- ),
- array(
- 'type' => 'select',
- 'name' => 'calendarRefresh',
- 'label' => 'Refresh Seconds',
- 'value' => $GLOBALS['calendarRefresh'],
- 'options' => $time
- )
- )
- )
- )
- );
- }
|