Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4bfe3fb

Browse files
Merge pull request payplug#80 from synolia/fix/bo-oneclick-toggle-display
SYL-155 fix oneclick display side effect
2 parents cbe09de + 949bc78 commit 4bfe3fb

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

src/Resources/views/form/form_gateway_config_row.html.twig

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,10 @@
1414
{% endblock %}
1515

1616
{% block _sylius_payment_method_gatewayConfig_config_secretKey_row %}
17-
</div>{# close previous <div.two.fields> to avoid 2 columns #}
17+
{% set isOney = constant('PayPlug\\SyliusPayPlugPlugin\\Gateway\\PayPlugGatewayFactory::ONE_CLICK') not in form.parent.children|keys %}
18+
{% if isOney %}
19+
</div>{# close previous <div.two.fields> to avoid 2 columns #}
20+
{% endif %}
1821
<div class="{% if required %}required {% endif %}field{% if (not compound or force_error|default(false)) and not valid %} error{% endif %}">
1922
{{- form_label(form) -}}
2023
{{- form_widget(form) -}}
@@ -23,7 +26,9 @@
2326
</span>
2427
{{- form_errors(form) -}}
2528
</div>
26-
<div class="required field">
29+
{% if isOney %}
30+
<div class="required field">
31+
{% endif %}
2732
{% endblock %}
2833

2934
{% block _sylius_payment_method_gatewayConfig_config_fees_for_row %}

0 commit comments

Comments
 (0)