From 86dc5afbdf40fb31c1c2fcc8d69bed7dc76168a0 Mon Sep 17 00:00:00 2001 From: Fred Tempez Date: Thu, 8 Aug 2024 06:21:22 +0200 Subject: [PATCH] Position au singulier --- module/geogallery/geogallery.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/module/geogallery/geogallery.php b/module/geogallery/geogallery.php index ae55d038..940e529c 100644 --- a/module/geogallery/geogallery.php +++ b/module/geogallery/geogallery.php @@ -169,7 +169,7 @@ class geogallery extends common 'directory' => $this->getInput('galleryAddDirectory', helper::FILTER_STRING_SHORT, true), ], 'legend' => [], - 'positions' => [] + 'position' => [] ] ]); $success = true; @@ -270,7 +270,7 @@ class geogallery extends common ], 'legend' => $legends, //'geo' => $geo, - 'positions' => $geo + 'position' => $geo ] ]); // Valeurs en sortie @@ -317,7 +317,7 @@ class geogallery extends common } self::$pictures[str_replace('.', '', $fileInfos->getFilename())] = [ - //$this->getData(['module', $this->getUrl(0), 'content', $this->getUrl(2), 'positions', str_replace('.', '', $fileInfos->getFilename())]) + 1, + //$this->getData(['module', $this->getUrl(0), 'content', $this->getUrl(2), 'position', str_replace('.', '', $fileInfos->getFilename())]) + 1, $fileInfos->getFilename(), template::text('legend[' . $fileInfos->getFilename() . ']', [ 'value' => $this->getData(['module', $this->getUrl(0), 'content', $this->getUrl(2), 'legend', str_replace('.', '', $fileInfos->getFilename())]) @@ -338,7 +338,7 @@ class geogallery extends common // Tri des images switch ($this->getData(['module', $this->getUrl(0), 'content', $this->getUrl(2), 'config', 'sort'])) { case self::SORT_HAND: - $positions = $this->getData(['module', $this->getUrl(0), 'content', $this->getUrl(2), 'positions']); + $positions = $this->getData(['module', $this->getUrl(0), 'content', $this->getUrl(2), 'position']); if ($positions) { foreach ($positions as $key => $value) { if (array_key_exists($key, self::$pictures)) { @@ -417,8 +417,8 @@ class geogallery extends common ]; } else { self::$galleries[] = [ - 'lat' => $this->getData(['module', $this->getUrl(0), 'content', $gallery, 'positions', 'directory', str_replace('.', '', $fileInfos->getFilename())]), - 'long' => $this->getData(['module', $this->getUrl(0), 'content', $gallery, 'positions', 'directory', str_replace('.', '', $fileInfos->getFilename())]), + 'lat' => $this->getData(['module', $this->getUrl(0), 'content', $gallery, 'position', 'directory', str_replace('.', '', $fileInfos->getFilename())]), + 'long' => $this->getData(['module', $this->getUrl(0), 'content', $gallery, 'position', 'directory', str_replace('.', '', $fileInfos->getFilename())]), 'img'=> $fileInfos->getPath() . '/' . strtolower($fileInfos->getFilename()), 'thumb' => str_replace('source', 'thumb', $fileInfos->getPath()) . '/' . self::THUMBS_SEPARATOR . strtolower($fileInfos->getFilename()), 'label' => $this->getData(['module', $this->getUrl(0), 'content', $gallery, 'legend', str_replace('.', '', $fileInfos->getFilename())])