{% extends 'VGMWOBundle::layout.html.twig' %}
{% block jumbotron_content %}
    <div class="jumbotron" style="padding-top: 10px; padding-bottom: 5px;"  id="jumbotron">
        <div class="container-fluid">
            <div class="col-md-12 text-center" style="padding-left: 0px;">
                <H3 style="margin: 0px;"><strong>Create departments</strong></H3>
            </div>
        </div>
    </div>
{% endblock %}
{% block content %}
    <div class="container" style="min-height: 500px;">
        <div class="col-md-12 text-right">
            <div class="col-ms-2 pull-right">
                <a href="{{ path('vgm_departments') }}">
                    <span class="glyphicon glyphicon-list"></span>
                    Main list
                </a>
            </div>
        </div>
        {{ form_start(edit_form) }}
        {{ form_errors(edit_form) }}
        <div class="container-fluid">
            <div class="col-lg-12">
                <label class="form-label">Parent:</label>
                {{ form_widget(edit_form.parent, { 'attr': {
                'tabindex' : 1,
                'class': 'form-control for-desktop',
                'placeholder': 'Parent'} }) }}
            </div>
            <div class="col-lg-12">
                <label class="form-label" style="margin-top: 10px;">Unit name:</label>
                {{ form_widget(edit_form.name, { 'attr': {
                'tabindex' : 2,
                'class': 'form-control for-desktop',
                'placeholder': 'Unit Name'} }) }}
            </div>
            <div class="col-lg-12">
                <label class="form-label" style="margin-top: 10px;">Street:</label>
                {{ form_widget(edit_form.adrees, { 'attr': {
                'tabindex' : 3,
                'class': 'form-control for-desktop',
                'placeholder': 'Street'} }) }}
            </div>
            <div class="col-lg-4">
                <label class="form-label" style="margin-top: 10px;">City:</label>
                {{ form_widget(edit_form.city, { 'attr': {
                'tabindex' : 4,
                'class': 'form-control for-desktop',
                'placeholder': 'City'} }) }}
            </div>
            <div class="col-lg-4">
                <label class="form-label" style="margin-top: 10px;">Zip code:</label>
                {{ form_widget(edit_form.zip_code, { 'attr': {
                'tabindex' : 5,
                'class': 'form-control for-desktop',
                'placeholder': 'Zip code'} }) }}
            </div>
            <div class="col-lg-4">
                <label class="form-label" style="margin-top: 10px;">State:</label>
                {{ form_widget(edit_form.state, { 'attr': {
                'tabindex' : 6,
                'class': 'form-control for-desktop',
                'placeholder': 'Sate'} }) }}
            </div>
            <div class="col-lg-12">
                <label class="form-label" style="margin-top: 10px;">Main phone:</label>
                {{ form_widget(edit_form.phone1, { 'attr': {
                'tabindex' : 7,
                'class': 'form-control for-desktop',
                'placeholder': 'Main phone'} }) }}
            </div>
            <div class="col-lg-12">
                <label class="form-label" style="margin-top: 10px;">Aux phone:</label>
                {{ form_widget(edit_form.phone2, { 'attr': {
                'tabindex' : 8,
                'class': 'form-control for-desktop',
                'placeholder': 'Aux phone'} }) }}
            </div>
        </div>
        <div class="container-fluid" style="margin-top: 10px;">
            <div class="col-lg-12 container-fluid text-right">
                <button class="btn btn-primary"
                        type="submit">
                    Update
                </button>
                <a class="btn btn-warning"
                   href="{{ path('units') }}">
                    Cancel
                </a>
            </div>
        </div>
        {{ form_end(edit_form) }}
    </div>
{% endblock %}
