Correct the way we show vat error

This commit is contained in:
PCoder 2019-12-26 14:08:53 +05:30
parent ec5bfb18b3
commit 364f5599e6
2 changed files with 2 additions and 2 deletions

View file

@ -1,7 +1,7 @@
{% if messages %}
<ul class="list-unstyled msg-list">
{% for message in messages %}
<div class="alert {% if message.tags and message.tags == 'error' or message.tags and message.tags == 'vat_error' %} alert-danger {% else %} alert-{{message.tags}} {% endif %}">{{ message|safe }}</div>
<div class="alert {% if message.tags and message.tags == 'error' %} alert-danger {% else %} alert-{{message.tags}} {% endif %}">{{ message|safe }}</div>
{% endfor %}
</ul>
{% endif %}

View file

@ -644,7 +644,7 @@ class SettingsView(LoginRequiredMixin, FormView):
messages.add_message(
request, messages.ERROR,
"VAT Number validation error: %s" % validate_result["error"],
extra_tags='vat_error'
extra_tags='error'
)
else:
msg = _("Billing address updated successfully")