Bug 16745 - Add edit catalog and edit items links to serials toolbar
authorKyle M Hall <kyle@bywatersolutions.com>
Wed, 15 Jun 2016 12:21:26 +0000 (12:21 +0000)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 24 Jun 2016 13:59:20 +0000 (13:59 +0000)
It would be very helpful for librarians to have links directly to the
record and items editor from a serial. Right now moving from the serial
to those editors requires jumping through a number of pages.

Test Plan:
1) Apply this patch
2) Browse subscription-detail.pl for a given serial
3) Under the Edit button, note the "Edit record" link
4) Verify the link takes you to the marc editor for that record
5) Create or find a serial that is set to create items on receiving
6) Under the Edit button, note the new "Edit items" link
7) Verify the link takes you to the items editor for that record
8) Create of find a serial that is *not* set to create items on receiving
9) Verify the "Edit items" link does not exists for that serial

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
koha-tmpl/intranet-tmpl/prog/en/includes/serials-toolbar.inc

index 02348b2..b368317 100644 (file)
                             [% IF ( cannotedit ) %] <li class="disabled"> [% ELSE %]
                             <li> [% END %]
                             <a href="/cgi-bin/koha/serials/subscription-add.pl?op=dup&amp;subscriptionid=[% subscriptionid %]">Edit as new (duplicate)</a></li>
+
+                            [% IF CAN_user_editcatalogue_edit_catalogue %]
+                                <li><a id="editbiblio" href="/cgi-bin/koha/cataloguing/addbiblio.pl?biblionumber=[% biblionumber %]">Edit record</a></li>
+                            [% END %]
+
+                            [% IF serialsadditems && CAN_user_editcatalogue_edit_items %]
+                                <li><a id="edititems" href="/cgi-bin/koha/cataloguing/additem.pl?biblionumber=[% biblionumber %]">Edit items</a></li>
+                            [% END %]
+
                             [% IF ( CAN_user_serials_delete_subscription ) %]
                             [% IF ( cannotedit ) %] <li class="disabled"> [% ELSE %]
                             <li> [% END %]