mirror of
https://github.com/morpheus65535/bazarr.git
synced 2024-11-11 01:23:38 +08:00
Fix for #1006
This commit is contained in:
parent
a067d10352
commit
af40005616
3 changed files with 16 additions and 8 deletions
|
@ -589,6 +589,7 @@ class EpisodesSubtitlesUpload(Resource):
|
|||
sonarrSeriesId = request.form.get('sonarrSeriesId')
|
||||
sonarrEpisodeId = request.form.get('sonarrEpisodeId')
|
||||
title = request.form.get('title')
|
||||
audioLanguage = request.form.get('audioLanguage')
|
||||
|
||||
_, ext = os.path.splitext(upload.filename)
|
||||
|
||||
|
@ -602,7 +603,8 @@ class EpisodesSubtitlesUpload(Resource):
|
|||
title=title,
|
||||
scene_name=sceneName,
|
||||
media_type='series',
|
||||
subtitle=upload)
|
||||
subtitle=upload,
|
||||
audio_language=audioLanguage)
|
||||
|
||||
if result is not None:
|
||||
message = result[0]
|
||||
|
@ -944,6 +946,7 @@ class MovieSubtitlesUpload(Resource):
|
|||
upload = request.files.get('upload')
|
||||
radarrId = request.form.get('radarrId')
|
||||
title = request.form.get('title')
|
||||
audioLanguage = request.form.get('audioLanguage')
|
||||
|
||||
_, ext = os.path.splitext(upload.filename)
|
||||
|
||||
|
@ -957,7 +960,8 @@ class MovieSubtitlesUpload(Resource):
|
|||
title=title,
|
||||
scene_name=sceneName,
|
||||
media_type='movie',
|
||||
subtitle=upload)
|
||||
subtitle=upload,
|
||||
audio_language=audioLanguage)
|
||||
|
||||
if result is not None:
|
||||
message = result[0]
|
||||
|
|
|
@ -199,6 +199,7 @@
|
|||
<input type="hidden" id="upload_sonarrSeriesId" name="sonarrSeriesId" value=""/>
|
||||
<input type="hidden" id="upload_sonarrEpisodeId" name="sonarrEpisodeId" value=""/>
|
||||
<input type="hidden" id="upload_title" name="title" value=""/>
|
||||
<input type="hidden" id="upload_audioLanguage" name="audioLanguage" value=""/>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" id="upload_save_button" class="btn btn-info">Save</button>
|
||||
|
@ -675,6 +676,7 @@
|
|||
$('#upload_sonarrSeriesId').val($(this).data("sonarrseriesid"));
|
||||
$('#upload_sonarrEpisodeId').val($(this).data("sonarrepisodeid"));
|
||||
$('#upload_title').val($(this).data("episode_title"));
|
||||
$('#upload_audioLanguage').val(seriesDetails['audio_language']['name']);
|
||||
|
||||
$('#manual_language_select').empty();
|
||||
$.each(enabledLanguages, function (i, item) {
|
||||
|
@ -896,7 +898,7 @@
|
|||
$('#seriesAlternateTitles').hide();
|
||||
}
|
||||
|
||||
$('#seriesAudioLanguage').text(seriesDetails['audio_language'].name);
|
||||
$('#seriesAudioLanguage').text(seriesDetails['audio_language']['name']);
|
||||
$('#seriesMappedPath').text(seriesDetails['mapped_path']);
|
||||
$('#seriesMappedPath').attr("data-original-title", seriesDetails['mapped_path']);
|
||||
$('#seriesFileCount').text(seriesDetails['episodeFileCount'] + ' files');
|
||||
|
|
|
@ -205,6 +205,7 @@
|
|||
<input type="hidden" id="upload_sceneName" name="sceneName" value="" />
|
||||
<input type="hidden" id="upload_radarrId" name="radarrId" value="" />
|
||||
<input type="hidden" id="upload_title" name="title" value="" />
|
||||
<input type="hidden" id="upload_audioLanguage" name="audioLanguage" value="" />
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" id="upload_save_button" class="btn btn-info">Save</button>
|
||||
|
@ -535,10 +536,11 @@
|
|||
$('#upload_button').on('click', function(e){
|
||||
e.preventDefault();
|
||||
$("#upload_movie_title_span").html(movieDetails['title']);
|
||||
$('#upload_moviePath').val($(this).data("moviepath"));
|
||||
$('#upload_sceneName').val($(this).data("scenename"));
|
||||
$('#upload_radarrId').val($(this).data("radarrid"));
|
||||
$('#upload_title').val($(this).data("movie_title"));
|
||||
$('#upload_moviePath').val(movieDetails['mapped_path']);
|
||||
$('#upload_sceneName').val(movieDetails['sceneName']);
|
||||
$('#upload_radarrId').val(movieDetails['radarrId']);
|
||||
$('#upload_title').val(movieDetails['title']);
|
||||
$('#upload_audioLanguage').val(movieDetails['audio_language']['name']);
|
||||
|
||||
$('#manual_language_select').empty();
|
||||
$.each(enabledLanguages, function (i, item) {
|
||||
|
@ -719,7 +721,7 @@
|
|||
$('#moviealternativeTitles').hide();
|
||||
}
|
||||
|
||||
$('#movieAudioLanguage').text(movieDetails['audio_language'].name);
|
||||
$('#movieAudioLanguage').text(movieDetails['audio_language']['name']);
|
||||
$('#movieMappedPath').text(movieDetails['mapped_path']);
|
||||
$('#movieMappedPath').attr("data-original-title", movieDetails['mapped_path']);
|
||||
|
||||
|
|
Loading…
Reference in a new issue