Contact update added

This commit is contained in:
Pinga 2023-12-05 11:42:10 +02:00
parent ae0c1ee158
commit 8a9de54510
2 changed files with 328 additions and 118 deletions

View file

@ -95,7 +95,7 @@
<label for="cc" class="form-label required">Country</label>
<select class="form-select" id="cc" name="cc" required="required">
{% for country in countries %}
<option value="{{ country.alpha2|lower }}" {% if postal_int.cc == country.alpha2 %}selected{% endif %}>{{ country.name }}</option>
<option value="{{ country.alpha2 }}" {% if postal_int.cc == country.alpha2 %}selected{% endif %}>{{ country.name }}</option>
{% endfor %}
</select>
</div>
@ -155,7 +155,7 @@
<!-- Personal or Business Checkbox -->
<div class="mb-3">
<div class="form-check">
<input type="checkbox" class="form-check-input" id="isBusiness" name="isBusiness">
<input type="checkbox" class="form-check-input" id="isBusiness" name="isBusiness" {% if contact.nin_type == 'business' %}checked{% endif %}>
<label class="form-check-label" for="isBusiness">This is a Business Contact</label>
</div>
<!-- You can invert the logic if you prefer the default to be 'Personal' instead of 'Business' -->
@ -251,7 +251,7 @@
<label for="locCC" class="form-label">Country</label>
<select class="form-select" id="locCC" name="locCC">
{% for country in countries %}
<option value="{{ country.alpha2|lower }}" {% if postal_loc.cc == country.alpha2 %}selected{% endif %}>{{ country.name }}</option>
<option value="{{ country.alpha2 }}" {% if postal_loc.cc == country.alpha2 %}selected{% endif %}>{{ country.name }}</option>
{% endfor %}
</select>
</div>