summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDieter Hametner <dh (plus) vdr (at) gekrumbel (dot) de>2011-09-04 19:17:52 (GMT)
committerDieter Hametner <dh (plus) vdr (at) gekrumbel (dot) de>2011-09-04 19:17:52 (GMT)
commit844fb6549414258296321648127a0d19fb2f49b8 (patch)
tree6a525e6f25eb63c5a9e1f88192836204b3af17cc
parentad26ae4fcac0fe73b7e8b55af8eb4bfa3999fb4e (diff)
downloadvdr-plugin-live-844fb6549414258296321648127a0d19fb2f49b8.tar.gz
vdr-plugin-live-844fb6549414258296321648127a0d19fb2f49b8.tar.bz2
Allow to remove rights to delete recordings. According to the bug entry
http://projects.vdr-developer.org/issues/645 this will allow to create a pure 'guest' only user account. The fix was suggested by mhanu in above bug entry.
-rw-r--r--pages/recordings.ecpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/pages/recordings.ecpp b/pages/recordings.ecpp
index 1722514..fd23b63 100644
--- a/pages/recordings.ecpp
+++ b/pages/recordings.ecpp
@@ -13,6 +13,7 @@
#include "tasks.h"
#include "tools.h"
#include "i18n.h"
+#include "users.h"
#include "recman.h"
@@ -55,6 +56,8 @@ pageTitle = tr("Recordings");
deleteResult = "";
if (!todel.empty()) {
+ if (!cUser::CurrentUserHasRightTo(UR_DELRECS))
+ throw HtmlError( tr("Sorry, no permission. Please contact your administrator!") );
deletions.push_back(todel);
}
for (deletions_type::const_iterator it = deletions.begin(); it != deletions.end(); ++it) {