mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
commit
33ee3d8ee3
29 changed files with 269 additions and 185 deletions
|
@ -1,11 +1,11 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
|
<link rel="stylesheet" type="text/css" href="css/metadataeditor.css">
|
||||||
<title>${TitleAutoOrganize}</title>
|
<title>${TitleAutoOrganize}</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="libraryFileOrganizerLogPage" data-role="page" class="page type-interior organizePage" data-helpurl="https://github.com/MediaBrowser/Wiki/wiki/Auto-Organize" data-require="jqmtable,jqmpopup,scripts/autoorganizelog,scripts/taskbutton,detailtablecss,paper-input,paper-checkbox">
|
<div id="libraryFileOrganizerLogPage" data-role="page" class="page type-interior organizePage" data-helpurl="https://github.com/MediaBrowser/Wiki/wiki/Auto-Organize" data-require="jqmtable,scripts/autoorganizelog,scripts/taskbutton,detailtablecss">
|
||||||
|
|
||||||
<div data-role="content">
|
<div data-role="content">
|
||||||
<div class="content-primary">
|
<div class="content-primary">
|
||||||
|
|
||||||
|
@ -52,48 +52,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div data-role="popup" class="popup episodeCorrectionPopup">
|
|
||||||
|
|
||||||
<div class="ui-bar-a" style="text-align: center; padding: 0 1em;">
|
|
||||||
<h3>${HeaderEpisodeOrganization}</h3>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div data-role="content">
|
|
||||||
<form class="episodeCorrectionForm" style="padding:0 .5em;">
|
|
||||||
|
|
||||||
<p><span class="inputFile"></span></p>
|
|
||||||
|
|
||||||
<div style="margin: 1em 0 1em; min-width: 250px;">
|
|
||||||
<label for="selectSeries" class="selectLabel">${LabelSeries}</label>
|
|
||||||
<select id="selectSeries" data-mini="true" required="required"></select>
|
|
||||||
</div>
|
|
||||||
<div style="margin: 1em 0;">
|
|
||||||
<paper-input id="txtSeason" type="number" pattern="[0-9]*" required min="0" label="${LabelSeasonNumber}"></paper-input>
|
|
||||||
</div>
|
|
||||||
<div style="margin: 1em 0;">
|
|
||||||
<paper-input id="txtEpisode" type="number" pattern="[0-9]*" required min="0" label="${LabelEpisodeNumber}"></paper-input>
|
|
||||||
</div>
|
|
||||||
<div style="margin: 1em 0;">
|
|
||||||
<paper-input id="txtEndingEpisode" type="number" pattern="[0-9]*" min="0" label="${LabelEndingEpisodeNumber}"></paper-input>
|
|
||||||
<div class="fieldDescription">${LabelEndingEpisodeNumberHelp}</div>
|
|
||||||
</div>
|
|
||||||
<br/>
|
|
||||||
<div>
|
|
||||||
<paper-checkbox type="checkbox" id="chkRememberCorrection">${OptionRememberOrganizeCorrection}</paper-checkbox>
|
|
||||||
</div>
|
|
||||||
<br />
|
|
||||||
<button type="submit" data-theme="b" data-icon="check" data-mini="true">
|
|
||||||
${ButtonOk}
|
|
||||||
</button>
|
|
||||||
<button type="button" data-icon="delete" onclick="$(this).parents('.popup').popup('close');" data-mini="true">
|
|
||||||
${ButtonCancel}
|
|
||||||
</button>
|
|
||||||
<input id="hfResultId" type="hidden" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<title>${TitleAutoOrganize}</title>
|
<title>${TitleAutoOrganize}</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="libraryFileOrganizerSmartMatchPage" data-role="page" class="page type-interior organizePage" data-helpurl="https://github.com/MediaBrowser/Wiki/wiki/Auto-Organize" data-require="scripts/autoorganizesmart,jqmlistview">
|
<div id="libraryFileOrganizerSmartMatchPage" data-role="page" class="page type-interior organizePage" data-helpurl="https://github.com/MediaBrowser/Wiki/wiki/Auto-Organize" data-require="scripts/autoorganizesmart,paper-icon-item,paper-fab,paper-item-body">
|
||||||
|
|
||||||
<div data-role="content">
|
<div data-role="content">
|
||||||
<div class="content-primary">
|
<div class="content-primary">
|
||||||
|
|
|
@ -16,12 +16,12 @@
|
||||||
},
|
},
|
||||||
"devDependencies": {},
|
"devDependencies": {},
|
||||||
"ignore": [],
|
"ignore": [],
|
||||||
"version": "1.0.35",
|
"version": "1.0.37",
|
||||||
"_release": "1.0.35",
|
"_release": "1.0.37",
|
||||||
"_resolution": {
|
"_resolution": {
|
||||||
"type": "version",
|
"type": "version",
|
||||||
"tag": "1.0.35",
|
"tag": "1.0.37",
|
||||||
"commit": "d84b62c2a98faed179e07ef805e54cd7e6d2e036"
|
"commit": "b383fff379b92417525a3295ebbe3b7db9e0b1a4"
|
||||||
},
|
},
|
||||||
"_source": "git://github.com/MediaBrowser/Emby.ApiClient.Javascript.git",
|
"_source": "git://github.com/MediaBrowser/Emby.ApiClient.Javascript.git",
|
||||||
"_target": "~1.0.3",
|
"_target": "~1.0.3",
|
||||||
|
|
|
@ -3428,12 +3428,12 @@
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
self.deleteSmartMatchEntry = function (name, options) {
|
self.deleteSmartMatchEntries = function (entries) {
|
||||||
|
|
||||||
var url = self.getUrl("Library/FileOrganizations/SmartMatches", options || {});
|
var url = self.getUrl("Library/FileOrganizations/SmartMatches/Delete");
|
||||||
|
|
||||||
var postData = {
|
var postData = {
|
||||||
Name: name
|
Entries: entries
|
||||||
};
|
};
|
||||||
|
|
||||||
return self.ajax({
|
return self.ajax({
|
||||||
|
|
|
@ -200,7 +200,7 @@
|
||||||
var title = items.length ? Globalize.translate('HeaderAddToCollection') : Globalize.translate('HeaderNewCollection');
|
var title = items.length ? Globalize.translate('HeaderAddToCollection') : Globalize.translate('HeaderNewCollection');
|
||||||
|
|
||||||
html += '<div class="dialogHeader">';
|
html += '<div class="dialogHeader">';
|
||||||
html += '<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>';
|
html += '<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>';
|
||||||
html += '<div class="dialogHeaderTitle">';
|
html += '<div class="dialogHeaderTitle">';
|
||||||
html += title;
|
html += title;
|
||||||
html += '</div>';
|
html += '</div>';
|
||||||
|
|
130
dashboard-ui/components/fileorganizer/fileorganizer.js
Normal file
130
dashboard-ui/components/fileorganizer/fileorganizer.js
Normal file
|
@ -0,0 +1,130 @@
|
||||||
|
define(['paperdialoghelper', 'paper-checkbox', 'paper-input', 'paper-button'], function (paperDialogHelper) {
|
||||||
|
|
||||||
|
function onApiFailure(e) {
|
||||||
|
|
||||||
|
Dashboard.hideLoadingMsg();
|
||||||
|
|
||||||
|
Dashboard.alert({
|
||||||
|
title: Globalize.translate('AutoOrganizeError'),
|
||||||
|
message: Globalize.translate('ErrorOrganizingFileWithErrorCode', e.getResponseHeader("X-Application-Error-Code"))
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function initEpisodeForm(context, item) {
|
||||||
|
|
||||||
|
$('.inputFile', context).html(item.OriginalFileName);
|
||||||
|
|
||||||
|
$('#txtSeason', context).val(item.ExtractedSeasonNumber);
|
||||||
|
$('#txtEpisode', context).val(item.ExtractedEpisodeNumber);
|
||||||
|
$('#txtEndingEpisode', context).val(item.ExtractedEndingEpisodeNumber);
|
||||||
|
|
||||||
|
$('#chkRememberCorrection', context).val(false);
|
||||||
|
|
||||||
|
$('#hfResultId', context).val(item.Id);
|
||||||
|
|
||||||
|
ApiClient.getItems(null, {
|
||||||
|
recursive: true,
|
||||||
|
includeItemTypes: 'Series',
|
||||||
|
sortBy: 'SortName'
|
||||||
|
|
||||||
|
}).then(function (result) {
|
||||||
|
|
||||||
|
var seriesHtml = result.Items.map(function (s) {
|
||||||
|
|
||||||
|
return '<option value="' + s.Id + '">' + s.Name + '</option>';
|
||||||
|
|
||||||
|
}).join('');
|
||||||
|
|
||||||
|
seriesHtml = '<option value=""></option>' + seriesHtml;
|
||||||
|
|
||||||
|
$('#selectSeries', context).html(seriesHtml);
|
||||||
|
|
||||||
|
}, onApiFailure);
|
||||||
|
}
|
||||||
|
|
||||||
|
function submitEpisodeForm(dlg) {
|
||||||
|
|
||||||
|
Dashboard.showLoadingMsg();
|
||||||
|
|
||||||
|
var resultId = $('#hfResultId', dlg).val();
|
||||||
|
|
||||||
|
var options = {
|
||||||
|
|
||||||
|
SeriesId: $('#selectSeries', dlg).val(),
|
||||||
|
SeasonNumber: $('#txtSeason', dlg).val(),
|
||||||
|
EpisodeNumber: $('#txtEpisode', dlg).val(),
|
||||||
|
EndingEpisodeNumber: $('#txtEndingEpisode', dlg).val(),
|
||||||
|
RememberCorrection: $('#chkRememberCorrection', dlg).checked()
|
||||||
|
};
|
||||||
|
|
||||||
|
ApiClient.performEpisodeOrganization(resultId, options).then(function () {
|
||||||
|
|
||||||
|
Dashboard.hideLoadingMsg();
|
||||||
|
|
||||||
|
dlg.submitted = true;
|
||||||
|
paperDialogHelper.close(dlg);
|
||||||
|
|
||||||
|
}, onApiFailure);
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
show: function (item) {
|
||||||
|
return new Promise(function (resolve, reject) {
|
||||||
|
|
||||||
|
var xhr = new XMLHttpRequest();
|
||||||
|
xhr.open('GET', 'components/fileorganizer/fileorganizer.template.html', true);
|
||||||
|
|
||||||
|
xhr.onload = function (e) {
|
||||||
|
|
||||||
|
var template = this.response;
|
||||||
|
var dlg = paperDialogHelper.createDialog({
|
||||||
|
removeOnClose: true,
|
||||||
|
size: 'small'
|
||||||
|
});
|
||||||
|
|
||||||
|
dlg.classList.add('ui-body-a');
|
||||||
|
dlg.classList.add('background-theme-a');
|
||||||
|
|
||||||
|
dlg.classList.add('formDialog');
|
||||||
|
|
||||||
|
var html = '';
|
||||||
|
|
||||||
|
html += Globalize.translateDocument(template);
|
||||||
|
|
||||||
|
dlg.innerHTML = html;
|
||||||
|
document.body.appendChild(dlg);
|
||||||
|
|
||||||
|
dlg.querySelector('.dialogHeaderTitle').innerHTML = Globalize.translate('FileOrganizeManually');
|
||||||
|
|
||||||
|
paperDialogHelper.open(dlg);
|
||||||
|
|
||||||
|
dlg.addEventListener('iron-overlay-closed', function () {
|
||||||
|
|
||||||
|
if (dlg.submitted) {
|
||||||
|
resolve();
|
||||||
|
} else {
|
||||||
|
reject();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
dlg.querySelector('.btnCancel').addEventListener('click', function (e) {
|
||||||
|
|
||||||
|
paperDialogHelper.close(dlg);
|
||||||
|
});
|
||||||
|
|
||||||
|
dlg.querySelector('form').addEventListener('submit', function (e) {
|
||||||
|
|
||||||
|
submitEpisodeForm(dlg);
|
||||||
|
|
||||||
|
e.preventDefault();
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
|
initEpisodeForm(dlg, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
xhr.send();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
};
|
||||||
|
});
|
|
@ -0,0 +1,34 @@
|
||||||
|
<div class="dialogHeader">
|
||||||
|
<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>
|
||||||
|
<div class="dialogHeaderTitle">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<form class="episodeCorrectionForm" style="margin:auto;">
|
||||||
|
|
||||||
|
<p><span class="inputFile"></span></p>
|
||||||
|
|
||||||
|
<div style="margin: 1em 0 1em; min-width: 250px;">
|
||||||
|
<label for="selectSeries" class="selectLabel">${LabelSeries}</label>
|
||||||
|
<select id="selectSeries" data-mini="true" required="required"></select>
|
||||||
|
</div>
|
||||||
|
<div style="margin: 1em 0;">
|
||||||
|
<paper-input id="txtSeason" type="number" pattern="[0-9]*" required min="0" label="${LabelSeasonNumber}"></paper-input>
|
||||||
|
</div>
|
||||||
|
<div style="margin: 1em 0;">
|
||||||
|
<paper-input id="txtEpisode" type="number" pattern="[0-9]*" required min="0" label="${LabelEpisodeNumber}"></paper-input>
|
||||||
|
</div>
|
||||||
|
<div style="margin: 1em 0;">
|
||||||
|
<paper-input id="txtEndingEpisode" type="number" pattern="[0-9]*" min="0" label="${LabelEndingEpisodeNumber}"></paper-input>
|
||||||
|
<div class="fieldDescription">${LabelEndingEpisodeNumberHelp}</div>
|
||||||
|
</div>
|
||||||
|
<br />
|
||||||
|
<div>
|
||||||
|
<paper-checkbox type="checkbox" id="chkRememberCorrection">${OptionRememberOrganizeCorrection}</paper-checkbox>
|
||||||
|
</div>
|
||||||
|
<br />
|
||||||
|
<button type="submit" data-role="none" class="clearButton">
|
||||||
|
<paper-button raised class="submit block"><iron-icon icon="check"></iron-icon><span>${ButtonOk}</span></paper-button>
|
||||||
|
</button>
|
||||||
|
<input id="hfResultId" type="hidden" />
|
||||||
|
</form>
|
|
@ -109,8 +109,8 @@
|
||||||
html += Globalize.translateDocument(template);
|
html += Globalize.translateDocument(template);
|
||||||
|
|
||||||
dlg.innerHTML = html;
|
dlg.innerHTML = html;
|
||||||
// needed for the collapsible
|
|
||||||
document.body.appendChild(dlg);
|
document.body.appendChild(dlg);
|
||||||
|
// needed for the collapsible
|
||||||
$(dlg.querySelector('form')).trigger('create');
|
$(dlg.querySelector('form')).trigger('create');
|
||||||
|
|
||||||
paperDialogHelper.open(dlg);
|
paperDialogHelper.open(dlg);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="dialogHeader">
|
<div class="dialogHeader">
|
||||||
<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>
|
<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>
|
||||||
<div class="dialogHeaderTitle">
|
<div class="dialogHeaderTitle">
|
||||||
${HeaderInviteUser}
|
${HeaderInviteUser}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -333,7 +333,7 @@
|
||||||
currentDeferred.resolveWith(null, [hasChanges]);
|
currentDeferred.resolveWith(null, [hasChanges]);
|
||||||
}
|
}
|
||||||
|
|
||||||
window.ItemIdentifier = {
|
return {
|
||||||
show: function (itemId) {
|
show: function (itemId) {
|
||||||
|
|
||||||
var deferred = DeferredBuilder.Deferred();
|
var deferred = DeferredBuilder.Deferred();
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="dialogHeader">
|
<div class="dialogHeader">
|
||||||
<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>
|
<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>
|
||||||
<div class="dialogHeaderTitle">
|
<div class="dialogHeaderTitle">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="dialogHeader">
|
<div class="dialogHeader">
|
||||||
<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>
|
<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>
|
||||||
<div class="dialogHeaderTitle">
|
<div class="dialogHeaderTitle">
|
||||||
${ButtonEdit}
|
${ButtonEdit}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="dialogHeader">
|
<div class="dialogHeader">
|
||||||
<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>
|
<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>
|
||||||
<div class="dialogHeaderTitle">
|
<div class="dialogHeaderTitle">
|
||||||
${ButtonEdit}
|
${ButtonEdit}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -206,7 +206,7 @@
|
||||||
var title = Globalize.translate('HeaderAddToPlaylist');
|
var title = Globalize.translate('HeaderAddToPlaylist');
|
||||||
|
|
||||||
html += '<div class="dialogHeader">';
|
html += '<div class="dialogHeader">';
|
||||||
html += '<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>';
|
html += '<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>';
|
||||||
html += '<div class="dialogHeaderTitle">';
|
html += '<div class="dialogHeaderTitle">';
|
||||||
html += title;
|
html += title;
|
||||||
html += '</div>';
|
html += '</div>';
|
||||||
|
|
|
@ -227,6 +227,12 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (AppInfo.enableSupporterMembership) {
|
||||||
|
context.querySelector('.btnSupporterForConverting a').href = 'https://emby.media/premiere';
|
||||||
|
} else {
|
||||||
|
context.querySelector('.btnSupporterForConverting a').href = '#';
|
||||||
|
}
|
||||||
|
|
||||||
ApiClient.getNamedConfiguration("livetv").then(function (config) {
|
ApiClient.getNamedConfiguration("livetv").then(function (config) {
|
||||||
|
|
||||||
$('#chkConvertRecordings', context).checked(config.EnableRecordingEncoding);
|
$('#chkConvertRecordings', context).checked(config.EnableRecordingEncoding);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<div class="dialogHeader">
|
<div class="dialogHeader">
|
||||||
<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>
|
<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>
|
||||||
<div class="dialogHeaderTitle">
|
<div class="dialogHeaderTitle">
|
||||||
${HeaderNewRecording}
|
${HeaderNewRecording}
|
||||||
</div>
|
</div>
|
||||||
|
@ -49,7 +49,7 @@
|
||||||
<br />
|
<br />
|
||||||
<paper-checkbox id="chkConvertRecordings">${OptionConvertRecordingsToStreamingFormat}</paper-checkbox>
|
<paper-checkbox id="chkConvertRecordings">${OptionConvertRecordingsToStreamingFormat}</paper-checkbox>
|
||||||
<div class="fieldDescription paperCheckboxFieldDescription">${OptionConvertRecordingsToStreamingFormatHelp}</div>
|
<div class="fieldDescription paperCheckboxFieldDescription">${OptionConvertRecordingsToStreamingFormatHelp}</div>
|
||||||
<div class="fieldDescription paperCheckboxFieldDescription hide btnSupporter"><a href="http://emby.media/premiere" target="_blank">${ButtonLearnMore}</a></div>
|
<div class="fieldDescription paperCheckboxFieldDescription btnSupporterForConverting"><a href="https://emby.media/premiere" target="_blank" class="accent">${FeatureRequiresEmbyPremiere}</a></div>
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
<div class="advancedToggle hide">
|
<div class="advancedToggle hide">
|
||||||
|
@ -69,7 +69,10 @@
|
||||||
<a class="clearLink btnSupporter hide" href="http://emby.media/premiere" target="_blank"><paper-button raised class="accent block"><iron-icon icon="check"></iron-icon><span>${HeaderBecomeProjectSupporter}</span></paper-button></a>
|
<a class="clearLink btnSupporter hide" href="http://emby.media/premiere" target="_blank"><paper-button raised class="accent block"><iron-icon icon="check"></iron-icon><span>${HeaderBecomeProjectSupporter}</span></paper-button></a>
|
||||||
</div>
|
</div>
|
||||||
<button type="submit" data-role="none" class="clearButton btnSubmitContainer">
|
<button type="submit" data-role="none" class="clearButton btnSubmitContainer">
|
||||||
<paper-button raised class="submit block" style="background:#cc3333;"><iron-icon icon="videocam"></iron-icon><span>${ButtonRecord}</span></paper-button>
|
<paper-button raised class="submit block" style="background:#cc3333;" autoFocus><iron-icon icon="videocam"></iron-icon><span>${ButtonRecord}</span></paper-button>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
</form>
|
</form>
|
|
@ -641,6 +641,10 @@ h1 a:hover {
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.ui-body-b a.accent {
|
||||||
|
color: #52B54B !important;
|
||||||
|
}
|
||||||
|
|
||||||
.ui-listview li h3 {
|
.ui-listview li h3 {
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,7 +55,7 @@
|
||||||
<div>
|
<div>
|
||||||
<paper-checkbox id="chkConvertRecordings">${OptionConvertRecordingsToStreamingFormat}</paper-checkbox>
|
<paper-checkbox id="chkConvertRecordings">${OptionConvertRecordingsToStreamingFormat}</paper-checkbox>
|
||||||
<div class="fieldDescription paperCheckboxFieldDescription">${OptionConvertRecordingsToStreamingFormatHelp}</div>
|
<div class="fieldDescription paperCheckboxFieldDescription">${OptionConvertRecordingsToStreamingFormatHelp}</div>
|
||||||
<div class="fieldDescription paperCheckboxFieldDescription"><a class="lnkSupporterLearnMore" href="http://emby.media/premiere" target="_blank" style="display:none;">${ButtonLearnMore}</a></div>
|
<div class="fieldDescription paperCheckboxFieldDescription btnSupporterForConverting"><a href="https://emby.media/premiere" target="_blank" class="accent">${FeatureRequiresEmbyPremiere}</a></div>
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
<br />
|
<br />
|
||||||
|
|
|
@ -52,43 +52,17 @@
|
||||||
|
|
||||||
function organizeEpsiodeWithCorrections(page, item) {
|
function organizeEpsiodeWithCorrections(page, item) {
|
||||||
|
|
||||||
Dashboard.showLoadingMsg();
|
showEpisodeCorrectionPopup(page, item);
|
||||||
|
|
||||||
ApiClient.getItems(null, {
|
|
||||||
recursive: true,
|
|
||||||
includeItemTypes: 'Series',
|
|
||||||
sortBy: 'SortName'
|
|
||||||
|
|
||||||
}).then(function (result) {
|
|
||||||
Dashboard.hideLoadingMsg();
|
|
||||||
showEpisodeCorrectionPopup(page, item, result.Items);
|
|
||||||
}, onApiFailure);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function showEpisodeCorrectionPopup(page, item, allSeries) {
|
function showEpisodeCorrectionPopup(page, item) {
|
||||||
|
|
||||||
var popup = $('.episodeCorrectionPopup', page).popup("open");
|
require(['components/fileorganizer/fileorganizer'], function (fileorganizer) {
|
||||||
|
|
||||||
$('.inputFile', popup).html(item.OriginalFileName);
|
fileorganizer.show(item).then(function () {
|
||||||
|
reloadItems(page);
|
||||||
$('#txtSeason', popup).val(item.ExtractedSeasonNumber);
|
});
|
||||||
$('#txtEpisode', popup).val(item.ExtractedEpisodeNumber);
|
});
|
||||||
$('#txtEndingEpisode', popup).val(item.ExtractedEndingEpisodeNumber);
|
|
||||||
|
|
||||||
$('#chkRememberCorrection', popup).val(false);
|
|
||||||
|
|
||||||
$('#hfResultId', popup).val(item.Id);
|
|
||||||
|
|
||||||
var seriesHtml = allSeries.map(function (s) {
|
|
||||||
|
|
||||||
return '<option value="' + s.Id + '">' + s.Name + '</option>';
|
|
||||||
|
|
||||||
}).join('');
|
|
||||||
|
|
||||||
seriesHtml = '<option value=""></option>' + seriesHtml;
|
|
||||||
|
|
||||||
$('#selectSeries', popup).html(seriesHtml);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function organizeFile(page, id) {
|
function organizeFile(page, id) {
|
||||||
|
@ -131,38 +105,9 @@
|
||||||
|
|
||||||
}, onApiFailure);
|
}, onApiFailure);
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function submitEpisodeForm(form) {
|
|
||||||
|
|
||||||
Dashboard.showLoadingMsg();
|
|
||||||
|
|
||||||
var page = $(form).parents('.page');
|
|
||||||
|
|
||||||
var resultId = $('#hfResultId', form).val();
|
|
||||||
|
|
||||||
var options = {
|
|
||||||
|
|
||||||
SeriesId: $('#selectSeries', form).val(),
|
|
||||||
SeasonNumber: $('#txtSeason', form).val(),
|
|
||||||
EpisodeNumber: $('#txtEpisode', form).val(),
|
|
||||||
EndingEpisodeNumber: $('#txtEndingEpisode', form).val(),
|
|
||||||
RememberCorrection: $('#chkRememberCorrection', form).checked()
|
|
||||||
};
|
|
||||||
|
|
||||||
ApiClient.performEpisodeOrganization(resultId, options).then(function () {
|
|
||||||
|
|
||||||
Dashboard.hideLoadingMsg();
|
|
||||||
|
|
||||||
$('.episodeCorrectionPopup', page).popup("close");
|
|
||||||
|
|
||||||
reloadItems(page);
|
|
||||||
|
|
||||||
}, onApiFailure);
|
|
||||||
}
|
|
||||||
|
|
||||||
function reloadItems(page) {
|
function reloadItems(page) {
|
||||||
|
|
||||||
Dashboard.showLoadingMsg();
|
Dashboard.showLoadingMsg();
|
||||||
|
@ -173,7 +118,6 @@
|
||||||
renderResults(page, result);
|
renderResults(page, result);
|
||||||
|
|
||||||
Dashboard.hideLoadingMsg();
|
Dashboard.hideLoadingMsg();
|
||||||
|
|
||||||
}, onApiFailure);
|
}, onApiFailure);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -229,9 +173,9 @@
|
||||||
var status = item.Status;
|
var status = item.Status;
|
||||||
|
|
||||||
if (status == 'SkippedExisting') {
|
if (status == 'SkippedExisting') {
|
||||||
html += '<div style="color:blue;">';
|
html += '<a data-resultid="' + item.Id + '" style="color:blue;" href="#" class="btnShowStatusMessage">';
|
||||||
html += item.OriginalFileName;
|
html += item.OriginalFileName;
|
||||||
html += '</div>';
|
html += '</a>';
|
||||||
}
|
}
|
||||||
else if (status == 'Failure') {
|
else if (status == 'Failure') {
|
||||||
html += '<a data-resultid="' + item.Id + '" style="color:red;" href="#" class="btnShowStatusMessage">';
|
html += '<a data-resultid="' + item.Id + '" style="color:red;" href="#" class="btnShowStatusMessage">';
|
||||||
|
@ -323,14 +267,9 @@
|
||||||
|
|
||||||
var page = $.mobile.activePage;
|
var page = $.mobile.activePage;
|
||||||
|
|
||||||
if (msg.MessageType == "ScheduledTaskEnded") {
|
if ((msg.MessageType == 'ScheduledTaskEnded' && msg.Data.Key == 'AutoOrganize') || msg.MessageType == 'AutoOrganizeUpdate') {
|
||||||
|
|
||||||
var result = msg.Data;
|
reloadItems(page);
|
||||||
|
|
||||||
if (result.Key == 'AutoOrganize') {
|
|
||||||
|
|
||||||
reloadItems(page);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -338,15 +277,21 @@
|
||||||
|
|
||||||
Dashboard.hideLoadingMsg();
|
Dashboard.hideLoadingMsg();
|
||||||
|
|
||||||
Dashboard.alert({
|
var page = $.mobile.activePage;
|
||||||
title: Globalize.translate('AutoOrganizeError'),
|
$('.episodeCorrectionPopup', page).popup("close");
|
||||||
message: Globalize.translate('ErrorOrganizingFileWithErrorCode', e.getResponseHeader("X-Application-Error-Code"))
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function onEpisodeCorrectionFormSubmit() {
|
if (e.status == 0) {
|
||||||
submitEpisodeForm(this);
|
Dashboard.alert({
|
||||||
return false;
|
title: 'Auto-Organize',
|
||||||
|
message: 'The operation is going to take a little longer. The view will be updated on completion.'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
Dashboard.alert({
|
||||||
|
title: Globalize.translate('AutoOrganizeError'),
|
||||||
|
message: Globalize.translate('ErrorOrganizingFileWithErrorCode', e.getResponseHeader("X-Application-Error-Code"))
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$(document).on('pageinit', "#libraryFileOrganizerLogPage", function () {
|
$(document).on('pageinit', "#libraryFileOrganizerLogPage", function () {
|
||||||
|
@ -361,8 +306,6 @@
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
$('.episodeCorrectionForm').off('submit', onEpisodeCorrectionFormSubmit).on('submit', onEpisodeCorrectionFormSubmit);
|
|
||||||
|
|
||||||
}).on('pageshow', "#libraryFileOrganizerLogPage", function () {
|
}).on('pageshow', "#libraryFileOrganizerLogPage", function () {
|
||||||
|
|
||||||
var page = this;
|
var page = this;
|
||||||
|
@ -377,7 +320,7 @@
|
||||||
taskKey: 'AutoOrganize'
|
taskKey: 'AutoOrganize'
|
||||||
});
|
});
|
||||||
|
|
||||||
$(ApiClient).on("websocketmessage.autoorganizelog", onWebSocketMessage);
|
Events.on(ApiClient, "websocketmessage", onWebSocketMessage);
|
||||||
|
|
||||||
}).on('pagebeforehide', "#libraryFileOrganizerLogPage", function () {
|
}).on('pagebeforehide', "#libraryFileOrganizerLogPage", function () {
|
||||||
|
|
||||||
|
@ -390,7 +333,7 @@
|
||||||
mode: 'off'
|
mode: 'off'
|
||||||
});
|
});
|
||||||
|
|
||||||
$(ApiClient).off("websocketmessage.autoorganizelog", onWebSocketMessage);
|
Events.off(ApiClient, "websocketmessage", onWebSocketMessage);
|
||||||
});
|
});
|
||||||
|
|
||||||
})(jQuery, document, window);
|
})(jQuery, document, window);
|
||||||
|
|
|
@ -49,42 +49,37 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
var html = "";
|
var html = "";
|
||||||
var currentType;
|
|
||||||
|
if (infos.length) {
|
||||||
|
html += '<div class="paperList">';
|
||||||
|
}
|
||||||
|
|
||||||
for (var i = 0, length = infos.length; i < length; i++) {
|
for (var i = 0, length = infos.length; i < length; i++) {
|
||||||
|
|
||||||
var info = infos[i];
|
var info = infos[i];
|
||||||
|
|
||||||
if (info.OrganizerType != currentType) {
|
html += '<paper-icon-item>';
|
||||||
currentType = info.OrganizerType;
|
|
||||||
|
|
||||||
if (html.length > 0) {
|
html += '<paper-fab mini icon="folder" item-icon class="blue"></paper-fab>';
|
||||||
html += "</ul>";
|
|
||||||
}
|
|
||||||
|
|
||||||
html += "<h2>" + currentType + "</h2>";
|
html += '<paper-item-body two-line>';
|
||||||
|
|
||||||
html += '<ul data-role="listview" data-inset="true" data-auto-enhanced="false" data-split-icon="action">';
|
html += "<div>" + info.DisplayName + "</div>";
|
||||||
}
|
|
||||||
|
|
||||||
html += "<li data-role='list-divider'><h3 style='font-weight:bold'>" + info.Name + "</h3></li>";
|
html += info.MatchStrings.map(function (m) {
|
||||||
|
return "<div secondary>" + m + "</div>";
|
||||||
|
}).join('');
|
||||||
|
|
||||||
for (var n = 0; n < info.MatchStrings.length; n++) {
|
html += '</paper-item-body>';
|
||||||
html += "<li title='" + info.MatchStrings[n] + "'>";
|
|
||||||
|
|
||||||
html += "<a style='padding-top: 0.5em; padding-bottom: 0.5em'>";
|
html += '<paper-icon-button icon="delete" class="btnDeleteMatchEntry" data-index="' + i + '" title="' + Globalize.translate('ButtonDelete') + '"></paper-icon-button>';
|
||||||
|
|
||||||
html += "<p>" + info.MatchStrings[n] + "</p>";
|
html += '</paper-icon-item>';
|
||||||
|
|
||||||
html += "<a id='btnDeleteMatchEntry" + info.Id + "' class='btnDeleteMatchEntry' href='#' data-id='" + info.Id + "' data-matchstring='" + info.MatchStrings[n] + "' data-icon='delete'>" + Globalize.translate('ButtonDelete') + "</a>";
|
|
||||||
|
|
||||||
html += "</a>";
|
|
||||||
|
|
||||||
html += "</li>";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
html += "</ul>";
|
if (infos.length) {
|
||||||
|
html += "</div>";
|
||||||
|
}
|
||||||
|
|
||||||
$('.divMatchInfos', page).html(html).trigger('create');
|
$('.divMatchInfos', page).html(html).trigger('create');
|
||||||
}
|
}
|
||||||
|
@ -105,14 +100,17 @@
|
||||||
$('.divMatchInfos', page).on('click', '.btnDeleteMatchEntry', function () {
|
$('.divMatchInfos', page).on('click', '.btnDeleteMatchEntry', function () {
|
||||||
|
|
||||||
var button = this;
|
var button = this;
|
||||||
var id = button.getAttribute('data-id');
|
var index = parseInt(button.getAttribute('data-index'));
|
||||||
|
|
||||||
var options = {
|
var info = currentResult.Items[index];
|
||||||
|
var entries = info.MatchStrings.map(function (m) {
|
||||||
|
return {
|
||||||
|
Name: info.ItemName,
|
||||||
|
Value: m
|
||||||
|
};
|
||||||
|
});
|
||||||
|
|
||||||
MatchString: button.getAttribute('data-matchstring')
|
ApiClient.deleteSmartMatchEntries(entries).then(function () {
|
||||||
};
|
|
||||||
|
|
||||||
ApiClient.deleteSmartMatchEntry(id, options).then(function () {
|
|
||||||
|
|
||||||
reloadList(page);
|
reloadList(page);
|
||||||
|
|
||||||
|
|
|
@ -408,7 +408,10 @@
|
||||||
function renderDetails(page, item, context, isStatic) {
|
function renderDetails(page, item, context, isStatic) {
|
||||||
|
|
||||||
renderSimilarItems(page, item, context);
|
renderSimilarItems(page, item, context);
|
||||||
renderSiblingLinks(page, item, context);
|
|
||||||
|
if (!isStatic) {
|
||||||
|
renderSiblingLinks(page, item, context);
|
||||||
|
}
|
||||||
|
|
||||||
if (item.Taglines && item.Taglines.length) {
|
if (item.Taglines && item.Taglines.length) {
|
||||||
$('.tagline', page).html(item.Taglines[0]).show();
|
$('.tagline', page).html(item.Taglines[0]).show();
|
||||||
|
|
|
@ -1061,9 +1061,9 @@
|
||||||
|
|
||||||
identifyItem: function (itemId) {
|
identifyItem: function (itemId) {
|
||||||
|
|
||||||
require(['components/itemidentifier/itemidentifier'], function () {
|
require(['components/itemidentifier/itemidentifier'], function (itemidentifier) {
|
||||||
|
|
||||||
ItemIdentifier.show(itemId);
|
itemidentifier.show(itemId);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -81,9 +81,9 @@
|
||||||
});
|
});
|
||||||
|
|
||||||
if (AppInfo.enableSupporterMembership) {
|
if (AppInfo.enableSupporterMembership) {
|
||||||
$('.lnkSupporterLearnMore', page).show();
|
page.querySelector('.btnSupporterForConverting a').href = 'https://emby.media/premiere';
|
||||||
} else {
|
} else {
|
||||||
$('.lnkSupporterLearnMore', page).hide();
|
page.querySelector('.btnSupporterForConverting a').href = '#';
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
|
@ -246,7 +246,7 @@
|
||||||
|
|
||||||
var html = '';
|
var html = '';
|
||||||
html += '<div class="dialogHeader">';
|
html += '<div class="dialogHeader">';
|
||||||
html += '<paper-icon-button icon="close" class="btnCancel" tabindex="-1"></paper-icon-button>';
|
html += '<paper-icon-button icon="arrow-back" class="btnCancel" tabindex="-1"></paper-icon-button>';
|
||||||
html += '<div class="dialogHeaderTitle">';
|
html += '<div class="dialogHeaderTitle">';
|
||||||
html += Globalize.translate('SyncMedia');
|
html += Globalize.translate('SyncMedia');
|
||||||
html += '</div>';
|
html += '</div>';
|
||||||
|
|
|
@ -70,7 +70,7 @@
|
||||||
<p id="itemDeathDate"></p>
|
<p id="itemDeathDate"></p>
|
||||||
<p id="seriesAirTime"></p>
|
<p id="seriesAirTime"></p>
|
||||||
<p class="airDate"></p>
|
<p class="airDate"></p>
|
||||||
<p class="itemOverview smoothScrollY"></p>
|
<p class="itemOverview topOverview"></p>
|
||||||
</div>
|
</div>
|
||||||
<div id="castCollapsible" style="display: none;" class="detailSection">
|
<div id="castCollapsible" style="display: none;" class="detailSection">
|
||||||
<h1 id="peopleHeader">
|
<h1 id="peopleHeader">
|
||||||
|
@ -110,6 +110,7 @@
|
||||||
</h1>
|
</h1>
|
||||||
<div>
|
<div>
|
||||||
<div class="tabDetails">
|
<div class="tabDetails">
|
||||||
|
<p class="itemOverview bottomOverview"></p>
|
||||||
<p id="players"></p>
|
<p id="players"></p>
|
||||||
<p class="itemExternalLinks"></p>
|
<p class="itemExternalLinks"></p>
|
||||||
<p class="itemStudios"></p>
|
<p class="itemStudios"></p>
|
||||||
|
|
|
@ -1535,5 +1535,6 @@
|
||||||
"LabelCodecIntrosPath": "Codec intros path:",
|
"LabelCodecIntrosPath": "Codec intros path:",
|
||||||
"LabelCodecIntrosPathHelp": "A folder containing video files. If an intro video file name matches the video codec, audio codec, audio profile, or a tag, then it will be played prior to the main feature.",
|
"LabelCodecIntrosPathHelp": "A folder containing video files. If an intro video file name matches the video codec, audio codec, audio profile, or a tag, then it will be played prior to the main feature.",
|
||||||
"OptionConvertRecordingsToStreamingFormat": "Automatically convert recordings to a streaming friendly format",
|
"OptionConvertRecordingsToStreamingFormat": "Automatically convert recordings to a streaming friendly format",
|
||||||
"OptionConvertRecordingsToStreamingFormatHelp": "Recordings will be converted on the fly to MP4 for easy playback on your devices. This feature requires an active Emby Premiere subscription."
|
"OptionConvertRecordingsToStreamingFormatHelp": "Recordings will be converted on the fly to MP4 for easy playback on your devices.",
|
||||||
|
"FeatureRequiresEmbyPremiere": "This feature requires an active Emby Premiere subscription."
|
||||||
}
|
}
|
|
@ -1550,5 +1550,6 @@
|
||||||
"LabelCodecIntrosPath": "Codec intros path:",
|
"LabelCodecIntrosPath": "Codec intros path:",
|
||||||
"LabelCodecIntrosPathHelp": "A folder containing video files. If an intro video file name matches the video codec, audio codec, audio profile, or a tag, then it will be played prior to the main feature.",
|
"LabelCodecIntrosPathHelp": "A folder containing video files. If an intro video file name matches the video codec, audio codec, audio profile, or a tag, then it will be played prior to the main feature.",
|
||||||
"OptionConvertRecordingsToStreamingFormat": "Automatically convert recordings to a streaming friendly format",
|
"OptionConvertRecordingsToStreamingFormat": "Automatically convert recordings to a streaming friendly format",
|
||||||
"OptionConvertRecordingsToStreamingFormatHelp": "Recordings will be converted on the fly to MP4 for easy playback on your devices. This feature requires an active Emby Premiere subscription."
|
"OptionConvertRecordingsToStreamingFormatHelp": "Recordings will be converted on the fly to MP4 for easy playback on your devices.",
|
||||||
|
"FeatureRequiresEmbyPremiere": "This feature requires an active Emby Premiere subscription."
|
||||||
}
|
}
|
||||||
|
|
|
@ -263,6 +263,7 @@
|
||||||
"HeaderSelectWatchFolderHelp": "Browse or enter the path to your watch folder. The folder must be writeable.",
|
"HeaderSelectWatchFolderHelp": "Browse or enter the path to your watch folder. The folder must be writeable.",
|
||||||
"OrganizePatternResult": "Result: {0}",
|
"OrganizePatternResult": "Result: {0}",
|
||||||
"AutoOrganizeError": "Error Organizing File",
|
"AutoOrganizeError": "Error Organizing File",
|
||||||
|
"FileOrganizeManually": "Organize File",
|
||||||
"ErrorOrganizingFileWithErrorCode": "There was an error organizing the file. Error code: {0}.",
|
"ErrorOrganizingFileWithErrorCode": "There was an error organizing the file. Error code: {0}.",
|
||||||
"HeaderRestart": "Restart",
|
"HeaderRestart": "Restart",
|
||||||
"HeaderShutdown": "Shutdown",
|
"HeaderShutdown": "Shutdown",
|
||||||
|
|
|
@ -264,6 +264,7 @@
|
||||||
"HeaderSelectWatchFolderHelp": "Browse or enter the path to your watch folder. The folder must be writeable.",
|
"HeaderSelectWatchFolderHelp": "Browse or enter the path to your watch folder. The folder must be writeable.",
|
||||||
"OrganizePatternResult": "Result: {0}",
|
"OrganizePatternResult": "Result: {0}",
|
||||||
"AutoOrganizeError": "Error Organizing File",
|
"AutoOrganizeError": "Error Organizing File",
|
||||||
|
"FileOrganizeManually": "Organize File",
|
||||||
"ErrorOrganizingFileWithErrorCode": "There was an error organizing the file. Error code: {0}.",
|
"ErrorOrganizingFileWithErrorCode": "There was an error organizing the file. Error code: {0}.",
|
||||||
"HeaderRestart": "Restart",
|
"HeaderRestart": "Restart",
|
||||||
"HeaderShutdown": "Shutdown",
|
"HeaderShutdown": "Shutdown",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue