From 40fc62a233255753695483b98dbc388753c80252 Mon Sep 17 00:00:00 2001
From: Luke Pulverenti
Date: Tue, 20 Jan 2015 00:19:13 -0500
Subject: [PATCH] sync updates
---
dashboard-ui/css/notifications.css | 2 +-
dashboard-ui/css/site.css | 8 ++++
dashboard-ui/dashboard.html | 46 ++---------------------
dashboard-ui/scripts/dashboardpage.js | 12 +-----
dashboard-ui/scripts/devices.js | 2 +-
dashboard-ui/scripts/librarybrowser.js | 4 --
dashboard-ui/scripts/notifications.js | 18 +++++----
dashboard-ui/scripts/site.js | 2 +-
dashboard-ui/scripts/syncjob.js | 4 +-
dashboard-ui/scripts/userlibraryaccess.js | 31 +++++++++++----
dashboard-ui/scripts/usernew.js | 27 ++++++++++---
dashboard-ui/scripts/userprofilespage.js | 4 +-
dashboard-ui/userlibraryaccess.html | 14 +++++--
dashboard-ui/usernew.html | 14 ++++---
dashboard-ui/wizardfinish.html | 2 +-
15 files changed, 95 insertions(+), 95 deletions(-)
diff --git a/dashboard-ui/css/notifications.css b/dashboard-ui/css/notifications.css
index a6feb479c..877b3d0b8 100644
--- a/dashboard-ui/css/notifications.css
+++ b/dashboard-ui/css/notifications.css
@@ -135,4 +135,4 @@
.imgNotificationWarning .imgNotificationInner {
background-image: url(images/notifications/error.png);
- }
+ }
\ No newline at end of file
diff --git a/dashboard-ui/css/site.css b/dashboard-ui/css/site.css
index 8d76bae7a..15afd48e9 100644
--- a/dashboard-ui/css/site.css
+++ b/dashboard-ui/css/site.css
@@ -1040,3 +1040,11 @@ h1 + .accentButton {
font-weight: normal;
margin: 0 .7em;
}
+
+ .dashboardFooter .appLinks a {
+ margin: .25em;
+ }
+
+ .dashboardFooter .appLinks img {
+ height: 16px;
+ }
diff --git a/dashboard-ui/dashboard.html b/dashboard-ui/dashboard.html
index 33bfa5add..ce99f9191 100644
--- a/dashboard-ui/dashboard.html
+++ b/dashboard-ui/dashboard.html
@@ -21,9 +21,6 @@
-
diff --git a/dashboard-ui/scripts/dashboardpage.js b/dashboard-ui/scripts/dashboardpage.js
index fed3b7716..16da8e2df 100644
--- a/dashboard-ui/scripts/dashboardpage.js
+++ b/dashboard-ui/scripts/dashboardpage.js
@@ -24,12 +24,6 @@
Dashboard.getPluginSecurityInfo().done(function (pluginSecurityInfo) {
- if (pluginSecurityInfo.IsMBSupporter) {
- $('#contribute', page).hide();
- } else {
- $('#contribute', page).show();
- }
-
DashboardPage.renderSupporterIcon(page, pluginSecurityInfo);
});
@@ -795,17 +789,15 @@
if (pluginSecurityInfo.IsMBSupporter) {
imgUrl = "css/images/supporter/supporterbadge.png";
- text = "Thank you for supporting Media Browser.";
+ text = Globalize.translate('MessageThankYouForSupporting');
$('.supporterIconContainer', page).html('
' + text + '');
- $('.supporterIconContainer', page).hide();
} else {
imgUrl = "css/images/supporter/nonsupporterbadge.png";
- text = "Please support Media Browser.";
+ text = Globalize.translate('MessagePleaseSupportMediaBrowser');
$('.supporterIconContainer', page).html('
' + text + '');
- $('.supporterIconContainer', page).hide();
}
},
diff --git a/dashboard-ui/scripts/devices.js b/dashboard-ui/scripts/devices.js
index 3f844b237..366da370d 100644
--- a/dashboard-ui/scripts/devices.js
+++ b/dashboard-ui/scripts/devices.js
@@ -79,7 +79,7 @@
ApiClient.getJSON(ApiClient.getUrl('Devices', {
- SupportsUniqueIdentifier: true
+ SupportsPersistentIdentifier: true
})).done(function (result) {
diff --git a/dashboard-ui/scripts/librarybrowser.js b/dashboard-ui/scripts/librarybrowser.js
index cf9d17a45..29d7e9103 100644
--- a/dashboard-ui/scripts/librarybrowser.js
+++ b/dashboard-ui/scripts/librarybrowser.js
@@ -492,10 +492,6 @@
return "itemlist.html?parentId=" + item.Id;
}
- if (item.CollectionType == 'movies') {
- return 'movieslatest.html?topParentId=' + item.Id;
- }
-
if (item.CollectionType == 'tvshows') {
return 'tvrecommended.html?topParentId=' + item.Id;
}
diff --git a/dashboard-ui/scripts/notifications.js b/dashboard-ui/scripts/notifications.js
index 985ef28fa..9d8ed7975 100644
--- a/dashboard-ui/scripts/notifications.js
+++ b/dashboard-ui/scripts/notifications.js
@@ -73,7 +73,7 @@
self.isFlyout = true;
var startIndex = 0;
- var limit = 40;
+ var limit = 5;
var elem = $('.notificationsFlyoutlist');
refreshNotifications(startIndex, limit, elem, null, false).done(function() {
@@ -177,16 +177,18 @@
html += '
';
- html += '
' + notification.Name + '
';
+ html += '
';
+ if (notification.Url) {
+ html += '' + notification.Name + '';
+ } else {
+ html += notification.Name;
+ }
+ html += '
';
- html += '
' + humane_date(notification.Date) + '
';
+ html += '
' + humane_date(notification.Date) + '
';
if (notification.Description) {
- html += '
' + notification.Description + '
';
- }
-
- if (notification.Url) {
- html += '
' + Globalize.translate('ButtonMoreInformation') + '
';
+ html += '
' + notification.Description + '
';
}
html += '
';
diff --git a/dashboard-ui/scripts/site.js b/dashboard-ui/scripts/site.js
index 5af308338..434e225ce 100644
--- a/dashboard-ui/scripts/site.js
+++ b/dashboard-ui/scripts/site.js
@@ -1318,7 +1318,7 @@ var Dashboard = {
PlayableMediaTypes: "Audio,Video",
SupportedCommands: Dashboard.getSupportedRemoteCommands().join(','),
- SupportsUniqueIdentifier: false
+ SupportsPersistentIdentifier: false
};
window.ConnectionManager = new MediaBrowser.ConnectionManager(jQuery, Logger, credentialProvider, appName, appVersion, deviceName, deviceId, capabilities);
diff --git a/dashboard-ui/scripts/syncjob.js b/dashboard-ui/scripts/syncjob.js
index c835c71bc..99f44a62e 100644
--- a/dashboard-ui/scripts/syncjob.js
+++ b/dashboard-ui/scripts/syncjob.js
@@ -5,12 +5,12 @@
var html = '';
html += '
';
- html += '';
+ html += '';
html += '';
html += '
';
html += '
';
- html += '';
+ html += '';
html += '';
html += '
';
diff --git a/dashboard-ui/scripts/userlibraryaccess.js b/dashboard-ui/scripts/userlibraryaccess.js
index b75c1eacb..d844ceabd 100644
--- a/dashboard-ui/scripts/userlibraryaccess.js
+++ b/dashboard-ui/scripts/userlibraryaccess.js
@@ -6,7 +6,7 @@
html += '
';
- $('.mediaFolderAccess', page).html(html).trigger('create');
+ $('.folderAccess', page).html(html).trigger('create');
+
+ $('#chkEnableAllFolders', page).checked(user.Policy.EnableAllFolders).checkboxradio('refresh').trigger('change');
}
function loadChannels(page, user, channels) {
@@ -110,11 +112,14 @@
function saveUser(user, page) {
- user.Policy.BlockedMediaFolders = $('.chkMediaFolder:not(:checked)', page).map(function () {
+ user.Policy.EnableAllFolders = $('#chkEnableAllFolders', page).checked();
+ user.Policy.EnabledFolders = user.Policy.EnableAllFolders ?
+ [] :
+ $('.chkFolder:checked', page).map(function () {
- return this.getAttribute('data-foldername');
+ return this.getAttribute('data-id');
- }).get();
+ }).get();
user.Policy.EnableAllChannels = $('#chkEnableAllChannels', page).checked();
user.Policy.EnabledChannels = user.Policy.EnableAllChannels ?
@@ -182,6 +187,16 @@
});
+ $('#chkEnableAllFolders', page).on('change', function () {
+
+ if (this.checked) {
+ $('.folderAccessListContainer', page).hide();
+ } else {
+ $('.folderAccessListContainer', page).show();
+ }
+
+ });
+
}).on('pageshow', "#userLibraryAccessPage", function () {
var page = this;
@@ -210,7 +225,7 @@
var promise4 = ApiClient.getJSON(ApiClient.getUrl("Library/MediaFolders", { IsHidden: false }));
var promise5 = ApiClient.getJSON(ApiClient.getUrl("Channels"));
var promise6 = ApiClient.getJSON(ApiClient.getUrl('Devices', {
- SupportsUniqueIdentifier: true
+ SupportsPersistentIdentifier: true
}));
$.when(promise1, promise2, promise4, promise5, promise6).done(function (response1, response2, response4, response5, response6) {
diff --git a/dashboard-ui/scripts/usernew.js b/dashboard-ui/scripts/usernew.js
index 3d1e3bb0a..4dfe10aa5 100644
--- a/dashboard-ui/scripts/usernew.js
+++ b/dashboard-ui/scripts/usernew.js
@@ -6,7 +6,7 @@
html += '
';
- $('.mediaFolderAccess', page).html(html).trigger('create');
+ $('.folderAccess', page).html(html).trigger('create');
+
+ $('#chkEnableAllFolders', page).checked(true).checkboxradio('refresh').trigger('change');
}
function loadChannels(page, channels) {
@@ -83,11 +85,14 @@
ApiClient.createUser(name).done(function (user) {
- user.Policy.BlockedMediaFolders = $('.chkMediaFolder:not(:checked)', page).map(function () {
+ user.Policy.EnableAllFolders = $('#chkEnableAllFolders', page).checked();
+ user.Policy.EnabledFolders = user.Policy.EnableAllFolders ?
+ [] :
+ $('.chkFolder:checked', page).map(function () {
- return this.getAttribute('data-id');
+ return this.getAttribute('data-id');
- }).get();
+ }).get();
user.Policy.EnableAllChannels = $('#chkEnableAllChannels', page).checked();
user.Policy.EnabledChannels = user.Policy.EnableAllChannels ?
@@ -142,6 +147,16 @@
});
+ $('#chkEnableAllFolders', page).on('change', function () {
+
+ if (this.checked) {
+ $('.folderAccessListContainer', page).hide();
+ } else {
+ $('.folderAccessListContainer', page).show();
+ }
+
+ });
+
}).on('pageshow', "#newUserPage", function () {
var page = this;
diff --git a/dashboard-ui/scripts/userprofilespage.js b/dashboard-ui/scripts/userprofilespage.js
index 17e8ae4c4..b79cc8731 100644
--- a/dashboard-ui/scripts/userprofilespage.js
+++ b/dashboard-ui/scripts/userprofilespage.js
@@ -341,7 +341,7 @@
ApiClient.getJSON(ApiClient.getUrl("Channels", {})).done(function (channelsResult) {
- var shareExcludes = $(".chkShareFolder:not(:checked)", page).get().map(function (i) {
+ var shareExcludes = $(".chkShareFolder:checked", page).get().map(function (i) {
return i.getAttribute('data-folderid');
});
@@ -355,7 +355,7 @@
data: {
ConnectUsername: $('#txtConnectUsername', page).val(),
- ExcludedLibraries: shareExcludes.join(','),
+ EnabledLibraries: shareExcludes.join(','),
SendingUserId: Dashboard.getCurrentUserId(),
EnableLiveTv: false
}
diff --git a/dashboard-ui/userlibraryaccess.html b/dashboard-ui/userlibraryaccess.html
index 48bf07908..f63ccc410 100644
--- a/dashboard-ui/userlibraryaccess.html
+++ b/dashboard-ui/userlibraryaccess.html
@@ -16,10 +16,18 @@