Added possibility to export the calendar in iCal format (closes #141)

This commit is contained in:
Bernd Bestel
2019-03-04 17:44:48 +01:00
parent 77b0bc675c
commit 90291fdbca
14 changed files with 336 additions and 71 deletions

View File

@@ -44,6 +44,18 @@ class ApiKeyAuthMiddleware extends BaseMiddleware
$validApiKey = false;
}
// Handling of special purpose API keys
if (!$validApiKey)
{
if ($routeName === 'calendar-ical')
{
if ($request->getQueryParam('secret') !== null && $apiKeyService->IsValidApiKey($request->getQueryParam('secret'), ApiKeyService::API_KEY_TYPE_SPECIAL_PURPOSE_CALENDAR_ICAL))
{
$validApiKey = true;
}
}
}
if (!$validSession && !$validApiKey)
{
define('GROCY_AUTHENTICATED', false);