bug search

This commit is contained in:
fredtempez 2020-12-14 12:34:02 +01:00
parent aa318357fa
commit 185a3993db
1 changed files with 4 additions and 4 deletions

View File

@ -141,8 +141,8 @@ class search extends common {
// Articles d'une sous-page blog // Articles d'une sous-page blog
if ($this->getData(['page', $childId, 'moduleId']) === 'blog') if ($this->getData(['page', $childId, 'moduleId']) === 'blog')
{ {
foreach($this->getData(['module',$childId]) as $articleId => $article) { foreach($this->getData(['module',$childId,'posts']) as $articleId => $article) {
if($this->getData(['module',$childId,$articleId,'state']) === true) { if($this->getData(['module',$childId,'posts',$articleId,'state']) === true) {
$url = $childId . '/' . $articleId; $url = $childId . '/' . $articleId;
$titre = $article['title']; $titre = $article['title'];
$contenu = ' ' . $titre . ' ' . $article['content']; $contenu = ' ' . $titre . ' ' . $article['content'];
@ -158,8 +158,8 @@ class search extends common {
// Articles d'un blog // Articles d'un blog
if ($this->getData(['page', $parentId, 'moduleId']) === 'blog' ) { if ($this->getData(['page', $parentId, 'moduleId']) === 'blog' ) {
foreach($this->getData(['module',$parentId]) as $articleId => $article) { foreach($this->getData(['module',$parentId,'posts']) as $articleId => $article) {
if($this->getData(['module',$parentId,$articleId,'state']) === true) if($this->getData(['module',$parentId,'posts',$articleId,'state']) === true)
{ {
$url = $parentId. '/' . $articleId; $url = $parentId. '/' . $articleId;
$titre = $article['title']; $titre = $article['title'];