Reprendre index d'origine pour les langues

This commit is contained in:
fredtempez 2019-09-29 19:46:53 +02:00
parent f33d26b285
commit 0c59bda365
1 changed files with 55 additions and 43 deletions

View File

@ -1,49 +1,61 @@
<?php echo template::formOpen('i18nIndex'); ?>
<div class="row">
<div class="col2">
<?php echo template::button('configBack', [
'class' => 'buttonGrey',
'href' => helper::baseUrl(false),
'ico' => 'home',
'value' => 'Accueil'
]); ?>
</div>
<div class="col2 offset6">
<?php echo template::button('configBack', [
'href' => helper::baseUrl() . $this->getUrl(0) . '/config',
'value' => 'Langues'
]); ?>
</div>
<div class="col2">
<?php echo template::submit('configSubmit'); ?>
</div>
</div>
<div class="row">
<div class="col12">
<div class="row">
<div class="col2">
<?php echo template::button('configBack', [
'class' => 'buttonGrey',
'href' => helper::baseUrl() . $this->getUrl(0) ,
'value' => 'Retour'
]); ?>
</div>
<div class="col2 offset8">
<?php echo template::submit('configSubmit'); ?>
</div>
</div>
<div class="row">
<div class="col8">
<div class="block">
<h4>Informations langue :
<?php echo $this->geti18n();?></h4>
<div class="row">
<div class="col4">
<?php echo template::select('pagei18nHomePageId', helper::arrayCollumn($this->getData(['page']), 'title', 'SORT_ASC'), [
'label' => 'Page d\'accueil',
'selected' => $this->getData(['page', 'homePageId'])
<h4>Ajouter une localisation</h4>
<div class="row">
<div class="col5">
<?php echo template::select('i18nLanguageCopyFrom', $this->i18nInstalled(true), [
'label' => 'Copier à partir ',
'help' => 'Pour démarrer sans copie des pages te des modules d\'une langue existante, ne rien sélectionner',
'selected' => -1
]); ?>
</div>
<div class="col8">
<?php echo template::text('pagei18nPageTitle', [
'label' => 'Titre du site',
'value' => $this->getData(['page', 'title']),
'help' => 'Il apparaît dans la barre de titre et les partages sur les réseaux sociaux.'
]); ?>
</div>
<div class="col1">
<?php echo template::ico('right-big'); ?>
</div>
<div class="col5">
<?php
$available = array ('' => 'Sélectionner');
$available = array_merge ($available, self::$i18nList);
echo template::select('i18nLanguageAdd', $available, [
'label' => 'vers'
]); ?>
</div>
</div>
<?php echo template::textarea('pagei18nMetaDescription', [
'label' => 'Description du site',
'value' => $this->getData(['page', 'metaDescription']),
'help' => 'Elle apparaît dans les partages sur les réseaux sociaux.'
]); ?>
</div>
</div>
</div>
<?php echo template::formClose(); ?>
</div>
<div class="col4">
<div class="block">
<h4>Supprimer une localisation</h4>
<div class="row">
<?php echo template::select('i18nLanguageRemove', $this->i18nInstalled(true, true), [
'label' => 'Localisations installées',
'help' => 'La suppression d\'une langue entraîne l\'effacement des pages et des modules',
'selected' => -1
]); ?>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col4">
<?php echo template::select('i18nHomePageId', helper::arrayCollumn($this->getData(['page']), 'title', 'SORT_ASC'), [
'label' => 'Page d\'accueil',
//'selected' => $this->getData(['config', 'homePageId'])
]); ?>
</div>
</div>
<?php echo template::formClose(); ?>