2019-02-24 20:07:41 +00:00
|
|
|
define([
|
2019-04-03 00:12:02 +01:00
|
|
|
"jQuery",
|
2019-02-24 20:07:41 +00:00
|
|
|
"emby-button",
|
|
|
|
"emby-input",
|
|
|
|
"scripts/livetvcomponents",
|
|
|
|
"paper-icon-button-light",
|
|
|
|
"emby-itemscontainer",
|
|
|
|
"emby-collapse",
|
|
|
|
"emby-select",
|
|
|
|
"livetvcss",
|
|
|
|
"emby-checkbox",
|
|
|
|
"emby-slider",
|
|
|
|
"listViewStyle",
|
2019-04-03 00:12:02 +01:00
|
|
|
"dashboardcss",
|
|
|
|
"detailtablecss"], function () {
|
2019-02-24 20:07:41 +00:00
|
|
|
|
2019-03-18 23:48:34 +00:00
|
|
|
function defineRoute(newRoute) {
|
2019-02-24 20:07:41 +00:00
|
|
|
var path = newRoute.path;
|
2019-12-15 20:47:47 +09:00
|
|
|
console.log("defining route: " + path);
|
2019-03-18 23:48:34 +00:00
|
|
|
newRoute.dictionary = "core";
|
2019-02-24 20:07:41 +00:00
|
|
|
Emby.Page.addRoute(path, newRoute);
|
|
|
|
}
|
|
|
|
|
2019-12-15 20:47:47 +09:00
|
|
|
console.log("defining core routes");
|
2019-03-18 23:41:40 +00:00
|
|
|
|
2019-12-15 22:42:33 +09:00
|
|
|
defineRoute({
|
2020-01-08 01:36:34 +09:00
|
|
|
path: "/addplugin.html",
|
2019-12-15 22:42:33 +09:00
|
|
|
autoFocus: false,
|
2020-01-08 01:36:34 +09:00
|
|
|
roles: "admin",
|
|
|
|
controller: "dashboard/plugins/add"
|
2019-12-15 22:42:33 +09:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/mypreferencesmenu.html",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade",
|
|
|
|
controller: "user/menu"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/myprofile.html",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade",
|
|
|
|
controller: "user/profile"
|
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/addserver.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
|
|
|
startup: true,
|
|
|
|
controller: "auth/addserver"
|
|
|
|
});
|
2019-12-15 22:42:33 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/mypreferencesdisplay.html",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade",
|
|
|
|
controller: "user/display"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/mypreferenceshome.html",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade",
|
|
|
|
controller: "user/home"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/mypreferencesplayback.html",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade",
|
|
|
|
controller: "user/playback"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/mypreferencessubtitles.html",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade",
|
|
|
|
controller: "user/subtitles"
|
|
|
|
});
|
|
|
|
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/dashboard.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/dashboard"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/dashboardgeneral.html",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/general",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin"
|
|
|
|
});
|
|
|
|
defineRoute({
|
2019-06-10 15:25:07 -07:00
|
|
|
path: "/networking.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/networking"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
2019-03-29 15:07:26 -07:00
|
|
|
path: "/devices.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
|
|
|
controller: "devices"
|
|
|
|
});
|
|
|
|
defineRoute({
|
2019-03-29 15:07:26 -07:00
|
|
|
path: "/device.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
|
|
|
controller: "device"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/dlnaprofile.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "dlnaprofile"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/dlnaprofiles.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "dlnaprofiles"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/dlnasettings.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "dlnasettings"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/edititemmetadata.html",
|
|
|
|
controller: "edititemmetadata",
|
|
|
|
autoFocus: false
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/encodingsettings.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "encodingsettings"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/forgotpassword.html",
|
|
|
|
anonymous: true,
|
|
|
|
startup: true,
|
|
|
|
controller: "auth/forgotpassword"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/forgotpasswordpin.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
|
|
|
startup: true,
|
|
|
|
controller: "auth/forgotpasswordpin"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/home.html",
|
|
|
|
autoFocus: false,
|
|
|
|
controller: "home",
|
|
|
|
transition: "fade",
|
|
|
|
type: "home"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/list.html",
|
|
|
|
autoFocus: false,
|
|
|
|
controller: "list",
|
|
|
|
transition: "fade"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/index.html",
|
|
|
|
autoFocus: false,
|
|
|
|
isDefaultRoute: true
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/itemdetails.html",
|
|
|
|
controller: "itemdetailpage",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade"
|
|
|
|
});
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/library.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "medialibrarypage"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/librarydisplay.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
|
|
|
controller: "librarydisplay"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/librarysettings.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
|
|
|
controller: "librarysettings"
|
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/livetv.html",
|
|
|
|
controller: "livetv/livetvsuggested",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade"
|
|
|
|
});
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/livetvguideprovider.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "livetvguideprovider"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/livetvsettings.html",
|
2019-04-03 00:12:02 +01:00
|
|
|
autoFocus: false,
|
|
|
|
controller: "livetvsettings"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/livetvstatus.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "livetvstatus"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/livetvtuner.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
|
|
|
controller: "livetvtuner"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/log.html",
|
|
|
|
roles: "admin",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/logs"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/login.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
|
|
|
startup: true,
|
2020-01-25 01:18:07 +03:00
|
|
|
controller: "auth/login",
|
|
|
|
type: "login"
|
2020-01-08 01:36:34 +09:00
|
|
|
});
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/metadataimages.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "metadataimagespage"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/metadatanfo.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "metadatanfo"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/movies.html",
|
|
|
|
autoFocus: false,
|
|
|
|
controller: "movies/moviesrecommended",
|
|
|
|
transition: "fade"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/music.html",
|
|
|
|
controller: "music/musicrecommended",
|
|
|
|
autoFocus: false,
|
|
|
|
transition: "fade"
|
|
|
|
});
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/notificationsetting.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/notifications/notification"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/notificationsettings.html",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/notifications/notifications",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin"
|
|
|
|
});
|
|
|
|
defineRoute({
|
2020-01-08 01:36:34 +09:00
|
|
|
path: "/nowplaying.html",
|
|
|
|
controller: "playback/nowplaying",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
2020-01-08 01:36:34 +09:00
|
|
|
transition: "fade",
|
|
|
|
fullscreen: true,
|
|
|
|
supportsThemeMedia: true,
|
|
|
|
enableMediaControl: false
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
2020-01-08 01:36:34 +09:00
|
|
|
path: "/playbackconfiguration.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
2020-01-08 01:36:34 +09:00
|
|
|
controller: "playbackconfiguration"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
2019-04-02 16:11:55 -07:00
|
|
|
path: "/availableplugins.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/plugins/available"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
2019-04-02 16:11:55 -07:00
|
|
|
path: "/installedplugins.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
2019-04-02 16:11:55 -07:00
|
|
|
roles: "admin",
|
2019-12-15 20:47:47 +09:00
|
|
|
controller: "dashboard/plugins/installed"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/scheduledtask.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
2019-12-15 22:42:33 +09:00
|
|
|
controller: "dashboard/scheduledtasks/scheduledtask"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/scheduledtasks.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
2019-12-15 22:42:33 +09:00
|
|
|
controller: "dashboard/scheduledtasks/scheduledtasks"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/search.html",
|
|
|
|
controller: "searchpage"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/selectserver.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
|
|
|
startup: true,
|
|
|
|
controller: "auth/selectserver"
|
|
|
|
});
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/serveractivity.html",
|
|
|
|
autoFocus: false,
|
|
|
|
roles: "admin",
|
|
|
|
controller: "serveractivity"
|
|
|
|
});
|
|
|
|
defineRoute({
|
2019-06-10 15:25:07 -07:00
|
|
|
path: "/apikeys.html",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
2019-06-10 15:25:07 -07:00
|
|
|
controller: "apikeys"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/streamingsettings.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "streamingsettings"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2020-01-08 01:36:34 +09:00
|
|
|
defineRoute({
|
|
|
|
path: "/tv.html",
|
|
|
|
autoFocus: false,
|
|
|
|
controller: "shows/tvrecommended",
|
|
|
|
transition: "fade"
|
|
|
|
});
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/useredit.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "useredit"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/userlibraryaccess.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "userlibraryaccess"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/usernew.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "usernew"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/userparentalcontrol.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "userparentalcontrol"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/userpassword.html",
|
|
|
|
autoFocus: false,
|
|
|
|
controller: "userpasswordpage"
|
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/userprofiles.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
roles: "admin",
|
|
|
|
controller: "userprofilespage"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2019-12-15 20:47:47 +09:00
|
|
|
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
|
|
|
path: "/wizardremoteaccess.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
2020-01-12 02:23:16 +09:00
|
|
|
controller: "wizard/remoteaccess"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/wizardfinish.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
2019-12-15 23:53:13 +09:00
|
|
|
controller: "wizard/finish"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/wizardlibrary.html",
|
|
|
|
autoFocus: false,
|
2019-04-03 00:12:02 +01:00
|
|
|
anonymous: true,
|
|
|
|
controller: "medialibrarypage"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/wizardsettings.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
2019-12-15 23:53:13 +09:00
|
|
|
controller: "wizard/settings"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/wizardstart.html",
|
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true,
|
2019-12-15 23:53:13 +09:00
|
|
|
controller: "wizard/start"
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
|
|
|
defineRoute({
|
|
|
|
path: "/wizarduser.html",
|
2019-12-15 23:53:13 +09:00
|
|
|
controller: "wizard/user",
|
2019-03-18 23:41:40 +00:00
|
|
|
autoFocus: false,
|
|
|
|
anonymous: true
|
|
|
|
});
|
2019-12-15 20:47:47 +09:00
|
|
|
|
2019-03-18 23:41:40 +00:00
|
|
|
defineRoute({
|
2020-01-08 01:36:34 +09:00
|
|
|
path: "/videoosd.html",
|
|
|
|
transition: "fade",
|
|
|
|
controller: "playback/videoosd",
|
|
|
|
autoFocus: false,
|
|
|
|
type: "video-osd",
|
|
|
|
supportsThemeMedia: true,
|
|
|
|
fullscreen: true,
|
|
|
|
enableMediaControl: false
|
2019-03-18 23:41:40 +00:00
|
|
|
});
|
2019-12-15 20:47:47 +09:00
|
|
|
defineRoute({
|
2020-01-08 01:36:34 +09:00
|
|
|
path: "/configurationpage",
|
2019-12-15 20:47:47 +09:00
|
|
|
autoFocus: false,
|
2020-01-08 01:36:34 +09:00
|
|
|
enableCache: false,
|
|
|
|
enableContentQueryString: true,
|
|
|
|
roles: "admin"
|
|
|
|
});
|
|
|
|
|
|
|
|
defineRoute({
|
|
|
|
path: "/",
|
|
|
|
isDefaultRoute: true,
|
|
|
|
autoFocus: false
|
2019-12-15 20:47:47 +09:00
|
|
|
});
|
2019-04-25 11:16:01 -07:00
|
|
|
});
|