Commit 2fc92e00 authored by imac's avatar imac

[Update]Redmine #649 : Structural change + fixed menu

parent 76e735c6
......@@ -954,9 +954,7 @@ footer{
/* ==========================================================================
VII/ Pages...............ALL pages
========================================================================== */
/* --------------*/ /* ---------->>> HOME <<<-----------*/ /* --------------*/
#home {
position: relative;
height: 100%;
......@@ -970,6 +968,10 @@ VII/ Pages...............ALL pages
.img-wrapper img{
display: none;
}
#home .img-wrapper.fixed{
position: fixed;
left: 0;
}
.news-btn{
position: absolute;
top: 50px;
......@@ -1782,7 +1784,7 @@ label.chevron.bottom::first-letter {
}
.container-bg{
position: fixed;
z-index: 99;
z-index: 9999999;
background-size: cover;
opacity: 0;
}
......@@ -2169,6 +2171,9 @@ label.chevron.bottom::first-letter {
padding: 0px 10px 0px 15px;
padding-bottom: 100px;
}
.right-container .contact-wrapper .right-panel{
padding: 0px;
}
.panel section > h2{
padding-top: 80px;
}
......@@ -2295,10 +2300,10 @@ label.chevron.bottom::first-letter {
padding-top: 30px;
}
/* --------------*/ /* ---------->>> Uniqpaper <<<-----------*/ /* --------------*/
#uniqpaper .cover-wrapper{
#cat-151 .cover-wrapper{
top: 0;
}
#uniqpaper .right-container .left-panel {
#cat-151 .right-container .left-panel {
width: 47.2%;
}
.floated-bloc{
......
......@@ -201,7 +201,7 @@
padding: 65px 20px;
}
/*Uniqpaper*/
#uniqpaper .right-container .left-panel {
#cat-151 .right-container .left-panel {
width: 34%;
}
.floated-bloc{
......@@ -219,6 +219,9 @@
.contact-form .footer{
padding: 30px 22px 32px;
}
.right-container .contact-wrapper .right-panel{
padding: 0px;
}
/* Catalogue */
.right-container .left-panel{
width: 37%;
......@@ -288,6 +291,9 @@
.right-panel-wrapper{
top: 0px !important;
}
.container-bg{
height: auto !important;
}
}
@media screen and (max-width: 860px) {
/* general */
......@@ -317,6 +323,12 @@
.rounded{
padding: 8px 22px 11px;
}
.mobile-nav{
display: none;
}
#catalogue .mobile-nav{
display: block;
}
/* Helper */
.close-btn{
top: 15px;
......@@ -388,12 +400,12 @@
letter-spacing: 0px;
}
/*Uniqpaper*/
#uniqpaper .right-container .left-panel {
#cat-151 .right-container .left-panel {
position: relative;
width: 100%;
left: initial !important;
}
#uniqpaper .cover-wrapper{
#cat-151 .cover-wrapper{
display: block;
}
.floated-bloc{
......
This diff is collapsed.
......@@ -110,13 +110,13 @@ jQuery(document).ready(function() {
jQuery(window).bind("popstate", function(e) {
/*jQuery(window).bind("popstate", function(e) {
var state = e.originalEvent.state;
if ( state === null ) {
var back_link = jQuery('.close-panel .circle-btn a').attr('href');
window.location.href = back_link;
}
});
});*/
});
......
<?php
/**
* Template Name: Contact
*
*/
get_header();
* Template Name: Contact
*
*/
$post_ID = 157;
if (!(isset($_POST['ajax']))) {
get_template_part( 'header', 'page-content' );
}
?>
<div class="container clearfix" id="contact" data-page = "contact">
<div class="container-bg abs-full"></div>
<?php get_sidebar(); ?>
<div class="contact-wrapper">
<div class="right-container">
<div class="hidden data-elem" data-postid ="cat-<?php echo $post_ID ?>" data-page = "<?php echo $post_ID ?>"></div>
<div class="contact-wrapper">
<div class="left-panel fixed-full position--after-menu ">
<div class="map">
<object id="map" type="image/svg+xml" data="<?php echo home_url('wp-content/themes/nap/assets/css/img/departements2.svg') ?>"></object>
</div>
</div>
</div>
<div class="right-panel full-height right">
<div class="filter-wrapper search-filter fixed full-height form-wrapper border-l row">
<div class="header-filter-contact">
......@@ -28,7 +25,6 @@ $post_ID = 157;
<form id="map-search" method="get" action='contact.php'>
<p class="form-element">
<span class = "chevron bottom"></span>
<select id="selectCountry" >
<?php
if (get_field('contact_pays', $post_ID)):
......@@ -42,16 +38,13 @@ $post_ID = 157;
endif;
?>
</select>
</p>
<p class="form-element cp">
<input placeholder="Code postal" class="search" id="search" type="text" name="search">
<input class ="search-btn" type="submit" />
</p>
</form>
</div>
<?php
if (get_field('zones_commerciaux', $post_ID)):
$i = 0;
......@@ -61,7 +54,6 @@ $post_ID = 157;
<figure style="background-image:url(<?php the_sub_field('photo_commercial'); ?>)"></figure>
<?php the_sub_field('infos_commercial'); ?>
</div>
<?php
// list zones par commercial
if (get_sub_field('list_zones', $post_ID)):
......@@ -93,10 +85,8 @@ $post_ID = 157;
<figure style="background-image:url(<?php echo get_field('photo_groupement', $post_ID) ?>)"></figure>
<?php echo get_field('contact_groupement', $post_ID) ?>
</div>
</div>
</div>
</div>
<div class="contact-form right border-l row gray-bg">
<div class="form-wrapper inner-form">
......@@ -104,23 +94,6 @@ $post_ID = 157;
<h2>Je souhaite être <br> contacté</h2>
<span class="open-filter abs-full display--only-mobile"></span>
</div>
<!--<form method="POST">
<div class="clearfix">
<div class="row left half-col">
<input placeholder = "Nom" type="text" name="name" id="name" value="" />
<input placeholder = "Prénom" type="text" name="fname" id="fname" value="" />
</div>
<div class="row right half-col">
<input placeholder = "Mail" type="text" name="mail" id="mail" value="" />
<input placeholder = "Téléphone" type="text" name="phone" id="phone" value="" />
</div>
<textarea name="message" id="message" title="Message" placeholder="Message"></textarea>
</div>
<input type = "submit" class="btn pink-btn rounded" value = 'Envoyer'>
</form>-->
<?php echo do_shortcode( '[contact-form-7 id="558" title="Contact form"]' ); ?>
</div>
<div class="footer blue-bg abs font-small">
......@@ -136,6 +109,9 @@ $post_ID = 157;
</div>
</div>
</div>
</div>
</div>
<?php get_footer(); ?>
\ No newline at end of file
<?php
if (!(isset($_POST['ajax']))) {
get_template_part( 'footer', 'page-content' );
}
?>
</div> <!-- END right-container -->
<?php
if (!(isset($_POST['ajax']))) {
get_footer();
} ?>
......@@ -63,7 +63,7 @@
</div>
</div>
</div>
<div id="loading-container-subpage">
<div id="loading-container-subpage" class = "loading-container-subpage">
<div class="loading-wrapper">
<div class="loading">
<div id="loading-center-absolute">
......
<?php
get_header();
get_sidebar();
$url = nap_attachment_image($ID);
?>
<div id="home">
<div class="container-bg abs-full hidden"></div>
<?php get_sidebar(); ?>
<div data-defaultimg ='<?php echo $url ;?>' class="transition img-wrapper" style ="background-image: url('<?php echo $url ;?>')"></div>
<div class="header mobile-nav display--only-mobile blue-bg fixed">
<div class="nav-wrapper blue-bg">
<ul></ul>
</div>
</div>
<div class="right-container">
<div class="news-btn circle-btn add-icon font-small animated zoomIn"><span>Nouveautés</span></div>
<aside class="news-wrapper container ">
<div class="news-header crete">
......@@ -31,7 +44,6 @@ $url = nap_attachment_image($ID);
endwhile;
endif;
?>
</div>
</aside>
<!--Menu for mobile-->
......@@ -43,8 +55,9 @@ $url = nap_attachment_image($ID);
</div>
</div>
</div>
</div><!--END home -->
<?php
</div><!--END home -->
</div>
<?php
get_footer();
get_footer();
......@@ -310,7 +310,7 @@ function nap_menu() {
} else {
$nappe_sets = false;
}
$menu.= '<li class ="parent-cat to-slide" data-page = "' . $category_id . '" data-img = "' . nap_category_image($category_id) . '"><a href="' . get_term_link($cat->slug, 'product_cat') . '">' . $cat->name . '</a>';
$menu.= '<li class ="parent-cat to-slide-cat" data-page = "' . $category_id . '" data-img = "' . nap_category_image($category_id) . '"><a href="' . get_term_link($cat->slug, 'product_cat') . '">' . $cat->name . '</a>';
$args2 = array(
'taxonomy' => $taxonomy,
......
<?php
if (!defined('ABSPATH')) {
exit; // Exit if accessed directly
}
if (!(isset($_POST['ajax']))) {
get_header();
}
$product;
$cate = get_queried_object();
$extClass = "";
if (is_product_category()){
$cateID = $cate->term_id;
$id = "catalogue";
}else{
$cateID = get_the_ID();
$id = 'cat-'.$cateID;
}
if ($cateID == 154){ //page stories
$extClass = "full-slides right";
}
?>
<div class="container clearfix" id="<?php echo $id ?>" data-page = "<?php echo $cateID; ?>">
<?php if (!(isset($_POST['ajax']))) { ?>
<?php if ($cateID == 154){ //page stories ?>
<div class="container-bg abs-full" style="background-image: url('<?php echo nap_attachment_image(154);?>')"></div>
<?php } else { ?>
<div class="container-bg abs-full"></div>
<?php } ?>
<?php get_sidebar(); } ?>
<?php if (is_product_category()){ ?>
<div class="header mobile-nav display--only-mobile blue-bg fixed">
<div class="nav-wrapper blue-bg">
<ul></ul>
</div>
</div>
<?php } // is_product_category ?>
<div class="right-container <?php echo $extClass ?>">
......@@ -32,4 +32,3 @@
</div>
</div>
<div class="main">
......@@ -5,17 +5,14 @@
$arrow = 'arrow-blue phototheque';
}
?>
<ul class = "main-list-nav <?php echo $arrow ?>">
<?php echo nap_menu(); ?>
<li class="to-slide" data-page = "uniqpaper" data-img = "<?php echo nap_attachment_image(151);?>"><a href="<?php echo get_permalink(151);?>">Personnalisation</a></li>
<li class="to-slide-cat" data-page = "151" data-img = "<?php echo nap_attachment_image(151);?>"><a href="<?php echo get_permalink(151);?>">Personnalisation</a></li>
</ul>
<?php if (!(isset($current_page) and $current_page == 'phototheque')) { ?>
<?php if (!(isset($current_page) and $current_page == 'phototheque')) { ?>
<ul class= "font-medium arrow-pink pink-list">
<li class="to-slide" data-page = "stories" data-img = "<?php echo nap_attachment_image(154);?>"><a href="<?php echo get_permalink(154);?>">Stories</a></li>
<li class="to-slide" data-page = "contact" data-img = "<?php echo nap_attachment_image(157);?>" ><a href="<?php echo get_permalink(157);?>">Contact</a></li>
<li class="to-slide-cat" data-page = "154" data-img = "<?php echo nap_attachment_image(154);?>"><a href="<?php echo get_permalink(154);?>">Stories</a></li>
<li class="to-slide-cat" data-page = "157" data-img = "<?php echo nap_attachment_image(157);?>" ><a href="<?php echo get_permalink(157);?>">Contact</a></li>
</ul>
<?php } ?>
<?php } ?>
</div>
<?php
/**
* Template Name: Stories
*
*/
get_header();
* Template Name: Stories
*
*/
$post_ID = get_the_ID();
if (!(isset($_POST['ajax']))) {
get_template_part( 'header', 'page-content' );
}
?>
<div class="container clearfix" data-page = "stories">
<div class="container-bg abs-full" style="background-image: url('<?php echo nap_attachment_image(154);?>')"></div>
<?php get_sidebar(); ?>
<div class="full-slides right-container right">
<div id="fullpage">
<div class="hidden data-elem" data-postid ="cat-<?php echo $post_ID ?>" data-page = "<?php echo $post_ID ?>" data-class="full-slides right"></div>
<div id="fullpage">
<span class = "moveDown chevron bottom hidden-elem"></span>
<?php
if (get_field('stories', 154)):
while (has_sub_field('stories', 154)) :
?>
<div class="section " style = "background-image:url('<?php the_sub_field('st_image'); ?>')">
......@@ -32,10 +31,9 @@ get_header();
endwhile;
endif;
?>
</div>
</div>
</div>
<?php
get_footer();
if (!(isset($_POST['ajax']))) {
get_template_part( 'footer', 'page-content' );
}
?>
<?php
/**
* Template Name: Personnalisation
*
*/
get_header(); ?>
<div class="container clearfix" id="uniqpaper" data-page = "uniqpaper">
<div class="container-bg abs-full"></div>
<?php get_sidebar(); ?>
<div class="right-container">
<div class="left-panel fixed-full position--after-menu ">
* Template Name: Personnalisation
*
*/
$post_ID = get_the_ID();
if (!(isset($_POST['ajax']))) {
get_template_part( 'header', 'page-content' );
}
?>
<div class="hidden data-elem" data-postid ="cat-<?php echo $post_ID ?>" data-page = "<?php echo $post_ID ?>"></div>
<div class="left-panel fixed-full position--after-menu ">
<div class="cover-wrapper abs-full transition" style = "background-image: url('<?php echo get_field('pers_image',151)?>')"></div>
<div class="abs floated-bloc">
<h2><?php echo get_field('pers_titre',151)?></h2>
<div class="text-content"><?php echo get_field('pers_texte',151)?></div>
</div>
</div>
</div>
<div class="right-panel right">
</div>
<div class="right-panel right">
<div class="form-wrapper clearfix">
<!--<form action="#" method="POST">
<h2>Information sur le produit</h2>
<textarea name = "description" placeholder="Describe yourself here..."> </textarea>
<h2>Vos coordonnées</h2>
<div class="clearfix">
<div class="row left half-col">
<input placeholder = "Nom" type="text" name="name" id="name" value="" />
<input placeholder = "Prénom" type="text" name="fname" id="fname" value="" />
<input placeholder = "Société" type="text" name="soc" id="soc" value="" />
</div>
<div class="row right half-col">
<input placeholder = "Mail" type="text" name="mail" id="mail" value="" />
<input placeholder = "Téléphone" type="text" name="phone" id="phone" value="" />
</div>
</div>
<div class="center">
<input type = "submit" class="btn pink-btn rounded" value = 'Envoyer'>
</div>
</form>-->
<?php echo do_shortcode( '[contact-form-7 id="663" title="Personnalisation form"]' ); ?>
</div>
</div>
</div>
<?php get_footer();
\ No newline at end of file
<?php
if (!(isset($_POST['ajax']))) {
get_template_part( 'footer', 'page-content' );
}
?>
<?php
//print_r($_GET);
/**
* The Template for displaying product archives, including the main shop page which is a post type archive
*
* This template can be overridden by copying it to yourtheme/woocommerce/archive-product.php.
*
* HOWEVER, on occasion WooCommerce will need to update template files and you
* (the theme developer) will need to copy the new files to your theme to
* maintain compatibility. We try to do this as little as possible, but it does
* happen. When this occurs the version of the template file will be bumped and
* the readme will list any important changes.
*
* @see https://docs.woocommerce.com/document/template-structure/
* @author WooThemes
* @package WooCommerce/Templates
* @version 2.0.0
*/
if (!defined('ABSPATH')) {
exit; // Exit if accessed directly
}
$current_page = 'catalogue';
* The Template for displaying product archives, including the main shop page which is a post type archive
*
* This template can be overridden by copying it to yourtheme/woocommerce/archive-product.php.
*
* HOWEVER, on occasion WooCommerce will need to update template files and you
* (the theme developer) will need to copy the new files to your theme to
* maintain compatibility. We try to do this as little as possible, but it does
* happen. When this occurs the version of the template file will be bumped and
* the readme will list any important changes.
*
* @see https://docs.woocommerce.com/document/template-structure/
* @author WooThemes
* @package WooCommerce/Templates
* @version 2.0.0
*/
?>
<?php
$product;
$cate = get_queried_object();
if (!(isset($_POST['ajax']))) {
get_header();
set_query_var( 'cateID',$cate->term_id);
get_template_part( 'header', 'page-content' );
}
$current_page = 'catalogue';
$product;
$cate = get_queried_object();
$cateID = $cate->term_id;
//SubCats
# JC 20170901
#$child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of' => the_category_ID(), 'exclude' => $cateID, 'orderby' => 'title', 'order' => 'ASC'));
$child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of' => the_category_ID(), 'exclude' => $cateID, 'orderby' => 'meta_value_num', 'meta_key' => 'order', 'order' => 'ASC'));
# JC 20170901 end
?>
<div class="container clearfix" id="catalogue" data-page = "<?php echo $cateID; ?>">
<?php if (!(isset($_POST['ajax']))) { ?>
<div class="container-bg abs-full"></div>
<?php get_sidebar(); } ?>
<div class="header mobile-nav display--only-mobile blue-bg fixed">
<div class="nav-wrapper blue-bg">
<ul></ul>
</div>
</div>
<div class="right-container">
<div class="left-panel fixed-full position--after-menu ">
<div class="left-panel fixed-full position--after-menu catlog-panel">
<?php if ($cateID != 20): ?>
<div class="filter-wrapper">
<div class="filter-btn fixed position--after-menu">
......@@ -98,12 +87,9 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
$filter_format = nap_selected_filter($_GET['pa_format'], $term);
$filter_matiere = nap_selected_filter($_GET['pa_matiere'], $term);
$filter_univers = nap_selected_filter($_GET['pa_univers'], $term);
?>
<li class="<?php echo $filter_format . ' ' . $filter_matiere .' '.$filter_univers ?>"><?php echo $term; ?></li>
<?php
endif;
endforeach;
foreach (array_unique($colors) as $name => $code) {
......@@ -116,18 +102,13 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
}
if ($value == 'pa_couleur'):
?>
<li class="reinit">Tout déselectionner</li>
<?php endif; ?>
</ul>
</div>
<?php endif; ?>
</div>
<?php endforeach; ?>
<div class="center filter-btn-list">
<div class="btn pink-btn rounded" id="search-btn">Rechercher</div>
<span class = "reinit-all">Effacer les filtres</span>
......@@ -154,11 +135,8 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
<div class="panel panel-content list-animation">
<?php if ($_GET['pa_couleur'] != '' || $_GET['pa_format'] != '' || $_GET['pa_matiere'] != '' || $_GET['pa_univers'] != '' || $_GET['sku'] != ''): ?>
<span class="search_result">Résultat de votre recherche :<span class="search_notfound" style="color:#ff6a5f"></span></span>
<?php endif; ?>
<?php foreach ($child_category as $key => $value) : ?>
<section id = "cat<?php echo $value->term_id ?>">
<h2 class="crete small-title"><?php echo $value->name ?></h2>
<div class="cover-mobile display--only-mobile animated fadeInUp" style = "background-image: url('<?php echo nap_category_image($value->term_id) ?>')">
......@@ -174,11 +152,9 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
# JC 20170901 end
$naps_posts = new WP_Query($args);
$options = array();
while ($naps_posts->have_posts()) : $naps_posts->the_post();
$id = get_the_ID();
$list_att = array();
$options['size'] = (get_field('produit_affichage', $id)) ? get_field('produit_affichage', $id) : 'small';
$args = array(
'post_type' => array('product', 'product_variation'),
......@@ -192,16 +168,12 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
$attribute_value['pa_format'] = get_the_terms($id, 'pa_format');
$attribute_value['pa_matiere'] = get_the_terms($id, 'pa_matiere');
$attribute_value['pa_univers'] = get_the_terms($id, 'pa_univers');
//var_dump($attribute_value['pa_format']);
if (is_array($attribute_value['pa_format'])) {
$list_formats ='';
foreach ($attribute_value['pa_format'] as $key => $value) {
$list_formats .= $value->name.',';
}
$list_att['pa_format'] = explode(',',$list_formats);
}
......@@ -214,16 +186,13 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
}
$list_att['pa_couleur'] = explode(',',$list_couleurs);
}
if (is_array($attribute_value['pa_format'])) {
$list_formats ='';
foreach ($attribute_value['pa_format'] as $key => $value) {
$list_formats .= $value->name.',';
}
$list_att['pa_format'] = explode(',',$list_formats);
}
if (is_array($attribute_value['pa_matiere'])) {
foreach ($attribute_value['pa_matiere'] as $key => $value) {
$list_att['pa_matiere'] = $value->name;
......@@ -234,7 +203,6 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
$list_att['pa_univers'] = $value->name;
}
}
nap_filter_attribute($id, $args, $options, $list_att, $_GET);
} else {
echo nap_get_item($id, $args, $current_page, $options);
......@@ -246,10 +214,9 @@ $child_category = get_terms('product_cat', array('parent' => $cateID, 'child_of'
</section>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<?php
if (!(isset($_POST['ajax']))) {
get_footer();
} ?>
get_template_part( 'footer', 'page-content' );
}
?>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment