search correctif pour download

This commit is contained in:
Fred Tempez 2022-05-26 19:37:47 +02:00
parent b908be1287
commit 9c6ef7a346

View File

@ -19,7 +19,7 @@
class search extends common {
const VERSION = '2.4';
const VERSION = '2.5';
const REALNAME = 'Recherche';
const DATADIRECTORY = self::DATA_DIR . 'search/';
@ -254,9 +254,13 @@ class search extends common {
}
// Articles d'une sous-page blog ou de news
if ($this->getData(['page', $childId, 'moduleId']) === 'blog' || $this->getData(['page', $childId, 'moduleId']) === 'news'
&& $this->getData(['module',$parentId,'posts']) )
{
if (
( $this->getData(['page', $childId, 'moduleId']) === 'blog'
|| $this->getData(['page', $childId, 'moduleId']) === 'news'
|| $this->getData(['page', $childId, 'moduleId']) === 'download'
)
&& $this->getData(['module',$childId,'posts'])
) {
foreach($this->getData(['module',$childId,'posts']) as $articleId => $article) {
if($this->getData(['module',$childId,'posts',$articleId,'state']) === true) {
$url = $childId . '/' . $articleId;
@ -273,8 +277,14 @@ class search extends common {
}
// Articles d'un blog ou de news
if ( $this->getData(['page', $parentId, 'moduleId']) === 'blog' || $this->getData(['page', $parentId, 'moduleId']) === 'news'
&& $this->getData(['module',$parentId,'posts']) ) {
if (
( $this->getData(['page', $parentId, 'moduleId']) === 'blog'
|| $this->getData(['page', $parentId, 'moduleId']) === 'news'
|| $this->getData(['page', $parentId, 'moduleId']) === 'download'
)
&& $this->getData(['module',$parentId,'posts'])
) {
foreach($this->getData(['module',$parentId,'posts']) as $articleId => $article) {
if($this->getData(['module',$parentId,'posts',$articleId,'state']) === true)
{