homepage-functions.php 83 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961
  1. <?php
  2. //homepage order
  3. function homepageOrder()
  4. {
  5. $homepageOrder = array(
  6. "homepageOrdercustomhtml" => $GLOBALS['homepageOrdercustomhtml'],
  7. "homepageOrdercustomhtmlTwo" => $GLOBALS['homepageOrdercustomhtmlTwo'],
  8. "homepageOrdernzbget" => $GLOBALS['homepageOrdernzbget'],
  9. "homepageOrderjdownloader" => $GLOBALS['homepageOrderjdownloader'],
  10. "homepageOrdersabnzbd" => $GLOBALS['homepageOrdersabnzbd'],
  11. "homepageOrderplexnowplaying" => $GLOBALS['homepageOrderplexnowplaying'],
  12. "homepageOrderplexrecent" => $GLOBALS['homepageOrderplexrecent'],
  13. "homepageOrderplexplaylist" => $GLOBALS['homepageOrderplexplaylist'],
  14. "homepageOrderembynowplaying" => $GLOBALS['homepageOrderembynowplaying'],
  15. "homepageOrderembyrecent" => $GLOBALS['homepageOrderembyrecent'],
  16. "homepageOrderombi" => $GLOBALS['homepageOrderombi'],
  17. "homepageOrdercalendar" => $GLOBALS['homepageOrdercalendar'],
  18. "homepageOrdertransmission" => $GLOBALS['homepageOrdertransmission'],
  19. "homepageOrderqBittorrent" => $GLOBALS['homepageOrderqBittorrent'],
  20. "homepageOrderdeluge" => $GLOBALS['homepageOrderdeluge'],
  21. "homepageOrderrTorrent" => $GLOBALS['homepageOrderrTorrent'],
  22. "homepageOrderdownloader" => $GLOBALS['homepageOrderdownloader'],
  23. "homepageOrderhealthchecks" => $GLOBALS['homepageOrderhealthchecks'],
  24. "homepageOrderunifi" => $GLOBALS['homepageOrderunifi'],
  25. "homepageOrdertautulli" => $GLOBALS['homepageOrdertautulli'],
  26. "homepageOrderPihole" => $GLOBALS['homepageOrderPihole'],
  27. "homepageOrderMonitorr" => $GLOBALS['homepageOrderMonitorr'],
  28. );
  29. asort($homepageOrder);
  30. return $homepageOrder;
  31. }
  32. function buildHomepage()
  33. {
  34. $homepageOrder = homepageOrder();
  35. $homepageBuilt = '';
  36. foreach ($homepageOrder as $key => $value) {
  37. $homepageBuilt .= buildHomepageItem($key);
  38. }
  39. return $homepageBuilt;
  40. }
  41. function buildHomepageItem($homepageItem)
  42. {
  43. $item = '<div id="' . $homepageItem . '">';
  44. switch ($homepageItem) {
  45. case 'homepageOrdercustomhtml':
  46. if ($GLOBALS['homepagCustomHTMLoneEnabled'] && qualifyRequest($GLOBALS['homepagCustomHTMLoneAuth'])) {
  47. $item .= ($GLOBALS['customHTMLone'] !== '') ? $GLOBALS['customHTMLone'] : '';
  48. }
  49. break;
  50. case 'homepageOrdercustomhtmlTwo':
  51. if ($GLOBALS['homepagCustomHTMLtwoEnabled'] && qualifyRequest($GLOBALS['homepagCustomHTMLtwoAuth'])) {
  52. $item .= ($GLOBALS['customHTMLtwo'] !== '') ? $GLOBALS['customHTMLtwo'] : '';
  53. }
  54. break;
  55. case 'homepageOrdernotice':
  56. break;
  57. case 'homepageOrdernoticeguest':
  58. break;
  59. case 'homepageOrderqBittorrent':
  60. if ($GLOBALS['homepageqBittorrentEnabled'] && qualifyRequest($GLOBALS['homepageqBittorrentAuth'])) {
  61. if ($GLOBALS['qBittorrentCombine']) {
  62. $item .= '
  63. <script>
  64. // homepageOrderqBittorrent
  65. buildDownloaderCombined(\'qBittorrent\');
  66. homepageDownloader("qBittorrent", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  67. // End homepageOrderqBittorrent
  68. </script>
  69. ';
  70. } else {
  71. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  72. $item .= '
  73. <script>
  74. // homepageOrderqBittorrent
  75. $("#' . $homepageItem . '").html(buildDownloader("qBittorrent"));
  76. homepageDownloader("qBittorrent", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  77. // End homepageOrderqBittorrent
  78. </script>
  79. ';
  80. }
  81. }
  82. break;
  83. case 'homepageOrderrTorrent':
  84. if ($GLOBALS['homepagerTorrentEnabled'] && qualifyRequest($GLOBALS['homepagerTorrentAuth'])) {
  85. if ($GLOBALS['rTorrentCombine']) {
  86. $item .= '
  87. <script>
  88. // homepageOrderrTorrent
  89. buildDownloaderCombined(\'rTorrent\');
  90. homepageDownloader("rTorrent", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  91. // End homepageOrderrTorrent
  92. </script>
  93. ';
  94. } else {
  95. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  96. $item .= '
  97. <script>
  98. // homepageOrderrTorrent
  99. $("#' . $homepageItem . '").html(buildDownloader("rTorrent"));
  100. homepageDownloader("rTorrent", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  101. // End homepageOrderrTorrent
  102. </script>
  103. ';
  104. }
  105. }
  106. break;
  107. case 'homepageOrderdeluge':
  108. if ($GLOBALS['homepageDelugeEnabled'] && qualifyRequest($GLOBALS['homepageDelugeAuth'])) {
  109. if ($GLOBALS['delugeCombine']) {
  110. $item .= '
  111. <script>
  112. // Deluge
  113. buildDownloaderCombined(\'deluge\');
  114. homepageDownloader("deluge", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  115. // End Deluge
  116. </script>
  117. ';
  118. } else {
  119. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  120. $item .= '
  121. <script>
  122. // Deluge
  123. $("#' . $homepageItem . '").html(buildDownloader("deluge"));
  124. homepageDownloader("deluge", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  125. // End Deluge
  126. </script>
  127. ';
  128. }
  129. }
  130. break;
  131. case 'homepageOrdertransmission':
  132. if ($GLOBALS['homepageTransmissionEnabled'] && qualifyRequest($GLOBALS['homepageTransmissionAuth'])) {
  133. if ($GLOBALS['transmissionCombine']) {
  134. $item .= '
  135. <script>
  136. // Transmission
  137. buildDownloaderCombined(\'transmission\');
  138. homepageDownloader("transmission", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  139. // End Transmission
  140. </script>
  141. ';
  142. } else {
  143. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  144. $item .= '
  145. <script>
  146. // Transmission
  147. $("#' . $homepageItem . '").html(buildDownloader("transmission"));
  148. homepageDownloader("transmission", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  149. // End Transmission
  150. </script>
  151. ';
  152. }
  153. }
  154. break;
  155. case 'homepageOrdernzbget':
  156. if ($GLOBALS['homepageNzbgetEnabled'] && qualifyRequest($GLOBALS['homepageNzbgetAuth'])) {
  157. if ($GLOBALS['nzbgetCombine']) {
  158. $item .= '
  159. <script>
  160. // NZBGet
  161. buildDownloaderCombined(\'nzbget\');
  162. homepageDownloader("nzbget", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  163. // End NZBGet
  164. </script>
  165. ';
  166. } else {
  167. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  168. $item .= '
  169. <script>
  170. // NZBGet
  171. $("#' . $homepageItem . '").html(buildDownloader("nzbget"));
  172. homepageDownloader("nzbget", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  173. // End NZBGet
  174. </script>
  175. ';
  176. }
  177. }
  178. break;
  179. case 'homepageOrderjdownloader':
  180. if ($GLOBALS['homepageJdownloaderEnabled'] && qualifyRequest($GLOBALS['homepageJdownloaderAuth'])) {
  181. if ($GLOBALS['jdownloaderCombine']) {
  182. $item .= '
  183. <script>
  184. // JDownloader
  185. buildDownloaderCombined(\'jdownloader\');
  186. homepageDownloader("jdownloader", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  187. // End JDownloader
  188. </script>
  189. ';
  190. } else {
  191. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  192. $item .= '
  193. <script>
  194. // JDownloader
  195. $("#' . $homepageItem . '").html(buildDownloader("jdownloader"));
  196. homepageDownloader("jdownloader", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  197. // End JDownloader
  198. </script>
  199. ';
  200. }
  201. }
  202. break;
  203. case 'homepageOrdersabnzbd':
  204. if ($GLOBALS['homepageSabnzbdEnabled'] && qualifyRequest($GLOBALS['homepageSabnzbdAuth'])) {
  205. if ($GLOBALS['sabnzbdCombine']) {
  206. $item .= '
  207. <script>
  208. // SabNZBd
  209. buildDownloaderCombined(\'sabnzbd\');
  210. homepageDownloader("sabnzbd", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  211. // End SabNZBd
  212. </script>
  213. ';
  214. } else {
  215. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Download Queue...</h2></div>';
  216. $item .= '
  217. <script>
  218. // SabNZBd
  219. $("#' . $homepageItem . '").html(buildDownloader("sabnzbd"));
  220. homepageDownloader("sabnzbd", "' . $GLOBALS['homepageDownloadRefresh'] . '");
  221. // End SabNZBd
  222. </script>
  223. ';
  224. }
  225. }
  226. break;
  227. case 'homepageOrderplexnowplaying':
  228. if ($GLOBALS['homepagePlexStreams']) {
  229. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Now Playing...</h2></div>';
  230. $item .= '
  231. <script>
  232. // Plex Stream
  233. homepageStream("plex", "' . $GLOBALS['homepageStreamRefresh'] . '");
  234. // End Plex Stream
  235. </script>
  236. ';
  237. }
  238. break;
  239. case 'homepageOrderplexrecent':
  240. if ($GLOBALS['homepagePlexRecent']) {
  241. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Recent...</h2></div>';
  242. $item .= '
  243. <script>
  244. // Plex Recent
  245. homepageRecent("plex", "' . $GLOBALS['homepageRecentRefresh'] . '");
  246. // End Plex Recent
  247. </script>
  248. ';
  249. }
  250. break;
  251. case 'homepageOrderplexplaylist':
  252. if ($GLOBALS['homepagePlexPlaylist']) {
  253. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Playlists...</h2></div>';
  254. $item .= '
  255. <script>
  256. // Plex Playlist
  257. homepagePlaylist("plex");
  258. // End Plex Playlist
  259. </script>
  260. ';
  261. }
  262. break;
  263. case 'homepageOrderembynowplaying':
  264. if ($GLOBALS['homepageEmbyStreams'] && $GLOBALS['homepageEmbyEnabled']) {
  265. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Now Playing...</h2></div>';
  266. $item .= '
  267. <script>
  268. // Emby Stream
  269. homepageStream("emby", "' . $GLOBALS['homepageStreamRefresh'] . '");
  270. // End Emby Stream
  271. </script>
  272. ';
  273. }
  274. break;
  275. case 'homepageOrderembyrecent':
  276. if ($GLOBALS['homepageEmbyRecent'] && $GLOBALS['homepageEmbyEnabled']) {
  277. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Recent...</h2></div>';
  278. $item .= '
  279. <script>
  280. // Emby Recent
  281. homepageRecent("emby", "' . $GLOBALS['homepageRecentRefresh'] . '");
  282. // End Emby Recent
  283. </script>
  284. ';
  285. }
  286. break;
  287. case 'homepageOrderombi':
  288. if ($GLOBALS['homepageOmbiEnabled']) {
  289. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Requests...</h2></div>';
  290. $item .= '
  291. <script>
  292. // Ombi Requests
  293. homepageRequests("' . $GLOBALS['ombiRefresh'] . '");
  294. // End Ombi Requests
  295. </script>
  296. ';
  297. }
  298. break;
  299. case 'homepageOrdercalendar':
  300. if ($GLOBALS['homepageSonarrEnabled'] && qualifyRequest($GLOBALS['homepageSonarrAuth']) || ($GLOBALS['homepageRadarrEnabled'] && qualifyRequest($GLOBALS['homepageRadarrAuth'])) || ($GLOBALS['homepageSickrageEnabled'] && qualifyRequest($GLOBALS['homepageSickrageAuth'])) || ($GLOBALS['homepageCouchpotatoEnabled'] && qualifyRequest($GLOBALS['homepageCouchpotatoAuth'])) || ($GLOBALS['homepageCalendarEnabled'] && qualifyRequest($GLOBALS['homepageCalendarAuth']) && $GLOBALS['calendariCal'] !== '')) {
  301. $item .= '
  302. <div id="calendar" class="fc fc-ltr m-b-30"></div>
  303. <script>
  304. // Calendar
  305. homepageCalendar("' . $GLOBALS['calendarRefresh'] . '");
  306. // End Calendar
  307. </script>
  308. ';
  309. }
  310. break;
  311. case 'homepageOrderhealthchecks':
  312. if ($GLOBALS['homepageHealthChecksEnabled'] && qualifyRequest($GLOBALS['homepageHealthChecksAuth'])) {
  313. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Health Checks...</h2></div>';
  314. $item .= '
  315. <script>
  316. // Health Checks
  317. homepageHealthChecks("' . $GLOBALS['healthChecksTags'] . '","' . $GLOBALS['homepageHealthChecksRefresh'] . '");
  318. // End Health Checks
  319. </script>
  320. ';
  321. }
  322. break;
  323. case 'homepageOrderunifi':
  324. if ($GLOBALS['homepageUnifiEnabled'] && qualifyRequest($GLOBALS['homepageUnifiAuth'])) {
  325. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Unifi...</h2></div>';
  326. $item .= '
  327. <script>
  328. // Unifi
  329. homepageUnifi("' . $GLOBALS['homepageHealthChecksRefresh'] . '");
  330. // End Unifi
  331. </script>
  332. ';
  333. }
  334. break;
  335. case 'homepageOrdertautulli':
  336. if ($GLOBALS['homepageTautulliEnabled'] && qualifyRequest($GLOBALS['homepageTautulliAuth'])) {
  337. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Tautulli...</h2></div>';
  338. $item .= '
  339. <script>
  340. // Tautulli
  341. homepageTautulli("' . $GLOBALS['homepageTautulliRefresh'] . '");
  342. // End Tautulli
  343. </script>
  344. ';
  345. }
  346. break;
  347. case 'homepageOrderPihole':
  348. if ($GLOBALS['homepagePiholeEnabled']) {
  349. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Pi-hole Stats...</h2></div>';
  350. $item .= '
  351. <script>
  352. // Pi-hole Stats
  353. homepagePihole("' . $GLOBALS['homepagePiholeRefresh'] . '");
  354. // End Pi-hole Stats
  355. </script>
  356. ';
  357. }
  358. break;
  359. case 'homepageOrderMonitorr':
  360. if ($GLOBALS['homepageMonitorrEnabled']) {
  361. $item .= '<div class="white-box"><h2 class="text-center" lang="en">Loading Monitorr...</h2></div>';
  362. $item .= '
  363. <script>
  364. // Monitorr
  365. homepageMonitorr("' . $GLOBALS['homepageMonitorrRefresh'] . '");
  366. // End Monitorr
  367. </script>
  368. ';
  369. }
  370. break;
  371. default:
  372. # code...
  373. break;
  374. }
  375. return $item . '</div>';
  376. }
  377. function getHomepageList()
  378. {
  379. $groups = groupSelect();
  380. $ombiTvOptions = array(
  381. array(
  382. 'name' => 'All Seasons',
  383. 'value' => 'all'
  384. ),
  385. array(
  386. 'name' => 'First Season Only',
  387. 'value' => 'first'
  388. ),
  389. array(
  390. 'name' => 'Last Season Only',
  391. 'value' => 'last'
  392. ),
  393. );
  394. $mediaServers = array(
  395. array(
  396. 'name' => 'N/A',
  397. 'value' => ''
  398. ),
  399. array(
  400. 'name' => 'Plex',
  401. 'value' => 'plex'
  402. ),
  403. array(
  404. 'name' => 'Emby [Not Available]',
  405. 'value' => 'emby'
  406. )
  407. );
  408. $limit = array(
  409. array(
  410. 'name' => '1 Item',
  411. 'value' => '1'
  412. ),
  413. array(
  414. 'name' => '2 Items',
  415. 'value' => '2'
  416. ),
  417. array(
  418. 'name' => '3 Items',
  419. 'value' => '3'
  420. ),
  421. array(
  422. 'name' => '4 Items',
  423. 'value' => '4'
  424. ),
  425. array(
  426. 'name' => '5 Items',
  427. 'value' => '5'
  428. ),
  429. array(
  430. 'name' => '6 Items',
  431. 'value' => '6'
  432. ),
  433. array(
  434. 'name' => '7 Items',
  435. 'value' => '7'
  436. ),
  437. array(
  438. 'name' => '8 Items',
  439. 'value' => '8'
  440. ),
  441. array(
  442. 'name' => 'Unlimited',
  443. 'value' => '1000'
  444. ),
  445. );
  446. $day = array(
  447. array(
  448. 'name' => 'Sunday',
  449. 'value' => '0'
  450. ),
  451. array(
  452. 'name' => 'Monday',
  453. 'value' => '1'
  454. ),
  455. array(
  456. 'name' => 'Tueday',
  457. 'value' => '2'
  458. ),
  459. array(
  460. 'name' => 'Wednesday',
  461. 'value' => '3'
  462. ),
  463. array(
  464. 'name' => 'Thursday',
  465. 'value' => '4'
  466. ),
  467. array(
  468. 'name' => 'Friday',
  469. 'value' => '5'
  470. ),
  471. array(
  472. 'name' => 'Saturday',
  473. 'value' => '6'
  474. )
  475. );
  476. $calendarDefault = array(
  477. array(
  478. 'name' => 'Month',
  479. 'value' => 'month'
  480. ),
  481. array(
  482. 'name' => 'Day',
  483. 'value' => 'basicDay'
  484. ),
  485. array(
  486. 'name' => 'Week',
  487. 'value' => 'basicWeek'
  488. ),
  489. array(
  490. 'name' => 'List',
  491. 'value' => 'list'
  492. )
  493. );
  494. $timeFormat = array(
  495. array(
  496. 'name' => '6p',
  497. 'value' => 'h(:mm)t'
  498. ),
  499. array(
  500. 'name' => '6:00p',
  501. 'value' => 'h:mmt'
  502. ),
  503. array(
  504. 'name' => '6:00',
  505. 'value' => 'h:mm'
  506. ),
  507. array(
  508. 'name' => '18',
  509. 'value' => 'H(:mm)'
  510. ),
  511. array(
  512. 'name' => '18:00',
  513. 'value' => 'H:mm'
  514. )
  515. );
  516. $rTorrentSortOptions = array(
  517. array(
  518. 'name' => 'Date Desc',
  519. 'value' => 'dated'
  520. ),
  521. array(
  522. 'name' => 'Date Asc',
  523. 'value' => 'datea'
  524. ),
  525. array(
  526. 'name' => 'Hash Desc',
  527. 'value' => 'hashd'
  528. ),
  529. array(
  530. 'name' => 'Hash Asc',
  531. 'value' => 'hasha'
  532. ),
  533. array(
  534. 'name' => 'Name Desc',
  535. 'value' => 'named'
  536. ),
  537. array(
  538. 'name' => 'Name Asc',
  539. 'value' => 'namea'
  540. ),
  541. array(
  542. 'name' => 'Size Desc',
  543. 'value' => 'sized'
  544. ),
  545. array(
  546. 'name' => 'Size Asc',
  547. 'value' => 'sizea'
  548. ),
  549. array(
  550. 'name' => 'Label Desc',
  551. 'value' => 'labeld'
  552. ),
  553. array(
  554. 'name' => 'Label Asc',
  555. 'value' => 'labela'
  556. ),
  557. array(
  558. 'name' => 'Status Desc',
  559. 'value' => 'statusd'
  560. ),
  561. array(
  562. 'name' => 'Status Asc',
  563. 'value' => 'statusa'
  564. ),
  565. );
  566. $qBittorrentApiOptions = array(
  567. array(
  568. 'name' => 'V1',
  569. 'value' => '1'
  570. ),
  571. array(
  572. 'name' => 'V2',
  573. 'value' => '2'
  574. ),
  575. );
  576. $qBittorrentSortOptions = array(
  577. array(
  578. 'name' => 'Hash',
  579. 'value' => 'hash'
  580. ),
  581. array(
  582. 'name' => 'Name',
  583. 'value' => 'name'
  584. ),
  585. array(
  586. 'name' => 'Size',
  587. 'value' => 'size'
  588. ),
  589. array(
  590. 'name' => 'Progress',
  591. 'value' => 'progress'
  592. ),
  593. array(
  594. 'name' => 'Download Speed',
  595. 'value' => 'dlspeed'
  596. ),
  597. array(
  598. 'name' => 'Upload Speed',
  599. 'value' => 'upspeed'
  600. ),
  601. array(
  602. 'name' => 'Priority',
  603. 'value' => 'priority'
  604. ),
  605. array(
  606. 'name' => 'Number of Seeds',
  607. 'value' => 'num_seeds'
  608. ),
  609. array(
  610. 'name' => 'Number of Seeds in Swarm',
  611. 'value' => 'num_complete'
  612. ),
  613. array(
  614. 'name' => 'Number of Leechers',
  615. 'value' => 'num_leechs'
  616. ),
  617. array(
  618. 'name' => 'Number of Leechers in Swarm',
  619. 'value' => 'num_incomplete'
  620. ),
  621. array(
  622. 'name' => 'Ratio',
  623. 'value' => 'ratio'
  624. ),
  625. array(
  626. 'name' => 'ETA',
  627. 'value' => 'eta'
  628. ),
  629. array(
  630. 'name' => 'State',
  631. 'value' => 'state'
  632. ),
  633. array(
  634. 'name' => 'Category',
  635. 'value' => 'category'
  636. )
  637. );
  638. $xmlStatus = (extension_loaded('xmlrpc')) ? 'Installed' : 'Not Installed';
  639. return array(array(
  640. 'name' => 'Calendar',
  641. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  642. 'image' => 'plugins/images/tabs/calendar.png',
  643. 'category' => 'HOMEPAGE',
  644. 'settings' => array(
  645. 'Enable' => array(
  646. array(
  647. 'type' => 'switch',
  648. 'name' => 'homepageCalendarEnabled',
  649. 'label' => 'Enable iCal',
  650. 'value' => $GLOBALS['homepageCalendarEnabled']
  651. ),
  652. array(
  653. 'type' => 'select',
  654. 'name' => 'homepageCalendarAuth',
  655. 'label' => 'Minimum Authentication',
  656. 'value' => $GLOBALS['homepageCalendarAuth'],
  657. 'options' => $groups
  658. ),
  659. array(
  660. 'type' => 'input',
  661. 'name' => 'calendariCal',
  662. 'label' => 'iCal URL\'s',
  663. 'value' => $GLOBALS['calendariCal'],
  664. 'placeholder' => 'separate by comma\'s'
  665. ),
  666. ),
  667. 'Misc Options' => array(
  668. array(
  669. 'type' => 'number',
  670. 'name' => 'calendarStart',
  671. 'label' => '# of Days Before',
  672. 'value' => $GLOBALS['calendarStart'],
  673. 'placeholder' => ''
  674. ),
  675. array(
  676. 'type' => 'number',
  677. 'name' => 'calendarEnd',
  678. 'label' => '# of Days After',
  679. 'value' => $GLOBALS['calendarEnd'],
  680. 'placeholder' => ''
  681. ),
  682. array(
  683. 'type' => 'select',
  684. 'name' => 'calendarFirstDay',
  685. 'label' => 'Start Day',
  686. 'value' => $GLOBALS['calendarFirstDay'],
  687. 'options' => $day
  688. ),
  689. array(
  690. 'type' => 'select',
  691. 'name' => 'calendarDefault',
  692. 'label' => 'Default View',
  693. 'value' => $GLOBALS['calendarDefault'],
  694. 'options' => $calendarDefault
  695. ),
  696. array(
  697. 'type' => 'select',
  698. 'name' => 'calendarTimeFormat',
  699. 'label' => 'Time Format',
  700. 'value' => $GLOBALS['calendarTimeFormat'],
  701. 'options' => $timeFormat
  702. ),
  703. array(
  704. 'type' => 'select',
  705. 'name' => 'calendarLimit',
  706. 'label' => 'Items Per Day',
  707. 'value' => $GLOBALS['calendarLimit'],
  708. 'options' => $limit
  709. ),
  710. array(
  711. 'type' => 'select',
  712. 'name' => 'calendarRefresh',
  713. 'label' => 'Refresh Seconds',
  714. 'value' => $GLOBALS['calendarRefresh'],
  715. 'options' => optionTime()
  716. )
  717. ),
  718. )
  719. ),
  720. array(
  721. 'name' => 'Plex',
  722. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  723. 'image' => 'plugins/images/tabs/plex.png',
  724. 'category' => 'Media Server',
  725. //'license' => $GLOBALS['license'],
  726. 'settings' => array(
  727. 'Enable' => array(
  728. array(
  729. 'type' => 'switch',
  730. 'name' => 'homepagePlexEnabled',
  731. 'label' => 'Enable',
  732. 'value' => $GLOBALS['homepagePlexEnabled']
  733. ),
  734. array(
  735. 'type' => 'select',
  736. 'name' => 'homepagePlexAuth',
  737. 'label' => 'Minimum Authentication',
  738. 'value' => $GLOBALS['homepagePlexAuth'],
  739. 'options' => $groups
  740. )
  741. ),
  742. 'Connection' => array(
  743. array(
  744. 'type' => 'input',
  745. 'name' => 'plexURL',
  746. 'label' => 'URL',
  747. 'value' => $GLOBALS['plexURL'],
  748. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  749. 'placeholder' => 'http(s)://hostname:port'
  750. ),
  751. array(
  752. 'type' => 'password-alt',
  753. 'name' => 'plexToken',
  754. 'label' => 'Token',
  755. 'value' => $GLOBALS['plexToken']
  756. ),
  757. array(
  758. 'type' => 'password-alt',
  759. 'name' => 'plexID',
  760. 'label' => 'Plex Machine',
  761. 'value' => $GLOBALS['plexID']
  762. )
  763. ),
  764. 'Active Streams' => array(
  765. array(
  766. 'type' => 'switch',
  767. 'name' => 'homepagePlexStreams',
  768. 'label' => 'Enable',
  769. 'value' => $GLOBALS['homepagePlexStreams']
  770. ),
  771. array(
  772. 'type' => 'select',
  773. 'name' => 'homepagePlexStreamsAuth',
  774. 'label' => 'Minimum Authorization',
  775. 'value' => $GLOBALS['homepagePlexStreamsAuth'],
  776. 'options' => $groups
  777. ),
  778. array(
  779. 'type' => 'switch',
  780. 'name' => 'homepageShowStreamNames',
  781. 'label' => 'User Information',
  782. 'value' => $GLOBALS['homepageShowStreamNames']
  783. ),
  784. array(
  785. 'type' => 'select',
  786. 'name' => 'homepageShowStreamNamesAuth',
  787. 'label' => 'Minimum Authorization',
  788. 'value' => $GLOBALS['homepageShowStreamNamesAuth'],
  789. 'options' => $groups
  790. ),
  791. array(
  792. 'type' => 'select',
  793. 'name' => 'homepageStreamRefresh',
  794. 'label' => 'Refresh Seconds',
  795. 'value' => $GLOBALS['homepageStreamRefresh'],
  796. 'options' => optionTime()
  797. ),
  798. ),
  799. 'Recent Items' => array(
  800. array(
  801. 'type' => 'switch',
  802. 'name' => 'homepagePlexRecent',
  803. 'label' => 'Enable',
  804. 'value' => $GLOBALS['homepagePlexRecent']
  805. ),
  806. array(
  807. 'type' => 'select',
  808. 'name' => 'homepagePlexRecentAuth',
  809. 'label' => 'Minimum Authorization',
  810. 'value' => $GLOBALS['homepagePlexRecentAuth'],
  811. 'options' => $groups
  812. ),
  813. array(
  814. 'type' => 'number',
  815. 'name' => 'homepageRecentLimit',
  816. 'label' => 'Item Limit',
  817. 'value' => $GLOBALS['homepageRecentLimit'],
  818. ),
  819. array(
  820. 'type' => 'select',
  821. 'name' => 'homepageRecentRefresh',
  822. 'label' => 'Refresh Seconds',
  823. 'value' => $GLOBALS['homepageRecentRefresh'],
  824. 'options' => optionTime()
  825. ),
  826. ),
  827. 'Media Search' => array(
  828. array(
  829. 'type' => 'switch',
  830. 'name' => 'mediaSearch',
  831. 'label' => 'Enable',
  832. 'value' => $GLOBALS['mediaSearch']
  833. ),
  834. array(
  835. 'type' => 'select',
  836. 'name' => 'mediaSearchAuth',
  837. 'label' => 'Minimum Authorization',
  838. 'value' => $GLOBALS['mediaSearchAuth'],
  839. 'options' => $groups
  840. ),
  841. array(
  842. 'type' => 'select',
  843. 'name' => 'mediaSearchType',
  844. 'label' => 'Media Server',
  845. 'value' => $GLOBALS['mediaSearchType'],
  846. 'options' => $mediaServers
  847. ),
  848. ),
  849. 'Playlists' => array(
  850. array(
  851. 'type' => 'switch',
  852. 'name' => 'homepagePlexPlaylist',
  853. 'label' => 'Enable',
  854. 'value' => $GLOBALS['homepagePlexPlaylist']
  855. ),
  856. array(
  857. 'type' => 'select',
  858. 'name' => 'homepagePlexPlaylistAuth',
  859. 'label' => 'Minimum Authorization',
  860. 'value' => $GLOBALS['homepagePlexPlaylistAuth'],
  861. 'options' => $groups
  862. ),
  863. ),
  864. 'Misc Options' => array(
  865. array(
  866. 'type' => 'input',
  867. 'name' => 'plexTabName',
  868. 'label' => 'Plex Tab Name',
  869. 'value' => $GLOBALS['plexTabName'],
  870. 'placeholder' => 'Only use if you have Plex in a reverse proxy'
  871. ),
  872. array(
  873. 'type' => 'input',
  874. 'name' => 'plexTabURL',
  875. 'label' => 'Plex Tab WAN URL',
  876. 'value' => $GLOBALS['plexTabURL'],
  877. 'placeholder' => 'http(s)://hostname:port'
  878. ),
  879. array(
  880. 'type' => 'select',
  881. 'name' => 'cacheImageSize',
  882. 'label' => 'Image Cache Size',
  883. 'value' => $GLOBALS['cacheImageSize'],
  884. 'options' => array(
  885. array(
  886. 'name' => 'Low',
  887. 'value' => '.5'
  888. ),
  889. array(
  890. 'name' => '1x',
  891. 'value' => '1'
  892. ),
  893. array(
  894. 'name' => '2x',
  895. 'value' => '2'
  896. ),
  897. array(
  898. 'name' => '3x',
  899. 'value' => '3'
  900. )
  901. )
  902. )
  903. ),
  904. 'Test Connection' => array(
  905. array(
  906. 'type' => 'blank',
  907. 'label' => 'Please Save before Testing'
  908. ),
  909. array(
  910. 'type' => 'button',
  911. 'label' => '',
  912. 'icon' => 'fa fa-flask',
  913. 'class' => 'pull-right',
  914. 'text' => 'Test Connection',
  915. 'attr' => 'onclick="testAPIConnection(\'plex\')"'
  916. ),
  917. )
  918. )
  919. ),
  920. array(
  921. 'name' => 'Emby-Jellyfin',
  922. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  923. 'image' => 'plugins/images/tabs/emby.png',
  924. 'category' => 'Media Server',
  925. 'settings' => array(
  926. 'Enable' => array(
  927. array(
  928. 'type' => 'switch',
  929. 'name' => 'homepageEmbyEnabled',
  930. 'label' => 'Enable',
  931. 'value' => $GLOBALS['homepageEmbyEnabled']
  932. ),
  933. array(
  934. 'type' => 'select',
  935. 'name' => 'homepageEmbyAuth',
  936. 'label' => 'Minimum Authentication',
  937. 'value' => $GLOBALS['homepageEmbyAuth'],
  938. 'options' => $groups
  939. )
  940. ),
  941. 'Connection' => array(
  942. array(
  943. 'type' => 'input',
  944. 'name' => 'embyURL',
  945. 'label' => 'URL',
  946. 'value' => $GLOBALS['embyURL'],
  947. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too. Make sure if Jelly fin to end url with /jellyfin',
  948. 'placeholder' => 'http(s)://hostname:port - make sure if Jelly fin to end url with /jellyfin'
  949. ),
  950. array(
  951. 'type' => 'password-alt',
  952. 'name' => 'embyToken',
  953. 'label' => 'Token',
  954. 'value' => $GLOBALS['embyToken']
  955. )
  956. ),
  957. 'Active Streams' => array(
  958. array(
  959. 'type' => 'switch',
  960. 'name' => 'homepageEmbyStreams',
  961. 'label' => 'Enable',
  962. 'value' => $GLOBALS['homepageEmbyStreams']
  963. ),
  964. array(
  965. 'type' => 'select',
  966. 'name' => 'homepageEmbyStreamsAuth',
  967. 'label' => 'Minimum Authorization',
  968. 'value' => $GLOBALS['homepageEmbyStreamsAuth'],
  969. 'options' => $groups
  970. ),
  971. array(
  972. 'type' => 'switch',
  973. 'name' => 'homepageShowStreamNames',
  974. 'label' => 'User Information',
  975. 'value' => $GLOBALS['homepageShowStreamNames']
  976. ),
  977. array(
  978. 'type' => 'select',
  979. 'name' => 'homepageShowStreamNamesAuth',
  980. 'label' => 'Minimum Authorization',
  981. 'value' => $GLOBALS['homepageShowStreamNamesAuth'],
  982. 'options' => $groups
  983. ),
  984. array(
  985. 'type' => 'select',
  986. 'name' => 'homepageStreamRefresh',
  987. 'label' => 'Refresh Seconds',
  988. 'value' => $GLOBALS['homepageStreamRefresh'],
  989. 'options' => optionTime()
  990. ),
  991. ),
  992. 'Recent Items' => array(
  993. array(
  994. 'type' => 'switch',
  995. 'name' => 'homepageEmbyRecent',
  996. 'label' => 'Enable',
  997. 'value' => $GLOBALS['homepageEmbyRecent']
  998. ),
  999. array(
  1000. 'type' => 'select',
  1001. 'name' => 'homepageEmbyRecentAuth',
  1002. 'label' => 'Minimum Authorization',
  1003. 'value' => $GLOBALS['homepageEmbyRecentAuth'],
  1004. 'options' => $groups
  1005. ),
  1006. array(
  1007. 'type' => 'number',
  1008. 'name' => 'homepageRecentLimit',
  1009. 'label' => 'Item Limit',
  1010. 'value' => $GLOBALS['homepageRecentLimit'],
  1011. ),
  1012. array(
  1013. 'type' => 'select',
  1014. 'name' => 'homepageRecentRefresh',
  1015. 'label' => 'Refresh Seconds',
  1016. 'value' => $GLOBALS['homepageRecentRefresh'],
  1017. 'options' => optionTime()
  1018. ),
  1019. ),
  1020. 'Misc Options' => array(
  1021. array(
  1022. 'type' => 'input',
  1023. 'name' => 'embyTabName',
  1024. 'label' => 'Emby Tab Name',
  1025. 'value' => $GLOBALS['embyTabName'],
  1026. 'placeholder' => 'Only use if you have Emby in a reverse proxy'
  1027. ),
  1028. array(
  1029. 'type' => 'input',
  1030. 'name' => 'embyTabURL',
  1031. 'label' => 'Emby Tab WAN URL',
  1032. 'value' => $GLOBALS['embyTabURL'],
  1033. 'placeholder' => 'http(s)://hostname:port'
  1034. ),
  1035. array(
  1036. 'type' => 'select',
  1037. 'name' => 'cacheImageSize',
  1038. 'label' => 'Image Cache Size',
  1039. 'value' => $GLOBALS['cacheImageSize'],
  1040. 'options' => array(
  1041. array(
  1042. 'name' => 'Low',
  1043. 'value' => '.5'
  1044. ),
  1045. array(
  1046. 'name' => '1x',
  1047. 'value' => '1'
  1048. ),
  1049. array(
  1050. 'name' => '2x',
  1051. 'value' => '2'
  1052. ),
  1053. array(
  1054. 'name' => '3x',
  1055. 'value' => '3'
  1056. )
  1057. )
  1058. )
  1059. )
  1060. )
  1061. ),
  1062. array(
  1063. 'name' => 'JDownloader',
  1064. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1065. 'image' => 'plugins/images/tabs/jdownloader.png',
  1066. 'category' => 'Downloader',
  1067. 'settings' => array(
  1068. 'custom' => '
  1069. <div class="row">
  1070. <div class="col-lg-12">
  1071. <div class="panel panel-info">
  1072. <div class="panel-heading">
  1073. <span lang="en">Notice</span>
  1074. </div>
  1075. <div class="panel-wrapper collapse in" aria-expanded="true">
  1076. <div class="panel-body">
  1077. <ul class="list-icons">
  1078. <li><i class="fa fa-chevron-right text-danger"></i> <a href="https://pypi.org/project/myjd-api/" target="_blank">Download [myjd-api] Module</a></li>
  1079. <li><i class="fa fa-chevron-right text-danger"></i> Add <b>/api/myjd</b> to the URL if you are using <a href="https://pypi.org/project/RSScrawler/" target="_blank">RSScrawler</a></li>
  1080. </ul>
  1081. </div>
  1082. </div>
  1083. </div>
  1084. </div>
  1085. </div>
  1086. ',
  1087. 'Enable' => array(
  1088. array(
  1089. 'type' => 'switch',
  1090. 'name' => 'homepageJdownloaderEnabled',
  1091. 'label' => 'Enable',
  1092. 'value' => $GLOBALS['homepageJdownloaderEnabled']
  1093. ),
  1094. array(
  1095. 'type' => 'select',
  1096. 'name' => 'homepageJdownloaderAuth',
  1097. 'label' => 'Minimum Authentication',
  1098. 'value' => $GLOBALS['homepageJdownloaderAuth'],
  1099. 'options' => $groups
  1100. )
  1101. ),
  1102. 'Connection' => array(
  1103. array(
  1104. 'type' => 'input',
  1105. 'name' => 'jdownloaderURL',
  1106. 'label' => 'URL',
  1107. 'value' => $GLOBALS['jdownloaderURL'],
  1108. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1109. 'placeholder' => 'http(s)://hostname:port'
  1110. )
  1111. ),
  1112. 'Misc Options' => array(
  1113. array(
  1114. 'type' => 'select',
  1115. 'name' => 'homepageDownloadRefresh',
  1116. 'label' => 'Refresh Seconds',
  1117. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1118. 'options' => optionTime()
  1119. ),
  1120. array(
  1121. 'type' => 'switch',
  1122. 'name' => 'jdownloaderCombine',
  1123. 'label' => 'Add to Combined Downloader',
  1124. 'value' => $GLOBALS['jdownloaderCombine']
  1125. ),
  1126. ),
  1127. 'Test Connection' => array(
  1128. array(
  1129. 'type' => 'blank',
  1130. 'label' => 'Please Save before Testing'
  1131. ),
  1132. array(
  1133. 'type' => 'button',
  1134. 'label' => '',
  1135. 'icon' => 'fa fa-flask',
  1136. 'class' => 'pull-right',
  1137. 'text' => 'Test Connection',
  1138. 'attr' => 'onclick="testAPIConnection(\'jdownloader\')"'
  1139. ),
  1140. )
  1141. )
  1142. ),
  1143. array(
  1144. 'name' => 'SabNZBD',
  1145. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1146. 'image' => 'plugins/images/tabs/sabnzbd.png',
  1147. 'category' => 'Downloader',
  1148. 'settings' => array(
  1149. 'Enable' => array(
  1150. array(
  1151. 'type' => 'switch',
  1152. 'name' => 'homepageSabnzbdEnabled',
  1153. 'label' => 'Enable',
  1154. 'value' => $GLOBALS['homepageSabnzbdEnabled']
  1155. ),
  1156. array(
  1157. 'type' => 'select',
  1158. 'name' => 'homepageSabnzbdAuth',
  1159. 'label' => 'Minimum Authentication',
  1160. 'value' => $GLOBALS['homepageSabnzbdAuth'],
  1161. 'options' => $groups
  1162. )
  1163. ),
  1164. 'Connection' => array(
  1165. array(
  1166. 'type' => 'input',
  1167. 'name' => 'sabnzbdURL',
  1168. 'label' => 'URL',
  1169. 'value' => $GLOBALS['sabnzbdURL'],
  1170. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1171. 'placeholder' => 'http(s)://hostname:port'
  1172. ),
  1173. array(
  1174. 'type' => 'password-alt',
  1175. 'name' => 'sabnzbdToken',
  1176. 'label' => 'Token',
  1177. 'value' => $GLOBALS['sabnzbdToken']
  1178. )
  1179. ),
  1180. 'Misc Options' => array(
  1181. array(
  1182. 'type' => 'select',
  1183. 'name' => 'homepageDownloadRefresh',
  1184. 'label' => 'Refresh Seconds',
  1185. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1186. 'options' => optionTime()
  1187. ),
  1188. array(
  1189. 'type' => 'switch',
  1190. 'name' => 'sabnzbdCombine',
  1191. 'label' => 'Add to Combined Downloader',
  1192. 'value' => $GLOBALS['sabnzbdCombine']
  1193. ),
  1194. ),
  1195. 'Test Connection' => array(
  1196. array(
  1197. 'type' => 'blank',
  1198. 'label' => 'Please Save before Testing'
  1199. ),
  1200. array(
  1201. 'type' => 'button',
  1202. 'label' => '',
  1203. 'icon' => 'fa fa-flask',
  1204. 'class' => 'pull-right',
  1205. 'text' => 'Test Connection',
  1206. 'attr' => 'onclick="testAPIConnection(\'sabnzbd\')"'
  1207. ),
  1208. )
  1209. )
  1210. ),
  1211. array(
  1212. 'name' => 'NZBGet',
  1213. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1214. 'image' => 'plugins/images/tabs/nzbget.png',
  1215. 'category' => 'Downloader',
  1216. 'settings' => array(
  1217. 'Enable' => array(
  1218. array(
  1219. 'type' => 'switch',
  1220. 'name' => 'homepageNzbgetEnabled',
  1221. 'label' => 'Enable',
  1222. 'value' => $GLOBALS['homepageNzbgetEnabled']
  1223. ),
  1224. array(
  1225. 'type' => 'select',
  1226. 'name' => 'homepageNzbgetAuth',
  1227. 'label' => 'Minimum Authentication',
  1228. 'value' => $GLOBALS['homepageNzbgetAuth'],
  1229. 'options' => $groups
  1230. )
  1231. ),
  1232. 'Connection' => array(
  1233. array(
  1234. 'type' => 'input',
  1235. 'name' => 'nzbgetURL',
  1236. 'label' => 'URL',
  1237. 'value' => $GLOBALS['nzbgetURL'],
  1238. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1239. 'placeholder' => 'http(s)://hostname:port'
  1240. ),
  1241. array(
  1242. 'type' => 'input',
  1243. 'name' => 'nzbgetUsername',
  1244. 'label' => 'Username',
  1245. 'value' => $GLOBALS['nzbgetUsername']
  1246. ),
  1247. array(
  1248. 'type' => 'password',
  1249. 'name' => 'nzbgetPassword',
  1250. 'label' => 'Password',
  1251. 'value' => $GLOBALS['nzbgetPassword']
  1252. )
  1253. ),
  1254. 'Misc Options' => array(
  1255. array(
  1256. 'type' => 'select',
  1257. 'name' => 'homepageDownloadRefresh',
  1258. 'label' => 'Refresh Seconds',
  1259. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1260. 'options' => optionTime()
  1261. ),
  1262. array(
  1263. 'type' => 'switch',
  1264. 'name' => 'nzbgetCombine',
  1265. 'label' => 'Add to Combined Downloader',
  1266. 'value' => $GLOBALS['nzbgetCombine']
  1267. ),
  1268. ),
  1269. 'Test Connection' => array(
  1270. array(
  1271. 'type' => 'blank',
  1272. 'label' => 'Please Save before Testing'
  1273. ),
  1274. array(
  1275. 'type' => 'button',
  1276. 'label' => '',
  1277. 'icon' => 'fa fa-flask',
  1278. 'class' => 'pull-right',
  1279. 'text' => 'Test Connection',
  1280. 'attr' => 'onclick="testAPIConnection(\'nzbget\')"'
  1281. ),
  1282. )
  1283. )
  1284. ),
  1285. array(
  1286. 'name' => 'Transmission',
  1287. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1288. 'image' => 'plugins/images/tabs/transmission.png',
  1289. 'category' => 'Downloader',
  1290. 'settings' => array(
  1291. 'Enable' => array(
  1292. array(
  1293. 'type' => 'switch',
  1294. 'name' => 'homepageTransmissionEnabled',
  1295. 'label' => 'Enable',
  1296. 'value' => $GLOBALS['homepageTransmissionEnabled']
  1297. ),
  1298. array(
  1299. 'type' => 'select',
  1300. 'name' => 'homepageTransmissionAuth',
  1301. 'label' => 'Minimum Authentication',
  1302. 'value' => $GLOBALS['homepageTransmissionAuth'],
  1303. 'options' => $groups
  1304. )
  1305. ),
  1306. 'Connection' => array(
  1307. array(
  1308. 'type' => 'input',
  1309. 'name' => 'transmissionURL',
  1310. 'label' => 'URL',
  1311. 'value' => $GLOBALS['transmissionURL'],
  1312. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1313. 'placeholder' => 'http(s)://hostname:port'
  1314. ),
  1315. array(
  1316. 'type' => 'input',
  1317. 'name' => 'transmissionUsername',
  1318. 'label' => 'Username',
  1319. 'value' => $GLOBALS['transmissionUsername']
  1320. ),
  1321. array(
  1322. 'type' => 'password',
  1323. 'name' => 'transmissionPassword',
  1324. 'label' => 'Password',
  1325. 'value' => $GLOBALS['transmissionPassword']
  1326. )
  1327. ),
  1328. 'Misc Options' => array(
  1329. array(
  1330. 'type' => 'switch',
  1331. 'name' => 'transmissionHideSeeding',
  1332. 'label' => 'Hide Seeding',
  1333. 'value' => $GLOBALS['transmissionHideSeeding']
  1334. ), array(
  1335. 'type' => 'switch',
  1336. 'name' => 'transmissionHideCompleted',
  1337. 'label' => 'Hide Completed',
  1338. 'value' => $GLOBALS['transmissionHideCompleted']
  1339. ),
  1340. array(
  1341. 'type' => 'select',
  1342. 'name' => 'homepageDownloadRefresh',
  1343. 'label' => 'Refresh Seconds',
  1344. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1345. 'options' => optionTime()
  1346. ),
  1347. array(
  1348. 'type' => 'switch',
  1349. 'name' => 'transmissionCombine',
  1350. 'label' => 'Add to Combined Downloader',
  1351. 'value' => $GLOBALS['transmissionCombine']
  1352. ),
  1353. )
  1354. )
  1355. ),
  1356. array(
  1357. 'name' => 'qBittorrent',
  1358. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1359. 'image' => 'plugins/images/tabs/qBittorrent.png',
  1360. 'category' => 'Downloader',
  1361. 'settings' => array(
  1362. 'Enable' => array(
  1363. array(
  1364. 'type' => 'switch',
  1365. 'name' => 'homepageqBittorrentEnabled',
  1366. 'label' => 'Enable',
  1367. 'value' => $GLOBALS['homepageqBittorrentEnabled']
  1368. ),
  1369. array(
  1370. 'type' => 'select',
  1371. 'name' => 'homepageqBittorrentAuth',
  1372. 'label' => 'Minimum Authentication',
  1373. 'value' => $GLOBALS['homepageqBittorrentAuth'],
  1374. 'options' => $groups
  1375. )
  1376. ),
  1377. 'Connection' => array(
  1378. array(
  1379. 'type' => 'input',
  1380. 'name' => 'qBittorrentURL',
  1381. 'label' => 'URL',
  1382. 'value' => $GLOBALS['qBittorrentURL'],
  1383. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1384. 'placeholder' => 'http(s)://hostname:port'
  1385. ),
  1386. array(
  1387. 'type' => 'select',
  1388. 'name' => 'qBittorrentApiVersion',
  1389. 'label' => 'API Version',
  1390. 'value' => $GLOBALS['qBittorrentApiVersion'],
  1391. 'options' => $qBittorrentApiOptions
  1392. ),
  1393. array(
  1394. 'type' => 'input',
  1395. 'name' => 'qBittorrentUsername',
  1396. 'label' => 'Username',
  1397. 'value' => $GLOBALS['qBittorrentUsername']
  1398. ),
  1399. array(
  1400. 'type' => 'password',
  1401. 'name' => 'qBittorrentPassword',
  1402. 'label' => 'Password',
  1403. 'value' => $GLOBALS['qBittorrentPassword']
  1404. )
  1405. ),
  1406. 'Misc Options' => array(
  1407. array(
  1408. 'type' => 'switch',
  1409. 'name' => 'qBittorrentHideSeeding',
  1410. 'label' => 'Hide Seeding',
  1411. 'value' => $GLOBALS['qBittorrentHideSeeding']
  1412. ),
  1413. array(
  1414. 'type' => 'switch',
  1415. 'name' => 'qBittorrentHideCompleted',
  1416. 'label' => 'Hide Completed',
  1417. 'value' => $GLOBALS['qBittorrentHideCompleted']
  1418. ),
  1419. array(
  1420. 'type' => 'select',
  1421. 'name' => 'qBittorrentSortOrder',
  1422. 'label' => 'Order',
  1423. 'value' => $GLOBALS['qBittorrentSortOrder'],
  1424. 'options' => $qBittorrentSortOptions
  1425. ), array(
  1426. 'type' => 'switch',
  1427. 'name' => 'qBittorrentReverseSorting',
  1428. 'label' => 'Reverse Sorting',
  1429. 'value' => $GLOBALS['qBittorrentReverseSorting']
  1430. ),
  1431. array(
  1432. 'type' => 'select',
  1433. 'name' => 'homepageDownloadRefresh',
  1434. 'label' => 'Refresh Seconds',
  1435. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1436. 'options' => optionTime()
  1437. ),
  1438. array(
  1439. 'type' => 'switch',
  1440. 'name' => 'qBittorrentCombine',
  1441. 'label' => 'Add to Combined Downloader',
  1442. 'value' => $GLOBALS['qBittorrentCombine']
  1443. ),
  1444. )
  1445. )
  1446. ),
  1447. array(
  1448. 'name' => 'rTorrent',
  1449. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1450. 'image' => 'plugins/images/tabs/rTorrent.png',
  1451. 'category' => 'Downloader',
  1452. 'settings' => array(
  1453. 'FYI' => array(
  1454. array(
  1455. 'type' => 'html',
  1456. 'label' => '',
  1457. 'override' => 12,
  1458. 'html' => '
  1459. <div class="row">
  1460. <div class="col-lg-12">
  1461. <div class="panel panel-info">
  1462. <div class="panel-heading">
  1463. <span lang="en">ATTENTION</span>
  1464. </div>
  1465. <div class="panel-wrapper collapse in" aria-expanded="true">
  1466. <div class="panel-body">
  1467. <h4 lang="en">This module requires XMLRPC</h4>
  1468. <span lang="en">Status: [ <b>' . $xmlStatus . '</b> ]</span>
  1469. <br/></br>
  1470. <span lang="en">
  1471. <h4><b>Note about API URL</b></h4>
  1472. Organizr appends the url with <code>/RPC2</code> unless the URL ends in <code>.php</code><br/>
  1473. <h5>Possible URLs:</h5>
  1474. <li>http://localhost:8080</li>
  1475. <li>https://domain.site/xmlrpc.php</li>
  1476. <li>https://seedbox.site/rutorrent/plugins/httprpc/action.php</li>
  1477. </span>
  1478. </div>
  1479. </div>
  1480. </div>
  1481. </div>
  1482. </div>
  1483. '
  1484. )
  1485. ),
  1486. 'Enable' => array(
  1487. array(
  1488. 'type' => 'switch',
  1489. 'name' => 'homepagerTorrentEnabled',
  1490. 'label' => 'Enable',
  1491. 'value' => $GLOBALS['homepagerTorrentEnabled']
  1492. ),
  1493. array(
  1494. 'type' => 'select',
  1495. 'name' => 'homepagerTorrentAuth',
  1496. 'label' => 'Minimum Authentication',
  1497. 'value' => $GLOBALS['homepagerTorrentAuth'],
  1498. 'options' => $groups
  1499. )
  1500. ),
  1501. 'Connection' => array(
  1502. array(
  1503. 'type' => 'input',
  1504. 'name' => 'rTorrentURL',
  1505. 'label' => 'URL',
  1506. 'value' => $GLOBALS['rTorrentURL'],
  1507. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1508. 'placeholder' => 'http(s)://hostname:port'
  1509. ),
  1510. array(
  1511. 'type' => 'input',
  1512. 'name' => 'rTorrentURLOverride',
  1513. 'label' => 'rTorrent API URL Override',
  1514. 'value' => $GLOBALS['rTorrentURLOverride'],
  1515. 'help' => 'Only use if you cannot connect. Please make sure to use local IP address and port - You also may use local dns name too.',
  1516. 'placeholder' => 'http(s)://hostname:port/xmlrpc'
  1517. ),
  1518. array(
  1519. 'type' => 'input',
  1520. 'name' => 'rTorrentUsername',
  1521. 'label' => 'Username',
  1522. 'value' => $GLOBALS['rTorrentUsername']
  1523. ),
  1524. array(
  1525. 'type' => 'password',
  1526. 'name' => 'rTorrentPassword',
  1527. 'label' => 'Password',
  1528. 'value' => $GLOBALS['rTorrentPassword']
  1529. ),
  1530. array(
  1531. 'type' => 'switch',
  1532. 'name' => 'rTorrentDisableCertCheck',
  1533. 'label' => 'Disable Certificate Check',
  1534. 'value' => $GLOBALS['rTorrentDisableCertCheck']
  1535. ),
  1536. ),
  1537. 'Misc Options' => array(
  1538. array(
  1539. 'type' => 'switch',
  1540. 'name' => 'rTorrentHideSeeding',
  1541. 'label' => 'Hide Seeding',
  1542. 'value' => $GLOBALS['rTorrentHideSeeding']
  1543. ), array(
  1544. 'type' => 'switch',
  1545. 'name' => 'rTorrentHideCompleted',
  1546. 'label' => 'Hide Completed',
  1547. 'value' => $GLOBALS['rTorrentHideCompleted']
  1548. ),
  1549. array(
  1550. 'type' => 'select',
  1551. 'name' => 'rTorrentSortOrder',
  1552. 'label' => 'Order',
  1553. 'value' => $GLOBALS['rTorrentSortOrder'],
  1554. 'options' => $rTorrentSortOptions
  1555. ),
  1556. array(
  1557. 'type' => 'select',
  1558. 'name' => 'homepageDownloadRefresh',
  1559. 'label' => 'Refresh Seconds',
  1560. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1561. 'options' => optionTime()
  1562. ),
  1563. array(
  1564. 'type' => 'switch',
  1565. 'name' => 'rTorrentCombine',
  1566. 'label' => 'Add to Combined Downloader',
  1567. 'value' => $GLOBALS['rTorrentCombine']
  1568. ),
  1569. ),
  1570. 'Test Connection' => array(
  1571. array(
  1572. 'type' => 'blank',
  1573. 'label' => 'Please Save before Testing'
  1574. ),
  1575. array(
  1576. 'type' => 'button',
  1577. 'label' => '',
  1578. 'icon' => 'fa fa-flask',
  1579. 'class' => 'pull-right',
  1580. 'text' => 'Test Connection',
  1581. 'attr' => 'onclick="testAPIConnection(\'rtorrent\')"'
  1582. ),
  1583. )
  1584. )
  1585. ),
  1586. array(
  1587. 'name' => 'Deluge',
  1588. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1589. 'image' => 'plugins/images/tabs/deluge.png',
  1590. 'category' => 'Downloader',
  1591. 'settings' => array(
  1592. 'custom' => '
  1593. <div class="row">
  1594. <div class="col-lg-12">
  1595. <div class="panel panel-info">
  1596. <div class="panel-heading">
  1597. <span lang="en">Notice</span>
  1598. </div>
  1599. <div class="panel-wrapper collapse in" aria-expanded="true">
  1600. <div class="panel-body">
  1601. <ul class="list-icons">
  1602. <li><i class="fa fa-chevron-right text-danger"></i> <a href="https://github.com/idlesign/deluge-webapi/tree/master/dist" target="_blank">Download Plugin</a></li>
  1603. <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>
  1604. <li><i class="fa fa-chevron-right text-danger"></i> Activate WebAPI plugin </li>
  1605. </ul>
  1606. </div>
  1607. </div>
  1608. </div>
  1609. </div>
  1610. </div>
  1611. ',
  1612. 'Enable' => array(
  1613. array(
  1614. 'type' => 'switch',
  1615. 'name' => 'homepageDelugeEnabled',
  1616. 'label' => 'Enable',
  1617. 'value' => $GLOBALS['homepageDelugeEnabled']
  1618. ),
  1619. array(
  1620. 'type' => 'select',
  1621. 'name' => 'homepageDelugeAuth',
  1622. 'label' => 'Minimum Authentication',
  1623. 'value' => $GLOBALS['homepageDelugeAuth'],
  1624. 'options' => $groups
  1625. )
  1626. ),
  1627. 'Connection' => array(
  1628. array(
  1629. 'type' => 'input',
  1630. 'name' => 'delugeURL',
  1631. 'label' => 'URL',
  1632. 'value' => $GLOBALS['delugeURL'],
  1633. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1634. 'placeholder' => 'http(s)://hostname:port'
  1635. ),
  1636. array(
  1637. 'type' => 'password',
  1638. 'name' => 'delugePassword',
  1639. 'label' => 'Password',
  1640. 'value' => $GLOBALS['delugePassword']
  1641. )
  1642. ),
  1643. 'Misc Options' => array(
  1644. array(
  1645. 'type' => 'switch',
  1646. 'name' => 'delugeHideSeeding',
  1647. 'label' => 'Hide Seeding',
  1648. 'value' => $GLOBALS['delugeHideSeeding']
  1649. ), array(
  1650. 'type' => 'switch',
  1651. 'name' => 'delugeHideCompleted',
  1652. 'label' => 'Hide Completed',
  1653. 'value' => $GLOBALS['delugeHideCompleted']
  1654. ),
  1655. array(
  1656. 'type' => 'select',
  1657. 'name' => 'homepageDownloadRefresh',
  1658. 'label' => 'Refresh Seconds',
  1659. 'value' => $GLOBALS['homepageDownloadRefresh'],
  1660. 'options' => optionTime()
  1661. ),
  1662. array(
  1663. 'type' => 'switch',
  1664. 'name' => 'delugeCombine',
  1665. 'label' => 'Add to Combined Downloader',
  1666. 'value' => $GLOBALS['delugeCombine']
  1667. ),
  1668. ),
  1669. 'Test Connection' => array(
  1670. array(
  1671. 'type' => 'blank',
  1672. 'label' => 'Please Save before Testing'
  1673. ),
  1674. array(
  1675. 'type' => 'button',
  1676. 'label' => '',
  1677. 'icon' => 'fa fa-flask',
  1678. 'class' => 'pull-right',
  1679. 'text' => 'Test Connection',
  1680. 'attr' => 'onclick="testAPIConnection(\'deluge\')"'
  1681. ),
  1682. )
  1683. )
  1684. ),
  1685. array(
  1686. 'name' => 'Sonarr',
  1687. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1688. 'image' => 'plugins/images/tabs/sonarr.png',
  1689. 'category' => 'PVR',
  1690. 'settings' => array(
  1691. 'Enable' => array(
  1692. array(
  1693. 'type' => 'switch',
  1694. 'name' => 'homepageSonarrEnabled',
  1695. 'label' => 'Enable',
  1696. 'value' => $GLOBALS['homepageSonarrEnabled']
  1697. ),
  1698. array(
  1699. 'type' => 'select',
  1700. 'name' => 'homepageSonarrAuth',
  1701. 'label' => 'Minimum Authentication',
  1702. 'value' => $GLOBALS['homepageSonarrAuth'],
  1703. 'options' => $groups
  1704. )
  1705. ),
  1706. 'Connection' => array(
  1707. array(
  1708. 'type' => 'input',
  1709. 'name' => 'sonarrURL',
  1710. 'label' => 'URL',
  1711. 'value' => $GLOBALS['sonarrURL'],
  1712. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1713. 'placeholder' => 'http(s)://hostname:port'
  1714. ),
  1715. array(
  1716. 'type' => 'password-alt',
  1717. 'name' => 'sonarrToken',
  1718. 'label' => 'Token',
  1719. 'value' => $GLOBALS['sonarrToken']
  1720. )
  1721. ),
  1722. 'Misc Options' => array(
  1723. array(
  1724. 'type' => 'number',
  1725. 'name' => 'calendarStart',
  1726. 'label' => '# of Days Before',
  1727. 'value' => $GLOBALS['calendarStart'],
  1728. 'placeholder' => ''
  1729. ),
  1730. array(
  1731. 'type' => 'number',
  1732. 'name' => 'calendarEnd',
  1733. 'label' => '# of Days After',
  1734. 'value' => $GLOBALS['calendarEnd'],
  1735. 'placeholder' => ''
  1736. ),
  1737. array(
  1738. 'type' => 'select',
  1739. 'name' => 'calendarFirstDay',
  1740. 'label' => 'Start Day',
  1741. 'value' => $GLOBALS['calendarFirstDay'],
  1742. 'options' => $day
  1743. ),
  1744. array(
  1745. 'type' => 'select',
  1746. 'name' => 'calendarDefault',
  1747. 'label' => 'Default View',
  1748. 'value' => $GLOBALS['calendarDefault'],
  1749. 'options' => $calendarDefault
  1750. ),
  1751. array(
  1752. 'type' => 'select',
  1753. 'name' => 'calendarTimeFormat',
  1754. 'label' => 'Time Format',
  1755. 'value' => $GLOBALS['calendarTimeFormat'],
  1756. 'options' => $timeFormat
  1757. ),
  1758. array(
  1759. 'type' => 'select',
  1760. 'name' => 'calendarLimit',
  1761. 'label' => 'Items Per Day',
  1762. 'value' => $GLOBALS['calendarLimit'],
  1763. 'options' => $limit
  1764. ),
  1765. array(
  1766. 'type' => 'select',
  1767. 'name' => 'calendarRefresh',
  1768. 'label' => 'Refresh Seconds',
  1769. 'value' => $GLOBALS['calendarRefresh'],
  1770. 'options' => optionTime()
  1771. ),
  1772. array(
  1773. 'type' => 'switch',
  1774. 'name' => 'sonarrUnmonitored',
  1775. 'label' => 'Show Unmonitored',
  1776. 'value' => $GLOBALS['sonarrUnmonitored']
  1777. )
  1778. ),
  1779. 'Test Connection' => array(
  1780. array(
  1781. 'type' => 'blank',
  1782. 'label' => 'Please Save before Testing'
  1783. ),
  1784. array(
  1785. 'type' => 'button',
  1786. 'label' => '',
  1787. 'icon' => 'fa fa-flask',
  1788. 'class' => 'pull-right',
  1789. 'text' => 'Test Connection',
  1790. 'attr' => 'onclick="testAPIConnection(\'sonarr\')"'
  1791. ),
  1792. )
  1793. )
  1794. ),
  1795. array(
  1796. 'name' => 'Lidarr',
  1797. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1798. 'image' => 'plugins/images/tabs/lidarr.png',
  1799. 'category' => 'PMR',
  1800. 'settings' => array(
  1801. 'Enable' => array(
  1802. array(
  1803. 'type' => 'switch',
  1804. 'name' => 'homepageLidarrEnabled',
  1805. 'label' => 'Enable',
  1806. 'value' => $GLOBALS['homepageLidarrEnabled']
  1807. ),
  1808. array(
  1809. 'type' => 'select',
  1810. 'name' => 'homepageLidarrAuth',
  1811. 'label' => 'Minimum Authentication',
  1812. 'value' => $GLOBALS['homepageLidarrAuth'],
  1813. 'options' => $groups
  1814. )
  1815. ),
  1816. 'Connection' => array(
  1817. array(
  1818. 'type' => 'input',
  1819. 'name' => 'lidarrURL',
  1820. 'label' => 'URL',
  1821. 'value' => $GLOBALS['lidarrURL'],
  1822. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1823. 'placeholder' => 'http(s)://hostname:port'
  1824. ),
  1825. array(
  1826. 'type' => 'password-alt',
  1827. 'name' => 'lidarrToken',
  1828. 'label' => 'Token',
  1829. 'value' => $GLOBALS['lidarrToken']
  1830. )
  1831. ),
  1832. 'Misc Options' => array(
  1833. array(
  1834. 'type' => 'number',
  1835. 'name' => 'calendarStart',
  1836. 'label' => '# of Days Before',
  1837. 'value' => $GLOBALS['calendarStart'],
  1838. 'placeholder' => ''
  1839. ),
  1840. array(
  1841. 'type' => 'number',
  1842. 'name' => 'calendarEnd',
  1843. 'label' => '# of Days After',
  1844. 'value' => $GLOBALS['calendarEnd'],
  1845. 'placeholder' => ''
  1846. ),
  1847. array(
  1848. 'type' => 'select',
  1849. 'name' => 'calendarFirstDay',
  1850. 'label' => 'Start Day',
  1851. 'value' => $GLOBALS['calendarFirstDay'],
  1852. 'options' => $day
  1853. ),
  1854. array(
  1855. 'type' => 'select',
  1856. 'name' => 'calendarDefault',
  1857. 'label' => 'Default View',
  1858. 'value' => $GLOBALS['calendarDefault'],
  1859. 'options' => $calendarDefault
  1860. ),
  1861. array(
  1862. 'type' => 'select',
  1863. 'name' => 'calendarTimeFormat',
  1864. 'label' => 'Time Format',
  1865. 'value' => $GLOBALS['calendarTimeFormat'],
  1866. 'options' => $timeFormat
  1867. ),
  1868. array(
  1869. 'type' => 'select',
  1870. 'name' => 'calendarLimit',
  1871. 'label' => 'Items Per Day',
  1872. 'value' => $GLOBALS['calendarLimit'],
  1873. 'options' => $limit
  1874. ),
  1875. array(
  1876. 'type' => 'select',
  1877. 'name' => 'calendarRefresh',
  1878. 'label' => 'Refresh Seconds',
  1879. 'value' => $GLOBALS['calendarRefresh'],
  1880. 'options' => optionTime()
  1881. ),
  1882. ),
  1883. 'Test Connection' => array(
  1884. array(
  1885. 'type' => 'blank',
  1886. 'label' => 'Please Save before Testing'
  1887. ),
  1888. array(
  1889. 'type' => 'button',
  1890. 'label' => '',
  1891. 'icon' => 'fa fa-flask',
  1892. 'class' => 'pull-right',
  1893. 'text' => 'Test Connection',
  1894. 'attr' => 'onclick="testAPIConnection(\'lidarr\')"'
  1895. ),
  1896. )
  1897. )
  1898. ),
  1899. array(
  1900. 'name' => 'Radarr',
  1901. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  1902. 'image' => 'plugins/images/tabs/radarr.png',
  1903. 'category' => 'PVR',
  1904. 'settings' => array(
  1905. 'Enable' => array(
  1906. array(
  1907. 'type' => 'switch',
  1908. 'name' => 'homepageRadarrEnabled',
  1909. 'label' => 'Enable',
  1910. 'value' => $GLOBALS['homepageRadarrEnabled']
  1911. ),
  1912. array(
  1913. 'type' => 'select',
  1914. 'name' => 'homepageRadarrAuth',
  1915. 'label' => 'Minimum Authentication',
  1916. 'value' => $GLOBALS['homepageRadarrAuth'],
  1917. 'options' => $groups
  1918. )
  1919. ),
  1920. 'Connection' => array(
  1921. array(
  1922. 'type' => 'input',
  1923. 'name' => 'radarrURL',
  1924. 'label' => 'URL',
  1925. 'value' => $GLOBALS['radarrURL'],
  1926. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  1927. 'placeholder' => 'http(s)://hostname:port'
  1928. ),
  1929. array(
  1930. 'type' => 'password-alt',
  1931. 'name' => 'radarrToken',
  1932. 'label' => 'Token',
  1933. 'value' => $GLOBALS['radarrToken']
  1934. )
  1935. ),
  1936. 'Misc Options' => array(
  1937. array(
  1938. 'type' => 'number',
  1939. 'name' => 'calendarStart',
  1940. 'label' => '# of Days Before',
  1941. 'value' => $GLOBALS['calendarStart'],
  1942. 'placeholder' => ''
  1943. ),
  1944. array(
  1945. 'type' => 'number',
  1946. 'name' => 'calendarEnd',
  1947. 'label' => '# of Days After',
  1948. 'value' => $GLOBALS['calendarEnd'],
  1949. 'placeholder' => ''
  1950. ),
  1951. array(
  1952. 'type' => 'select',
  1953. 'name' => 'calendarFirstDay',
  1954. 'label' => 'Start Day',
  1955. 'value' => $GLOBALS['calendarFirstDay'],
  1956. 'options' => $day
  1957. ),
  1958. array(
  1959. 'type' => 'select',
  1960. 'name' => 'calendarDefault',
  1961. 'label' => 'Default View',
  1962. 'value' => $GLOBALS['calendarDefault'],
  1963. 'options' => $calendarDefault
  1964. ),
  1965. array(
  1966. 'type' => 'select',
  1967. 'name' => 'calendarTimeFormat',
  1968. 'label' => 'Time Format',
  1969. 'value' => $GLOBALS['calendarTimeFormat'],
  1970. 'options' => $timeFormat
  1971. ),
  1972. array(
  1973. 'type' => 'select',
  1974. 'name' => 'calendarLimit',
  1975. 'label' => 'Items Per Day',
  1976. 'value' => $GLOBALS['calendarLimit'],
  1977. 'options' => $limit
  1978. ),
  1979. array(
  1980. 'type' => 'select',
  1981. 'name' => 'calendarRefresh',
  1982. 'label' => 'Refresh Seconds',
  1983. 'value' => $GLOBALS['calendarRefresh'],
  1984. 'options' => optionTime()
  1985. )
  1986. ),
  1987. 'Test Connection' => array(
  1988. array(
  1989. 'type' => 'blank',
  1990. 'label' => 'Please Save before Testing'
  1991. ),
  1992. array(
  1993. 'type' => 'button',
  1994. 'label' => '',
  1995. 'icon' => 'fa fa-flask',
  1996. 'class' => 'pull-right',
  1997. 'text' => 'Test Connection',
  1998. 'attr' => 'onclick="testAPIConnection(\'radarr\')"'
  1999. ),
  2000. )
  2001. )
  2002. ),
  2003. array(
  2004. 'name' => 'CouchPotato',
  2005. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  2006. 'image' => 'plugins/images/tabs/couchpotato.png',
  2007. 'category' => 'PVR',
  2008. 'settings' => array(
  2009. 'Enable' => array(
  2010. array(
  2011. 'type' => 'switch',
  2012. 'name' => 'homepageCouchpotatoEnabled',
  2013. 'label' => 'Enable',
  2014. 'value' => $GLOBALS['homepageCouchpotatoEnabled']
  2015. ),
  2016. array(
  2017. 'type' => 'select',
  2018. 'name' => 'homepageCouchpotatoAuth',
  2019. 'label' => 'Minimum Authentication',
  2020. 'value' => $GLOBALS['homepageCouchpotatoAuth'],
  2021. 'options' => $groups
  2022. )
  2023. ),
  2024. 'Connection' => array(
  2025. array(
  2026. 'type' => 'input',
  2027. 'name' => 'couchpotatoURL',
  2028. 'label' => 'URL',
  2029. 'value' => $GLOBALS['couchpotatoURL'],
  2030. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  2031. 'placeholder' => 'http(s)://hostname:port'
  2032. ),
  2033. array(
  2034. 'type' => 'password-alt',
  2035. 'name' => 'couchpotatoToken',
  2036. 'label' => 'Token',
  2037. 'value' => $GLOBALS['couchpotatoToken']
  2038. )
  2039. ),
  2040. 'Misc Options' => array(
  2041. array(
  2042. 'type' => 'select',
  2043. 'name' => 'calendarFirstDay',
  2044. 'label' => 'Start Day',
  2045. 'value' => $GLOBALS['calendarFirstDay'],
  2046. 'options' => $day
  2047. ),
  2048. array(
  2049. 'type' => 'select',
  2050. 'name' => 'calendarDefault',
  2051. 'label' => 'Default View',
  2052. 'value' => $GLOBALS['calendarDefault'],
  2053. 'options' => $calendarDefault
  2054. ),
  2055. array(
  2056. 'type' => 'select',
  2057. 'name' => 'calendarTimeFormat',
  2058. 'label' => 'Time Format',
  2059. 'value' => $GLOBALS['calendarTimeFormat'],
  2060. 'options' => $timeFormat
  2061. ),
  2062. array(
  2063. 'type' => 'select',
  2064. 'name' => 'calendarLimit',
  2065. 'label' => 'Items Per Day',
  2066. 'value' => $GLOBALS['calendarLimit'],
  2067. 'options' => $limit
  2068. ),
  2069. array(
  2070. 'type' => 'select',
  2071. 'name' => 'calendarRefresh',
  2072. 'label' => 'Refresh Seconds',
  2073. 'value' => $GLOBALS['calendarRefresh'],
  2074. 'options' => optionTime()
  2075. )
  2076. )
  2077. )
  2078. ),
  2079. array(
  2080. 'name' => 'SickRage',
  2081. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  2082. 'image' => 'plugins/images/tabs/sickrage.png',
  2083. 'category' => 'PVR',
  2084. 'settings' => array(
  2085. 'Enable' => array(
  2086. array(
  2087. 'type' => 'switch',
  2088. 'name' => 'homepageSickrageEnabled',
  2089. 'label' => 'Enable',
  2090. 'value' => $GLOBALS['homepageSickrageEnabled']
  2091. ),
  2092. array(
  2093. 'type' => 'select',
  2094. 'name' => 'homepageSickrageAuth',
  2095. 'label' => 'Minimum Authentication',
  2096. 'value' => $GLOBALS['homepageSickrageAuth'],
  2097. 'options' => $groups
  2098. )
  2099. ),
  2100. 'Connection' => array(
  2101. array(
  2102. 'type' => 'input',
  2103. 'name' => 'sickrageURL',
  2104. 'label' => 'URL',
  2105. 'value' => $GLOBALS['sickrageURL'],
  2106. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  2107. 'placeholder' => 'http(s)://hostname:port'
  2108. ),
  2109. array(
  2110. 'type' => 'password-alt',
  2111. 'name' => 'sickrageToken',
  2112. 'label' => 'Token',
  2113. 'value' => $GLOBALS['sickrageToken']
  2114. )
  2115. ),
  2116. 'Misc Options' => array(
  2117. array(
  2118. 'type' => 'select',
  2119. 'name' => 'calendarFirstDay',
  2120. 'label' => 'Start Day',
  2121. 'value' => $GLOBALS['calendarFirstDay'],
  2122. 'options' => $day
  2123. ),
  2124. array(
  2125. 'type' => 'select',
  2126. 'name' => 'calendarDefault',
  2127. 'label' => 'Default View',
  2128. 'value' => $GLOBALS['calendarDefault'],
  2129. 'options' => $calendarDefault
  2130. ),
  2131. array(
  2132. 'type' => 'select',
  2133. 'name' => 'calendarTimeFormat',
  2134. 'label' => 'Time Format',
  2135. 'value' => $GLOBALS['calendarTimeFormat'],
  2136. 'options' => $timeFormat
  2137. ),
  2138. array(
  2139. 'type' => 'select',
  2140. 'name' => 'calendarLimit',
  2141. 'label' => 'Items Per Day',
  2142. 'value' => $GLOBALS['calendarLimit'],
  2143. 'options' => $limit
  2144. ),
  2145. array(
  2146. 'type' => 'select',
  2147. 'name' => 'calendarRefresh',
  2148. 'label' => 'Refresh Seconds',
  2149. 'value' => $GLOBALS['calendarRefresh'],
  2150. 'options' => optionTime()
  2151. )
  2152. )
  2153. )
  2154. ),
  2155. array(
  2156. 'name' => 'Ombi',
  2157. 'enabled' => (strpos('personal', $GLOBALS['license']) !== false) ? true : false,
  2158. 'image' => 'plugins/images/tabs/ombi.png',
  2159. 'category' => 'Requests',
  2160. 'settings' => array(
  2161. 'Enable' => array(
  2162. array(
  2163. 'type' => 'switch',
  2164. 'name' => 'homepageOmbiEnabled',
  2165. 'label' => 'Enable',
  2166. 'value' => $GLOBALS['homepageOmbiEnabled']
  2167. ),
  2168. array(
  2169. 'type' => 'select',
  2170. 'name' => 'homepageOmbiAuth',
  2171. 'label' => 'Minimum Authentication',
  2172. 'value' => $GLOBALS['homepageOmbiAuth'],
  2173. 'options' => $groups
  2174. )
  2175. ),
  2176. 'Connection' => array(
  2177. array(
  2178. 'type' => 'input',
  2179. 'name' => 'ombiURL',
  2180. 'label' => 'URL',
  2181. 'value' => $GLOBALS['ombiURL'],
  2182. 'help' => 'Please make sure to use local IP address and port - You also may use local dns name too.',
  2183. 'placeholder' => 'http(s)://hostname:port'
  2184. ),
  2185. array(
  2186. 'type' => 'password-alt',
  2187. 'name' => 'ombiToken',
  2188. 'label' => 'Token',
  2189. 'value' => $GLOBALS['ombiToken']
  2190. )
  2191. ),
  2192. 'Misc Options' => array(
  2193. array(
  2194. 'type' => 'select',
  2195. 'name' => 'homepageOmbiRequestAuth',
  2196. 'label' => 'Minimum Group to Request',
  2197. 'value' => $GLOBALS['homepageOmbiRequestAuth'],
  2198. 'options' => $groups
  2199. ),
  2200. array(
  2201. 'type' => 'select',
  2202. 'name' => 'ombiTvDefault',
  2203. 'label' => 'TV Show Default Request',
  2204. 'value' => $GLOBALS['ombiTvDefault'],
  2205. 'options' => $ombiTvOptions
  2206. ),
  2207. array(
  2208. 'type' => 'switch',
  2209. 'name' => 'ombiLimitUser',
  2210. 'label' => 'Limit to User',
  2211. 'value' => $GLOBALS['ombiLimitUser']
  2212. ),
  2213. array(
  2214. 'type' => 'number',
  2215. 'name' => 'ombiLimit',
  2216. 'label' => 'Item Limit',
  2217. 'value' => $GLOBALS['ombiLimit'],
  2218. ),
  2219. array(
  2220. 'type' => 'select',
  2221. 'name' => 'ombiRefresh',
  2222. 'label' => 'Refresh Seconds',
  2223. 'value' => $GLOBALS['ombiRefresh'],
  2224. 'options' => optionTime()
  2225. ),
  2226. array(
  2227. 'type' => 'switch',
  2228. 'name' => 'ombiAlias',
  2229. 'label' => 'Use Ombi Alias Names',
  2230. 'value' => $GLOBALS['ombiAlias'],
  2231. 'help' => 'Use Ombi Alias Names instead of Usernames - If Alias is blank, Alias will fallback to Username'
  2232. )
  2233. ),
  2234. 'Default Filter' => array(
  2235. array(
  2236. 'type' => 'switch',
  2237. 'name' => 'ombiDefaultFilterAvailable',
  2238. 'label' => 'Show Available',
  2239. 'value' => $GLOBALS['ombiDefaultFilterAvailable'],
  2240. 'help' => 'Show All Available Ombi Requests'
  2241. ),
  2242. array(
  2243. 'type' => 'switch',
  2244. 'name' => 'ombiDefaultFilterUnavailable',
  2245. 'label' => 'Show Unavailable',
  2246. 'value' => $GLOBALS['ombiDefaultFilterUnavailable'],
  2247. 'help' => 'Show All Unavailable Ombi Requests'
  2248. ),
  2249. array(
  2250. 'type' => 'switch',
  2251. 'name' => 'ombiDefaultFilterApproved',
  2252. 'label' => 'Show Approved',
  2253. 'value' => $GLOBALS['ombiDefaultFilterApproved'],
  2254. 'help' => 'Show All Approved Ombi Requests'
  2255. ),
  2256. array(
  2257. 'type' => 'switch',
  2258. 'name' => 'ombiDefaultFilterUnapproved',
  2259. 'label' => 'Show Unapproved',
  2260. 'value' => $GLOBALS['ombiDefaultFilterUnapproved'],
  2261. 'help' => 'Show All Unapproved Ombi Requests'
  2262. ),
  2263. array(
  2264. 'type' => 'switch',
  2265. 'name' => 'ombiDefaultFilterDenied',
  2266. 'label' => 'Show Denied',
  2267. 'value' => $GLOBALS['ombiDefaultFilterDenied'],
  2268. 'help' => 'Show All Denied Ombi Requests'
  2269. )
  2270. ),
  2271. 'Test Connection' => array(
  2272. array(
  2273. 'type' => 'blank',
  2274. 'label' => 'Please Save before Testing'
  2275. ),
  2276. array(
  2277. 'type' => 'button',
  2278. 'label' => '',
  2279. 'icon' => 'fa fa-flask',
  2280. 'class' => 'pull-right',
  2281. 'text' => 'Test Connection',
  2282. 'attr' => 'onclick="testAPIConnection(\'ombi\')"'
  2283. ),
  2284. )
  2285. )
  2286. ),
  2287. array(
  2288. 'name' => 'Unifi',
  2289. 'enabled' => true,
  2290. 'image' => 'plugins/images/tabs/ubnt.png',
  2291. 'category' => 'Monitor',
  2292. 'settings' => array(
  2293. 'Enable' => array(
  2294. array(
  2295. 'type' => 'switch',
  2296. 'name' => 'homepageUnifiEnabled',
  2297. 'label' => 'Enable',
  2298. 'value' => $GLOBALS['homepageUnifiEnabled']
  2299. ),
  2300. array(
  2301. 'type' => 'select',
  2302. 'name' => 'homepageUnifiAuth',
  2303. 'label' => 'Minimum Authentication',
  2304. 'value' => $GLOBALS['homepageUnifiAuth'],
  2305. 'options' => $groups
  2306. )
  2307. ),
  2308. 'Connection' => array(
  2309. array(
  2310. 'type' => 'input',
  2311. 'name' => 'unifiURL',
  2312. 'label' => 'URL',
  2313. 'value' => $GLOBALS['unifiURL'],
  2314. 'help' => 'URL for Unifi',
  2315. 'placeholder' => 'Unifi API URL'
  2316. ),
  2317. array(
  2318. 'type' => 'blank',
  2319. 'label' => ''
  2320. ),
  2321. array(
  2322. 'type' => 'input',
  2323. 'name' => 'unifiUsername',
  2324. 'label' => 'Username',
  2325. 'value' => $GLOBALS['unifiUsername']
  2326. ),
  2327. array(
  2328. 'type' => 'password',
  2329. 'name' => 'unifiPassword',
  2330. 'label' => 'Password',
  2331. 'value' => $GLOBALS['unifiPassword']
  2332. ),
  2333. array(
  2334. 'type' => 'input',
  2335. 'name' => 'unifiSiteName',
  2336. 'label' => 'Site Name',
  2337. 'value' => $GLOBALS['unifiSiteName'],
  2338. 'help' => 'Site Name - not Site ID nor Site Description',
  2339. ),
  2340. array(
  2341. 'type' => 'button',
  2342. 'label' => 'Grab Unifi Site',
  2343. 'icon' => 'fa fa-building',
  2344. 'text' => 'Get Unifi Site',
  2345. 'attr' => 'onclick="getUnifiSite(\'unifiSite\')"'
  2346. ),
  2347. ),
  2348. 'Misc Options' => array(
  2349. array(
  2350. 'type' => 'select',
  2351. 'name' => 'homepageUnifiRefresh',
  2352. 'label' => 'Refresh Seconds',
  2353. 'value' => $GLOBALS['homepageUnifiRefresh'],
  2354. 'options' => optionTime()
  2355. ),
  2356. ),
  2357. 'Test Connection' => array(
  2358. array(
  2359. 'type' => 'blank',
  2360. 'label' => 'Please Save before Testing'
  2361. ),
  2362. array(
  2363. 'type' => 'button',
  2364. 'label' => '',
  2365. 'icon' => 'fa fa-flask',
  2366. 'class' => 'pull-right',
  2367. 'text' => 'Test Connection',
  2368. 'attr' => 'onclick="testAPIConnection(\'unifi\')"'
  2369. ),
  2370. )
  2371. )
  2372. ),
  2373. array(
  2374. 'name' => 'HealthChecks',
  2375. 'enabled' => true,
  2376. 'image' => 'plugins/images/tabs/healthchecks.png',
  2377. 'category' => 'Monitor',
  2378. 'settings' => array(
  2379. 'Enable' => array(
  2380. array(
  2381. 'type' => 'switch',
  2382. 'name' => 'homepageHealthChecksEnabled',
  2383. 'label' => 'Enable',
  2384. 'value' => $GLOBALS['homepageHealthChecksEnabled']
  2385. ),
  2386. array(
  2387. 'type' => 'select',
  2388. 'name' => 'homepageHealthChecksAuth',
  2389. 'label' => 'Minimum Authentication',
  2390. 'value' => $GLOBALS['homepageHealthChecksAuth'],
  2391. 'options' => $groups
  2392. )
  2393. ),
  2394. 'Connection' => array(
  2395. array(
  2396. 'type' => 'input',
  2397. 'name' => 'healthChecksURL',
  2398. 'label' => 'URL',
  2399. 'value' => $GLOBALS['healthChecksURL'],
  2400. 'help' => 'URL for HealthChecks API',
  2401. 'placeholder' => 'HealthChecks API URL'
  2402. ),
  2403. array(
  2404. 'type' => 'password-alt',
  2405. 'name' => 'healthChecksToken',
  2406. 'label' => 'Token',
  2407. 'value' => $GLOBALS['healthChecksToken']
  2408. )
  2409. ),
  2410. 'Misc Options' => array(
  2411. array(
  2412. 'type' => 'input',
  2413. 'name' => 'healthChecksTags',
  2414. 'label' => 'Tags',
  2415. 'value' => $GLOBALS['healthChecksTags'],
  2416. 'help' => 'Pull only checks with this tag - Blank for all',
  2417. 'placeholder' => 'Multiple tags using CSV - tag1,tag2'
  2418. ),
  2419. array(
  2420. 'type' => 'select',
  2421. 'name' => 'homepageHealthChecksRefresh',
  2422. 'label' => 'Refresh Seconds',
  2423. 'value' => $GLOBALS['homepageHealthChecksRefresh'],
  2424. 'options' => optionTime()
  2425. ),
  2426. ),
  2427. )
  2428. ),
  2429. array(
  2430. 'name' => 'CustomHTML-1',
  2431. 'enabled' => (strpos('personal,business', $GLOBALS['license']) !== false) ? true : false,
  2432. 'image' => 'plugins/images/tabs/custom1.png',
  2433. 'category' => 'Custom',
  2434. 'settings' => array(
  2435. 'Enable' => array(
  2436. array(
  2437. 'type' => 'switch',
  2438. 'name' => 'homepagCustomHTMLoneEnabled',
  2439. 'label' => 'Enable',
  2440. 'value' => $GLOBALS['homepagCustomHTMLoneEnabled']
  2441. ),
  2442. array(
  2443. 'type' => 'select',
  2444. 'name' => 'homepagCustomHTMLoneAuth',
  2445. 'label' => 'Minimum Authentication',
  2446. 'value' => $GLOBALS['homepagCustomHTMLoneAuth'],
  2447. 'options' => $groups
  2448. )
  2449. ),
  2450. 'Code' => array(
  2451. array(
  2452. 'type' => 'textbox',
  2453. 'name' => 'customHTMLone',
  2454. 'class' => 'hidden customHTMLoneTextarea',
  2455. 'label' => '',
  2456. 'value' => $GLOBALS['customHTMLone'],
  2457. ),
  2458. array(
  2459. 'type' => 'html',
  2460. 'override' => 12,
  2461. 'label' => 'Custom HTML/JavaScript',
  2462. 'html' => '<button type="button" class="hidden savecustomHTMLoneTextarea btn btn-info btn-circle pull-right m-r-5 m-l-10"><i class="fa fa-save"></i> </button><div id="customHTMLoneEditor" style="height:300px">' . htmlentities($GLOBALS['customHTMLone']) . '</div>'
  2463. ),
  2464. )
  2465. )
  2466. ),
  2467. array(
  2468. 'name' => 'CustomHTML-2',
  2469. 'enabled' => (strpos('personal,business', $GLOBALS['license']) !== false) ? true : false,
  2470. 'image' => 'plugins/images/tabs/custom2.png',
  2471. 'category' => 'Custom',
  2472. 'settings' => array(
  2473. 'Enable' => array(
  2474. array(
  2475. 'type' => 'switch',
  2476. 'name' => 'homepagCustomHTMLtwoEnabled',
  2477. 'label' => 'Enable',
  2478. 'value' => $GLOBALS['homepagCustomHTMLtwoEnabled']
  2479. ),
  2480. array(
  2481. 'type' => 'select',
  2482. 'name' => 'homepagCustomHTMLtwoAuth',
  2483. 'label' => 'Minimum Authentication',
  2484. 'value' => $GLOBALS['homepagCustomHTMLtwoAuth'],
  2485. 'options' => $groups
  2486. )
  2487. ),
  2488. 'Code' => array(
  2489. array(
  2490. 'type' => 'textbox',
  2491. 'name' => 'customHTMLtwo',
  2492. 'class' => 'hidden customHTMLtwoTextarea',
  2493. 'label' => '',
  2494. 'value' => $GLOBALS['customHTMLtwo'],
  2495. ),
  2496. array(
  2497. 'type' => 'html',
  2498. 'override' => 12,
  2499. 'label' => 'Custom HTML/JavaScript',
  2500. 'html' => '<button type="button" class="hidden savecustomHTMLtwoTextarea btn btn-info btn-circle pull-right m-r-5 m-l-10"><i class="fa fa-save"></i> </button><div id="customHTMLtwoEditor" style="height:300px">' . htmlentities($GLOBALS['customHTMLtwo']) . '</div>'
  2501. ),
  2502. )
  2503. )
  2504. ),
  2505. array(
  2506. 'name' => 'Misc',
  2507. 'enabled' => true,
  2508. 'image' => 'plugins/images/organizr/logo-no-border.png',
  2509. 'category' => 'Custom',
  2510. 'settings' => array(
  2511. 'YouTube' => array(
  2512. array(
  2513. 'type' => 'input',
  2514. 'name' => 'youtubeAPI',
  2515. 'label' => 'Youtube API Key',
  2516. 'value' => $GLOBALS['youtubeAPI'],
  2517. 'help' => 'Please make sure to input this API key as the organizr one gets limited'
  2518. ),
  2519. array(
  2520. 'type' => 'html',
  2521. 'override' => 6,
  2522. 'label' => 'Instructions',
  2523. 'html' => '<a href="https://www.slickremix.com/docs/get-api-key-for-youtube/" target="_blank">Click here for instructions</a>'
  2524. ),
  2525. )
  2526. )
  2527. ),
  2528. array(
  2529. 'name' => 'Pi-hole',
  2530. 'enabled' => true,
  2531. 'image' => 'plugins/images/tabs/pihole.png',
  2532. 'category' => 'Monitor',
  2533. 'settings' => array(
  2534. 'Enable' => array(
  2535. array(
  2536. 'type' => 'switch',
  2537. 'name' => 'homepagePiholeEnabled',
  2538. 'label' => 'Enable',
  2539. 'value' => $GLOBALS['homepagePiholeEnabled']
  2540. ),
  2541. array(
  2542. 'type' => 'select',
  2543. 'name' => 'homepagePiholeAuth',
  2544. 'label' => 'Minimum Authentication',
  2545. 'value' => $GLOBALS['homepagePiholeAuth'],
  2546. 'options' => $groups
  2547. )
  2548. ),
  2549. 'Connection' => array(
  2550. array(
  2551. 'type' => 'input',
  2552. 'name' => 'piholeURL',
  2553. 'label' => 'URL',
  2554. 'value' => $GLOBALS['piholeURL'],
  2555. 'help' => 'Please make sure to use local IP address and port and to include \'/admin/\' at the end of the URL. You can add multiple Pi-holes by comma separating the URLs.',
  2556. 'placeholder' => 'http(s)://hostname:port/admin/'
  2557. ),
  2558. ),
  2559. 'Misc' => array(
  2560. array(
  2561. 'type' => 'switch',
  2562. 'name' => 'piholeHeaderToggle',
  2563. 'label' => 'Toggle Title',
  2564. 'value' => $GLOBALS['piholeHeaderToggle'],
  2565. 'help' => 'Shows/hides the title of this homepage module'
  2566. ),
  2567. array(
  2568. 'type' => 'switch',
  2569. 'name' => 'homepagePiholeCombine',
  2570. 'label' => 'Combine stat cards',
  2571. 'value' => $GLOBALS['homepagePiholeCombine'],
  2572. 'help' => 'This controls whether to combine the stats for multiple piholes into 1 card.',
  2573. ),
  2574. ),
  2575. )
  2576. ),
  2577. array(
  2578. 'name' => 'Tautulli',
  2579. 'enabled' => true,
  2580. 'image' => 'plugins/images/tabs/tautulli.png',
  2581. 'category' => 'Monitor',
  2582. 'settings' => array(
  2583. 'Enable' => array(
  2584. array(
  2585. 'type' => 'switch',
  2586. 'name' => 'homepageTautulliEnabled',
  2587. 'label' => 'Enable',
  2588. 'value' => $GLOBALS['homepageTautulliEnabled']
  2589. ),
  2590. array(
  2591. 'type' => 'select',
  2592. 'name' => 'homepageTautulliAuth',
  2593. 'label' => 'Minimum Authentication',
  2594. 'value' => $GLOBALS['homepageTautulliAuth'],
  2595. 'options' => $groups
  2596. )
  2597. ),
  2598. 'Options' => array(
  2599. array(
  2600. 'type' => 'input',
  2601. 'name' => 'tautulliHeader',
  2602. 'label' => 'Title',
  2603. 'value' => $GLOBALS['tautulliHeader'],
  2604. 'help' => 'Sets the title of this homepage module'
  2605. ),
  2606. array(
  2607. 'type' => 'switch',
  2608. 'name' => 'tautulliHeaderToggle',
  2609. 'label' => 'Toggle Title',
  2610. 'value' => $GLOBALS['tautulliHeaderToggle'],
  2611. 'help' => 'Shows/hides the title of this homepage module'
  2612. )
  2613. ),
  2614. 'Connection' => array(
  2615. array(
  2616. 'type' => 'input',
  2617. 'name' => 'tautulliURL',
  2618. 'label' => 'URL',
  2619. 'value' => $GLOBALS['tautulliURL'],
  2620. 'help' => 'URL for Tautulli API, include the IP, the port and the base URL (e.g. /tautulli/) in the URL',
  2621. 'placeholder' => 'http://<ip>:<port>'
  2622. ),
  2623. array(
  2624. 'type' => 'password-alt',
  2625. 'name' => 'tautulliApikey',
  2626. 'label' => 'API Key',
  2627. 'value' => $GLOBALS['tautulliApikey']
  2628. ),
  2629. array(
  2630. 'type' => 'select',
  2631. 'name' => 'homepageTautulliRefresh',
  2632. 'label' => 'Refresh Seconds',
  2633. 'value' => $GLOBALS['homepageTautulliRefresh'],
  2634. 'options' => optionTime()
  2635. ),
  2636. ),
  2637. 'Library Stats' => array(
  2638. array(
  2639. 'type' => 'switch',
  2640. 'name' => 'tautulliLibraries',
  2641. 'label' => 'Libraries',
  2642. 'value' => $GLOBALS['tautulliLibraries'],
  2643. 'help' => 'Shows/hides the card with library information.',
  2644. ),
  2645. array(
  2646. 'type' => 'select',
  2647. 'name' => 'homepageTautulliLibraryAuth',
  2648. 'label' => 'Minimum Authentication',
  2649. 'value' => $GLOBALS['homepageTautulliLibraryAuth'],
  2650. 'options' => $groups
  2651. ),
  2652. ),
  2653. 'Viewing Stats' => array(
  2654. array(
  2655. 'type' => 'switch',
  2656. 'name' => 'tautulliPopularMovies',
  2657. 'label' => 'Popular Movies',
  2658. 'value' => $GLOBALS['tautulliPopularMovies'],
  2659. 'help' => 'Shows/hides the card with Popular Movies information.',
  2660. ),
  2661. array(
  2662. 'type' => 'switch',
  2663. 'name' => 'tautulliPopularTV',
  2664. 'label' => 'Popular TV',
  2665. 'value' => $GLOBALS['tautulliPopularTV'],
  2666. 'help' => 'Shows/hides the card with Popular TV information.',
  2667. ),
  2668. array(
  2669. 'type' => 'switch',
  2670. 'name' => 'tautulliTopMovies',
  2671. 'label' => 'Top Movies',
  2672. 'value' => $GLOBALS['tautulliTopMovies'],
  2673. 'help' => 'Shows/hides the card with Top Movies information.',
  2674. ),
  2675. array(
  2676. 'type' => 'switch',
  2677. 'name' => 'tautulliTopTV',
  2678. 'label' => 'Top TV',
  2679. 'value' => $GLOBALS['tautulliTopTV'],
  2680. 'help' => 'Shows/hides the card with Top TV information.',
  2681. ),
  2682. array(
  2683. 'type' => 'select',
  2684. 'name' => 'homepageTautulliViewsAuth',
  2685. 'label' => 'Minimum Authentication',
  2686. 'value' => $GLOBALS['homepageTautulliViewsAuth'],
  2687. 'options' => $groups
  2688. ),
  2689. ),
  2690. 'Misc Stats' => array(
  2691. array(
  2692. 'type' => 'switch',
  2693. 'name' => 'tautulliTopUsers',
  2694. 'label' => 'Top Users',
  2695. 'value' => $GLOBALS['tautulliTopUsers'],
  2696. 'help' => 'Shows/hides the card with Top Users information.',
  2697. ),
  2698. array(
  2699. 'type' => 'switch',
  2700. 'name' => 'tautulliTopPlatforms',
  2701. 'label' => 'Top Platforms',
  2702. 'value' => $GLOBALS['tautulliTopPlatforms'],
  2703. 'help' => 'Shows/hides the card with Top Platforms information.',
  2704. ),
  2705. array(
  2706. 'type' => 'select',
  2707. 'name' => 'homepageTautulliMiscAuth',
  2708. 'label' => 'Minimum Authentication',
  2709. 'value' => $GLOBALS['homepageTautulliMiscAuth'],
  2710. 'options' => $groups
  2711. ),
  2712. ),
  2713. )
  2714. ),
  2715. array(
  2716. 'name' => 'Monitorr',
  2717. 'enabled' => true,
  2718. 'image' => 'plugins/images/tabs/monitorr.png',
  2719. 'category' => 'Monitor',
  2720. 'settings' => array(
  2721. 'Enable' => array(
  2722. array(
  2723. 'type' => 'switch',
  2724. 'name' => 'homepageMonitorrEnabled',
  2725. 'label' => 'Enable',
  2726. 'value' => $GLOBALS['homepageMonitorrEnabled']
  2727. ),
  2728. array(
  2729. 'type' => 'select',
  2730. 'name' => 'homepageMonitorrAuth',
  2731. 'label' => 'Minimum Authentication',
  2732. 'value' => $GLOBALS['homepageMonitorrAuth'],
  2733. 'options' => $groups
  2734. )
  2735. ),
  2736. 'Connection' => array(
  2737. array(
  2738. 'type' => 'input',
  2739. 'name' => 'monitorrURL',
  2740. 'label' => 'URL',
  2741. 'value' => $GLOBALS['monitorrURL'],
  2742. 'help' => 'URL for Monitorr. Please use the revers proxy URL i.e. https://domain.com/monitorr/.',
  2743. 'placeholder' => 'http://domain.com/monitorr/'
  2744. ),
  2745. array(
  2746. 'type' => 'select',
  2747. 'name' => 'homepageMonitorrRefresh',
  2748. 'label' => 'Refresh Seconds',
  2749. 'value' => $GLOBALS['homepageMonitorrRefresh'],
  2750. 'options' => optionTime()
  2751. ),
  2752. ),
  2753. 'Options' => array(
  2754. array(
  2755. 'type' => 'input',
  2756. 'name' => 'monitorrHeader',
  2757. 'label' => 'Title',
  2758. 'value' => $GLOBALS['monitorrHeader'],
  2759. 'help' => 'Sets the title of this homepage module',
  2760. ),
  2761. array(
  2762. 'type' => 'switch',
  2763. 'name' => 'monitorrHeaderToggle',
  2764. 'label' => 'Toggle Title',
  2765. 'value' => $GLOBALS['monitorrHeaderToggle'],
  2766. 'help' => 'Shows/hides the title of this homepage module'
  2767. ),
  2768. array(
  2769. 'type' => 'switch',
  2770. 'name' => 'monitorrCompact',
  2771. 'label' => 'Compact view',
  2772. 'value' => $GLOBALS['monitorrCompact'],
  2773. 'help' => 'Toggles the compact view of this homepage module'
  2774. ),
  2775. ),
  2776. )
  2777. ),
  2778. );
  2779. }
  2780. function buildHomepageSettings()
  2781. {
  2782. $homepageOrder = homepageOrder();
  2783. $homepageList = '<h4>Drag Homepage Items to Order Them</h4><div id="homepage-items-sort" class="external-events">';
  2784. $inputList = '<form id="homepage-values" class="row">';
  2785. foreach ($homepageOrder as $key => $val) {
  2786. switch ($key) {
  2787. case 'homepageOrdercustomhtml':
  2788. $class = 'bg-info';
  2789. $image = 'plugins/images/tabs/custom1.png';
  2790. if (!$GLOBALS['homepagCustomHTMLoneEnabled']) {
  2791. $class .= ' faded';
  2792. }
  2793. break;
  2794. case 'homepageOrdercustomhtmlTwo':
  2795. $class = 'bg-info';
  2796. $image = 'plugins/images/tabs/custom2.png';
  2797. if (!$GLOBALS['homepagCustomHTMLtwoEnabled']) {
  2798. $class .= ' faded';
  2799. }
  2800. break;
  2801. case 'homepageOrdertransmission':
  2802. $class = 'bg-transmission';
  2803. $image = 'plugins/images/tabs/transmission.png';
  2804. if (!$GLOBALS['homepageTransmissionEnabled']) {
  2805. $class .= ' faded';
  2806. }
  2807. break;
  2808. case 'homepageOrdernzbget':
  2809. $class = 'bg-nzbget';
  2810. $image = 'plugins/images/tabs/nzbget.png';
  2811. if (!$GLOBALS['homepageNzbgetEnabled']) {
  2812. $class .= ' faded';
  2813. }
  2814. break;
  2815. case 'homepageOrderjdownloader':
  2816. $class = 'bg-sab';
  2817. $image = 'plugins/images/tabs/jdownloader.png';
  2818. if (!$GLOBALS['homepageJdownloaderEnabled']) {
  2819. $class .= ' faded';
  2820. }
  2821. break;
  2822. case 'homepageOrdersabnzbd':
  2823. $class = 'bg-sab';
  2824. $image = 'plugins/images/tabs/sabnzbd.png';
  2825. if (!$GLOBALS['homepageSabnzbdEnabled']) {
  2826. $class .= ' faded';
  2827. }
  2828. break;
  2829. case 'homepageOrderdeluge':
  2830. $class = 'bg-deluge';
  2831. $image = 'plugins/images/tabs/deluge.png';
  2832. if (!$GLOBALS['homepageDelugeEnabled']) {
  2833. $class .= ' faded';
  2834. }
  2835. break;
  2836. case 'homepageOrderqBittorrent':
  2837. $class = 'bg-qbit';
  2838. $image = 'plugins/images/tabs/qBittorrent.png';
  2839. if (!$GLOBALS['homepageqBittorrentEnabled']) {
  2840. $class .= ' faded';
  2841. }
  2842. break;
  2843. case 'homepageOrderrTorrent':
  2844. $class = 'bg-qbit';
  2845. $image = 'plugins/images/tabs/rTorrent.png';
  2846. if (!$GLOBALS['homepagerTorrentEnabled']) {
  2847. $class .= ' faded';
  2848. }
  2849. break;
  2850. case 'homepageOrderplexnowplaying':
  2851. case 'homepageOrderplexrecent':
  2852. case 'homepageOrderplexplaylist':
  2853. $class = 'bg-plex';
  2854. $image = 'plugins/images/tabs/plex.png';
  2855. if (!$GLOBALS['homepagePlexEnabled']) {
  2856. $class .= ' faded';
  2857. }
  2858. break;
  2859. case 'homepageOrderembynowplaying':
  2860. case 'homepageOrderembyrecent':
  2861. $class = 'bg-emby';
  2862. $image = 'plugins/images/tabs/emby.png';
  2863. if (!$GLOBALS['homepageEmbyEnabled']) {
  2864. $class .= ' faded';
  2865. }
  2866. break;
  2867. case 'homepageOrderombi':
  2868. $class = 'bg-inverse';
  2869. $image = 'plugins/images/tabs/ombi.png';
  2870. if (!$GLOBALS['homepageOmbiEnabled']) {
  2871. $class .= ' faded';
  2872. }
  2873. break;
  2874. case 'homepageOrdercalendar':
  2875. $class = 'bg-primary';
  2876. $image = 'plugins/images/tabs/calendar.png';
  2877. if (!$GLOBALS['homepageSonarrEnabled'] && !$GLOBALS['homepageRadarrEnabled'] && !$GLOBALS['homepageSickrageEnabled'] && !$GLOBALS['homepageCouchpotatoEnabled']) {
  2878. $class .= ' faded';
  2879. }
  2880. break;
  2881. case 'homepageOrderdownloader':
  2882. $class = 'bg-inverse';
  2883. $image = 'plugins/images/tabs/downloader.png';
  2884. if (!$GLOBALS['jdownloaderCombine'] && !$GLOBALS['sabnzbdCombine'] && !$GLOBALS['nzbgetCombine'] && !$GLOBALS['rTorrentCombine'] && !$GLOBALS['delugeCombine'] && !$GLOBALS['transmissionCombine'] && !$GLOBALS['qBittorrentCombine']) {
  2885. $class .= ' faded';
  2886. }
  2887. break;
  2888. case 'homepageOrderhealthchecks':
  2889. $class = 'bg-healthchecks';
  2890. $image = 'plugins/images/tabs/healthchecks.png';
  2891. if (!$GLOBALS['homepageHealthChecksEnabled']) {
  2892. $class .= ' faded';
  2893. }
  2894. break;
  2895. case 'homepageOrderunifi':
  2896. $class = 'bg-info';
  2897. $image = 'plugins/images/tabs/ubnt.png';
  2898. if (!$GLOBALS['homepageUnifiEnabled']) {
  2899. $class .= ' faded';
  2900. }
  2901. break;
  2902. case 'homepageOrdertautulli':
  2903. $class = 'bg-info';
  2904. $image = 'plugins/images/tabs/tautulli.png';
  2905. if (!$GLOBALS['homepageTautulliEnabled']) {
  2906. $class .= ' faded';
  2907. }
  2908. break;
  2909. case 'homepageOrderPihole':
  2910. $class = 'bg-info';
  2911. $image = 'plugins/images/tabs/pihole.png';
  2912. if (!$GLOBALS['homepagePiholeEnabled']) {
  2913. $class .= ' faded';
  2914. }
  2915. break;
  2916. case 'homepageOrderMonitorr':
  2917. $class = 'bg-info';
  2918. $image = 'plugins/images/tabs/monitorr.png';
  2919. if (!$GLOBALS['homepageMonitorrEnabled']) {
  2920. $class .= ' faded';
  2921. }
  2922. break;
  2923. default:
  2924. $class = 'blue-bg';
  2925. $image = '';
  2926. break;
  2927. }
  2928. $homepageList .= '
  2929. <div class="col-md-3 col-xs-12 sort-homepage m-t-10 hvr-grow">
  2930. <div class="homepage-drag fc-event ' . $class . ' lazyload" data-src="' . $image . '">
  2931. <span class="ordinal-position text-uppercase badge bg-org homepage-number" data-link="' . $key . '" style="float:left;width: 30px;">' . $val . '</span>
  2932. <span class="homepage-text">&nbsp; ' . strtoupper(substr($key, 13)) . '</span>
  2933. </div>
  2934. </div>
  2935. ';
  2936. $inputList .= '<input type="hidden" name="' . $key . '">';
  2937. }
  2938. $homepageList .= '</div>';
  2939. $inputList .= '</form>';
  2940. return $homepageList . $inputList;
  2941. }
  2942. function ombiTVDefault($type)
  2943. {
  2944. switch ($type) {
  2945. case 'all':
  2946. return ($type == $GLOBALS['ombiTvDefault']) ? true : false;
  2947. case 'first':
  2948. return ($type == $GLOBALS['ombiTvDefault']) ? true : false;
  2949. case 'last':
  2950. return ($type == $GLOBALS['ombiTvDefault']) ? true : false;
  2951. default:
  2952. return false;
  2953. }
  2954. return false;
  2955. }