From 3d511ea2fbad0c67220fc92ec909bab2e5f856be Mon Sep 17 00:00:00 2001 From: wvengen Date: Wed, 18 Dec 2013 22:19:36 +0100 Subject: [PATCH] only show receive in finance when access to ordering --- app/views/finance/balancing/_orders.html.haml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/views/finance/balancing/_orders.html.haml b/app/views/finance/balancing/_orders.html.haml index c25696e7..0f69abcc 100644 --- a/app/views/finance/balancing/_orders.html.haml +++ b/app/views/finance/balancing/_orders.html.haml @@ -19,7 +19,8 @@ %td= show_user(order.updated_by) %td - unless order.closed? - = link_to t('orders.index.action_receive'), receive_order_path(order), class: 'btn btn-mini' + - if current_user.role_orders? + = link_to t('orders.index.action_receive'), receive_order_path(order), class: 'btn btn-mini' = link_to t('.clear'), new_finance_order_path(order_id: order.id), class: 'btn btn-mini btn-primary' = link_to t('.close'), close_direct_finance_order_path(order), :confirm => t('.confirm'), :method => :put, class: 'btn btn-mini'