1.15.02 Configuration du site, la page ne se recharge plus après un changement d'onglet.
Le dernier onglet vu avant un submit est mémorisé. Mise à jour module suscribe 2.4
This commit is contained in:
parent
ff5edbc47c
commit
368e7dc99e
@ -31,7 +31,6 @@ class config extends common
|
||||
'logDownload' => self::GROUP_ADMIN,
|
||||
'blacklistReset' => self::GROUP_ADMIN,
|
||||
'blacklistDownload' => self::GROUP_ADMIN,
|
||||
'register' => self::GROUP_ADMIN,
|
||||
'testmail' => self::GROUP_ADMIN,
|
||||
];
|
||||
|
||||
@ -536,6 +535,18 @@ class config extends common
|
||||
]
|
||||
]);
|
||||
|
||||
|
||||
// Sauvegarde la position des onglets de la vue de l'utilisateur courant
|
||||
$this->setData([
|
||||
'user',
|
||||
$this->getUser('id'),
|
||||
'view',
|
||||
[
|
||||
'config' => $this->getInput('containerSelected'),
|
||||
'page' => $this->getData(['user', $this->getUser('id'), 'view', 'page']),
|
||||
]
|
||||
]);
|
||||
|
||||
// Efface les fichiers de backup lorsque l'option est désactivée
|
||||
if ($this->getInput('configFileBackup', helper::FILTER_BOOLEAN) === false) {
|
||||
$path = realpath('site/data');
|
||||
@ -976,27 +987,6 @@ class config extends common
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Stocke la variable dans les paramètres de l'utilisateur pour activer la tab à sa prochaine visite
|
||||
* @return never
|
||||
*/
|
||||
public function register(): void
|
||||
{
|
||||
$this->setData([
|
||||
'user',
|
||||
$this->getUser('id'),
|
||||
'view',
|
||||
[
|
||||
'config' => $this->getUrl(2),
|
||||
'page' => $this->getData(['user', $this->getUser('id'), 'view', 'page']),
|
||||
]
|
||||
]);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config/' . $this->getUrl(2),
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Envoi un message de test
|
||||
* @return void
|
||||
|
@ -164,6 +164,7 @@ $(document).ready(function () {
|
||||
$("#connectContainer").hide();
|
||||
$("#networkContainer").hide();
|
||||
$("#localeContainer").show();
|
||||
document.getElementById("containerSelected").value = "locale";
|
||||
$("#configSetupButton").removeClass("activeButton");
|
||||
$("#configLocaleButton").addClass("activeButton");
|
||||
$("#configSocialButton").removeClass("activeButton");
|
||||
@ -176,6 +177,7 @@ $(document).ready(function () {
|
||||
$("#connectContainer").hide();
|
||||
$("#networkContainer").hide();
|
||||
$("#setupContainer").show();
|
||||
document.getElementById("containerSelected").value = "setup";
|
||||
$("#configSetupButton").addClass("activeButton");
|
||||
$("#configLocaleButton").removeClass("activeButton");
|
||||
$("#configSocialButton").removeClass("activeButton");
|
||||
@ -189,6 +191,7 @@ $(document).ready(function () {
|
||||
$("#localeContainer").hide();
|
||||
$("#networkContainer").hide();
|
||||
$("#socialContainer").show();
|
||||
document.getElementById("containerSelected").value = "social";
|
||||
$("#configSetupButton").removeClass("activeButton");
|
||||
$("#configLocaleButton").removeClass("activeButton");
|
||||
$("#configSocialButton").addClass("activeButton");
|
||||
@ -201,6 +204,7 @@ $(document).ready(function () {
|
||||
$("#socialContainer").hide();
|
||||
$("#networkContainer").hide();
|
||||
$("#connectContainer").show();
|
||||
document.getElementById("containerSelected").value = "connect";
|
||||
$("#configSetupButton").removeClass("activeButton");
|
||||
$("#configLocaleButton").removeClass("activeButton");
|
||||
$("#configSocialButton").removeClass("activeButton");
|
||||
@ -213,6 +217,7 @@ $(document).ready(function () {
|
||||
$("#socialContainer").hide();
|
||||
$("#connectContainer").hide();
|
||||
$("#networkContainer").show();
|
||||
document.getElementById("containerSelected").value = "network";
|
||||
$("#configSetupButton").removeClass("activeButton");
|
||||
$("#configLocaleButton").removeClass("activeButton");
|
||||
$("#configSocialButton").removeClass("activeButton");
|
||||
|
@ -19,24 +19,25 @@
|
||||
<?php echo template::button('configSetupButton', [
|
||||
'value' => 'Configuration',
|
||||
'class' => 'buttonTab',
|
||||
'href' => helper::baseUrl() . 'config/register/setup'
|
||||
]); ?>
|
||||
<?php echo template::button('configSocialButton', [
|
||||
'value' => 'Référencement',
|
||||
'class' => 'buttonTab',
|
||||
'href' => helper::baseUrl() . 'config/register/social'
|
||||
]); ?>
|
||||
<?php echo template::button('configConnectButton', [
|
||||
'value' => 'Connexion',
|
||||
'class' => 'buttonTab',
|
||||
'href' => helper::baseUrl() . 'config/register/connect'
|
||||
]); ?>
|
||||
<?php echo template::button('configNetworkButton', [
|
||||
'value' => 'Réseau',
|
||||
'class' => 'buttonTab',
|
||||
'href' => helper::baseUrl() . 'config/register/network'
|
||||
]); ?>
|
||||
</div>
|
||||
|
||||
<!-- Champ caché pour transmettre l'onglet-->
|
||||
<?php echo template::hidden('containerSelected'); ?>
|
||||
|
||||
<!-- Pages de formulaires -->
|
||||
<?php include('core/module/config/view/locale/locale.php') ?>
|
||||
<?php include('core/module/config/view/setup/setup.php') ?>
|
||||
<?php include('core/module/config/view/social/social.php') ?>
|
||||
|
@ -1,3 +1,5 @@
|
||||
# Version 2.4
|
||||
- L'approbation par un administrateur initialise le pseudo avec l'id de l'utilisateur.
|
||||
# Version 2.3
|
||||
- Warning lors de la saisie d'un email vide
|
||||
# Version 2.2
|
||||
|
@ -1 +1 @@
|
||||
{"name":"suscribe","realName":"Auto Inscription","version":"2.3","update":"0.0","delete":true,"dataDirectory":""}
|
||||
{"name":"suscribe","realName":"Auto Inscription","version":"2.4","update":"0.0","delete":true,"dataDirectory":""}
|
@ -15,7 +15,7 @@
|
||||
class suscribe extends common
|
||||
{
|
||||
|
||||
const VERSION = '2.3';
|
||||
const VERSION = '2.4';
|
||||
const REALNAME = 'Auto Inscription';
|
||||
const DELETE = true;
|
||||
const UPDATE = '0.0';
|
||||
@ -315,6 +315,7 @@ class suscribe extends common
|
||||
'password' => '',
|
||||
// pas de groupe afin de le différencier dans la liste des users
|
||||
'timer' => time(),
|
||||
'pseudo' => $userId,
|
||||
'auth' => $auth,
|
||||
'status' => self::STATUS_EMAIL_AWAITING
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user