{% set pcfields = 0 %}
{% for field in module_params['fields'] %}
{% if field.name!="id" and (field.type.name == "double" or field.type.name == "currency") %}
{% set pcfields = pcfields+1 %}
{% endif %}
{% endfor %}
{% if pcfields==0 %}
This module has no numeric/currency fields so the payment feature could not be used
{% else %}
Enable Payment:
{% if module_settings.payment.enabled is defined and module_settings.payment.enabled %}On{% else %}Off{% endif %}
Payment Currency Field:
{% if module_settings.payment.currency_field is defined and field_labels[module_settings.payment.currency_field] is defined %}
{% if field_labels[module_settings.payment.currency_field] is defined %}
{{field_labels[module_settings.payment.currency_field]|trans}}
{% else %}
{{module_settings.payment.currency_field|trans}}
{% endif %}
{% endif %}
Payment Amount Field:
{% if module_settings.payment.amount_field is defined %}
{{field_labels[module_settings.payment.amount_field]|trans}}
{% endif %}
{% include 'themes/default/config/module/condition-field.html' with { is_group: "true", condition_rows: module_settings.payment.show_conditions, f_label: "Show on Conditions", f_name: "show_conditions", f_group: "payment_settings"} %}
{% include 'themes/default/config/module/update-field.html' with { is_group: "true", condition_rows: module_settings.payment.update_success, f_label: "Update Fields On Success Payment", f_name: "update_success", f_group: "payment_settings"} %}
{% include 'themes/default/config/module/update-field.html' with { is_group: "true", condition_rows: module_settings.payment.update_cancel, f_label: "Update Fields On Cancel Payment", f_name: "update_cancel", f_group: "payment_settings"} %}