diff --git a/app/Http/Controllers/DownloadBitcoinEventCalendar.php b/app/Http/Controllers/DownloadBitcoinEventCalendar.php
new file mode 100644
index 00000000..3cdb4ee2
--- /dev/null
+++ b/app/Http/Controllers/DownloadBitcoinEventCalendar.php
@@ -0,0 +1,48 @@
+with([
+ 'venue.city.country',
+ ])
+ ->get();
+
+ $entries = [];
+ foreach ($events as $event) {
+ $entries[] = Event::create()
+ ->name($event->title)
+ ->uniqueIdentifier('ID'.$event->id)
+ ->address($event->venue->name.', '.$event->venue->street.', '.$event->venue->city->name.', '.$event->venue->city->country->name)
+ ->description($event->description.' Link: '.$event->link)
+ ->image($event->getFirstMediaUrl('logo'))
+ ->startsAt($event->from)
+ ->endsAt($event->to)
+ ->alertMinutesBefore(60 * 24);
+ }
+
+ $calendar = Calendar::create()
+ ->name(__('Bitcoin Events'))
+ ->refreshInterval(5)
+ ->event($entries);
+
+ return response($calendar->get())
+ ->header('Content-Type', 'text/calendar; charset=utf-8');
+ }
+}
diff --git a/app/Http/Controllers/DownloadMeetupCalendar.php b/app/Http/Controllers/DownloadMeetupCalendar.php
new file mode 100644
index 00000000..82d5504f
--- /dev/null
+++ b/app/Http/Controllers/DownloadMeetupCalendar.php
@@ -0,0 +1,47 @@
+with([
+ 'meetupEvents',
+ ])
+ ->findOrFail($request->input('meetup'));
+
+ $entries = [];
+ foreach ($meetup->meetupEvents as $event) {
+ $entries[] = Event::create()
+ ->name($meetup->name)
+ ->uniqueIdentifier('ID'.$event->id)
+ ->address($event->location)
+ ->description($event->description.' Link: '.$event->link)
+ ->image($meetup->getFirstMediaUrl('logo'))
+ ->startsAt($event->start)
+ ->alertMinutesBefore(60 * 2);
+ }
+
+ $calendar = Calendar::create()
+ ->name($meetup->name)
+ ->refreshInterval(5)
+ ->event($entries);
+
+ return response($calendar->get())
+ ->header('Content-Type', 'text/calendar; charset=utf-8');
+ }
+}
diff --git a/app/Http/Livewire/Tables/MeetupTable.php b/app/Http/Livewire/Tables/MeetupTable.php
index 8603fba2..ef055386 100644
--- a/app/Http/Livewire/Tables/MeetupTable.php
+++ b/app/Http/Livewire/Tables/MeetupTable.php
@@ -60,7 +60,9 @@ class MeetupTable extends DataTableComponent
->sortable(),
Column::make(__('Links'),)
->label(
- fn($row, Column $column) => view('columns.meetups.action')->withRow($row)
+ fn($row, Column $column) => view('columns.meetups.action')
+ ->withRow($row)
+ ->withCountry($this->country)
)
->collapseOnMobile(),
];
diff --git a/composer.json b/composer.json
index 9de7e56f..cef12e13 100644
--- a/composer.json
+++ b/composer.json
@@ -32,6 +32,7 @@
"sentry/sentry-laravel": "^3.1",
"simplesoftwareio/simple-qrcode": "^4.2",
"spatie/eloquent-sortable": "^4.0",
+ "spatie/icalendar-generator": "^2.5",
"spatie/laravel-comments": "^1.4",
"spatie/laravel-comments-livewire": "^1.2",
"spatie/laravel-google-fonts": "^1.2",
diff --git a/composer.lock b/composer.lock
index 2b3f2ce0..ef86cdc9 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "233c21d81dfd51b9929f8cf795c2435c",
+ "content-hash": "d570d40413edbe29a499759d99b8584c",
"packages": [
{
"name": "akuechler/laravel-geoly",
@@ -9247,6 +9247,143 @@
],
"time": "2022-01-21T08:32:41+00:00"
},
+ {
+ "name": "spatie/enum",
+ "version": "3.13.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/spatie/enum.git",
+ "reference": "f1a0f464ba909491a53e60a955ce84ad7cd93a2c"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/spatie/enum/zipball/f1a0f464ba909491a53e60a955ce84ad7cd93a2c",
+ "reference": "f1a0f464ba909491a53e60a955ce84ad7cd93a2c",
+ "shasum": ""
+ },
+ "require": {
+ "ext-json": "*",
+ "php": "^8.0"
+ },
+ "require-dev": {
+ "fakerphp/faker": "^1.9.1",
+ "larapack/dd": "^1.1",
+ "phpunit/phpunit": "^9.0",
+ "vimeo/psalm": "^4.3"
+ },
+ "suggest": {
+ "fakerphp/faker": "To use the enum faker provider",
+ "phpunit/phpunit": "To use the enum assertions"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Spatie\\Enum\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Brent Roose",
+ "email": "brent@spatie.be",
+ "homepage": "https://spatie.be",
+ "role": "Developer"
+ },
+ {
+ "name": "Tom Witkowski",
+ "email": "dev@gummibeer.de",
+ "homepage": "https://gummibeer.de",
+ "role": "Developer"
+ }
+ ],
+ "description": "PHP Enums",
+ "homepage": "https://github.com/spatie/enum",
+ "keywords": [
+ "enum",
+ "enumerable",
+ "spatie"
+ ],
+ "support": {
+ "docs": "https://docs.spatie.be/enum",
+ "issues": "https://github.com/spatie/enum/issues",
+ "source": "https://github.com/spatie/enum"
+ },
+ "funding": [
+ {
+ "url": "https://spatie.be/open-source/support-us",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/spatie",
+ "type": "github"
+ }
+ ],
+ "time": "2022-04-22T08:51:55+00:00"
+ },
+ {
+ "name": "spatie/icalendar-generator",
+ "version": "2.5.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/spatie/icalendar-generator.git",
+ "reference": "128d8fe4f0d759b8bdb0383a178c15963b54f458"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/spatie/icalendar-generator/zipball/128d8fe4f0d759b8bdb0383a178c15963b54f458",
+ "reference": "128d8fe4f0d759b8bdb0383a178c15963b54f458",
+ "shasum": ""
+ },
+ "require": {
+ "ext-mbstring": "*",
+ "nesbot/carbon": "^2.54",
+ "php": "^7.4|^8.0",
+ "spatie/enum": "^3.11"
+ },
+ "require-dev": {
+ "ext-json": "*",
+ "larapack/dd": "^1.1",
+ "pestphp/pest": "^1.22",
+ "phpunit/phpunit": "^9.5",
+ "spatie/pest-plugin-snapshots": "^1.1",
+ "spatie/phpunit-snapshot-assertions": "^4.2",
+ "vimeo/psalm": "^4.13"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Spatie\\IcalendarGenerator\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Ruben Van Assche",
+ "email": "ruben@spatie.be",
+ "homepage": "https://spatie.be",
+ "role": "Developer"
+ }
+ ],
+ "description": "Build calendars in the iCalendar format",
+ "homepage": "https://github.com/spatie/icalendar-generator",
+ "keywords": [
+ "calendar",
+ "iCalendar",
+ "ical",
+ "ics",
+ "spatie"
+ ],
+ "support": {
+ "source": "https://github.com/spatie/icalendar-generator/tree/2.5.1"
+ },
+ "time": "2022-10-26T10:18:21+00:00"
+ },
{
"name": "spatie/image",
"version": "2.2.4",
diff --git a/resources/views/columns/meetups/action.blade.php b/resources/views/columns/meetups/action.blade.php
index ab9ea67f..59fbfa3c 100644
--- a/resources/views/columns/meetups/action.blade.php
+++ b/resources/views/columns/meetups/action.blade.php
@@ -3,13 +3,25 @@