ZwiiCMS/core/module/translate/translate.php

47 lines
1.2 KiB
PHP
Raw Normal View History

2020-11-11 19:48:07 +01:00
<?php
/**
* This file is part of Zwii.
*
* For full copyright and license information, please see the LICENSE
* file that was distributed with this source code.
*
* @author Rémi Jean <remi.jean@outlook.com>
* @copyright Copyright (C) 2008-2018, Rémi Jean
* @license GNU General Public License, version 3
* @link http://zwiicms.fr/
*/
class translate extends common {
public static $actions = [
/*'config' => self::GROUP_MODERATOR,*/
'index' => self::GROUP_MODERATOR
];
/**
* Configuration
*/
public function index() {
// Soumission du formulaire
if($this->isPost()) {
$this->setData(['config','translate', [
2020-11-14 14:52:18 +01:00
'active' => $this->getInput('translateActive', helper::FILTER_BOOLEAN),
2020-11-14 15:49:01 +01:00
'showCredits' => $this->getInput('translateActive', helper::FILTER_BOOLEAN) ? $this->getInput('translateCredits', helper::FILTER_BOOLEAN) : false,
2020-11-11 19:48:07 +01:00
]]);
// Valeurs en sortie
$this->addOutput([
'redirect' => helper::baseUrl() . $this->getUrl(),
'notification' => 'Modifications enregistrées',
'state' => true
]);
}
// Valeurs en sortie
$this->addOutput([
'title' => 'Paramètres',
'view' => 'index'
]);
}
}