hide receive screen for stock orders
This commit is contained in:
parent
aa6041d337
commit
41ea9ed66e
3 changed files with 8 additions and 4 deletions
|
@ -20,7 +20,10 @@
|
||||||
%td
|
%td
|
||||||
- unless order.closed?
|
- unless order.closed?
|
||||||
- if current_user.role_orders?
|
- if current_user.role_orders?
|
||||||
= link_to t('orders.index.action_receive'), receive_order_path(order), class: 'btn btn-mini'
|
- unless order.stockit?
|
||||||
|
= link_to t('orders.index.action_receive'), receive_order_path(order), class: 'btn btn-mini'
|
||||||
|
- else
|
||||||
|
= link_to t('orders.index.action_receive'), '#', class: 'btn btn-mini disabled'
|
||||||
= link_to t('.clear'), new_finance_order_path(order_id: order.id), class: 'btn btn-mini btn-primary'
|
= 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),
|
= link_to t('.close'), close_direct_finance_order_path(order),
|
||||||
:confirm => t('.confirm'), :method => :put, class: 'btn btn-mini'
|
:confirm => t('.confirm'), :method => :put, class: 'btn btn-mini'
|
||||||
|
|
|
@ -53,8 +53,9 @@
|
||||||
%td= format_time(order.ends)
|
%td= format_time(order.ends)
|
||||||
%td= truncate(order.note)
|
%td= truncate(order.note)
|
||||||
%td
|
%td
|
||||||
-# TODO btn-success class only if not received before
|
- unless order.stockit?
|
||||||
= link_to t('.action_receive'), receive_order_path(order), class: 'btn btn-small btn-success'
|
-# TODO btn-success class only if not received before
|
||||||
|
= link_to t('.action_receive'), receive_order_path(order), class: 'btn btn-small btn-success'
|
||||||
|
|
||||||
%td
|
%td
|
||||||
= link_to t('ui.edit'), '#', class: 'btn btn-small disabled', tabindex: -1
|
= link_to t('ui.edit'), '#', class: 'btn btn-small disabled', tabindex: -1
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
= link_to t('ui.edit'), edit_order_path(@order), class: 'btn'
|
= link_to t('ui.edit'), edit_order_path(@order), class: 'btn'
|
||||||
= link_to t('.action_end'), finish_order_path(@order), method: :post, class: 'btn btn-success',
|
= link_to t('.action_end'), finish_order_path(@order), method: :post, class: 'btn btn-success',
|
||||||
confirm: t('.confirm_end', order: @order.name)
|
confirm: t('.confirm_end', order: @order.name)
|
||||||
- elsif not @order.closed?
|
- elsif not @order.closed? and not @order.stockit?
|
||||||
-# TODO btn-success class only if not received before
|
-# TODO btn-success class only if not received before
|
||||||
= link_to t('orders.index.action_receive'), receive_order_path(@order), class: 'btn btn-success'
|
= link_to t('orders.index.action_receive'), receive_order_path(@order), class: 'btn btn-success'
|
||||||
- unless @order.closed?
|
- unless @order.closed?
|
||||||
|
|
Loading…
Reference in a new issue