diff --git a/.ddev/config.yaml b/.ddev/config.yaml index 97e5975a..8e8bf0bd 100644 --- a/.ddev/config.yaml +++ b/.ddev/config.yaml @@ -15,7 +15,7 @@ additional_hostnames: - ski-wochenenden - schnee-event additional_fqdns: [] -nfs_mount_enabled: true +nfs_mount_enabled: false provider: default omit_containers: [dba] use_dns_when_possible: true diff --git a/package.json b/package.json index 60ee75c6..4d4fd989 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "license": "WTFPL", "repository": "https://gitlab.com/dreipunktnull/ep_theme.git", "scripts": { - "dev": "./node_modules/.bin/encore dev --watch --watch-poll", + "dev": "./node_modules/.bin/encore dev --watch --watch-poll=500", "build": "./node_modules/.bin/encore production" }, "dependencies": { diff --git a/public/typo3conf/ext/ep_products/Classes/Service/SnowreportImportService.php b/public/typo3conf/ext/ep_products/Classes/Service/SnowreportImportService.php index 0bd69778..85b09ce1 100644 --- a/public/typo3conf/ext/ep_products/Classes/Service/SnowreportImportService.php +++ b/public/typo3conf/ext/ep_products/Classes/Service/SnowreportImportService.php @@ -205,22 +205,30 @@ class SnowreportImportService implements SingletonInterface $snowReportStoragePid = SettingsUtility::get('snowReportStoragePid'); foreach ($xml->children() as $item) { + $include = (string) $item->aktuell === 'true'; + $available = (string) $item->verf === 'true'; $vendorUid = (int) $item->uid; $result = $this->webcamRepository->findByVendorUid($vendorUid); + // Skip invalid cams + if ($include === false && $result->count() === 0) { + continue; + } + // Add new cam if not in db yet if ($result->count() === 0) { $webcam = new Webcam(); $webcam->setVendorUid($vendorUid); $webcam->setPid($snowReportStoragePid); $webcam->setUrl((string) $item->url); $webcam->setName((string) $item->dt); - $webcam->setAvailable((string) $item->verf === 'true'); + $webcam->setAvailable($available); $this->webcamRepository->add($webcam); $snowreport->addWebcam($webcam); } else { + // Update cam in db and set availability $webcam = $result->getFirst(); $webcam->setUrl((string) $item->url); $webcam->setName((string) $item->dt); - $webcam->setAvailable((string) $item->verf === 'true'); + $webcam->setAvailable($available && $include); } static::$validWebcamUids[] = $vendorUid; } diff --git a/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/_app.js b/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/_app.js index 2e565cd5..30c33579 100644 --- a/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/_app.js +++ b/public/typo3conf/ext/ep_theme/Resources/Private/Assets/js/_app.js @@ -160,7 +160,7 @@ new Vue({ accessibility: false, // This is a hack to avoid a slick carousel bug. see: https://github.com/kenwheeler/slick/issues/1407#issuecomment-325228683 mobileFirst: true, infinite: false, - slidesToShow: 1.25, + slidesToShow: 1.15, slidesToScroll: 1, arrows: false, dots: false, @@ -175,15 +175,21 @@ new Vue({ } }, { - breakpoint: 830, + breakpoint: 992, settings: { slidesToShow: 2.75, } }, { - breakpoint: 480, + breakpoint: 640, settings: { - slidesToShow: 2.25, + slidesToShow: 2.5, + } + }, + { + breakpoint: 384, + settings: { + slidesToShow: 1.75, } } ] @@ -196,7 +202,7 @@ new Vue({ accessibility: false, // This is a hack to avoid a slick carousel bug. see: https://github.com/kenwheeler/slick/issues/1407#issuecomment-325228683 mobileFirst: true, infinite: false, - slidesToShow: 1.25, + slidesToShow: 1.15, slidesToScroll: 1, arrows: false, responsive: [ @@ -216,9 +222,15 @@ new Vue({ } }, { - breakpoint: 768, + breakpoint: 640, settings: { - slidesToShow: 2.25, + slidesToShow: 2.5, + } + }, + { + breakpoint: 384, + settings: { + slidesToShow: 1.75, } } ]