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

minify resources

This commit is contained in:
Luke Pulverenti 2017-01-27 22:16:59 -05:00
parent 8a6884abef
commit 661eeac16e
201 changed files with 203 additions and 52376 deletions

View file

@ -1,79 +1 @@
define(['datetime', 'listViewStyle'], function (datetime) {
'use strict';
return function (view, params) {
view.querySelector('#chkDebugLog').addEventListener('change', function () {
ApiClient.getServerConfiguration().then(function (config) {
config.EnableDebugLevelLogging = view.querySelector('#chkDebugLog').checked;
ApiClient.updateServerConfiguration(config);
});
});
view.addEventListener('viewbeforeshow', function () {
Dashboard.showLoadingMsg();
var apiClient = ApiClient;
apiClient.getJSON(apiClient.getUrl('System/Logs')).then(function (logs) {
var html = '';
html += '<div class="paperList">';
html += logs.map(function (log) {
var logUrl = apiClient.getUrl('System/Logs/Log', {
name: log.Name
});
logUrl += "&api_key=" + apiClient.accessToken();
var logHtml = '';
logHtml += '<div class="listItem">';
logHtml += '<a item-icon class="clearLink" href="' + logUrl + '" target="_blank">';
logHtml += '<i class="md-icon listItemIcon">schedule</i>';
logHtml += "</a>";
logHtml += '<div class="listItemBody two-line">';
logHtml += '<a class="clearLink" href="' + logUrl + '" target="_blank">';
logHtml += "<h3 class='listItemBodyText'>" + log.Name + "</h3>";
var date = datetime.parseISO8601Date(log.DateModified, true);
var text = datetime.toLocaleDateString(date);
text += ' ' + datetime.getDisplayTime(date);
logHtml += '<div class="listItemBodyText secondary">' + text + '</div>';
logHtml += "</a>";
logHtml += '</div>';
logHtml += '</div>';
return logHtml;
})
.join('');
html += '</div>';
view.querySelector('.serverLogs').innerHTML = html;
Dashboard.hideLoadingMsg();
});
apiClient.getServerConfiguration().then(function (config) {
view.querySelector('#chkDebugLog').checked = config.EnableDebugLevelLogging;
});
});
};
});
define(["datetime","listViewStyle"],function(datetime){"use strict";return function(view,params){view.querySelector("#chkDebugLog").addEventListener("change",function(){ApiClient.getServerConfiguration().then(function(config){config.EnableDebugLevelLogging=view.querySelector("#chkDebugLog").checked,ApiClient.updateServerConfiguration(config)})}),view.addEventListener("viewbeforeshow",function(){Dashboard.showLoadingMsg();var apiClient=ApiClient;apiClient.getJSON(apiClient.getUrl("System/Logs")).then(function(logs){var html="";html+='<div class="paperList">',html+=logs.map(function(log){var logUrl=apiClient.getUrl("System/Logs/Log",{name:log.Name});logUrl+="&api_key="+apiClient.accessToken();var logHtml="";logHtml+='<div class="listItem">',logHtml+='<a item-icon class="clearLink" href="'+logUrl+'" target="_blank">',logHtml+='<i class="md-icon listItemIcon">schedule</i>',logHtml+="</a>",logHtml+='<div class="listItemBody two-line">',logHtml+='<a class="clearLink" href="'+logUrl+'" target="_blank">',logHtml+="<h3 class='listItemBodyText'>"+log.Name+"</h3>";var date=datetime.parseISO8601Date(log.DateModified,!0),text=datetime.toLocaleDateString(date);return text+=" "+datetime.getDisplayTime(date),logHtml+='<div class="listItemBodyText secondary">'+text+"</div>",logHtml+="</a>",logHtml+="</div>",logHtml+="</div>"}).join(""),html+="</div>",view.querySelector(".serverLogs").innerHTML=html,Dashboard.hideLoadingMsg()}),apiClient.getServerConfiguration().then(function(config){view.querySelector("#chkDebugLog").checked=config.EnableDebugLevelLogging})})}});