Bug 11027: (follow-up) Create link to baskets/basketgroups only if user have required...
authorMathieu Saby <mathieu.saby@univ-rennes2.fr>
Sun, 22 Dec 2013 21:48:34 +0000 (22:48 +0100)
committerGalen Charlton <gmc@esilibrary.com>
Mon, 21 Apr 2014 04:33:57 +0000 (04:33 +0000)
With this followup, a user without order_manage permission won't be able
to cick on a basket and a user without group_manage permission won't be
able to click on a basketgroup

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt

index a036945..c5341c2 100644 (file)
@@ -159,10 +159,18 @@ $(document).ready(function() {
                    [% lateorder.subtotal %]
             </td>
             <td>
-                <a href="basket.pl?basketno=[% lateorder.basketno %]" title="basket">[% lateorder.basketname %] ([% lateorder.basketno %])</a>
+                [% IF ( CAN_user_acquisition_order_manage ) %]
+                    <a href="basket.pl?basketno=[% lateorder.basketno %]" title="basket">[% lateorder.basketname %] ([% lateorder.basketno %])</a>
+                [% ELSE %]
+                    [% lateorder.basketname %] ([% lateorder.basketno %])
+                [% END %]
             </td>
             <td>
-                <a href="basketgroup.pl?op=add&booksellerid=[% lateorder.supplierid %]&basketgroupid=[% lateorder.basketgroupid %]" title="basketgroup">[% lateorder.basketgroupname %] ([% lateorder.basketgroupid %])</a>
+                [% IF ( CAN_user_acquisition_group_manage ) %]
+                    <a href="basketgroup.pl?op=add&booksellerid=[% lateorder.supplierid %]&basketgroupid=[% lateorder.basketgroupid %]" title="basketgroup">[% lateorder.basketgroupname %] ([% lateorder.basketgroupid %])</a>
+                [% ELSE %]
+                    [% lateorder.basketgroupname %] ([% lateorder.basketgroupid %])</a>
+                [% END %]
             </td>
             <td>[% lateorder.branch %]
             </td>