<?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;
/* @templates/Front/Shop/daily-maintenance.html.twig */
class __TwigTemplate_e7b38b243b9c0babdb0a0aadf9a1738d21a49d0bf87d74b9681a45c9326f6b2f extends \Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'content' => [$this, 'block_content'],
];
}
protected function doGetParent(array $context)
{
// line 1
return $this->loadTemplate(((twig_get_attribute($this->env, $this->source, (isset($context["is_mobile"]) || array_key_exists("is_mobile", $context) ? $context["is_mobile"] : (function () { throw new RuntimeError('Variable "is_mobile" does not exist.', 1, $this->source); })()), "check", [], "any", false, false, false, 1)) ? ("@templates/Mobile/Shop/layout.html.twig") : ("@templates/Front/Shop/layout.html.twig")), "@templates/Front/Shop/daily-maintenance.html.twig", 1);
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@templates/Front/Shop/daily-maintenance.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@templates/Front/Shop/daily-maintenance.html.twig"));
$this->getParent($context)->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 3
public function block_content($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
// line 4
echo " <div class=\"card shadow my-5 mx-5 text-center\">
<div class=\"card-header\">
<h2>";
// line 6
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("app.ui.maintenance_on"), "html", null, true);
echo "</h2>
</div>
<div class=\"card-body\">
<p id=\"countDown\">
</p>
</div>
</div>
<script>
\$(document).ready(function () {
let countDownDate = new Date();
if (countDownDate.getHours() !== 0) {
countDownDate.setDate(countDownDate.getDate() + 1);
}
countDownDate.setHours(0,6,0,0);
countDownDate = countDownDate.getTime();
let x = setInterval(function () {
let now = new Date().getTime();
let distance = countDownDate - now;
let hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
let minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
let seconds = Math.floor((distance % (1000 * 60)) / 1000);
\$('#countDown').html(hours + \"h \"
+ minutes + \"m \" + seconds + \"s \");
if (distance < 0) {
clearInterval(x);
//window.location.href='/';
}
}, 1000);
});
</script>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "@templates/Front/Shop/daily-maintenance.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 71 => 6, 67 => 4, 57 => 3, 35 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends is_mobile.check ? '@templates/Mobile/Shop/layout.html.twig' : '@templates/Front/Shop/layout.html.twig' %}
{% block content %}
<div class=\"card shadow my-5 mx-5 text-center\">
<div class=\"card-header\">
<h2>{{ 'app.ui.maintenance_on'|trans }}</h2>
</div>
<div class=\"card-body\">
<p id=\"countDown\">
</p>
</div>
</div>
<script>
\$(document).ready(function () {
let countDownDate = new Date();
if (countDownDate.getHours() !== 0) {
countDownDate.setDate(countDownDate.getDate() + 1);
}
countDownDate.setHours(0,6,0,0);
countDownDate = countDownDate.getTime();
let x = setInterval(function () {
let now = new Date().getTime();
let distance = countDownDate - now;
let hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
let minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
let seconds = Math.floor((distance % (1000 * 60)) / 1000);
\$('#countDown').html(hours + \"h \"
+ minutes + \"m \" + seconds + \"s \");
if (distance < 0) {
clearInterval(x);
//window.location.href='/';
}
}, 1000);
});
</script>
{% endblock %}
", "@templates/Front/Shop/daily-maintenance.html.twig", "/vhosts/nou.roviniete.ro/templates/Front/Shop/daily-maintenance.html.twig");
}
}