summaryrefslogtreecommitdiff
path: root/fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig
diff options
context:
space:
mode:
Diffstat (limited to 'fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig')
-rw-r--r--fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig27
1 files changed, 27 insertions, 0 deletions
diff --git a/fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig b/fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig
index 2ed5249..e48d107 100644
--- a/fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig
+++ b/fai_gestion/plugins/CustomTheme/src/Template/Bake/Element/form.twig
@@ -13,6 +13,29 @@
* @license http://www.opensource.org/licenses/mit-license.php MIT License
*/
#}
+<?php
+/**
+ * Copyright 2016-2018 Ludovic Pouzenc <ludovic@pouzenc.fr>
+ * Copyright 2016 Nicolas Goaziou <mail@nicolasgoaziou.fr>
+ *
+ * This file is part of FAI Gestion forked from CHD Gestion.
+ *
+ * FAI Gestion is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * FAI Gestion is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with FAI Gestion. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Auto-generated code with CakePHP(tm) bake derived code.
+**/
+?>
{% set fields = Bake.filterFields(fields, schema, modelObject) %}
<nav class="large-2 medium-3 columns" id="actions-sidebar">
<ul class="side-nav">
@@ -31,8 +54,12 @@
{% for type, data in associations %}
{%- for alias, details in data %}
{%- if details.controller is not same as(_view.name) and details.controller not in done %}
+{% if BakeExtra.hasAction('index', details.controller) %}
<li><?= $this->Html->link(__('List {{ alias|underscore|humanize }}'), ['controller' => '{{ details.controller }}', 'action' => 'index']) ?></li>
+{% endif %}
+{% if BakeExtra.hasAction('add', details.controller) %}
<li><?= $this->Html->link(__('New {{ alias|singularize|underscore|humanize }}'), ['controller' => '{{ details.controller }}', 'action' => 'add']) ?></li>
+{% endif %}
{{- "\n" }}
{%- set done = done|merge([details.controller]) %}
{%- endif %}