{% extends "SsoBackendBundle:WsApplicationAttribute:base.html.twig" %}
{% form_theme form with [':Forms:jquery.collection.html.twig', _self] %}
{% block title %}{{ parent() }} - New{% endblock %}

{% block _sso_backendbundle_webserviceapplicationattributes_attributeOptions_entry_row %}
    <div class="row">
        <div class="col-xs-4">
            {{ form_row(form.label) }}
        </div>
        <div class="col-xs-4">
            {{ form_row(form.value) }}
        </div>
        <div class="col-xs-4">
            <label class="control-label">&#160;</label>
            <div class="collection-actions">
                <a href="#" class="btn btn-default collection-add"><span class="glyphicon glyphicon-plus-sign"></span></a>
                <a href="#" class="btn btn-default collection-remove"><span class="glyphicon glyphicon-trash"></span></a>
                <a href="#" class="btn btn-default collection-up"><span class="glyphicon glyphicon-arrow-up"></span></a>
                <a href="#" class="btn btn-default collection-down"><span class="glyphicon glyphicon-arrow-down"></span></a>
            </div>
        </div>
    </div>
    {{ form_rest(form) }}
{% endblock %}

{% block body %}
    <h1>Create Attribute</h1>
    <div class="well clearfix">
        {{ form(form) }}
        <ul class="record_actions">
            <li>
                <a class="btn btn-success" href="{{ path('_admin_backend_webservice_application_attribute') }}">
                    Back to the list
                </a>
            </li>
        </ul>
    </div>
{% endblock %}

{% block javascripts %}
    {{ parent() }}
    <script>
        (function () {
            $(".form-collection").collection({
                add: '<a href="#" class="btn btn-default collection-add"><span class="glyphicon glyphicon-plus-sign"></span></a>',
                max: 10000
            });
        })();
    </script>
{% endblock %}
