Correction d'un souci d'affichage de la carte

This commit is contained in:
2021-04-01 13:22:31 +02:00
parent 19798d9cf5
commit a887f6892b
10 changed files with 4714 additions and 110 deletions

View File

@@ -62,7 +62,8 @@
"symfony/polyfill-php73": "^1.0", "symfony/polyfill-php73": "^1.0",
"symfony/lock": "^3.4|^4.0", "symfony/lock": "^3.4|^4.0",
"thelia/propel": "dev-thelia-2.4", "thelia/propel": "dev-thelia-2.4",
"symfony/var-dumper": "^2.0|^3.0|^4.0" "symfony/var-dumper": "^2.0|^3.0|^4.0",
"thelia/pay-plug-module": "~1.0.0"
}, },
"require-dev": { "require-dev": {
"fzaninotto/faker": "1.5.*", "fzaninotto/faker": "1.5.*",

300
composer.lock generated
View File

@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "5775e58f869179ca9e753e2556329f65", "content-hash": "5015ee747b2b1185dc163aeeba2a17fb",
"packages": [ "packages": [
{ {
"name": "commerceguys/addressing", "name": "commerceguys/addressing",
@@ -245,6 +245,123 @@
], ],
"time": "2017-01-03T10:49:41+00:00" "time": "2017-01-03T10:49:41+00:00"
}, },
{
"name": "giggsey/libphonenumber-for-php",
"version": "8.12.4",
"source": {
"type": "git",
"url": "https://github.com/giggsey/libphonenumber-for-php.git",
"reference": "cb79970730aacaedb74c8288214a5576572fa7b0"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/giggsey/libphonenumber-for-php/zipball/cb79970730aacaedb74c8288214a5576572fa7b0",
"reference": "cb79970730aacaedb74c8288214a5576572fa7b0",
"shasum": ""
},
"require": {
"ext-mbstring": "*",
"giggsey/locale": "^1.7",
"php": ">=5.3.2"
},
"require-dev": {
"pear/pear-core-minimal": "^1.9",
"pear/pear_exception": "^1.0",
"pear/versioncontrol_git": "^0.5",
"phing/phing": "^2.7",
"php-coveralls/php-coveralls": "^1.0|^2.0",
"phpunit/phpunit": "^4.8.36|^5.0",
"symfony/console": "^2.8|^3.0"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "8.x-dev"
}
},
"autoload": {
"psr-4": {
"libphonenumber\\": "src/"
},
"exclude-from-classmap": [
"/src/data/",
"/src/carrier/data/",
"/src/geocoding/data/",
"/src/timezone/data/"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"Apache-2.0"
],
"authors": [
{
"name": "Joshua Gigg",
"email": "giggsey@gmail.com",
"homepage": "https://giggsey.com/"
}
],
"description": "PHP Port of Google's libphonenumber",
"homepage": "https://github.com/giggsey/libphonenumber-for-php",
"keywords": [
"geocoding",
"geolocation",
"libphonenumber",
"mobile",
"phonenumber",
"validation"
],
"time": "2020-05-19T11:20:54+00:00"
},
{
"name": "giggsey/locale",
"version": "1.9",
"source": {
"type": "git",
"url": "https://github.com/giggsey/Locale.git",
"reference": "b07f1eace8072ccc61445ad8fbd493ff9d783043"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/giggsey/Locale/zipball/b07f1eace8072ccc61445ad8fbd493ff9d783043",
"reference": "b07f1eace8072ccc61445ad8fbd493ff9d783043",
"shasum": ""
},
"require": {
"php": ">=5.3.2"
},
"require-dev": {
"pear/pear-core-minimal": "^1.9",
"pear/pear_exception": "^1.0",
"pear/versioncontrol_git": "^0.5",
"phing/phing": "~2.7",
"php-coveralls/php-coveralls": "^1.0|^2.0",
"phpunit/phpunit": "^4.8|^5.0",
"symfony/console": "^2.8|^3.0|^4.0",
"symfony/filesystem": "^2.8|^3.0|^4.0",
"symfony/finder": "^2.8|^3.0|^4.0",
"symfony/process": "^2.8|^3.0|^4.0"
},
"type": "library",
"autoload": {
"psr-4": {
"Giggsey\\Locale\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Joshua Gigg",
"email": "giggsey@gmail.com",
"homepage": "http://giggsey.com/"
}
],
"description": "Locale functions required by libphonenumber-for-php",
"time": "2020-07-07T11:16:24+00:00"
},
{ {
"name": "imagine/imagine", "name": "imagine/imagine",
"version": "v0.7.1", "version": "v0.7.1",
@@ -585,6 +702,52 @@
], ],
"time": "2018-07-04T16:31:37+00:00" "time": "2018-07-04T16:31:37+00:00"
}, },
{
"name": "payplug/payplug-php",
"version": "3.3.1",
"source": {
"type": "git",
"url": "https://github.com/payplug/payplug-php.git",
"reference": "405b0213a423408c2c6a80a26f4bc45360062034"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/payplug/payplug-php/zipball/405b0213a423408c2c6a80a26f4bc45360062034",
"reference": "405b0213a423408c2c6a80a26f4bc45360062034",
"shasum": ""
},
"require": {
"ext-curl": "*",
"ext-openssl": "*",
"php": ">=5.3.0"
},
"require-dev": {
"phpdocumentor/phpdocumentor": "2.*",
"phpunit/phpunit": "4.6.*"
},
"type": "library",
"autoload": {
"psr-0": {
"Payplug\\": "lib/"
},
"psr-4": {
"Payplug\\": "lib/Payplug"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "PayPlug",
"email": "support@payplug.com"
}
],
"description": "A simple PHP library for PayPlug public API.",
"homepage": "https://www.payplug.com",
"time": "2015-05-06T00:00:00+00:00"
},
{ {
"name": "psr/cache", "name": "psr/cache",
"version": "1.0.1", "version": "1.0.1",
@@ -3662,6 +3825,58 @@
"description": "php 5.4 currency tools", "description": "php 5.4 currency tools",
"time": "2017-09-30T16:33:49+00:00" "time": "2017-09-30T16:33:49+00:00"
}, },
{
"name": "thelia/installer",
"version": "1.3",
"source": {
"type": "git",
"url": "https://github.com/thelia/installer.git",
"reference": "dca473563e05011c7aea3aaebc6f154fef4187fe"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thelia/installer/zipball/dca473563e05011c7aea3aaebc6f154fef4187fe",
"reference": "dca473563e05011c7aea3aaebc6f154fef4187fe",
"shasum": ""
},
"require": {
"composer-plugin-api": "^1.0||^2.0"
},
"require-dev": {
"composer/composer": "1.0.*@dev||2.0.*@dev"
},
"type": "composer-plugin",
"extra": {
"class": "Thelia\\Composer\\TheliaInstallerPlugin"
},
"autoload": {
"psr-0": {
"Thelia\\Composer": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"LGPL-3.0-or-later"
],
"authors": [
{
"name": "Manuel Raynaud",
"email": "raynaud.manu@gmail.com",
"homepage": "https://github.com/lunika"
}
],
"description": "custom installer for Thelia.",
"keywords": [
"Thelia",
"Thelia-module",
"Thelia-template"
],
"support": {
"issues": "https://github.com/thelia/installer/issues",
"source": "https://github.com/thelia/installer/tree/1.3"
},
"time": "2020-10-26T10:32:18+00:00"
},
{ {
"name": "thelia/math-tools", "name": "thelia/math-tools",
"version": "1.0.2", "version": "1.0.2",
@@ -3703,6 +3918,35 @@
"description": "Number management library", "description": "Number management library",
"time": "2015-11-05T15:52:55+00:00" "time": "2015-11-05T15:52:55+00:00"
}, },
{
"name": "thelia/pay-plug-module",
"version": "1.0.5",
"source": {
"type": "git",
"url": "https://github.com/thelia-modules/PayPlugModule.git",
"reference": "6d759873603753d7183bfbd27a33368ba8749c1c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thelia-modules/PayPlugModule/zipball/6d759873603753d7183bfbd27a33368ba8749c1c",
"reference": "6d759873603753d7183bfbd27a33368ba8749c1c",
"shasum": ""
},
"require": {
"giggsey/libphonenumber-for-php": "^8.12",
"payplug/payplug-php": "^3.2",
"thelia/installer": "~1.1"
},
"type": "thelia-module",
"extra": {
"installer-name": "PayPlugModule"
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"LGPL-3.0-or-later"
],
"time": "2021-02-18T09:05:39+00:00"
},
{ {
"name": "thelia/propel", "name": "thelia/propel",
"version": "dev-thelia-2.4", "version": "dev-thelia-2.4",
@@ -5082,58 +5326,6 @@
"notification-url": "https://packagist.org/downloads/", "notification-url": "https://packagist.org/downloads/",
"time": "2014-12-24T09:51:48+00:00" "time": "2014-12-24T09:51:48+00:00"
}, },
{
"name": "thelia/installer",
"version": "1.3",
"source": {
"type": "git",
"url": "https://github.com/thelia/installer.git",
"reference": "dca473563e05011c7aea3aaebc6f154fef4187fe"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thelia/installer/zipball/dca473563e05011c7aea3aaebc6f154fef4187fe",
"reference": "dca473563e05011c7aea3aaebc6f154fef4187fe",
"shasum": ""
},
"require": {
"composer-plugin-api": "^1.0||^2.0"
},
"require-dev": {
"composer/composer": "1.0.*@dev||2.0.*@dev"
},
"type": "composer-plugin",
"extra": {
"class": "Thelia\\Composer\\TheliaInstallerPlugin"
},
"autoload": {
"psr-0": {
"Thelia\\Composer": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"LGPL-3.0-or-later"
],
"authors": [
{
"name": "Manuel Raynaud",
"email": "raynaud.manu@gmail.com",
"homepage": "https://github.com/lunika"
}
],
"description": "custom installer for Thelia.",
"keywords": [
"Thelia",
"Thelia-module",
"Thelia-template"
],
"support": {
"issues": "https://github.com/thelia/installer/issues",
"source": "https://github.com/thelia/installer/tree/1.3"
},
"time": "2020-10-26T10:32:18+00:00"
},
{ {
"name": "webmozart/assert", "name": "webmozart/assert",
"version": "1.3.0", "version": "1.3.0",
@@ -5196,5 +5388,5 @@
"php": ">=5.6 <7.4" "php": ">=5.6 <7.4"
}, },
"platform-dev": [], "platform-dev": [],
"plugin-api-version": "2.0.0" "plugin-api-version": "1.1.0"
} }

View File

@@ -105,58 +105,9 @@
$('input[type=radio][delivery-mode]').click(function() { $('input[type=radio][delivery-mode]').click(function() {
$('div[id^="select"]').not($('#select-' + $(this).attr('delivery-mode'))).slideUp(); $('div[id^="select"]').not($('#select-' + $(this).attr('delivery-mode'))).slideUp();
$('#select-' + $(this).attr('delivery-mode')).slideDown('fast'); $('#select-' + $(this).attr('delivery-mode')).slideDown('fast');
initMapCnc();
}); });
function initMapCnc() {
const LIMITES = {
north: 50.85043724044059,
east: 2.6869845409159923,
south: 50.616717259788544,
west: 1.8122213465336767,
};
var opt = {
center: new google.maps.LatLng($("#map-center-lat-cnc").val(), $("#map-center-lon-cnc").val()),
zoom: 12,
streetViewControl: true,
mapTypeControl: true,
restriction: {
latLngBounds: LIMITES,
strictBounds: false,
}
};
if (document.getElementById('cnc_map'))
DataCnc.map = new google.maps.Map(document.getElementById('cnc_map'), opt);
displayPinsCnc();
}
function displayPinsCnc() {
var arrays = [];
$('#coordinates-cnc').eq(0).find('tr').each((r,row) => arrays.push($(row).find('td,th').map((c,cell) => $(cell).text()).toArray()))
arrays.forEach(function(place) {
var marker = new google.maps.Marker({
title: place[3],
label: place[0],
position: new google.maps.LatLng(place[1], place[2]),
map: DataCnc.map
});
});
}
/*********************************************************/
var DataCnc = {
markers: [],
map: null,
geocoder: null,
bounds: null
};
</script> </script>

View File

@@ -155,6 +155,44 @@
}); });
} }
function initMapCnc() {
const LIMITES = {
north: 50.85043724044059,
east: 2.6869845409159923,
south: 50.616717259788544,
west: 1.8122213465336767,
};
var opt = {
center: new google.maps.LatLng($("#map-center-lat-cnc").val(), $("#map-center-lon-cnc").val()),
zoom: 12,
streetViewControl: true,
mapTypeControl: true,
restriction: {
latLngBounds: LIMITES,
strictBounds: false,
}
};
if (document.getElementById('cnc_map'))
DataCnc.map = new google.maps.Map(document.getElementById('cnc_map'), opt);
displayPinsCnc();
}
function displayPinsCnc() {
var arrays = [];
$('#coordinates-cnc').eq(0).find('tr').each((r,row) => arrays.push($(row).find('td,th').map((c,cell) => $(cell).text()).toArray()))
arrays.forEach(function(place) {
var marker = new google.maps.Marker({
title: place[3],
label: place[0],
position: new google.maps.LatLng(place[1], place[2]),
map: DataCnc.map
});
});
}
/*********************************************************/ /*********************************************************/
@@ -164,6 +202,12 @@
geocoder: null, geocoder: null,
bounds: null bounds: null
}; };
var DataCnc = {
markers: [],
map: null,
geocoder: null,
bounds: null
};
if (typeof(google) === 'undefined') { if (typeof(google) === 'undefined') {
loadScript(); loadScript();

File diff suppressed because one or more lines are too long

View File

@@ -11073,3 +11073,12 @@ td.product .name > a:focus,
#sale-details .sale-information .description { #sale-details .sale-information .description {
margin-bottom: 10px; margin-bottom: 10px;
} }
/*
.sticky {
position: fixed !important;
top: 0;
width: 100%;
z-index: 3000;
}
*/

View File

@@ -47,6 +47,13 @@
{hook name="content.content-top" content="$content_id"} {hook name="content.content-top" content="$content_id"}
{assign var="cpt" value=0}
{loop type="image" name="content-images" content="$content_id"}
{$images[$cpt]['url'] = "{$IMAGE_URL}"}
{$images[$cpt]['title'] = "{$TITLE}"}
{$cpt = $cpt +1}
{/loop}
{loop name="blog.content" type="content" id=$content_id limit="1"} {loop name="blog.content" type="content" id=$content_id limit="1"}
<h1 id="main-label" class="page-header">{$TITLE}</h1> <h1 id="main-label" class="page-header">{$TITLE}</h1>
{if $CHAPO} {if $CHAPO}
@@ -54,12 +61,17 @@
{$CHAPO} {$CHAPO}
</div> </div>
{/if} {/if}
<img src="{$images[0]['url']}" alt="{$images[0]['title']}" class="recette-image-1" />
{if $DESCRIPTION} {if $DESCRIPTION}
<div class="description"> <div class="description">
{$DESCRIPTION nofilter} {$DESCRIPTION nofilter}
</div> </div>
{/if} {/if}
<img src="{$images[1]['url']}" alt="{$images[1]['title']}" class="recette-image-2" />
{ifloop rel="blog.document"} {ifloop rel="blog.document"}
<div class="documents"> <div class="documents">
<ul> <ul>

View File

@@ -159,6 +159,8 @@ GNU General Public License : http://www.gnu.org/licenses/
{hook name="main.header-bottom"} {hook name="main.header-bottom"}
</div><!-- /.header-container --> </div><!-- /.header-container -->
{hook name="main.header-bottom"}
<main class="main-container" role="main"> <main class="main-container" role="main">
<div class="container"> <div class="container">
{hook name="main.content-top"} {hook name="main.content-top"}
@@ -304,6 +306,19 @@ GNU General Public License : http://www.gnu.org/licenses/
<!-- Custom scripts --> <!-- Custom scripts -->
<script src="{javascript file='assets/dist/js/thelia.min.js'}"></script> <script src="{javascript file='assets/dist/js/thelia.min.js'}"></script>
{* <script>*}
{* var header = $(".nav-main");*}
{* var sticky = header[0].offsetTop;*}
{* window.onscroll = function () {*}
{* if (window.pageYOffset > sticky) {*}
{* header.addClass("sticky");*}
{* } else {*}
{* header.removeClass("sticky");*}
{* }*}
{* };*}
{* </script>*}
{hook name="main.body-bottom"} {hook name="main.body-bottom"}
</body> </body>
</html> </html>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,27 @@
{
"name": "Default",
"version": "1.0.0",
"description": "Default template for Thelia 2",
"main": "Gruntfile.js",
"keywords": [
"template",
"default",
"thelia"
],
"author": "Michael Espeche <mespeche@openstudio.fr>",
"license": "LGPL-3.0+",
"dependencies": {
"grunt": "^0.4.5",
"grunt-autoprefixer": "^3.0.0",
"grunt-contrib-clean": "^0.6.0",
"grunt-contrib-copy": "^0.8.0",
"grunt-contrib-cssmin": "^0.12.2",
"grunt-contrib-imagemin": "^1.0.0",
"grunt-contrib-jshint": "^0.11.2",
"grunt-contrib-less": "^1.0.1",
"grunt-contrib-uglify": "^0.9.1",
"grunt-contrib-watch": "^0.6.1",
"grunt-css-count": "^0.3.0",
"load-grunt-tasks": "^3.1.0"
}
}