var/cache/dev/twig/22/226184b8b2e8e366567405a18e708e8e.php line 33

  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* app/payment/_table.html.twig */
  14. class __TwigTemplate_9d864ff3c78cde1a33f65d9cefec6cb2 extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->parent false;
  23.         $this->blocks = [
  24.         ];
  25.     }
  26.     protected function doDisplay(array $context, array $blocks = [])
  27.     {
  28.         $macros $this->macros;
  29.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  30.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""app/payment/_table.html.twig"));
  31.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  32.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""app/payment/_table.html.twig"));
  33.         // line 1
  34.         echo "<table
  35.   id=\"datatable\"
  36.   class=\"table table-bordered dt-responsive nowrap w-100\"
  37.   data-controller=\"payment\"
  38. >
  39.   <thead>
  40.     <tr>
  41.       <th>#</th>
  42.       <th>";
  43.         // line 9
  44.         echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Payé par", [], "messages");
  45.         echo "</th>
  46.       <th>";
  47.         // line 10
  48.         echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Abonnement", [], "messages");
  49.         echo "</th>
  50.       <th>";
  51.         // line 11
  52.         echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Date", [], "messages");
  53.         echo "</th>
  54.       <th>";
  55.         // line 12
  56.         echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Montant", [], "messages");
  57.         echo "</th>
  58.       <th>";
  59.         // line 13
  60.         echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Collecté par", [], "messages");
  61.         echo "</th>
  62.       <th width=\"220px\">";
  63.         // line 14
  64.         echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Actions", [], "messages");
  65.         echo "</th>
  66.     </tr>
  67.   </thead>
  68.   <tbody>
  69.     ";
  70.         // line 18
  71.         $context['_parent'] = $context;
  72.         $context['_seq'] = twig_ensure_traversable((isset($context["payments"]) || array_key_exists("payments"$context) ? $context["payments"] : (function () { throw new RuntimeError('Variable "payments" does not exist.'18$this->source); })()));
  73.         $context['loop'] = [
  74.           'parent' => $context['_parent'],
  75.           'index0' => 0,
  76.           'index'  => 1,
  77.           'first'  => true,
  78.         ];
  79.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  80.             $length count($context['_seq']);
  81.             $context['loop']['revindex0'] = $length 1;
  82.             $context['loop']['revindex'] = $length;
  83.             $context['loop']['length'] = $length;
  84.             $context['loop']['last'] = === $length;
  85.         }
  86.         foreach ($context['_seq'] as $context["_key"] => $context["payment"]) {
  87.             // line 19
  88.             echo "    <tr>
  89.       <th scope=\"row\">
  90.         ";
  91.             // line 21
  92.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse21), "html"nulltrue);
  93.             echo "
  94.       </th>
  95.       <td>
  96.         <div class=\"d-flex align-items-center\">
  97.           <div class=\"flex-shrink-0 me-3\">
  98.             <img
  99.               class=\"rounded-circle avatar-md\"
  100.               src=\"";
  101.             // line 28
  102.             ((twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "payedBy", [], "any"falsefalsefalse28), "photo", [], "any"falsefalsefalse28)) ? (print (twig_escape_filter($this->env, ("/uploads/family_members/" twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "payedBy", [], "any"falsefalsefalse28), "photo", [], "any"falsefalsefalse28)), "html"nulltrue))) : (print ("/front/images/family.png")));
  103.             echo "\"
  104.               alt=\"";
  105.             // line 29
  106.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "payedBy", [], "any"falsefalsefalse29), "firstName", [], "any"falsefalsefalse29), "html"nulltrue);
  107.             echo " ";
  108.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source,             // line 30
  109. $context["payment"], "payedBy", [], "any"falsefalsefalse30), "lastName", [], "any"falsefalsefalse30), "html"nulltrue);
  110.             // line 31
  111.             echo "\"
  112.             />
  113.           </div>
  114.           <div class=\"flex-grow-1\">
  115.             <a
  116.               href=\"";
  117.             // line 36
  118.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_family_member_show", ["id" => twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source,             // line 37
  119. $context["payment"], "payedBy", [], "any"falsefalsefalse37), "id", [], "any"falsefalsefalse37)]), "html"nulltrue);
  120.             // line 38
  121.             echo "\"
  122.             >
  123.               <h5 class=\"font-size-14 mb-0\">
  124.                 ";
  125.             // line 41
  126.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "payedBy", [], "any"falsefalsefalse41), "firstName", [], "any"falsefalsefalse41), "html"nulltrue);
  127.             echo "
  128.                 ";
  129.             // line 42
  130.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "payedBy", [], "any"falsefalsefalse42), "lastName", [], "any"falsefalsefalse42), "html"nulltrue);
  131.             echo "
  132.               </h5>
  133.             </a>
  134.           </div>
  135.         </div>
  136.       </td>
  137.       <td>
  138.         ";
  139.             // line 51
  140.             ((twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "subscription", [], "any"falsefalsefalse51), "service", [], "any"falsefalsefalse51)) ? (print (twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "subscription", [], "any"falsefalsefalse51), "service", [], "any"falsefalsefalse51), "name", [], "any"falsefalsefalse51), "html"nulltrue))) : (print ("")));
  141.             // line 52
  142.             echo "
  143.         -
  144.         ";
  145.             // line 57
  146.             ((twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source,             // line 55
  147. $context["payment"], "subscription", [], "any"falsefalsefalse55), "service", [], "any"falsefalsefalse55)) ? (print (twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source,             // line 56
  148. $context["payment"], "subscription", [], "any"falsefalsefalse56), "service", [], "any"falsefalsefalse56), "duration", [], "any"falsefalsefalse56), "html"nulltrue))) : (print ("")));
  149.             // line 58
  150.             echo "
  151.         ";
  152.             // line 59
  153.             echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Jours", [], "messages");
  154.             // line 60
  155.             echo "        <br />
  156.         <b> ";
  157.             // line 61
  158.             echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Prix", [], "messages");
  159.             echo " : </b>
  160.         <span class=\"text-info\"
  161.           >";
  162.             // line 63
  163.             echo twig_escape_filter($this->envtwig_number_format_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "subscription", [], "any"falsefalsefalse63), "total", [], "any"falsefalsefalse63), 0"."" "), "html"nulltrue);
  164.             echo "
  165.           ";
  166.             // line 64
  167.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["company"]) || array_key_exists("company"$context) ? $context["company"] : (function () { throw new RuntimeError('Variable "company" does not exist.'64$this->source); })()), "currencie", [], "any"falsefalsefalse64), "html"nulltrue);
  168.             echo "
  169.         </span>
  170.         /
  171.         <b> ";
  172.             // line 67
  173.             echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Remise", [], "messages");
  174.             echo " : </b>
  175.         <span class=\"text-info\"
  176.           >";
  177.             // line 69
  178.             echo twig_escape_filter($this->envtwig_number_format_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["payment"], "subscription", [], "any"falsefalsefalse69), "discount", [], "any"falsefalsefalse69), 0"."" "), "html"nulltrue);
  179.             echo "
  180.           ";
  181.             // line 70
  182.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["company"]) || array_key_exists("company"$context) ? $context["company"] : (function () { throw new RuntimeError('Variable "company" does not exist.'70$this->source); })()), "currencie", [], "any"falsefalsefalse70), "html"nulltrue);
  183.             echo "
  184.         </span>
  185.       </td>
  186.       <td>
  187.         ";
  188.             // line 74
  189.             ((twig_get_attribute($this->env$this->source$context["payment"], "date", [], "any"falsefalsefalse74)) ? (print (twig_escape_filter($this->envtwig_date_format_filter($this->envtwig_get_attribute($this->env$this->source$context["payment"], "date", [], "any"falsefalsefalse74), "d-m-Y"), "html"nulltrue))) : (print ("")));
  190.             echo "
  191.       </td>
  192.       <td>
  193.         <b> ";
  194.             // line 77
  195.             echo $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Total", [], "messages");
  196.             echo " : </b>
  197.         <span class=\"text-info\"
  198.           >";
  199.             // line 79
  200.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["payment"], "amount", [], "any"falsefalsefalse79), "html"nulltrue);
  201.             echo "
  202.           ";
  203.             // line 80
  204.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["company"]) || array_key_exists("company"$context) ? $context["company"] : (function () { throw new RuntimeError('Variable "company" does not exist.'80$this->source); })()), "currencie", [], "any"falsefalsefalse80), "html"nulltrue);
  205.             echo "
  206.         </span>
  207.         <br />
  208.       </td>
  209.       <td>
  210.         ";
  211.             // line 85
  212.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["payment"], "createdBy", [], "any"falsefalsefalse85), "html"nulltrue);
  213.             echo "
  214.       </td>
  215.       <td>
  216.         <a
  217.           data-action=\"payment#edit\"
  218.           data-payment-id=\"";
  219.             // line 90
  220.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["payment"], "id", [], "any"falsefalsefalse90), "html"nulltrue);
  221.             echo "\"
  222.           href=\"javascript:void(0)\"
  223.           class=\"btn btn-info waves-effect waves-light me-2\"
  224.           data-toggle=\"tooltip\"
  225.           data-placement=\"top\"
  226.           title=\"";
  227.             // line 95
  228.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Modifier"), "html"nulltrue);
  229.             echo "\"
  230.         >
  231.           <i class=\"bx bx-edit font-size-16 align-middle\"></i>
  232.         </a>
  233.         <a
  234.           data-action=\"payment#del\"
  235.           data-payment-id=\"";
  236.             // line 102
  237.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["payment"], "id", [], "any"falsefalsefalse102), "html"nulltrue);
  238.             echo "\"
  239.           data-payment-token=\"";
  240.             // line 103
  241.             echo twig_escape_filter($this->env$this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderCsrfToken(("delete" twig_get_attribute($this->env$this->source$context["payment"], "id", [], "any"falsefalsefalse103))), "html"nulltrue);
  242.             echo "\"
  243.           href=\"javascript:void(0)\"
  244.           class=\"btn btn-danger waves-effect waves-light me-2\"
  245.           data-toggle=\"tooltip\"
  246.           data-placement=\"top\"
  247.           title=\"";
  248.             // line 108
  249.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Supprimer"), "html"nulltrue);
  250.             echo "\"
  251.         >
  252.           <i class=\"bx bx-trash font-size-16 align-middle\"></i>
  253.         </a>
  254.         ";
  255.             // line 137
  256.             echo "      </td>
  257.     </tr>
  258.     ";
  259.             ++$context['loop']['index0'];
  260.             ++$context['loop']['index'];
  261.             $context['loop']['first'] = false;
  262.             if (isset($context['loop']['length'])) {
  263.                 --$context['loop']['revindex0'];
  264.                 --$context['loop']['revindex'];
  265.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  266.             }
  267.         }
  268.         $_parent $context['_parent'];
  269.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['payment'], $context['_parent'], $context['loop']);
  270.         $context array_intersect_key($context$_parent) + $_parent;
  271.         // line 140
  272.         echo "  </tbody>
  273. </table>
  274. ";
  275.         
  276.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  277.         
  278.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  279.     }
  280.     /**
  281.      * @codeCoverageIgnore
  282.      */
  283.     public function getTemplateName()
  284.     {
  285.         return "app/payment/_table.html.twig";
  286.     }
  287.     /**
  288.      * @codeCoverageIgnore
  289.      */
  290.     public function isTraitable()
  291.     {
  292.         return false;
  293.     }
  294.     /**
  295.      * @codeCoverageIgnore
  296.      */
  297.     public function getDebugInfo()
  298.     {
  299.         return array (  283 => 140,  267 => 137,  260 => 108,  252 => 103,  248 => 102,  238 => 95,  230 => 90,  222 => 85,  214 => 80,  210 => 79,  205 => 77,  199 => 74,  192 => 70,  188 => 69,  183 => 67,  177 => 64,  173 => 63,  168 => 61,  165 => 60,  163 => 59,  160 => 58,  158 => 56,  157 => 55,  156 => 57,  152 => 52,  150 => 51,  139 => 42,  135 => 41,  130 => 38,  128 => 37,  127 => 36,  120 => 31,  118 => 30,  115 => 29,  111 => 28,  101 => 21,  97 => 19,  80 => 18,  73 => 14,  69 => 13,  65 => 12,  61 => 11,  57 => 10,  53 => 9,  43 => 1,);
  300.     }
  301.     public function getSourceContext()
  302.     {
  303.         return new Source("<table
  304.   id=\"datatable\"
  305.   class=\"table table-bordered dt-responsive nowrap w-100\"
  306.   data-controller=\"payment\"
  307. >
  308.   <thead>
  309.     <tr>
  310.       <th>#</th>
  311.       <th>{% trans %} Payé par {% endtrans %}</th>
  312.       <th>{% trans %} Abonnement {% endtrans %}</th>
  313.       <th>{% trans %} Date {% endtrans %}</th>
  314.       <th>{% trans %} Montant {% endtrans %}</th>
  315.       <th>{% trans %} Collecté par {% endtrans %}</th>
  316.       <th width=\"220px\">{% trans %} Actions {% endtrans %}</th>
  317.     </tr>
  318.   </thead>
  319.   <tbody>
  320.     {% for payment in payments %}
  321.     <tr>
  322.       <th scope=\"row\">
  323.         {{ loop.index }}
  324.       </th>
  325.       <td>
  326.         <div class=\"d-flex align-items-center\">
  327.           <div class=\"flex-shrink-0 me-3\">
  328.             <img
  329.               class=\"rounded-circle avatar-md\"
  330.               src=\"{{ payment.payedBy.photo ? '/uploads/family_members/' ~ payment.payedBy.photo : '/front/images/family.png' }}\"
  331.               alt=\"{{ payment.payedBy.firstName }} {{
  332.                 payment.payedBy.lastName
  333.               }}\"
  334.             />
  335.           </div>
  336.           <div class=\"flex-grow-1\">
  337.             <a
  338.               href=\"{{
  339.                 path('app_family_member_show', { id: payment.payedBy.id })
  340.               }}\"
  341.             >
  342.               <h5 class=\"font-size-14 mb-0\">
  343.                 {{ payment.payedBy.firstName }}
  344.                 {{ payment.payedBy.lastName }}
  345.               </h5>
  346.             </a>
  347.           </div>
  348.         </div>
  349.       </td>
  350.       <td>
  351.         {{
  352.           payment.subscription.service ? payment.subscription.service.name : \"\"
  353.         }}
  354.         -
  355.         {{
  356.           payment.subscription.service
  357.             ? payment.subscription.service.duration
  358.             : \"\"
  359.         }}
  360.         {% trans %} Jours {% endtrans %}
  361.         <br />
  362.         <b> {% trans %} Prix {% endtrans %} : </b>
  363.         <span class=\"text-info\"
  364.           >{{ payment.subscription.total|number_format(0, '.', ' ') }}
  365.           {{ company.currencie }}
  366.         </span>
  367.         /
  368.         <b> {% trans %} Remise {% endtrans %} : </b>
  369.         <span class=\"text-info\"
  370.           >{{ payment.subscription.discount|number_format(0, '.', ' ') }}
  371.           {{ company.currencie }}
  372.         </span>
  373.       </td>
  374.       <td>
  375.         {{ payment.date ? payment.date|date('d-m-Y') : '' }}
  376.       </td>
  377.       <td>
  378.         <b> {% trans %} Total {% endtrans %} : </b>
  379.         <span class=\"text-info\"
  380.           >{{ payment.amount }}
  381.           {{ company.currencie }}
  382.         </span>
  383.         <br />
  384.       </td>
  385.       <td>
  386.         {{ payment.createdBy }}
  387.       </td>
  388.       <td>
  389.         <a
  390.           data-action=\"payment#edit\"
  391.           data-payment-id=\"{{ payment.id }}\"
  392.           href=\"javascript:void(0)\"
  393.           class=\"btn btn-info waves-effect waves-light me-2\"
  394.           data-toggle=\"tooltip\"
  395.           data-placement=\"top\"
  396.           title=\"{{ 'Modifier' | trans }}\"
  397.         >
  398.           <i class=\"bx bx-edit font-size-16 align-middle\"></i>
  399.         </a>
  400.         <a
  401.           data-action=\"payment#del\"
  402.           data-payment-id=\"{{ payment.id }}\"
  403.           data-payment-token=\"{{ csrf_token('delete' ~ payment.id) }}\"
  404.           href=\"javascript:void(0)\"
  405.           class=\"btn btn-danger waves-effect waves-light me-2\"
  406.           data-toggle=\"tooltip\"
  407.           data-placement=\"top\"
  408.           title=\"{{ 'Supprimer' | trans }}\"
  409.         >
  410.           <i class=\"bx bx-trash font-size-16 align-middle\"></i>
  411.         </a>
  412.         {#
  413.         <form
  414.           style=\"display: contents\"
  415.           id=\"delete-form\"
  416.           method=\"post\"
  417.           action=\"{{ path('app_payment_delete', { id: payment.id }) }}\"
  418.           onclick=\"alertify.set('notifier','position', 'top-right'); alertify.confirm('Supprimer', 'Voulez-vous vraiment supprimer cet objet?', function(e){ document.getElementById('delete-form').submit(); }, function(){ alertify.error('Annuler')});\"
  419.         >
  420.           <input
  421.             type=\"hidden\"
  422.             name=\"_token\"
  423.             value=\"{{ csrf_token('delete' ~ payment.id) }}\"
  424.           />
  425.           <a
  426.             href=\"javascript:void(0);\"
  427.             type=\"button\"
  428.             class=\"btn btn-danger waves-effect waves-light me-2\"
  429.             data-toggle=\"tooltip\"
  430.             data-placement=\"top\"
  431.             title=\"{{ 'Supprimer' | trans }}\"
  432.           >
  433.             <i class=\"bx bx-trash font-size-16 align-middle\"></i>
  434.           </a>
  435.         </form>
  436.         #}
  437.       </td>
  438.     </tr>
  439.     {% endfor %}
  440.   </tbody>
  441. </table>
  442. ""app/payment/_table.html.twig""/var/www/clevernursery.com/templates/app/payment/_table.html.twig");
  443.     }
  444. }