forked from ZwiiCMS-Team/ZwiiCMS
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
|
||||
echo '<h1 id="sectionTitle">' . $this->core->output['title'] . '</h1>';
|
||||
// echo '<h1 id="sectionTitle">' . $this->core->output['title'] . '</h1>';
|
||||
// remplacé par :
|
||||
//echo '<h2 id="sectionTitle">';
|
||||
//if ($this->getData(['page', $this->getUrl(0), 'parentPageId']) !== '' ) {
|
||||
// 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 '<h2 id="sectionTitle">';
|
||||
if ( !empty($this->getData(['page', $this->getUrl(0), 'parentPageId'])) &&
|
||||
$this->getData(['page', $this->getUrl(0), 'includeParent'])) {
|
||||
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'] . '</h2>';
|
||||
// Fin modif
|
||||
|
||||
}
|
||||
echo $this->core->output['content'];
|
||||
}
|
||||
|
@ -65,6 +65,7 @@ class page extends common {
|
||||
'disable' => false,
|
||||
'content' => 'Contenu de votre nouvelle page.',
|
||||
'hideTitle' => false,
|
||||
'includeParent' => false,
|
||||
'metaDescription' => '',
|
||||
'metaTitle' => '',
|
||||
'moduleId' => '',
|
||||
@ -226,6 +227,7 @@ class page extends common {
|
||||
'disable'=> $this->getinput('pageDisable', helper::FILTER_BOOLEAN),
|
||||
'content' => (empty($this->getInput('pageEditContent', null)) ? "<p></p>" : $this->getInput('pageEditContent', null)) ,
|
||||
'hideTitle' => $this->getInput('pageEditHideTitle', helper::FILTER_BOOLEAN),
|
||||
'includeParent' => $this->getInput('pageEditIncludeParent', helper::FILTER_BOOLEAN),
|
||||
'metaDescription' => $this->getInput('pageEditMetaDescription', helper::FILTER_STRING_LONG),
|
||||
'metaTitle' => $this->getInput('pageEditMetaTitle'),
|
||||
'moduleId' => $this->getInput('pageEditModuleId'),
|
||||
|
@ -217,8 +217,33 @@ if ($("#pageEditBlock").val() === "bar") {
|
||||
$("#pageEditTargetBlankWrapper").addClass("disabled");
|
||||
$("#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 class="row">
|
||||
<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 class="col6">
|
||||
@ -119,6 +116,18 @@
|
||||
]); ?>
|
||||
</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>
|
||||
|
Loading…
x
Reference in New Issue
Block a user