/
var
/
www
/
html
/
boazapp
/
var
/
cache
/
prod
/
twig
/
42
/
Upload File
HOME
<?php use Twig\Environment; use Twig\Error\LoaderError; use Twig\Error\RuntimeError; use Twig\Extension\CoreExtension; 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; /* cargo/depots.html.twig */ class __TwigTemplate_d9c23eb0007b4b9cc8afcb969134f0775c84707ff988c332560cfa77e554da8e extends Template { private $source; private $macros = []; public function __construct(Environment $env) { parent::__construct($env); $this->source = $this->getSourceContext(); $this->blocks = [ 'content' => [$this, 'block_content'], 'javascript' => [$this, 'block_javascript'], ]; } protected function doGetParent(array $context) { // line 1 return "base1.html.twig"; } protected function doDisplay(array $context, array $blocks = []) { $macros = $this->macros; $this->parent = $this->loadTemplate("base1.html.twig", "cargo/depots.html.twig", 1); yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks)); } // line 3 public function block_content($context, array $blocks = []) { $macros = $this->macros; // line 4 yield "\t<div class=\"content\"> \t <div class=\"container-fluid\"> \t <div class=\"row\"> \t <div class=\"col-md-12\"> \t <div class=\"card\"> \t <div class=\"header\" style=\"display:flex; align-items: center; justify-content: space-between\"> \t <h4 class=\"title\">Depot List</h4> <a href=\""; // line 11 yield $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("depot"); yield "\" class=\"btn btn-default\">Add New</a> \t </div> \t <div class=\"content table-responsive table-full-width\"> <table class=\"table table-hover\" data-page-length='100' style=\"table-layout: fixed;\"> <thead> <tr> \t\t\t\t\t\t\t <th>Name</th> \t\t\t\t\t\t\t <th>Location</th> \t\t\t\t\t\t\t <th>Actions</th> \t\t\t\t\t\t\t </tr> </thead> <tbody> "; // line 23 $context['_parent'] = $context; $context['_seq'] = CoreExtension::ensureTraversable(($context["depots"] ?? null)); foreach ($context['_seq'] as $context["_key"] => $context["item"]) { // line 24 yield "\t\t\t\t\t\t\t\t\t\t\t<tr class=\"tableRow\"> \t\t\t\t\t\t\t\t <td>"; // line 25 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "name", [], "any", false, false, false, 25), "html", null, true); yield "</td> \t\t\t\t\t\t\t\t <td>"; // line 26 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "location", [], "any", false, false, false, 26), "html", null, true); yield "</td> \t\t\t\t\t\t\t\t <td> <a href=\""; // line 28 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("allReleasesByDepot", ["id" => CoreExtension::getAttribute($this->env, $this->source, $context["item"], "id", [], "any", false, false, false, 28)]), "html", null, true); yield "\">Release Orders</a> | <a href=\""; // line 29 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("depot", ["id" => CoreExtension::getAttribute($this->env, $this->source, $context["item"], "id", [], "any", false, false, false, 29)]), "html", null, true); yield "\">Edit</a> | <a href=\""; // line 30 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("delete_depot", ["id" => CoreExtension::getAttribute($this->env, $this->source, $context["item"], "id", [], "any", false, false, false, 30)]), "html", null, true); yield "\" class=\"delete\">Delete</a> </td> \t\t\t\t\t\t\t\t </tr> \t\t\t\t\t\t\t\t\t\t"; } $_parent = $context['_parent']; unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']); $context = array_intersect_key($context, $_parent) + $_parent; // line 34 yield " </tbody> </table> </div> \t </div> \t </div> \t \t </div> \t </div> \t</div> "; return; yield ''; } // line 47 public function block_javascript($context, array $blocks = []) { $macros = $this->macros; // line 48 yield " "; yield from $this->yieldParentBlock("javascript", $context, $blocks); yield " <script> document.querySelectorAll('.delete').forEach(del => { del.addEventListener('click', function(e){ e.preventDefault(); const link = e.target.getAttribute('href') const res = confirm('Are you sure you want to delete this depot?'); if(res) { window.location.href = link; } }) }) </script> "; return; yield ''; } /** * @codeCoverageIgnore */ public function getTemplateName() { return "cargo/depots.html.twig"; } /** * @codeCoverageIgnore */ public function isTraitable() { return false; } /** * @codeCoverageIgnore */ public function getDebugInfo() { return array ( 130 => 48, 126 => 47, 110 => 34, 100 => 30, 96 => 29, 92 => 28, 87 => 26, 83 => 25, 80 => 24, 76 => 23, 61 => 11, 52 => 4, 48 => 3, 37 => 1,); } public function getSourceContext() { return new Source("", "cargo/depots.html.twig", "/var/www/html/boazapp/templates/cargo/depots.html.twig"); } }