autodisconnect
This commit is contained in:
parent
0535dc951b
commit
3d928d866b
@ -2402,7 +2402,7 @@ class core extends common {
|
||||
$this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
||||
AND ( $this->getUser('group') === self::GROUP_BANNED
|
||||
OR ( $_SESSION['csrf'] !== $this->getData(['user',$this->getUser('id'),'accessCsrf'])
|
||||
AND $this->getData(['config','autoDisconnect']) === true)
|
||||
AND $this->getData(['config','connect', 'autoDisconnect']) === true)
|
||||
)
|
||||
) {
|
||||
$user = new user;
|
||||
|
@ -399,7 +399,7 @@ class config extends common {
|
||||
}
|
||||
|
||||
// Eviter déconnexion automatique après son activation
|
||||
if ( $this->getData(['config','autoDisconnect']) === false
|
||||
if ( $this->getData(['config','connect', 'autoDisconnect']) === false
|
||||
AND $this->getInput('configAutoDisconnect',helper::FILTER_BOOLEAN) === true ) {
|
||||
$this->setData(['user',$this->getuser('id'),'accessCsrf',$_SESSION['csrf']]);
|
||||
}
|
||||
|
@ -17,7 +17,7 @@
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('connectAutoDisconnect', true, 'Déconnexion automatique', [
|
||||
'checked' => $this->getData(['config','autoDisconnect']),
|
||||
'checked' => $this->getData(['config','connect', 'autoDisconnect']),
|
||||
'help' => 'Déconnecte les sessions ouvertes précédemment sur d\'autres navigateurs ou terminaux. Activation recommandée.'
|
||||
]); ?>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user