Lity bug galery + login

This commit is contained in:
fredtempez 2021-03-29 19:40:43 +02:00
parent 6a76673dd3
commit 27154982ec

View File

@ -2074,11 +2074,13 @@ class core extends common {
'disable' => $this->getData(['page', $this->getUrl(0), 'disable']), 'disable' => $this->getData(['page', $this->getUrl(0), 'disable']),
'contentRight' => $this->getData(['page',$this->getData(['page',$this->getUrl(0),'barRight']),'content']), 'contentRight' => $this->getData(['page',$this->getData(['page',$this->getUrl(0),'barRight']),'content']),
'contentLeft' => $this->getData(['page',$this->getData(['page',$this->getUrl(0),'barLeft']),'content']), 'contentLeft' => $this->getData(['page',$this->getData(['page',$this->getUrl(0),'barLeft']),'content']),
'display' => $this->getData(['page', $this->getUrl(0), 'lity']) === true
&& $this->getUser('password') !== $this->getInput('ZWII_USER_PASSWORD')
? self::DISPLAY_LAYOUT_LITY
: $this->output['display']
]); ]);
if ( $this->getData(['page', $this->getUrl(0), 'lity']) === true
&& $this->getUser('password') !== $this->getInput('ZWII_USER_PASSWORD') ) {
$this->addOutput([
'display' => self::DISPLAY_LAYOUT_LITY
]);
}
} }
// Importe le module // Importe le module
else { else {
@ -2100,6 +2102,12 @@ class core extends common {
'contentLeft' => $this->getData(['page',$this->getData(['page',$this->getUrl(0),'barLeft']),'content']) 'contentLeft' => $this->getData(['page',$this->getData(['page',$this->getUrl(0),'barLeft']),'content'])
]); ]);
$pageContent = $this->getData(['page', $this->getUrl(0), 'content']); $pageContent = $this->getData(['page', $this->getUrl(0), 'content']);
if ( $this->getData(['page', $this->getUrl(0), 'lity']) === true
&& $this->getUser('password') !== $this->getInput('ZWII_USER_PASSWORD') ) {
$this->addOutput([
'display' => self::DISPLAY_LAYOUT_LITY
]);
}
} }
else { else {
$moduleId = $this->getUrl(0); $moduleId = $this->getUrl(0);
@ -2175,10 +2183,7 @@ class core extends common {
// Affichage // Affichage
if($output['display']) { if($output['display']) {
$this->addOutput([ $this->addOutput([
'display' => $this->getData(['page', $this->getUrl(0), 'lity']) === true 'display' => $output['display']
&& $this->getUser('password') !== $this->getInput('ZWII_USER_PASSWORD')
? self::DISPLAY_LAYOUT_LITY
: $this->output['display']
]); ]);
} }
// Contenu brut // Contenu brut
@ -2347,8 +2352,11 @@ class core extends common {
'metaDescription' => $this->getData(['locale', 'metaDescription']) 'metaDescription' => $this->getData(['locale', 'metaDescription'])
]); ]);
} }
switch($this->output['display']) { switch($this->output['display']) {
// Layout brut
case self::DISPLAY_RAW:
echo $this->output['content'];
break;
// Layout vide // Layout vide
case self::DISPLAY_LAYOUT_BLANK: case self::DISPLAY_LAYOUT_BLANK:
require 'core/layout/blank.php'; require 'core/layout/blank.php';
@ -2367,17 +2375,13 @@ class core extends common {
case self::DISPLAY_LAYOUT_LIGHT: case self::DISPLAY_LAYOUT_LIGHT:
require 'core/layout/light.php'; require 'core/layout/light.php';
break; break;
// Layout Lity
case self::DISPLAY_LAYOUT_LITY:
require 'core/layout/lity.php';
break;
// Layout principal // Layout principal
case self::DISPLAY_LAYOUT_MAIN: case self::DISPLAY_LAYOUT_MAIN:
require 'core/layout/main.php'; require 'core/layout/main.php';
break; break;
// Layout brut // Layout Lity
case self::DISPLAY_RAW: case self::DISPLAY_LAYOUT_LITY:
echo $this->output['content']; require 'core/layout/lity.php';
break; break;
} }
} }