Breadcumb paramétable la page
This commit is contained in:
parent
5de140b0e4
commit
ed0cd3b836
@ -1992,15 +1992,17 @@ class layout extends common {
|
|||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
// Chemin de fer pour le titre avec des enfants
|
// Chemin de fer pour le titre avec des enfants
|
||||||
echo '<h1 id="sectionTitle">' . $this->core->output['title'] . '</h1>';
|
// echo '<h1 id="sectionTitle">' . $this->core->output['title'] . '</h1>';
|
||||||
// remplacé par :
|
// remplacé par :
|
||||||
//echo '<h2 id="sectionTitle">';
|
echo '<h2 id="sectionTitle">';
|
||||||
//if ($this->getData(['page', $this->getUrl(0), 'parentPageId']) !== '' ) {
|
if ( !empty($this->getData(['page', $this->getUrl(0), 'parentPageId'])) &&
|
||||||
// echo '<a href="' . helper::baseUrl() . $this->getData(['page', $this->getUrl(0), 'parentPageId']) .'">';
|
$this->getData(['page', $this->getUrl(0), 'includeParent'])) {
|
||||||
// echo ucfirst($this->getData(['page', $this->getUrl(0), 'parentPageId'])) . '</a> > ';
|
echo '<a href="' . helper::baseUrl() . $this->getData(['page', $this->getUrl(0), 'parentPageId']) .'">';
|
||||||
//}
|
echo ucfirst($this->getData(['page', $this->getUrl(0), 'parentPageId'])) . '</a> > ';
|
||||||
// echo $this->core->output['title'] . '</h1>';
|
}
|
||||||
|
echo $this->core->output['title'] . '</h2>';
|
||||||
// Fin modif
|
// Fin modif
|
||||||
|
|
||||||
}
|
}
|
||||||
echo $this->core->output['content'];
|
echo $this->core->output['content'];
|
||||||
}
|
}
|
||||||
|
@ -65,6 +65,7 @@ class page extends common {
|
|||||||
'disable' => false,
|
'disable' => false,
|
||||||
'content' => 'Contenu de votre nouvelle page.',
|
'content' => 'Contenu de votre nouvelle page.',
|
||||||
'hideTitle' => false,
|
'hideTitle' => false,
|
||||||
|
'includeParent' => false,
|
||||||
'metaDescription' => '',
|
'metaDescription' => '',
|
||||||
'metaTitle' => '',
|
'metaTitle' => '',
|
||||||
'moduleId' => '',
|
'moduleId' => '',
|
||||||
@ -226,6 +227,7 @@ class page extends common {
|
|||||||
'disable'=> $this->getinput('pageDisable', helper::FILTER_BOOLEAN),
|
'disable'=> $this->getinput('pageDisable', helper::FILTER_BOOLEAN),
|
||||||
'content' => (empty($this->getInput('pageEditContent', null)) ? "<p></p>" : $this->getInput('pageEditContent', null)) ,
|
'content' => (empty($this->getInput('pageEditContent', null)) ? "<p></p>" : $this->getInput('pageEditContent', null)) ,
|
||||||
'hideTitle' => $this->getInput('pageEditHideTitle', helper::FILTER_BOOLEAN),
|
'hideTitle' => $this->getInput('pageEditHideTitle', helper::FILTER_BOOLEAN),
|
||||||
|
'includeParent' => $this->getInput('pageEditIncludeParent', helper::FILTER_BOOLEAN),
|
||||||
'metaDescription' => $this->getInput('pageEditMetaDescription', helper::FILTER_STRING_LONG),
|
'metaDescription' => $this->getInput('pageEditMetaDescription', helper::FILTER_STRING_LONG),
|
||||||
'metaTitle' => $this->getInput('pageEditMetaTitle'),
|
'metaTitle' => $this->getInput('pageEditMetaTitle'),
|
||||||
'moduleId' => $this->getInput('pageEditModuleId'),
|
'moduleId' => $this->getInput('pageEditModuleId'),
|
||||||
|
@ -217,8 +217,33 @@ if ($("#pageEditBlock").val() === "bar") {
|
|||||||
$("#pageEditTargetBlankWrapper").addClass("disabled");
|
$("#pageEditTargetBlankWrapper").addClass("disabled");
|
||||||
$("#pageEditTargetBlankWrapper").slideDown();
|
$("#pageEditTargetBlankWrapper").slideDown();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Masquer ou afficher le chemin de fer
|
||||||
|
*/
|
||||||
|
|
||||||
|
var pageEditHideTitleDOM = $("#pageEditHideTitle");
|
||||||
|
pageEditHideTitleDOM.on("change", function() {
|
||||||
|
if ($(this).is(':checked')) {
|
||||||
|
$("#pageEditIncludeParentWrapper").removeClass("disabled");
|
||||||
|
$("#pageEditIncludeParentWrapper").slideUp();
|
||||||
|
} else {
|
||||||
|
$("#pageEditIncludeParentWrapper").addClass("disabled");
|
||||||
|
$("#pageEditIncludeParentWrapper").slideDown();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
var pageEditParentPageIdDOM = $("#pageEditParentPageId");
|
||||||
|
pageEditParentPageIdDOM.on("change", function() {
|
||||||
|
if ($(this).val() === "") {
|
||||||
|
console.log('true');
|
||||||
|
$("#pageEditIncludeParentWrapper").removeClass("disabled");
|
||||||
|
$("#pageEditIncludeParentWrapper").slideUp();
|
||||||
|
} else {
|
||||||
|
console.log('faux');
|
||||||
|
$("#pageEditIncludeParentWrapper").addClass("disabled");
|
||||||
|
$("#pageEditIncludeParentWrapper").slideDown();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -55,9 +55,6 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col6">
|
<div class="col6">
|
||||||
<?php echo template::checkbox('pageEditHideTitle', true, 'Cacher le titre dans la page', [
|
|
||||||
'checked' => $this->getData(['page', $this->getUrl(2), 'hideTitle'])
|
|
||||||
]); ?>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="col6">
|
<div class="col6">
|
||||||
@ -119,6 +116,18 @@
|
|||||||
]); ?>
|
]); ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col6">
|
||||||
|
<?php echo template::checkbox('pageEditHideTitle', true, 'Masquer le titre ', [
|
||||||
|
'checked' => $this->getData(['page', $this->getUrl(2), 'hideTitle'])
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
<div class="col6">
|
||||||
|
<?php echo template::checkbox('pageEditIncludeParent', true, 'Nom de la page parente', [
|
||||||
|
'checked' => $this->getData(['page', $this->getUrl(2), 'includeParent'])
|
||||||
|
]); ?>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user