1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

display program data path and bookmark in the dashboard

This commit is contained in:
Luke Pulverenti 2013-06-01 23:17:10 -04:00
parent 040643b20d
commit 3875ea65c4
2 changed files with 26 additions and 1 deletions

View file

@ -273,6 +273,21 @@
$('#divRunningTasks', page).html(html).trigger('create');
},
bookmarkPageIfSupported: function (url) {
if (window.sidebar && window.sidebar.addPanel) { // Mozilla Firefox Bookmark
window.sidebar.addPanel("Media Browser", url, '');
} else if (window.external && window.external.AddFavorite) { // IE Favorite
window.external.AddFavorite(url, "Media Browser");
} else { // webkit - safari/chrome
return false;
}
return true;
},
renderSystemInfo: function (dashboardInfo) {
Dashboard.updateSystemInfo(dashboardInfo.SystemInfo);
@ -289,6 +304,14 @@
$('#ports', page).html('Running on ports <b>' + port + '</b> and <b>' + dashboardInfo.SystemInfo.WebSocketPortNumber + '</b>');
}
$('#programDataPath', page).html(dashboardInfo.SystemInfo.ProgramDataPath);
var host = ApiClient.serverHostName();
var url = "http://" + host + ":" + port + "/mediabrowser";
$('#bookmarkUrl', page).html(url).attr("href", url);
if (dashboardInfo.RunningTasks.filter(function (task) {
return task.Id == dashboardInfo.ApplicationUpdateTaskId;