mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
fixes #687 - Enable/disable live tv per user
This commit is contained in:
parent
e30d68fdd4
commit
70dcad3253
4 changed files with 23 additions and 9 deletions
|
@ -30,7 +30,7 @@
|
||||||
|
|
||||||
})[0];
|
})[0];
|
||||||
|
|
||||||
var message = 'The following file will be deleted:<p style="word-wrap:break-word;">' + item.OriginalPath + '</p><p>Are you sure you wish to proceed?</p>';
|
var message = 'The following file will be <b>deleted</b>:<p style="word-wrap:break-word;">' + item.OriginalPath + '</p><p>Are you sure you wish to proceed?</p>';
|
||||||
|
|
||||||
Dashboard.confirm(message, "Delete File", function (confirmResult) {
|
Dashboard.confirm(message, "Delete File", function (confirmResult) {
|
||||||
|
|
||||||
|
@ -79,7 +79,7 @@
|
||||||
$('#txtEndingEpisode', popup).val(item.ExtractedEndingEpisodeNumber);
|
$('#txtEndingEpisode', popup).val(item.ExtractedEndingEpisodeNumber);
|
||||||
|
|
||||||
$('#hfResultId', popup).val(item.Id);
|
$('#hfResultId', popup).val(item.Id);
|
||||||
|
|
||||||
if (item.ExtractedName) {
|
if (item.ExtractedName) {
|
||||||
$('#fldRememberCorrection', popup).hide();
|
$('#fldRememberCorrection', popup).hide();
|
||||||
} else {
|
} else {
|
||||||
|
@ -115,7 +115,15 @@
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var message = 'The following file will be moved from:<p style="word-wrap:break-word;">' + item.OriginalPath + '</p><p>to:</p><p style="word-wrap:break-word;">' + item.TargetPath + '</p><p>Are you sure you wish to proceed?</p>';
|
var message = 'The following file will be moved from:<p style="word-wrap:break-word;">' + item.OriginalPath + '</p><p>to:</p><p style="word-wrap:break-word;">' + item.TargetPath + '</p>';
|
||||||
|
|
||||||
|
if (item.DuplicatePaths.length) {
|
||||||
|
message += '<p><b>In addition the following dupliates will be deleted:</b></p>';
|
||||||
|
|
||||||
|
message += '<p style="word-wrap:break-word;">' + item.DuplicatePaths.join('<br/>') + '</p>';
|
||||||
|
}
|
||||||
|
|
||||||
|
message += '<p>Are you sure you wish to proceed?</p>';
|
||||||
|
|
||||||
Dashboard.confirm(message, "Organize File", function (confirmResult) {
|
Dashboard.confirm(message, "Organize File", function (confirmResult) {
|
||||||
|
|
||||||
|
|
|
@ -74,7 +74,7 @@
|
||||||
html += '<a class="viewMenuLink viewMenuTextLink desktopViewMenuLink' + (view == 'tv' ? selectedCssClass : '') + '" href="tvrecommended.html">' + (view == 'tv' ? selectedHtml : '') + '<span class="viewName">TV</span></a>';
|
html += '<a class="viewMenuLink viewMenuTextLink desktopViewMenuLink' + (view == 'tv' ? selectedCssClass : '') + '" href="tvrecommended.html">' + (view == 'tv' ? selectedHtml : '') + '<span class="viewName">TV</span></a>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (liveTvInfo.ActiveServiceName) {
|
if (liveTvInfo.EnabledUsers.indexOf(user.Id) != -1) {
|
||||||
html += '<a class="viewMenuLink viewMenuTextLink desktopViewMenuLink' + (view == 'livetv' ? selectedCssClass : '') + '" href="livetvsuggested.html">' + (view == 'livetv' ? selectedHtml : '') + '<span class="viewName">Live TV</span></a>';
|
html += '<a class="viewMenuLink viewMenuTextLink desktopViewMenuLink' + (view == 'livetv' ? selectedCssClass : '') + '" href="livetvsuggested.html">' + (view == 'livetv' ? selectedHtml : '') + '<span class="viewName">Live TV</span></a>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -146,7 +146,7 @@
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (liveTvInfo.ActiveServiceName) {
|
if (liveTvInfo.EnabledUsers.indexOf(Dashboard.getCurrentUserId()) != -1) {
|
||||||
html += getCollapsibleHtml('Live TV', [
|
html += getCollapsibleHtml('Live TV', [
|
||||||
|
|
||||||
{ text: 'Suggested', href: 'livetvsuggested.html' },
|
{ text: 'Suggested', href: 'livetvsuggested.html' },
|
||||||
|
@ -223,7 +223,7 @@
|
||||||
var link = links[i];
|
var link = links[i];
|
||||||
|
|
||||||
var href = selectedIndex == i ? '#' : link.href;
|
var href = selectedIndex == i ? '#' : link.href;
|
||||||
|
|
||||||
html += '<li><a class="libraryPanelLink" href="' + href + '">' + link.text + '</a></li>';
|
html += '<li><a class="libraryPanelLink" href="' + href + '">' + link.text + '</a></li>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
$('#chkEnableMediaPlayback', page).checked(user.Configuration.EnableMediaPlayback || false).checkboxradio("refresh");
|
$('#chkEnableMediaPlayback', page).checked(user.Configuration.EnableMediaPlayback || false).checkboxradio("refresh");
|
||||||
|
|
||||||
$('#chkManageLiveTv', page).checked(user.Configuration.EnableLiveTvManagement || false).checkboxradio("refresh");
|
$('#chkManageLiveTv', page).checked(user.Configuration.EnableLiveTvManagement || false).checkboxradio("refresh");
|
||||||
|
$('#chkEnableLiveTvAccess', page).checked(user.Configuration.EnableLiveTvAccess || false).checkboxradio("refresh");
|
||||||
|
|
||||||
Dashboard.hideLoadingMsg();
|
Dashboard.hideLoadingMsg();
|
||||||
}
|
}
|
||||||
|
@ -57,6 +58,7 @@
|
||||||
user.Configuration.EnableRemoteControlOfOtherUsers = $('#chkEnableRemoteControlOtherUsers', page).checked();
|
user.Configuration.EnableRemoteControlOfOtherUsers = $('#chkEnableRemoteControlOtherUsers', page).checked();
|
||||||
user.Configuration.EnableLiveTvManagement = $('#chkManageLiveTv', page).checked();
|
user.Configuration.EnableLiveTvManagement = $('#chkManageLiveTv', page).checked();
|
||||||
user.Configuration.EnableMediaPlayback = $('#chkEnableMediaPlayback', page).checked();
|
user.Configuration.EnableMediaPlayback = $('#chkEnableMediaPlayback', page).checked();
|
||||||
|
user.Configuration.EnableLiveTvAccess = $('#chkEnableLiveTvAccess', page).checked();
|
||||||
|
|
||||||
var userId = getParameterByName("userId");
|
var userId = getParameterByName("userId");
|
||||||
|
|
||||||
|
|
|
@ -33,12 +33,16 @@
|
||||||
<label for="chkEnableMediaPlayback">Allow media playback</label>
|
<label for="chkEnableMediaPlayback">Allow media playback</label>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<input type="checkbox" id="chkEnableRemoteControlOtherUsers" name="chkEnableRemoteControlOtherUsers" data-mini="true" />
|
<input type="checkbox" id="chkEnableLiveTvAccess" name="chkEnableLiveTvAccess" data-mini="true" />
|
||||||
<label for="chkEnableRemoteControlOtherUsers">Allow this user to remote control other users</label>
|
<label for="chkEnableLiveTvAccess">Allow browsing of live tv</label>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<input type="checkbox" id="chkManageLiveTv" name="chkManageLiveTv" data-mini="true" />
|
<input type="checkbox" id="chkManageLiveTv" name="chkManageLiveTv" data-mini="true" />
|
||||||
<label for="chkManageLiveTv">Allow this user to schedule tv recordings</label>
|
<label for="chkManageLiveTv">Allow scheduling of tv recordings</label>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<input type="checkbox" id="chkEnableRemoteControlOtherUsers" name="chkEnableRemoteControlOtherUsers" data-mini="true" />
|
||||||
|
<label for="chkEnableRemoteControlOtherUsers">Allow this user to remote control other users</label>
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue