{#
* Plugin Name : ProductPlus
*
* Copyright (C) BraTech Co., Ltd. All Rights Reserved.
* http://www.bratech.co.jp/
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
#}
{% for ProductItem in ProductItems %}
{% set name = 'productplus_' ~ ProductItem.id %}
{% if ProductItem.input_type == constant('Plugin\\ProductPlus42\\Entity\\ProductItem::IMAGE_TYPE') %}
<div class="row">
<div class="col-3">
<div class="d-inline-block" data-tooltip="true" data-placement="top" title="{{ 'tooltip.product.image'|trans }}">
<span>{{ form[name].vars.label }}</span>
{% if form[name].vars.required %}
<span class="badge bg-primary ms-1">
{{ 'admin.common.required'|trans }}
</span>
{% endif %}
</div>
</div>
<div class="col mb-2">
<p id="message-{{ ProductItem.id }}"></p>
<div id="upload-zone-{{ ProductItem.id }}" class="media rounded">
<div class="media-body">
{{ form_widget(form[name], { attr : { style : 'display:none;' } }) }}
{{ form_errors(form[name]) }}
</div><!-- /.media-body -->
</div><!-- /.media -->
</div>
</div>
{% else %}
<div class="row" id="detail_box__productplus_{{ ProductItem.id }}">
<div class="col-3">
<div class="d-inline-block">
<span>{{ form[name].vars.label }}</span>
{% if form[name].vars.required %}
<span class="badge bg-primary ms-1">
{{ 'admin.common.required'|trans }}
</span>
{% endif %}
</div>
</div>
<div class="col mb-2">
<div>
{{ form_widget(form[name]) }}
{{ form_errors(form[name]) }}
</div>
</div>
</div>
{% endif %}
{% endfor %}