Merge branch 'master' of https://github.com/fredtempez/ZwiiCMS
This commit is contained in:
commit
1a72d7d2dd
@ -1,6 +1,11 @@
|
|||||||
# ChangeLog
|
# ChangeLog
|
||||||
|
|
||||||
|
|
||||||
|
## Version 9.0.21
|
||||||
|
- Corrections :
|
||||||
|
- Liens de l'éditeur de page : impossibilité de sélectionner un lien vers une page parente
|
||||||
|
- Export des données du site, problème lors de la création de l'arborescence.
|
||||||
|
|
||||||
## Version 9.0.20
|
## Version 9.0.20
|
||||||
- Correction :
|
- Correction :
|
||||||
- Footer : Taille de la police du numéro de version
|
- Footer : Taille de la police du numéro de version
|
||||||
|
@ -553,14 +553,29 @@ class common {
|
|||||||
$children = [];
|
$children = [];
|
||||||
// Exclure les barres
|
// Exclure les barres
|
||||||
if ($this->getData(['page', $parentId, 'block']) !== 'bar' ) {
|
if ($this->getData(['page', $parentId, 'block']) !== 'bar' ) {
|
||||||
$parents [] = ['title' => $this->getData(['page', $parentId, 'title']) ,
|
// Boucler sur les enfants et récupérer le tableau children avec la liste des enfants
|
||||||
'value'=> $rewrite.$parentId
|
foreach($childIds as $childId) {
|
||||||
];
|
$children [] = [ 'title' => ' » '. $this->getData(['page', $childId, 'title']) ,
|
||||||
foreach($childIds as $childId) {
|
|
||||||
$parents [] = ['title' => $this->getData(['page', $parentId, 'title']) . ' / '. $this->getData(['page', $childId, 'title']) ,
|
|
||||||
'value'=> $rewrite.$childId
|
'value'=> $rewrite.$childId
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
// Traitement
|
||||||
|
if (empty($childIds)) {
|
||||||
|
// Pas d'enfant, uniuement l'entrée du parent
|
||||||
|
$parents [] = ['title' => $this->getData(['page', $parentId, 'title']) ,
|
||||||
|
'value'=> $rewrite.$parentId
|
||||||
|
];
|
||||||
|
} else {
|
||||||
|
// Des enfants, on ajoute la page parent en premier
|
||||||
|
array_unshift ($children , ['title' => $this->getData(['page', $parentId, 'title']) ,
|
||||||
|
'value'=> $rewrite.$parentId
|
||||||
|
]);
|
||||||
|
// puis on ajoute les enfants au parent
|
||||||
|
$parents [] = ['title' => $this->getData(['page', $parentId, 'title']) ,
|
||||||
|
'value'=> $rewrite.$parentId ,
|
||||||
|
'menu' => $children
|
||||||
|
];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user