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

add web path as config option

This commit is contained in:
dkanada 2019-03-11 21:31:33 -07:00
parent 96e4296256
commit 9d462263b9
5 changed files with 40 additions and 3 deletions

View file

@ -109,7 +109,13 @@
<div class="listItem listItem-border"> <div class="listItem listItem-border">
<div class="listItemBody two-line"> <div class="listItemBody two-line">
<div class="listItemBodyText secondary" style="margin:0;">${LabelTranscodingTemporaryFiles}</div> <div class="listItemBodyText secondary" style="margin:0;">${LabelTranscodingTemporaryFiles}</div>
<div class="listItemBodyText" id="transcodingTemporaryPath"></div> <div class="listItemBodyText" id="transcodePath"></div>
</div>
</div>
<div class="listItem listItem-border">
<div class="listItemBody two-line">
<div class="listItemBodyText secondary" style="margin:0;">${LabelWeb}</div>
<div class="listItemBodyText" id="webPath"></div>
</div> </div>
</div> </div>
</div> </div>

View file

@ -109,6 +109,23 @@ define(["jQuery", "loading", "fnchecked", "emby-checkbox", "emby-textarea", "emb
}) })
}); });
$("#btnSelectWebPath", view).on("click.selectDirectory", function() {
require(["directorybrowser"], function(directoryBrowser) {
var picker = new directoryBrowser;
picker.show({
callback: function(path) {
if (path) {
view.querySelector("#txtWebPath").value = path;
}
picker.close();
},
validateWriteable: true,
header: Globalize.translate("LabelWebPath"),
instruction: Globalize.translate("LabelWebPathHelp")
})
})
});
$(".dashboardGeneralForm", view).off("submit", onSubmit).on("submit", onSubmit); $(".dashboardGeneralForm", view).off("submit", onSubmit).on("submit", onSubmit);
view.addEventListener("viewshow", function() { view.addEventListener("viewshow", function() {
var promiseConfig = ApiClient.getServerConfiguration(); var promiseConfig = ApiClient.getServerConfiguration();

View file

@ -55,6 +55,16 @@
<div class="fieldDescription">${LabelMetadataPathHelp}</div> <div class="fieldDescription">${LabelMetadataPathHelp}</div>
<input type="hidden" id="txtMetadataNetworkPath" /> <input type="hidden" id="txtMetadataNetworkPath" />
</div> </div>
<div class="inputContainer">
<div style="display: flex; align-items: center;">
<div style="flex-grow:1;">
<input is="emby-input" id="txtWebPath" label="${LabelWebPath}" autocomplete="off" />
</div>
<button type="button" is="paper-icon-button-light" id="btnSelectWebPath" title="${ButtonSelectDirectory}" class="emby-input-iconbutton"><i class="md-icon">search</i></button>
</div>
<div class="fieldDescription">${LabelWebPathHelp}</div>
</div>
</div> </div>
<div class="verticalSection autoUpdatesContainer hide"> <div class="verticalSection autoUpdatesContainer hide">

View file

@ -383,7 +383,7 @@ define(["datetime", "events", "itemHelper", "serverNotifications", "dom", "globa
for (var i = 0, length = tasks.length; i < length; i++) { for (var i = 0, length = tasks.length; i < length; i++) {
var task = tasks[i]; var task = tasks[i];
html += "<p>"; html += "<p>";
html += task.Name + "<br/>"; html += task.Name + "<br/>";
if (task.State === "Running") { if (task.State === "Running") {
@ -407,8 +407,9 @@ define(["datetime", "events", "itemHelper", "serverNotifications", "dom", "globa
renderPaths: function (page, systemInfo) { renderPaths: function (page, systemInfo) {
page.querySelector("#cachePath").innerHTML = systemInfo.CachePath; page.querySelector("#cachePath").innerHTML = systemInfo.CachePath;
page.querySelector("#logPath").innerHTML = systemInfo.LogPath; page.querySelector("#logPath").innerHTML = systemInfo.LogPath;
page.querySelector("#transcodingTemporaryPath").innerHTML = systemInfo.TranscodingTempPath; page.querySelector("#transcodePath").innerHTML = systemInfo.TranscodingTempPath;
page.querySelector("#metadataPath").innerHTML = systemInfo.InternalMetadataPath; page.querySelector("#metadataPath").innerHTML = systemInfo.InternalMetadataPath;
page.querySelector("#webPath").innerHTML = systemInfo.WebPath;
}, },
startInterval: function (apiClient) { startInterval: function (apiClient) {
apiClient.sendMessage("SessionsStart", "0,1500"); apiClient.sendMessage("SessionsStart", "0,1500");

View file

@ -1122,6 +1122,8 @@
"LabelMetadataDownloadersHelp": "Enable and rank your preferred metadata downloaders in order of priority. Lower priority downloaders will only be used to fill in missing information.", "LabelMetadataDownloadersHelp": "Enable and rank your preferred metadata downloaders in order of priority. Lower priority downloaders will only be used to fill in missing information.",
"LabelMetadataPath": "Metadata path:", "LabelMetadataPath": "Metadata path:",
"LabelMetadataPathHelp": "Specify a custom location for downloaded artwork and metadata.", "LabelMetadataPathHelp": "Specify a custom location for downloaded artwork and metadata.",
"LabelWebPath": "Web path:",
"LabelWebPathHelp": "The path where the web client source is located.",
"LabelMetadataReaders": "Metadata readers:", "LabelMetadataReaders": "Metadata readers:",
"LabelMetadataReadersHelp": "Rank your preferred local metadata sources in order of priority. The first file found will be read.", "LabelMetadataReadersHelp": "Rank your preferred local metadata sources in order of priority. The first file found will be read.",
"LabelMetadataSavers": "Metadata savers:", "LabelMetadataSavers": "Metadata savers:",
@ -1329,6 +1331,7 @@
"LabelVideoCodec": "Video: {0}", "LabelVideoCodec": "Video: {0}",
"LabelVideoType": "Video Type:", "LabelVideoType": "Video Type:",
"LabelView": "View:", "LabelView": "View:",
"LabelWeb": "Web",
"LabelWebsite": "Website:", "LabelWebsite": "Website:",
"LabelWindowBackgroundColor": "Text background color:", "LabelWindowBackgroundColor": "Text background color:",
"LabelXDlnaCap": "X-Dlna cap:", "LabelXDlnaCap": "X-Dlna cap:",