<?php

use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;

/* platform/ags/editLineItem.html.twig */
class __TwigTemplate_a9dbd9f981ffbc5f4b2a3d8750b08a4a056877bee9f19ffcf22479baac02f554 extends Template
{
    private $source;
    private $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'nav_title' => [$this, 'block_nav_title'],
            'body' => [$this, 'block_body'],
        ];
    }

    protected function doGetParent(array $context)
    {
        // line 1
        return "base.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = [])
    {
        $macros = $this->macros;
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "platform/ags/editLineItem.html.twig"));

        $this->parent = $this->loadTemplate("base.html.twig", "platform/ags/editLineItem.html.twig", 1);
        $this->parent->display($context, array_merge($this->blocks, $blocks));
        
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);

    }

    // line 3
    public function block_nav_title($context, array $blocks = [])
    {
        $macros = $this->macros;
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "nav_title"));

        echo "<i class=\"fas fa-graduation-cap\"></i>&nbsp;&nbsp;<span class=\"text-danger\">Platform</span> - AGS line item edition";
        
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);

    }

    // line 5
    public function block_body($context, array $blocks = [])
    {
        $macros = $this->macros;
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "body"));

        // line 6
        echo "<div class=\"card bg-light\">
    <div class=\"card-header\">
        <i class=\"fas fa-graduation-cap\"></i>&nbsp;Edit line item <code>";
        // line 8
        echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["lineItem"]) || array_key_exists("lineItem", $context) ? $context["lineItem"] : (function () { throw new RuntimeError('Variable "lineItem" does not exist.', 8, $this->source); })()), "identifier", [], "any", false, false, false, 8), "html", null, true);
        echo "</code>
    </div>
    <div id=\"collapseForm\" class=\"collapse card-body  ";
        // line 10
        echo ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 10, $this->source); })()), "vars", [], "any", false, false, false, 10), "submitted", [], "any", false, false, false, 10)) ? ("") : ("show"));
        echo "\" role=\"tabpanel\" aria-labelledby=\"headingForm\" data-parent=\"#accordionForm\">
        ";
        // line 11
        echo         $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 11, $this->source); })()), 'form_start');
        echo "
        ";
        // line 12
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 12, $this->source); })()), 'errors');
        echo "
        <div class=\"form-row\">
            <div class=\"col-md-8\">
                ";
        // line 15
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 15, $this->source); })()), "line_item_id", [], "any", false, false, false, 15), 'row');
        echo "
            </div>
            <div class=\"col-md-4\">
                ";
        // line 18
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 18, $this->source); })()), "line_item_label", [], "any", false, false, false, 18), 'row');
        echo "
            </div>
        </div>
        <div class=\"form-row\">
            <div class=\"col-md-4\">
                ";
        // line 23
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 23, $this->source); })()), "line_item_score_maximum", [], "any", false, false, false, 23), 'row');
        echo "
            </div>
            <div class=\"col-md-4\">
                ";
        // line 26
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 26, $this->source); })()), "line_item_resource_id", [], "any", false, false, false, 26), 'row');
        echo "
            </div>
            <div class=\"col-md-4\">
                ";
        // line 29
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 29, $this->source); })()), "line_item_resource_link_id", [], "any", false, false, false, 29), 'row');
        echo "
            </div>
        </div>
        <div class=\"form-row\">
            <div class=\"col-md-4\">
                ";
        // line 34
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 34, $this->source); })()), "line_item_tag", [], "any", false, false, false, 34), 'row');
        echo "
            </div>
            <div class=\"col-md-4\">
                <div class=\"form-group\">
                    ";
        // line 38
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 38, $this->source); })()), "line_item_start_date", [], "any", false, false, false, 38), 'label');
        echo "
                    <div class=\"input-group\" id=\"lineItemStartDateTimeDatetimepicker\" data-target-input=\"nearest\">
                        <div class=\"input-group-prepend\">
                            <a class=\"btn btn-secondary text-white\" data-target=\"#lineItemStartDateTimeDatetimepicker\" data-toggle=\"datetimepicker\">
                                <i class=\"fas fa-calendar-day\" aria-hidden=\"true\"></i>
                            </a>
                        </div>
                        ";
        // line 45
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 45, $this->source); })()), "line_item_start_date", [], "any", false, false, false, 45), 'widget');
        echo "
                    </div>
                    ";
        // line 47
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 47, $this->source); })()), "line_item_start_date", [], "any", false, false, false, 47), 'help');
        echo "
                    ";
        // line 48
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 48, $this->source); })()), "line_item_start_date", [], "any", false, false, false, 48), 'errors');
        echo "
                </div>
            </div>
            <div class=\"col-md-4\">
                <div class=\"form-group\">
                    ";
        // line 53
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 53, $this->source); })()), "line_item_end_date", [], "any", false, false, false, 53), 'label');
        echo "
                    <div class=\"input-group\" id=\"lineItemEndDateTimeDatetimepicker\" data-target-input=\"nearest\">
                        <div class=\"input-group-prepend\">
                            <a class=\"btn btn-secondary text-white\" data-target=\"#lineItemEndDateTimeDatetimepicker\" data-toggle=\"datetimepicker\">
                                <i class=\"fas fa-calendar-day\" aria-hidden=\"true\"></i>
                            </a>
                        </div>
                        ";
        // line 60
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 60, $this->source); })()), "line_item_end_date", [], "any", false, false, false, 60), 'widget');
        echo "
                    </div>
                    ";
        // line 62
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 62, $this->source); })()), "line_item_end_date", [], "any", false, false, false, 62), 'help');
        echo "
                    ";
        // line 63
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 63, $this->source); })()), "line_item_end_date", [], "any", false, false, false, 63), 'errors');
        echo "
                </div>
            </div>
        </div>
        <div class=\"form-row\">
            <div class=\"col-md-12\">
                <div class=\"form-group\">
                    ";
        // line 70
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 70, $this->source); })()), "line_item_additional_properties", [], "any", false, false, false, 70), 'label');
        echo "<br/>
                    <div class=\"input-group\">
                        <div class=\"input-group-prepend\" role=\"group\" aria-label=\"Format additional properties\">
                            <div class=\"btn-group-vertical\" role=\"group\">
                                <button id=\"additionalPropertiesFormat\" type=\"button\" class=\"btn btn-secondary btn-block\" title=\"Format additional properties (JSON)\">
                                    <i class=\"fas fa-align-left\"></i>
                                </button>
                            </div>
                        </div>
                        ";
        // line 79
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 79, $this->source); })()), "line_item_additional_properties", [], "any", false, false, false, 79), 'widget');
        echo "
                    </div>
                    <div id=\"additionalPropertiesError\" class=\"invalid-feedback\">
                        Invalid additional properties, please provide a valid JSON representation
                    </div>
                    ";
        // line 84
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 84, $this->source); })()), "line_item_additional_properties", [], "any", false, false, false, 84), 'help');
        echo "
                    ";
        // line 85
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 85, $this->source); })()), "line_item_additional_properties", [], "any", false, false, false, 85), 'errors');
        echo "
                </div>
            </div>
        </div>
    </div>
    <div class=\"card-footer\">
        <div class=\"btn-group float-right\" role=\"group\" aria-label=\"Basic example\">
            ";
        // line 92
        echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 92, $this->source); })()), "submit", [], "any", false, false, false, 92), 'widget');
        echo "
            <a href=\"";
        // line 93
        echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("platform_ags_view_line_item", ["lineItemIdentifier" => $this->extensions['App\Twig\AppExtension']->base64UrlEncode(twig_get_attribute($this->env, $this->source, (isset($context["lineItem"]) || array_key_exists("lineItem", $context) ? $context["lineItem"] : (function () { throw new RuntimeError('Variable "lineItem" does not exist.', 93, $this->source); })()), "identifier", [], "any", false, false, false, 93))]), "html", null, true);
        echo "\" class=\"btn btn-secondary\"><i class=\"fas fa-undo-alt\"></i>&nbsp;Cancel</a>
        </div>
    </div>
    ";
        // line 96
        echo         $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 96, $this->source); })()), 'form_end');
        echo "
</div>
<script>
    \$(\"#lineItemStartDateTimeDatetimepicker\").datetimepicker({
        format: \"YYYY-MM-DD HH:mm\",
        allowInputToggle: true,
        buttons: {
            showToday: true,
            showClear: true,
            showClose: true
        }
    });
    \$(\"#lineItemEndDateTimeDatetimepicker\").datetimepicker({
        format: \"YYYY-MM-DD HH:mm\",
        allowInputToggle: true,
        buttons: {
            showToday: true,
            showClear: true,
            showClose: true
        }
    });

    function checkAdditionalProperties() {
        try {
            if (\$(\"#line_item_line_item_additional_properties\").val() != '') {
                \$(\"#line_item_line_item_additional_properties\").val(
                    JSON.stringify(JSON.parse(\$(\"#line_item_line_item_additional_properties\").val()), undefined, 4)
                );
                \$(\"#line_item_line_item_additional_properties\").removeClass('is-invalid');
                \$(\"#line_item_line_item_additional_properties\").addClass('is-valid');
            } else {
                \$(\"#line_item_line_item_additional_properties\").removeClass('is-invalid');
                \$(\"#line_item_line_item_additional_properties\").removeClass('is-valid');
            }
            \$('#additionalPropertiesError').hide();
        } catch(e) {
            \$(\"#line_item_line_item_additional_properties\").removeClass('is-valid');
            \$(\"#line_item_line_item_additional_properties\").addClass('is-invalid');
            \$('#additionalPropertiesError').show();
        }
    }

    \$(\"#additionalPropertiesFormat\").click(function(event){
        checkAdditionalProperties();
    });

    \$('form[name=line_item]').submit(function (evt) {
        checkAdditionalProperties();
        try {
            JSON.parse(\$(\"#line_item_line_item_additional_properties\").val() || \"{}\");
            return;
        } catch(e) {
            evt.preventDefault();
        }
    });

    \$( document ).ready(function() {
        checkAdditionalProperties();
    });
</script>
";
        
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);

    }

    public function getTemplateName()
    {
        return "platform/ags/editLineItem.html.twig";
    }

    public function isTraitable()
    {
        return false;
    }

    public function getDebugInfo()
    {
        return array (  237 => 96,  231 => 93,  227 => 92,  217 => 85,  213 => 84,  205 => 79,  193 => 70,  183 => 63,  179 => 62,  174 => 60,  164 => 53,  156 => 48,  152 => 47,  147 => 45,  137 => 38,  130 => 34,  122 => 29,  116 => 26,  110 => 23,  102 => 18,  96 => 15,  90 => 12,  86 => 11,  82 => 10,  77 => 8,  73 => 6,  66 => 5,  53 => 3,  36 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("{% extends 'base.html.twig' %}

{% block nav_title %}<i class=\"fas fa-graduation-cap\"></i>&nbsp;&nbsp;<span class=\"text-danger\">Platform</span> - AGS line item edition{% endblock %}

{% block body %}
<div class=\"card bg-light\">
    <div class=\"card-header\">
        <i class=\"fas fa-graduation-cap\"></i>&nbsp;Edit line item <code>{{ lineItem.identifier }}</code>
    </div>
    <div id=\"collapseForm\" class=\"collapse card-body  {{ form.vars.submitted ? '' : 'show' }}\" role=\"tabpanel\" aria-labelledby=\"headingForm\" data-parent=\"#accordionForm\">
        {{ form_start(form) }}
        {{ form_errors(form) }}
        <div class=\"form-row\">
            <div class=\"col-md-8\">
                {{ form_row(form.line_item_id) }}
            </div>
            <div class=\"col-md-4\">
                {{ form_row(form.line_item_label) }}
            </div>
        </div>
        <div class=\"form-row\">
            <div class=\"col-md-4\">
                {{ form_row(form.line_item_score_maximum) }}
            </div>
            <div class=\"col-md-4\">
                {{ form_row(form.line_item_resource_id) }}
            </div>
            <div class=\"col-md-4\">
                {{ form_row(form.line_item_resource_link_id) }}
            </div>
        </div>
        <div class=\"form-row\">
            <div class=\"col-md-4\">
                {{ form_row(form.line_item_tag) }}
            </div>
            <div class=\"col-md-4\">
                <div class=\"form-group\">
                    {{ form_label(form.line_item_start_date) }}
                    <div class=\"input-group\" id=\"lineItemStartDateTimeDatetimepicker\" data-target-input=\"nearest\">
                        <div class=\"input-group-prepend\">
                            <a class=\"btn btn-secondary text-white\" data-target=\"#lineItemStartDateTimeDatetimepicker\" data-toggle=\"datetimepicker\">
                                <i class=\"fas fa-calendar-day\" aria-hidden=\"true\"></i>
                            </a>
                        </div>
                        {{ form_widget(form.line_item_start_date) }}
                    </div>
                    {{ form_help(form.line_item_start_date) }}
                    {{ form_errors(form.line_item_start_date) }}
                </div>
            </div>
            <div class=\"col-md-4\">
                <div class=\"form-group\">
                    {{ form_label(form.line_item_end_date) }}
                    <div class=\"input-group\" id=\"lineItemEndDateTimeDatetimepicker\" data-target-input=\"nearest\">
                        <div class=\"input-group-prepend\">
                            <a class=\"btn btn-secondary text-white\" data-target=\"#lineItemEndDateTimeDatetimepicker\" data-toggle=\"datetimepicker\">
                                <i class=\"fas fa-calendar-day\" aria-hidden=\"true\"></i>
                            </a>
                        </div>
                        {{ form_widget(form.line_item_end_date) }}
                    </div>
                    {{ form_help(form.line_item_end_date) }}
                    {{ form_errors(form.line_item_end_date) }}
                </div>
            </div>
        </div>
        <div class=\"form-row\">
            <div class=\"col-md-12\">
                <div class=\"form-group\">
                    {{ form_label(form.line_item_additional_properties) }}<br/>
                    <div class=\"input-group\">
                        <div class=\"input-group-prepend\" role=\"group\" aria-label=\"Format additional properties\">
                            <div class=\"btn-group-vertical\" role=\"group\">
                                <button id=\"additionalPropertiesFormat\" type=\"button\" class=\"btn btn-secondary btn-block\" title=\"Format additional properties (JSON)\">
                                    <i class=\"fas fa-align-left\"></i>
                                </button>
                            </div>
                        </div>
                        {{ form_widget(form.line_item_additional_properties) }}
                    </div>
                    <div id=\"additionalPropertiesError\" class=\"invalid-feedback\">
                        Invalid additional properties, please provide a valid JSON representation
                    </div>
                    {{ form_help(form.line_item_additional_properties) }}
                    {{ form_errors(form.line_item_additional_properties) }}
                </div>
            </div>
        </div>
    </div>
    <div class=\"card-footer\">
        <div class=\"btn-group float-right\" role=\"group\" aria-label=\"Basic example\">
            {{ form_widget(form.submit) }}
            <a href=\"{{ path('platform_ags_view_line_item', {'lineItemIdentifier': lineItem.identifier|base64_url_encode}) }}\" class=\"btn btn-secondary\"><i class=\"fas fa-undo-alt\"></i>&nbsp;Cancel</a>
        </div>
    </div>
    {{ form_end(form) }}
</div>
<script>
    \$(\"#lineItemStartDateTimeDatetimepicker\").datetimepicker({
        format: \"YYYY-MM-DD HH:mm\",
        allowInputToggle: true,
        buttons: {
            showToday: true,
            showClear: true,
            showClose: true
        }
    });
    \$(\"#lineItemEndDateTimeDatetimepicker\").datetimepicker({
        format: \"YYYY-MM-DD HH:mm\",
        allowInputToggle: true,
        buttons: {
            showToday: true,
            showClear: true,
            showClose: true
        }
    });

    function checkAdditionalProperties() {
        try {
            if (\$(\"#line_item_line_item_additional_properties\").val() != '') {
                \$(\"#line_item_line_item_additional_properties\").val(
                    JSON.stringify(JSON.parse(\$(\"#line_item_line_item_additional_properties\").val()), undefined, 4)
                );
                \$(\"#line_item_line_item_additional_properties\").removeClass('is-invalid');
                \$(\"#line_item_line_item_additional_properties\").addClass('is-valid');
            } else {
                \$(\"#line_item_line_item_additional_properties\").removeClass('is-invalid');
                \$(\"#line_item_line_item_additional_properties\").removeClass('is-valid');
            }
            \$('#additionalPropertiesError').hide();
        } catch(e) {
            \$(\"#line_item_line_item_additional_properties\").removeClass('is-valid');
            \$(\"#line_item_line_item_additional_properties\").addClass('is-invalid');
            \$('#additionalPropertiesError').show();
        }
    }

    \$(\"#additionalPropertiesFormat\").click(function(event){
        checkAdditionalProperties();
    });

    \$('form[name=line_item]').submit(function (evt) {
        checkAdditionalProperties();
        try {
            JSON.parse(\$(\"#line_item_line_item_additional_properties\").val() || \"{}\");
            return;
        } catch(e) {
            evt.preventDefault();
        }
    });

    \$( document ).ready(function() {
        checkAdditionalProperties();
    });
</script>
{% endblock body %}
", "platform/ags/editLineItem.html.twig", "C:\\wamp64\\www\\devkit-lti1p3-master-tool\\templates\\platform\\ags\\editLineItem.html.twig");
    }
}
