- if company_signed_in?
  - breadcrumb :order, @order
- else
  - breadcrumb :admin_order, @order

%h1= t('.heading', id: @order.id)

= render @order.cart, currency: @order.currency, view_format: :order, total: @order.total

- if @order.invoice?
  %p= t('orders.show.invoice.true')
  %h4= t('orders.show.billing_address')
  = render @order.billing_address

- else
  %p= t('orders.show.invoice.false')

%p= t("orders.show.polish_taxpayer.#{@order.polish_taxpayer}")
 
- unless @order.paid?
  = link_to fa_icon('credit-card', text: 'Przejdź do płatności'), order_payment_path(@order), class: 'button'
  = link_to fa_icon('ban', text: 'Anuluj zamówienie'), @order, method: :delete, class: 'button dark-red-bg'
  - if admin_user_signed_in?
    = link_to fa_icon('lock', text: "Oznacz jako opłacone"), mark_paid_admin_order_path(@order), class: 'button dark-green-bg', method: :patch
- else
  Zamówienie opłacone &mdash; nie możesz go zmodyfikować ani anulować.


- if company_signed_in?
  - breadcrumb :order, @order
- else
  - breadcrumb :admin_order, @order

%h1= t('.heading', id: @order.id)

= render @order.cart, currency: @order.currency, view_format: :order, total: @order.total

- if @order.invoice?
  %p= t('orders.show.invoice.true')
  - if @order.billing_address
    %h4= t('orders.show.billing_address')
    = render @order.billing_address

- else
  %p= t('orders.show.invoice.false')

%p= t("orders.show.polish_taxpayer.#{@order.polish_taxpayer}")
 
- unless @order.paid?
  = link_to fa_icon('credit-card', text: 'Przejdź do płatności'), order_payment_path(@order), class: 'button'
  = link_to fa_icon('ban', text: 'Anuluj zamówienie'), @order, method: :delete, class: 'button dark-red-bg'
  - if admin_user_signed_in?
    = link_to fa_icon('lock', text: "Oznacz jako opłacone"), mark_paid_admin_order_path(@order), class: 'button dark-green-bg', method: :patch
- else
  Zamówienie opłacone &mdash; nie możesz go zmodyfikować ani anulować.


Fix error in orders/show view
Fix error in orders/show view
