Skip to content

Commit

Permalink
Merge pull request #9459 from Freso/issue/9235/allow-librarians-to-mo…
Browse files Browse the repository at this point in the history
…ve-to-new-work

Permit librarians to move editions to a new work
  • Loading branch information
jimchamp authored Jul 22, 2024
2 parents 800bcab + 0fcb733 commit f7b418f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion openlibrary/templates/books/edit/edition.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

$ edition_config = get_edition_config()
$ is_privileged_user = ctx.user and (ctx.user.is_admin() or ctx.user.is_super_librarian())
$ is_librarian = is_privileged_user or (ctx.user and ctx.user.is_librarian())

$def radiobuttons(name, options, value):
$for v in options:
Expand Down Expand Up @@ -378,7 +379,7 @@
$_("WARNING: Any edits made to the work from this page will be ignored.")
</span>
</div>
$ config = {'addnew': is_privileged_user, 'new_name': _('-- Move to a new work')}
$ config = {'addnew': is_librarian, 'new_name': _('-- Move to a new work')}
<div class="multi-input-autocomplete multi-input-autocomplete--works" data-config="$dumps(config)">
$if book.works:
$for i, work in enumerate(book.works):
Expand Down

0 comments on commit f7b418f

Please sign in to comment.