{% extends 'layout_frontend.html.twig' %}
{% block title %}{{ parent() }} {{ competition.name }}{% endblock %}
{% form_theme form 'shared/form/form_errors.html.twig' %}
{% block content %}
<!--Main Content Start-->
<div class="main-content innerpagebg wf100 p80">
<!--News Large Page Start-->
<!--Start-->
<div class="news-details">
<div class="container">
<div class="row">
<!--Event Start-->
<div class="col-lg-12">
{% include 'shared/dashboard/alerts.html.twig' %}
<div class="news-details-wrap">
<div class="news-large-post">
<div class="google-map">
<div class="google-map">
<div id="map-canvas"></div>
</div>
</div>
<div class="post-txt">
<h1>{{ competition.name }}</h1>
<ul class="post-meta">
<li><i class="fas fa-location-arrow"></i> {{ competition.event.name }}</li>
<li><i class="fas fa-map-marker-alt"></i> {{ competition.location }}</li>
<li><i class="fas fa-calendar-alt"></i> {{ competition.startDate|date('F j, Y') }}</li>
</ul>
{{ competition.description|raw }}
</div>
</div>
</div>
</div>
<!--Event End-->
</div>
<div class="row">
<div class="col-lg-12">
<div class="contact-two wf100 p40-0">
<!--Form Start-->
<div class="contact-form">
<h2>Register for the competition</h2>
<form class="form" method="POST" action="">
<ul class="form-row">
<li class="half-col">
{{ form_widget(form.name, {'attr': {'class': 'form-control', 'placeholder': 'Your Name'} }) }}
{{ form_errors(form.name) }}
</li>
<li class="half-col">
{{ form_widget(form.email, {'attr': {'class': 'form-control', 'placeholder': 'Email'} }) }}
{{ form_errors(form.email) }}
</li>
<li class="full-col">
{{ form_widget(form.phoneNumber, {'attr': {'class': 'form-control', 'placeholder': "Your phone number"} }) }}
{{ form_errors(form.phoneNumber) }}
</li>
<li class="full-col">
{{ form_widget(form.teamName, {'attr': {'class': 'form-control', 'placeholder': "Your team's name"} }) }}
{{ form_errors(form.teamName) }}
</li>
<li class="full-col">
{{ form_widget(form.message, {'attr': {'class': 'form-control', 'placeholder': 'Write your message'} }) }}
{{ form_errors(form.message) }}
</li>
<li class="full-col">
{{ form_widget(form.downPaymentAmount, {'attr': {'class': 'form-control', 'placeholder': 'Enter your down payment amount (min $' ~ competition.minimumDownPayment ~ ')'} }) }}
{{ form_errors(form.downPaymentAmount) }}
</li>
<li class="full-col recaptcha">
<div id="g-recaptcha" class="g-recaptcha" data-sitekey="{{ recaptcha_site_key }}"></div>
</li>
<li class="full-col">
{{ form_widget(form._token) }}
<button type="submit">Continue to down payment</button>
</li>
</ul>
</form>
</div>
<!--Form End-->
</div>
</div>
</div>
</div>
</div>
<!--End-->
</div>
<!--Main Content End-->
{% endblock %}
{% block page_javascripts %}
<script type="text/javascript">
$(document).ready(function () {
codeAddress("{{ competition.location }}");
});
</script>
{% endblock %}