Merge pull request #2620 from szporwolik/dev_extract_geojsons

[Awards] Extract of hardcoded geojsons
This commit is contained in:
Andreas Kristiansen
2025-12-02 09:54:07 +01:00
committed by GitHub
19 changed files with 392 additions and 465 deletions

View File

@@ -775,7 +775,6 @@ class Awards extends CI_Controller {
public function rac() {
$footerData = [];
$footerData['scripts'] = [
'assets/js/sections/racmap_geojson.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/racmap_geojson.js")),
'assets/js/sections/racmap.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/racmap.js")),
'assets/js/leaflet/L.Maidenhead.js',
];
@@ -838,7 +837,6 @@ class Awards extends CI_Controller {
public function helvetia() {
$footerData = [];
$footerData['scripts'] = [
'assets/js/sections/helvetiamap_geojson.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/helvetiamap_geojson.js")),
'assets/js/sections/helvetiamap.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/helvetiamap.js")),
'assets/js/leaflet/L.Maidenhead.js',
];
@@ -1369,7 +1367,6 @@ class Awards extends CI_Controller {
public function wap() {
$footerData = [];
$footerData['scripts'] = [
'assets/js/sections/wapmap_geojson.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/wapmap_geojson.js")),
'assets/js/sections/wapmap.js?' . filemtime(realpath(__DIR__ . "/../../assets/js/sections/wapmap.js")),
'assets/js/leaflet/L.Maidenhead.js',
];
@@ -1464,14 +1461,14 @@ class Awards extends CI_Controller {
foreach ($wap_array as $was => $value) {
foreach ($value as $key) {
if($key != "") {
if (strpos($key, '>W<') !== false) {
$states[$was] = 'W';
break;
}
if (strpos($key, '>C<') !== false) {
$states[$was] = 'C';
break;
}
if (strpos($key, '>W<') !== false) {
$states[$was] = 'W';
break;
}
if (strpos($key, '-') !== false) {
$states[$was] = '-';
break;