From 0934984f8facc04e91358f8f8dab7a34caf028a2 Mon Sep 17 00:00:00 2001 From: eric Date: Tue, 29 Apr 2014 21:07:24 -0400 Subject: [PATCH] rights holder can create new work --- frontend/templates/new_edition.html | 2 ++ frontend/templates/rh_tools.html | 1 + frontend/views.py | 2 ++ 3 files changed, 5 insertions(+) diff --git a/frontend/templates/new_edition.html b/frontend/templates/new_edition.html index e417565e..8aaed8d0 100644 --- a/frontend/templates/new_edition.html +++ b/frontend/templates/new_edition.html @@ -17,7 +17,9 @@

Create New Edition

{% endif %} {% else %} + {% if edition.pk %}

Add Ebook Links for {{ edition.work }}

+ {% endif %} {% endif %} {% if admin %} diff --git a/frontend/templates/rh_tools.html b/frontend/templates/rh_tools.html index 10229f2b..c652ace3 100644 --- a/frontend/templates/rh_tools.html +++ b/frontend/templates/rh_tools.html @@ -221,6 +221,7 @@ Any questions not covered here? Please email us at this form to enter the metadata.
  • Your ebooks must have ISBNs assigned.
  • Your metadata should have title, authors, language, description.
  • Contact us to load ONIX or CSV files for you.
  • diff --git a/frontend/views.py b/frontend/views.py index 8d4f7b96..9e490daa 100755 --- a/frontend/views.py +++ b/frontend/views.py @@ -498,6 +498,8 @@ def new_edition(request, work_id, edition_id, by=None): elif work and work.last_campaign(): if request.user in work.last_campaign().managers.all(): admin = True + elif work==None and request.user.rights_holder.count(): + admin = True if edition_id: try: edition = models.Edition.objects.get(id = edition_id)