réorganisation ajout catégorie
This commit is contained in:
parent
e17613e532
commit
f4b98a6eac
4 changed files with 63 additions and 6 deletions
|
|
@ -10,6 +10,8 @@
|
|||
<p class="block confirm">Modification enregistrée</p>
|
||||
{{elseif $_GET.msg == "suppression"}}
|
||||
<p class="block confirm">Catégorie supprimée</p>
|
||||
{{else}}
|
||||
<p class="block confirm">{{$_GET.msg}}</p>
|
||||
{{/if}}
|
||||
{{elseif $_GET.err}}
|
||||
{{if $_GET.msg == "modification"}}
|
||||
|
|
@ -44,9 +46,11 @@
|
|||
</section>
|
||||
|
||||
{{* Traiter l'envoi du formulaire *}}
|
||||
{{*
|
||||
{{#form on="save"}}
|
||||
|
||||
*}}
|
||||
{{* Vérifier s'il existe déjà une catégorie avec le même nom *}}
|
||||
{{*
|
||||
{{#load type="category"}}
|
||||
{{if $name|tolower == $_POST.name|trim|tolower}}
|
||||
{{:error message="Impossible d'ajouter la catégorie « %s » car elle existe déjà !"|args:$name|trim}}
|
||||
|
|
@ -65,8 +69,8 @@
|
|||
{{/form}}
|
||||
|
||||
{{:form_errors}}
|
||||
|
||||
{{* formulaire d'ajout de catégorie *}}
|
||||
*}}
|
||||
{{* formulaire d'ajout de catégorie
|
||||
<form method="post" action="{{$self_url}}">
|
||||
<fieldset class="ajout_categorie">
|
||||
<legend>Ajouter une catégorie</legend>
|
||||
|
|
@ -78,5 +82,5 @@
|
|||
</p>
|
||||
</fieldset>
|
||||
</form>
|
||||
|
||||
*}}
|
||||
{{:admin_footer}}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue