This commit is contained in:
Michael RICOIS 2017-11-16 16:50:01 +01:00
parent b516aa748b
commit ea761282f0
5 changed files with 125 additions and 25 deletions

View File

@ -122,7 +122,7 @@ class PostController extends FrontController
'postContent' => $content['content'],
'postLink' => '',
'id_guide_post_select' => $id_post,
'id_guide_post_select' => $content['id_guide_post'],
));
$metaTags = Tools::completeMetaTags(array(

View File

@ -255,7 +255,7 @@ class PurchaseGuide extends Module
$rewrite = $category->getLinkRewrite($cookie->id_lang);
$smarty->assign(array(
'link_rewrite' => '/guide/'.$rewrite,
'link_rewrite' => 'guide/'.$rewrite,
));
return $this->display(dirname(__FILE__), '/views/templates/hook/topmenulink.tpl');
@ -263,12 +263,17 @@ class PurchaseGuide extends Module
public function hookLeftColumn($params)
{
global $cookie, $smarty;
global $cookie, $smarty, $site_version, $page_name;
if (!in_array($page_name, array('rubrique', 'post'))) {
return false;
}
$id_category = Tools::getValue('cid', 0);
// Récup de l'arbre en fonction des catégories
$model = new GuideCategory($id_category);
if ($model->id_parent == 0) {
$id_main_category = $id_category;
$id_child_category = 0;

View File

@ -1,22 +1,22 @@
{include file="$tpl_dir./breadcrumb.tpl"}
<h1>Guide d'achat - {$categoryTitle}</h1>
<div class="rte{if $content_only} content_only{/if}">
<div class="content-guide rte{if $content_only} content_only{/if}">
<div>
<div style="width:50%;float:left;">
<div class="guide-intro">
<div class="guide-intro-left">
<h2>{$subcategoryTitle}</h2>
<div>
<p>{$subcategoryContent}</p>
</div>
</div>
<div>
<div class="guide-intro-right">
<img alt="" src="{$subcategoryImg}"/>
</div>
</div>
<div class="clear">
<div style="width:24%;float:left;">
<div class="guide-content">
<div class="guide-content-menu">
<ul>
{foreach from=$postList item=p}
<li{if $p.id_guide_post==$id_guide_post_select} class="selected"{/if}>
@ -26,7 +26,7 @@
</ul>
</div>
<div style="width:75%;float:right;">
<div class="guide-content-txt">
<h3>{$postTitle}</h3>
<p>{$postContent}</p>
</div>

View File

@ -6,7 +6,9 @@
<ul class="block_content">
{foreach from=$c.children item=children name=loopChild}
{assign var="class" value=""}
{if $id_guide_category_select_child==0 && $smarty.foreach.loopChild.first}
{if $id_guide_category_select_child==0
&& $c.id_guide_category==$id_guide_category_select_main
&& $smarty.foreach.loopChild.first}
{assign var="class" value="selected"}
{/if}
{if $children.id_guide_category==$id_guide_category_select_child}

View File

@ -1852,7 +1852,7 @@ body#page-404 .footer_links {
/** SUBMENU **/
.container_submenu {
border-top: 4px solid #70bc2c;
height: 380px;
height: 400px;
left: 0;
position: absolute;
overflow: hidden;
@ -1902,10 +1902,20 @@ li.active .container_submenu .content_submenu {
}
.container_submenu .content_footer {
display: block;
width: 100%;
margin: 0 auto;
position: absolute;
bottom: 0;
bottom: 0;
background-color: #fff;
padding:15px 0;
color: #666666;
font-size: 14px;
font-weight: bold;
}
.container_submenu .content_footer a,
.container_submenu .content_footer a:hover,
.container_submenu .content_footer a:visited {
color: #ec15ac;
}
.submenu {
width: 965px;
@ -7463,19 +7473,102 @@ div.addresses ul.address.item {
.block-guide {
margin-bottom: 20px;
background: #f6f6f6;
-moz-box-shadow: 1px 2px 1px #cccccc;
-webkit-box-shadow: 1px 2px 1px #cccccc;
-ms-box-shadow: 1px 2px 1px #cccccc;
-o-box-shadow: 1px 2px 1px #cccccc;
box-shadow: 1px 2px 1px #cccccc;
background: #fff;
padding: 10px 20px;
}
.block-guide h4 {
font-size:14px;
}
.block-guide h5 {
font-size:12px;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
background: #fff;
-moz-box-shadow: 2px 2px 5px #cccccc;
-webkit-box-shadow: 2px 2px 5px #CCC;
-ms-box-shadow: 2px 2px 5px #cccccc;
-o-box-shadow: 2px 2px 5px #cccccc;
box-shadow: 2px 2px 5px #ccc;
color: #1e1633;
}
.block-guide ul {
margin-left: 5px;
margin: 0px;
list-style: none outside;
margin-left: 5px;
}
.block-guide h5 {
margin-top: 10px;
}
.block-guide h5 a {
font-style: normal;
font-weight: bold;
font-size: 14px;
line-height: 1.5em;
color: #000;
}
.block-guide h5 a.selected {
color: #796dc7;
}
.block-guide ul li a {
margin: 0 0 0 10px;
color: #000;
}
.block-guide ul li.selected a {
color: #796dc7;
}
.guide-intro {}
.guide-intro-left {
width: 430px;
float: left;
color: #1e1633;
background: #fff;
font-size: 26px;
text-transform: none;
line-height: 1.5em;
font-weight: normal;
text-align: left;
margin: 0px 5px 20px 0px;
min-height: 180px;
padding: 10px 0px 0px 20px;
-moz-box-shadow: 2px 2px 5px #cccccc;
-webkit-box-shadow: 2px 2px 5px #cccccc;
-ms-box-shadow: 2px 2px 5px #cccccc;
-o-box-shadow: 2px 2px 5px #cccccc;
box-shadow: 2px 2px 5px #cccccc;
}
.guide-intro-right {}
.guide-content {
clear: both;
}
.guide-content-menu {
width: 160px;
float: left;
background: #fff;
font-size: 26px;
text-transform: none;
line-height: 1.5em;
font-weight: normal;
text-align: left;
margin: 0px 5px 0px 0px;
padding: 10px 0px 10px 0px;
-moz-box-shadow: 2px 2px 5px #cccccc;
-webkit-box-shadow: 2px 2px 5px #cccccc;
-ms-box-shadow: 2px 2px 5px #cccccc;
-o-box-shadow: 2px 2px 5px #cccccc;
box-shadow: 2px 2px 5px #cccccc;
}
.guide-content ul {
margin: 0px;
list-style: none outside;
}
.guide-content ul li a {
color: #000;
}
.guide-content ul li.selected a {
font-weight: bold;
color: #796dc7;
}
.guide-content-txt {
width:580px;
float: right;
padding: 0 5px;
}