You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
688 B
37 lines
688 B
<?php
|
|
// SPDX-License-Identifier: EUPL-1.2
|
|
// Authors: see README.md
|
|
|
|
use SeaCMS\Api\JsonResponse;
|
|
|
|
/**
|
|
* authentification plugin for Pico 3.
|
|
*/
|
|
class SeacmsAuth extends AbstractPicoPlugin
|
|
{
|
|
/**
|
|
* Pico API version.
|
|
* @var int
|
|
*/
|
|
const API_VERSION = 3;
|
|
|
|
/**
|
|
* return api routes
|
|
* @return array
|
|
*/
|
|
public function registerOnPageRenderedApiRoutes():array
|
|
{
|
|
return [
|
|
'GET login/isConnected' => 'apiIsConnected',
|
|
];
|
|
}
|
|
|
|
/**
|
|
* method for api
|
|
* @return JsonResponse
|
|
*/
|
|
public function apiIsConnected(): JsonResponse
|
|
{
|
|
return new JsonResponse(200,['connected'=>false]);
|
|
}
|
|
}
|
|
|