- storing ||= f.object
- variant = Maybe(storing.parcel_item.variant)

.nested-fields.storing-fields
  = f.referenced_association :storage, source: :storage, label: false, input_html: { class: 'storing-storage', data: { required: true } }
  .storing-quantifier
    = f.input :quantity, label: false, wrapper: :append do
      = f.input_field :quantity, class: 'storing-quantity', placeholder: '0', data: { required: true }
      %span.add-on.item-population-unit-name
        = variant.unit_name.or_else('#')
  .act
    - if f.object.destroyable?
      = link_to_remove_association(content_tag(:i) + h(:destroy.tl), f, 'data-no-turbolink' => true, class: 'destroy remove remove-item')
- storing ||= f.object
- variant = Maybe(storing.parcel_item.variant)

.nested-fields.storing-fields
  = f.referenced_association :storage, source: :storage, label: false, input_html: { class: 'storing-storage', data: { required: true } }
  .storing-quantifier
    = f.input :quantity, label: false, wrapper: :append do
      = f.input_field :quantity, class: 'storing-quantity', placeholder: '0', data: { required: true }
      %span.add-on.item-population-unit-name
        = variant.unit_name.or_else('#')
  .nested-remove.act
    - if f.object.destroyable?
      = link_to_remove_association(content_tag(:i) + h(:destroy.tl), f, 'data-no-turbolink' => true, class: 'destroy remove remove-item')
Fix bug where we could remove a storage zone even if there was only one (despite it's allowed when there are 2 storage zone)
Fix bug where we could remove a storage zone even if there was only one (despite it's allowed when there are 2 storage zone)
