281 lines
13 KiB
PHP
Executable File
281 lines
13 KiB
PHP
Executable File
<?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;
|
|
use Twig\TemplateWrapper;
|
|
|
|
/* configindex/views/admin/edit.twig */
|
|
class __TwigTemplate_3649cc372845a43791f9d7f02b5ff7da extends Template
|
|
{
|
|
private Source $source;
|
|
/**
|
|
* @var array<string, Template>
|
|
*/
|
|
private array $macros = [];
|
|
|
|
public function __construct(Environment $env)
|
|
{
|
|
parent::__construct($env);
|
|
|
|
$this->source = $this->getSourceContext();
|
|
|
|
$this->blocks = [
|
|
'title' => [$this, 'block_title'],
|
|
'content' => [$this, 'block_content'],
|
|
'scripts' => [$this, 'block_scripts'],
|
|
];
|
|
}
|
|
|
|
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
|
|
{
|
|
// line 1
|
|
return "layouts/dashboard.twig";
|
|
}
|
|
|
|
protected function doDisplay(array $context, array $blocks = []): iterable
|
|
{
|
|
$macros = $this->macros;
|
|
$this->parent = $this->load("layouts/dashboard.twig", 1);
|
|
yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
|
|
}
|
|
|
|
// line 3
|
|
/**
|
|
* @return iterable<null|scalar|\Stringable>
|
|
*/
|
|
public function block_title(array $context, array $blocks = []): iterable
|
|
{
|
|
$macros = $this->macros;
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["title"] ?? null), "html", null, true);
|
|
yield " - ";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["platformName"] ?? null), "html", null, true);
|
|
yield from [];
|
|
}
|
|
|
|
// line 5
|
|
/**
|
|
* @return iterable<null|scalar|\Stringable>
|
|
*/
|
|
public function block_content(array $context, array $blocks = []): iterable
|
|
{
|
|
$macros = $this->macros;
|
|
// line 6
|
|
yield "<div class=\"container-fluid px-4\">
|
|
<h1 class=\"mt-4\">";
|
|
// line 7
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["title"] ?? null), "html", null, true);
|
|
yield "</h1>
|
|
<ol class=\"breadcrumb mb-4\">
|
|
<li class=\"breadcrumb-item\"><a href=\"";
|
|
// line 9
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('url')->getCallable()("dashboard"), "html", null, true);
|
|
yield "\">";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("layout.menu.dashboard"), "html", null, true);
|
|
yield "</a></li>
|
|
<li class=\"breadcrumb-item\"><a href=\"";
|
|
// line 10
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('url')->getCallable()("admin/configindex"), "html", null, true);
|
|
yield "?theme=";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["currentTheme"] ?? null), "html", null, true);
|
|
yield "\">";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["title"] ?? null), "html", null, true);
|
|
yield "</a></li>
|
|
<li class=\"breadcrumb-item active\">";
|
|
// line 11
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["page_key"] ?? null), "html", null, true);
|
|
yield "</li>
|
|
</ol>
|
|
|
|
<div class=\"alert alert-info d-flex align-items-center mb-4\">
|
|
<i class=\"bi bi-info-circle-fill me-2\"></i>
|
|
<div>
|
|
Você está editando a página para o tema: <strong>";
|
|
// line 17
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::capitalize($this->env->getCharset(), ($context["currentTheme"] ?? null)), "html", null, true);
|
|
yield "</strong>.
|
|
<br><small>Arquivo: <code>";
|
|
// line 18
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::replace(($context["foundPath"] ?? null), [ (string)($context["base_path"] ?? null) => ""]), "html", null, true);
|
|
yield "</code></small>
|
|
</div>
|
|
</div>
|
|
|
|
<div class=\"card mb-4\">
|
|
<div class=\"card-body\">
|
|
<form action=\"";
|
|
// line 24
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('url')->getCallable()((("admin/configindex/" . ($context["page_key"] ?? null)) . "/update")), "html", null, true);
|
|
yield "?theme=";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["currentTheme"] ?? null), "html", null, true);
|
|
yield "\" method=\"POST\">
|
|
<div class=\"row mb-3\">
|
|
<div class=\"col-md-6\">
|
|
<div class=\"form-check form-switch\">
|
|
<input class=\"form-check-input\" type=\"checkbox\" id=\"show_public_nav\" name=\"config_index_show_public_nav\" ";
|
|
// line 28
|
|
if ((($tmp = ($context["page_data"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
|
|
if ((($tmp = CoreExtension::getAttribute($this->env, $this->source, ($context["page_data"] ?? null), "config_index_show_public_nav", [], "any", false, false, false, 28)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
|
|
yield "checked";
|
|
}
|
|
} else {
|
|
yield "checked";
|
|
}
|
|
yield ">
|
|
<label class=\"form-check-label\" for=\"show_public_nav\">";
|
|
// line 29
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.show_public_nav"), "html", null, true);
|
|
yield "</label>
|
|
</div>
|
|
</div>
|
|
<div class=\"col-md-6\">
|
|
<div class=\"form-check form-switch\">
|
|
<input class=\"form-check-input\" type=\"checkbox\" id=\"show_dashboard_nav\" name=\"config_index_show_dashboard_nav\" ";
|
|
// line 34
|
|
if ((($tmp = ($context["page_data"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
|
|
if ((($tmp = CoreExtension::getAttribute($this->env, $this->source, ($context["page_data"] ?? null), "config_index_show_dashboard_nav", [], "any", false, false, false, 34)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
|
|
yield "checked";
|
|
}
|
|
} else {
|
|
yield "checked";
|
|
}
|
|
yield ">
|
|
<label class=\"form-check-label\" for=\"show_dashboard_nav\">";
|
|
// line 35
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.show_dashboard_nav"), "html", null, true);
|
|
yield "</label>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class=\"mb-3\">
|
|
<label for=\"content\" class=\"form-label\">";
|
|
// line 41
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.form_content"), "html", null, true);
|
|
yield "</label>
|
|
<textarea name=\"content\" id=\"content\" class=\"form-control\" rows=\"18\">";
|
|
// line 42
|
|
if ((($tmp = ($context["template_code"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
|
|
yield ($context["template_code"] ?? null);
|
|
} else {
|
|
yield CoreExtension::getAttribute($this->env, $this->source, ($context["page_data"] ?? null), "config_index_content", [], "any", false, false, false, 42);
|
|
}
|
|
yield "</textarea>
|
|
</div>
|
|
|
|
<div class=\"mb-4\">
|
|
<h5 class=\"mb-3\">";
|
|
// line 46
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.template_translations"), "html", null, true);
|
|
yield "</h5>
|
|
";
|
|
// line 47
|
|
if ((($tmp = ($context["languages"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
|
|
// line 48
|
|
yield " ";
|
|
$context['_parent'] = $context;
|
|
$context['_seq'] = CoreExtension::ensureTraversable(($context["languages"] ?? null));
|
|
foreach ($context['_seq'] as $context["_key"] => $context["lang"]) {
|
|
// line 49
|
|
yield " <div class=\"mb-3\">
|
|
<label class=\"form-label\">";
|
|
// line 50
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($context["lang"], "html", null, true);
|
|
yield " - ";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.index_json_section"), "html", null, true);
|
|
yield " ";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(($context["page_key"] ?? null), "html", null, true);
|
|
yield ")</label>
|
|
<textarea name=\"translations_index_section[";
|
|
// line 51
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($context["lang"], "html", null, true);
|
|
yield "]\" class=\"form-control\" rows=\"10\">";
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((CoreExtension::getAttribute($this->env, $this->source, ($context["translations_index_section"] ?? null), $context["lang"], [], "array", true, true, false, 51)) ? (Twig\Extension\CoreExtension::default((($_v0 = ($context["translations_index_section"] ?? null)) && is_array($_v0) || $_v0 instanceof ArrayAccess ? ($_v0[$context["lang"]] ?? null) : null), "{}")) : ("{}")), "html", null, true);
|
|
yield "</textarea>
|
|
</div>
|
|
<hr/>
|
|
";
|
|
}
|
|
$_parent = $context['_parent'];
|
|
unset($context['_seq'], $context['_key'], $context['lang'], $context['_parent']);
|
|
$context = array_intersect_key($context, $_parent) + $_parent;
|
|
// line 55
|
|
yield " ";
|
|
}
|
|
// line 56
|
|
yield " </div>
|
|
|
|
|
|
|
|
<button type=\"submit\" class=\"btn btn-primary\">
|
|
<i class=\"bi bi-save\"></i> ";
|
|
// line 61
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.save"), "html", null, true);
|
|
yield "
|
|
</button>
|
|
<a href=\"";
|
|
// line 63
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('url')->getCallable()("admin/configindex"), "html", null, true);
|
|
yield "\" class=\"btn btn-secondary\">
|
|
";
|
|
// line 64
|
|
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getFunction('__')->getCallable()("configindex.cancel"), "html", null, true);
|
|
yield "
|
|
</a>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
";
|
|
yield from [];
|
|
}
|
|
|
|
// line 72
|
|
/**
|
|
* @return iterable<null|scalar|\Stringable>
|
|
*/
|
|
public function block_scripts(array $context, array $blocks = []): iterable
|
|
{
|
|
$macros = $this->macros;
|
|
yield from [];
|
|
}
|
|
|
|
/**
|
|
* @codeCoverageIgnore
|
|
*/
|
|
public function getTemplateName(): string
|
|
{
|
|
return "configindex/views/admin/edit.twig";
|
|
}
|
|
|
|
/**
|
|
* @codeCoverageIgnore
|
|
*/
|
|
public function isTraitable(): bool
|
|
{
|
|
return false;
|
|
}
|
|
|
|
/**
|
|
* @codeCoverageIgnore
|
|
*/
|
|
public function getDebugInfo(): array
|
|
{
|
|
return array ( 243 => 72, 231 => 64, 227 => 63, 222 => 61, 215 => 56, 212 => 55, 200 => 51, 192 => 50, 189 => 49, 184 => 48, 182 => 47, 178 => 46, 167 => 42, 163 => 41, 154 => 35, 144 => 34, 136 => 29, 126 => 28, 117 => 24, 108 => 18, 104 => 17, 95 => 11, 87 => 10, 81 => 9, 76 => 7, 73 => 6, 66 => 5, 53 => 3, 42 => 1,);
|
|
}
|
|
|
|
public function getSourceContext(): Source
|
|
{
|
|
return new Source("", "configindex/views/admin/edit.twig", "/app/modules/configindex/views/admin/edit.twig");
|
|
}
|
|
}
|