Ver código fonte

[Backend] User : correctif avoirs

develop
Guillaume 3 anos atrás
pai
commit
b2811bf31c
1 arquivos alterados com 21 adições e 18 exclusões
  1. +21
    -18
      ShopBundle/Resources/views/backend/default/block/macros.html.twig

+ 21
- 18
ShopBundle/Resources/views/backend/default/block/macros.html.twig Ver arquivo

@@ -332,6 +332,7 @@


{% macro list_reduction_credits(reductionCredits, user) %}
{% set merchant_current = merchantUtils.getMerchantCurrent() %}
<table class="table table-condensed">
<thead>
<tr>
@@ -344,24 +345,26 @@
</thead>
<tbody>
{% for reductionCredit in reductionCredits %}
{% set isUsed = orderUtils.isReductionCreditUsed(reductionCredit, user) %}
<tr>
<td>{{ reductionCredit.title }}</td>
<td>
{{ reductionCredit.value|format_price(false) }}
</td>
<td>
{% include '@EasyAdmin/default/field_boolean.html.twig' with {value: reductionCredit.status} %}
</td>
<td>
{% include '@EasyAdmin/default/field_boolean.html.twig' with {value: isUsed} %}
</td>
<td>
{% if isUsed == false %}
{{ _self.button('ReductionCredit', 'edit', reductionCredit.id, 'primary') }}
{% endif %}
</td>
</tr>
{% if reductionCredit.getMerchant() == merchant_current %}
{% set isUsed = orderUtils.isReductionCreditUsed(reductionCredit, user) %}
<tr>
<td>{{ reductionCredit.title }}</td>
<td>
{{ reductionCredit.value|format_price(false) }}
</td>
<td>
{% include '@EasyAdmin/default/field_boolean.html.twig' with {value: reductionCredit.status} %}
</td>
<td>
{% include '@EasyAdmin/default/field_boolean.html.twig' with {value: isUsed} %}
</td>
<td>
{% if isUsed == false %}
{{ _self.button('ReductionCredit', 'edit', reductionCredit.id, 'primary') }}
{% endif %}
</td>
</tr>
{% endif %}
{% endfor %}
</tbody>
</table>

Carregando…
Cancelar
Salvar