master
fefa4ka 9 years ago
parent c18fb103bf
commit 8987d10773
  1. 3
      djangocms_forms/forms.py
  2. 21
      zsite/static/less/consultation.less
  3. 17
      zsite/templates/form_template/consultation.html
  4. 14
      zsite/templates/form_template/order_modal.html

@ -323,6 +323,9 @@ class FormBuilder(forms.Form):
if data['name'] == 'phone' and data['value'] in ['4955331826', '123456']: if data['name'] == 'phone' and data['value'] in ['4955331826', '123456']:
return return
if data['name'] == 'message' and data['value']:
return
# Some contacts # Some contacts
if not send or len(contacts) == 0: if not send or len(contacts) == 0:
return return

@ -1,7 +1,7 @@
.modal-consultation, .consultation-form { .modal-consultation, .consultation-form {
@media (min-width: 0) { @media (min-width: 0) {
img { img {
display: none; display: none;
} }
@ -14,10 +14,10 @@
} }
} }
@media (min-width: @screen-tablet) { @media (min-width: @screen-tablet) {
img { img {
display: block; display: block;
float: left; float: left;
width: 30%; width: 30%;
margin-top: 60px; margin-top: 60px;
} }
@ -34,7 +34,7 @@
margin-top: 18px; margin-top: 18px;
} }
.help-text { .help-text {
margin-top: 10px; margin-top: 10px;
margin-bottom: 5px; margin-bottom: 5px;
@ -52,6 +52,11 @@
} }
.modal-consultation { .modal-consultation {
.form_message {
display: none;
}
.tabs-list { .tabs-list {
margin-left: -5px; margin-left: -5px;
margin-bottom: 5px; margin-bottom: 5px;
@ -90,11 +95,11 @@
} }
} }
} }
.consultation-person { .consultation-person {
.consultation-person-description { .consultation-person-description {
font-size: 12px; font-size: 12px;
@ -105,7 +110,7 @@
display: block; display: block;
} }
} }
.btn-consultation { .btn-consultation {
margin-bottom: 10px; margin-bottom: 10px;
margin-right: -13px; margin-right: -13px;

@ -22,7 +22,7 @@
<div class="form-errors" style="display:none;"></div> <div class="form-errors" style="display:none;"></div>
<div class="field-wrapper"> <div class="field-wrapper">
<label for="name"> <label for="name">
{% trans 'Name' %} {% trans 'Name' %}
</label> </label>
@ -34,7 +34,7 @@
<div id="contact-type" ng-tabs class="tabs-plugin"> <div id="contact-type" ng-tabs class="tabs-plugin">
<ul class="tabs-list list-unstyled list-inline"> <ul class="tabs-list list-unstyled list-inline">
<li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-phone">{% trans 'Call' %}</a></li> <li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-phone">{% trans 'Call' %}</a></li>
<li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-email">{% trans 'Email' %}</a> <li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-email">{% trans 'Email' %}</a>
</ul> </ul>
@ -68,9 +68,14 @@
{% endif %} {% endif %}
</div> </div>
{% csrf_token %} {% csrf_token %}
<div class="form_message">
{{ form.message }}
</div>
{% for hidden in form.hidden_fields %} {% for hidden in form.hidden_fields %}
{{ hidden }} {{ hidden }}
{% endfor %} {% endfor %}
@ -93,7 +98,7 @@
</div> </div>
</div> </div>
</div> </div>
</form> </form>
</div> </div>
@ -118,8 +123,8 @@
}); });
consultation_link = true; consultation_link = true;
} }
}); });
</script> </script>
{% endaddtoblock %} {% endaddtoblock %}

@ -26,7 +26,7 @@
<div class="form-errors" style="display:none;"></div> <div class="form-errors" style="display:none;"></div>
<div class="field-wrapper"> <div class="field-wrapper">
<label for="name"> <label for="name">
{% trans 'Name' %} {% trans 'Name' %}
</label> </label>
@ -38,7 +38,7 @@
<div id="contact-type" ng-tabs class="tabs-plugin"> <div id="contact-type" ng-tabs class="tabs-plugin">
<ul class="tabs-list list-unstyled list-inline"> <ul class="tabs-list list-unstyled list-inline">
<li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-phone">{% trans 'Call' %}</a></li> <li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-phone">{% trans 'Call' %}</a></li>
<li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-email">{% trans 'Email' %}</a> <li ng-tab-head="active"><a ng-click="$event.preventDefault()" href="#contact-email">{% trans 'Email' %}</a>
</ul> </ul>
@ -72,8 +72,10 @@
{% endif %} {% endif %}
</div> </div>
<div class="form_message">
{{ form.message }}
</div>
{% csrf_token %} {% csrf_token %}
{% for hidden in form.hidden_fields %} {% for hidden in form.hidden_fields %}
{{ hidden }} {{ hidden }}
@ -95,7 +97,7 @@
</div> </div>
</div> </div>
</div> </div>
</form> </form>
</div> </div>
@ -124,8 +126,8 @@
}); });
consultation_link = true; consultation_link = true;
} }
}); });
</script> </script>
{% endaddtoblock %} {% endaddtoblock %}

Loading…
Cancel
Save