bug routeur
This commit is contained in:
parent
107c41f409
commit
920f012007
@ -1743,7 +1743,7 @@ class core extends common {
|
|||||||
$accessInfo['userName'] = '';
|
$accessInfo['userName'] = '';
|
||||||
$accessInfo['pageId'] = '';
|
$accessInfo['pageId'] = '';
|
||||||
if($this->getData(['page', $this->getUrl(0)]) !== null
|
if($this->getData(['page', $this->getUrl(0)]) !== null
|
||||||
OR $this->getData(['page', $this->getUrl(2)]) !== NULL) { // Page Redirection éviter une valeur nulle
|
) {
|
||||||
if(
|
if(
|
||||||
$this->getData(['page', $this->getUrl(0), 'group']) === self::GROUP_VISITOR
|
$this->getData(['page', $this->getUrl(0), 'group']) === self::GROUP_VISITOR
|
||||||
OR (
|
OR (
|
||||||
@ -1762,6 +1762,8 @@ class core extends common {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
var_dump($access);
|
||||||
|
echo $this->getUrl(0);
|
||||||
/**
|
/**
|
||||||
* Contrôle si la page demandée est en édition ou accès à la gestion du site
|
* Contrôle si la page demandée est en édition ou accès à la gestion du site
|
||||||
* conditions de blocage :
|
* conditions de blocage :
|
||||||
@ -1772,12 +1774,12 @@ class core extends common {
|
|||||||
*/
|
*/
|
||||||
foreach($this->getData(['user']) as $userId => $userIds){
|
foreach($this->getData(['user']) as $userId => $userIds){
|
||||||
$t = explode('/',$this->getData(['user', $userId, 'accessUrl']));
|
$t = explode('/',$this->getData(['user', $userId, 'accessUrl']));
|
||||||
if ( $this->getuser('id') &&
|
if ( $this->getuser('id')
|
||||||
$userId !== $this->getuser('id') &&
|
AND $userId !== $this->getuser('id')
|
||||||
$this->getData(['user', $userId,'accessUrl']) === $this->getUrl() &&
|
AND $this->getData(['user', $userId,'accessUrl']) === $this->getUrl()
|
||||||
array_intersect($t,self::$accessList) &&
|
AND array_intersect($t,self::$accessList)
|
||||||
array_intersect($t,self::$accessExclude) !== false &&
|
AND array_intersect($t,self::$accessExclude) !== false
|
||||||
time() < $this->getData(['user', $userId,'accessTimer']) + self::ACCESS_TIMER
|
AND time() < $this->getData(['user', $userId,'accessTimer']) + self::ACCESS_TIMER
|
||||||
) {
|
) {
|
||||||
$access = false;
|
$access = false;
|
||||||
$accessInfo['userName'] = $this->getData(['user', $userId, 'lastname']) . ' ' . $this->getData(['user', $userId, 'firstname']);
|
$accessInfo['userName'] = $this->getData(['user', $userId, 'lastname']) . ' ' . $this->getData(['user', $userId, 'firstname']);
|
||||||
@ -1791,16 +1793,13 @@ class core extends common {
|
|||||||
}
|
}
|
||||||
// Breadcrumb
|
// Breadcrumb
|
||||||
$title = $this->getData(['page', $this->getUrl(0), 'title']);
|
$title = $this->getData(['page', $this->getUrl(0), 'title']);
|
||||||
if (!empty($this->getData(['page', $this->getUrl(0), 'parentPageId'])) &&
|
if (!empty($this->getData(['page', $this->getUrl(0), 'parentPageId']))
|
||||||
$this->getData(['page', $this->getUrl(0), 'breadCrumb'])) {
|
AND $this->getData(['page', $this->getUrl(0), 'breadCrumb'])) {
|
||||||
$title = '<a href="' . helper::baseUrl() .
|
$title = '<a href="' . helper::baseUrl() . $this->getData(['page', $this->getUrl(0), 'parentPageId']) .
|
||||||
$this->getData(['page', $this->getUrl(0), 'parentPageId']) .
|
'">' . ucfirst($this->getData(['page',$this->getData(['page', $this->getUrl(0), 'parentPageId']), 'title'])) .
|
||||||
'">' .
|
'</a> › '. $this->getData(['page', $this->getUrl(0), 'title']);
|
||||||
ucfirst($this->getData(['page',$this->getData(['page', $this->getUrl(0), 'parentPageId']), 'title'])) .
|
|
||||||
'</a> › '.
|
|
||||||
$this->getData(['page', $this->getUrl(0), 'title']);
|
|
||||||
}
|
}
|
||||||
|
var_dump($access);
|
||||||
// Importe la page
|
// Importe la page
|
||||||
if(
|
if(
|
||||||
$this->getData(['page', $this->getUrl(0)]) !== null
|
$this->getData(['page', $this->getUrl(0)]) !== null
|
||||||
@ -1874,6 +1873,7 @@ class core extends common {
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
AND $output['access'] === true
|
AND $output['access'] === true
|
||||||
|
AND $access !== false
|
||||||
) {
|
) {
|
||||||
// Enregistrement du contenu de la méthode POST lorsqu'une notice est présente
|
// Enregistrement du contenu de la méthode POST lorsqu'une notice est présente
|
||||||
if(common::$inputNotices) {
|
if(common::$inputNotices) {
|
||||||
@ -1997,6 +1997,7 @@ class core extends common {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
var_dump($access);
|
||||||
// Erreurs
|
// Erreurs
|
||||||
if($access === 'login') {
|
if($access === 'login') {
|
||||||
http_response_code(302);
|
http_response_code(302);
|
||||||
|
Loading…
Reference in New Issue
Block a user