From 0dea8a8c026f233bb8c4a2be5fe71879c8a2a8cc Mon Sep 17 00:00:00 2001 From: Johan Cwiklinski Date: Thu, 25 Jan 2024 06:51:03 +0100 Subject: [PATCH] Headers, Galette 1.1.0 compat --- .github/workflows/ci-linux.yml | 7 +- _config.inc.php | 27 ++----- _define.php | 25 ++----- _routes.php | 20 +----- .../Controllers/Crud/CategoriesController.php | 56 +++++---------- .../Controllers/Crud/ObjectsController.php | 64 ++++++----------- .../Controllers/Crud/StatusController.php | 56 +++++---------- .../Controllers/ImagesController.php | 27 ++----- .../Controllers/MainController.php | 31 ++------ .../Controllers/PdfController.php | 27 ++----- .../Entity/CategoryPicture.php | 36 ++-------- .../Entity/LendCategory.php | 39 ++-------- lib/GaletteObjectsLend/Entity/LendObject.php | 37 ++-------- lib/GaletteObjectsLend/Entity/LendPDF.php | 37 ++-------- lib/GaletteObjectsLend/Entity/LendRent.php | 37 ++-------- lib/GaletteObjectsLend/Entity/LendStatus.php | 37 ++-------- .../Entity/ObjectPicture.php | 37 ++-------- lib/GaletteObjectsLend/Entity/Picture.php | 72 +++++++------------ lib/GaletteObjectsLend/Entity/Preferences.php | 37 ++-------- .../Filters/CategoriesList.php | 59 ++++----------- .../Filters/ObjectsList.php | 64 ++++------------- lib/GaletteObjectsLend/Filters/StatusList.php | 40 +++-------- lib/GaletteObjectsLend/IO/PdfObject.php | 26 +------ lib/GaletteObjectsLend/IO/PdfObjects.php | 26 +------ .../PluginGaletteObjectslend.php | 41 +++-------- .../Repository/Categories.php | 28 +------- lib/GaletteObjectsLend/Repository/Objects.php | 28 +------- lib/GaletteObjectsLend/Repository/Status.php | 28 +------- templates/default/categories_list.html.twig | 20 ++++++ templates/default/category_edit.html.twig | 20 ++++++ templates/default/headers.html.twig | 20 ++++++ templates/default/list_lent_object.html.twig | 20 ++++++ templates/default/objects_edit.html.twig | 20 ++++++ templates/default/objects_list.html.twig | 20 ++++++ templates/default/preferences.html.twig | 20 ++++++ templates/default/status_edit.html.twig | 20 ++++++ templates/default/status_list.html.twig | 20 ++++++ templates/default/take_more_objects_away.tpl | 20 ++++++ templates/default/take_object.html.twig | 20 ++++++ 39 files changed, 438 insertions(+), 831 deletions(-) diff --git a/.github/workflows/ci-linux.yml b/.github/workflows/ci-linux.yml index 1bfd615..f8e457b 100644 --- a/.github/workflows/ci-linux.yml +++ b/.github/workflows/ci-linux.yml @@ -63,7 +63,7 @@ jobs: - name: CS run: | cd galette-core/galette/plugins/plugin-objectslend - ../../vendor/bin/phpcs -n -p --standard=../../../phpcs-rules.xml lib/ ./*.php + ../../vendor/bin/phpcs lib/ ./*.php - name: Check missing symbols run: | @@ -76,3 +76,8 @@ jobs: cd galette-core/galette/plugins/plugin-objectslend ../../vendor/bin/phpstan analyze --ansi --memory-limit=2G --no-interaction --no-progress if: matrix.php-versions == '8.1' + + - name: Headers checks + run: | + cd galette-core/galette/plugins/plugin-objectslend + ../../vendor/bin/docheader --docheader=../../../.docheader check lib ./*.php diff --git a/_config.inc.php b/_config.inc.php index 8b61027..c5d4c5b 100644 --- a/_config.inc.php +++ b/_config.inc.php @@ -1,41 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * Copyright © 2017 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @version 0.7 - * @link http://galette.tuxfamily.org - * @since Available since 0.7 */ define('LEND_PREFIX', 'lend_'); diff --git a/_define.php b/_define.php index 13dc9b9..04db815 100644 --- a/_define.php +++ b/_define.php @@ -1,39 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ $this->register( @@ -41,7 +24,7 @@ 'Manage rent/lend of object', //Short description 'Mélissa Djebel, Johan Cwiklinski', //Author '2.0.0', //Version - '1.0.0', //Galette version compatibility + '1.1.0', //Galette version compatibility 'objectslend', //routing name and translation domain '2023-12-07', //Date [ diff --git a/_routes.php b/_routes.php index f279c02..7f4bcf9 100644 --- a/_routes.php +++ b/_routes.php @@ -1,15 +1,9 @@ . - * - * @category Plugins - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @version SVN: $Id$ - * @link http://galette.tuxfamily.org - * @since 2017-11-19 */ use Analog\Analog; diff --git a/lib/GaletteObjectsLend/Controllers/Crud/CategoriesController.php b/lib/GaletteObjectsLend/Controllers/Crud/CategoriesController.php index 1ae8fb1..88e2b42 100644 --- a/lib/GaletteObjectsLend/Controllers/Crud/CategoriesController.php +++ b/lib/GaletteObjectsLend/Controllers/Crud/CategoriesController.php @@ -1,15 +1,9 @@ . - * - * @category Controllers - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2021-05-09 */ namespace GaletteObjectsLend\Controllers\Crud; @@ -49,23 +34,16 @@ /** * Categories controller * - * @category Controllers - * @name CategoriesController - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2021-05-09 + * @author Johan Cwiklinski */ class CategoriesController extends AbstractPluginController { /** - * @var array + * @var array */ #[Inject("Plugin Galette Objects Lend")] - protected $module_info; + protected array $module_info; // CRUD - Create @@ -101,14 +79,14 @@ public function doAdd(Request $request, Response $response): Response /** * List page * - * @param Request $request PSR Request - * @param Response $response PSR Response - * @param string $option One of 'page' or 'order' - * @param string|integer $value Value of the option + * @param Request $request PSR Request + * @param Response $response PSR Response + * @param string|null $option One of 'page' or 'order' + * @param integer|string|null $value Value of the option * * @return Response */ - public function list(Request $request, Response $response, $option = null, $value = null): Response + public function list(Request $request, Response $response, string $option = null, int|string $value = null): Response { if (isset($this->session->objectslend_filter_categories)) { $filters = $this->session->objectslend_filter_categories; @@ -212,7 +190,7 @@ public function filter(Request $request, Response $response): Response * * @return Response */ - public function edit(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function edit(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { if ($this->session->objectslend_category !== null) { $category = $this->session->objectslend_category; @@ -255,7 +233,7 @@ public function edit(Request $request, Response $response, int $id = null, $acti * * @return Response */ - public function doEdit(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function doEdit(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { $post = $request->getParsedBody(); $category = new LendCategory($this->zdb, $this->plugins, $id); @@ -337,7 +315,7 @@ public function doEdit(Request $request, Response $response, int $id = null, $ac /** * Get redirection URI * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -349,7 +327,7 @@ public function redirectUri(array $args): string /** * Get form URI * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -364,7 +342,7 @@ public function formUri(array $args): string /** * Get confirmation removal page title * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -380,8 +358,8 @@ public function confirmRemoveTitle(array $args): string /** * Remove object * - * @param array $args Route arguments - * @param array $post POST values + * @param array $args Route arguments + * @param array $post POST values * * @return boolean */ diff --git a/lib/GaletteObjectsLend/Controllers/Crud/ObjectsController.php b/lib/GaletteObjectsLend/Controllers/Crud/ObjectsController.php index a1eefee..cb61eea 100644 --- a/lib/GaletteObjectsLend/Controllers/Crud/ObjectsController.php +++ b/lib/GaletteObjectsLend/Controllers/Crud/ObjectsController.php @@ -1,15 +1,9 @@ . - * - * @category Controllers - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2021-05-12 */ namespace GaletteObjectsLend\Controllers\Crud; @@ -59,23 +44,16 @@ /** * Objects controller * - * @category Controllers - * @name ObjectsController - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2021-05-12 + * @author Johan Cwiklinski */ class ObjectsController extends AbstractPluginController { /** - * @var array + * @var array */ #[Inject("Plugin Galette Objects Lend")] - protected $module_info; + protected array $module_info; // CRUD - Create @@ -111,14 +89,14 @@ public function doAdd(Request $request, Response $response): Response /** * List page * - * @param Request $request PSR Request - * @param Response $response PSR Response - * @param string $option One of 'page' or 'order' - * @param string|integer $value Value of the option + * @param Request $request PSR Request + * @param Response $response PSR Response + * @param string|null $option One of 'page' or 'order' + * @param integer|string|null $value Value of the option * * @return Response */ - public function list(Request $request, Response $response, $option = null, $value = null): Response + public function list(Request $request, Response $response, string $option = null, int|string $value = null): Response { if (isset($this->session->objectslend_filter_objects)) { $filters = $this->session->objectslend_filter_objects; @@ -330,7 +308,7 @@ public function handleBatch(Request $request, Response $response): Response * * @return Response */ - public function edit(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function edit(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { if ($this->session->objectslend_object !== null) { $object = $this->session->objectslend_object; @@ -402,7 +380,7 @@ public function edit(Request $request, Response $response, int $id = null, $acti * * @return Response */ - public function doEdit(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function doEdit(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { $post = $request->getParsedBody(); @@ -518,7 +496,7 @@ public function doEdit(Request $request, Response $response, int $id = null, $ac * * @return Response */ - public function doUpdateStatus(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function doUpdateStatus(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { $post = $request->getParsedBody(); @@ -989,7 +967,7 @@ public function doReturn(Request $request, Response $response, int $id): Respons /** * Get redirection URI * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -1001,7 +979,7 @@ public function redirectUri(array $args): string /** * Get form URI * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -1020,12 +998,12 @@ public function formUri(array $args): string * batchs, it should be found elsewhere. * In post values, we look for id key, as well as all {sthing}_sel keys (like members_sel or contrib_sel) * - * @param array $args Request arguments - * @param array $post POST values + * @param array $args Request arguments + * @param ?array $post POST values * * @return null|integer|integer[] */ - protected function getIdsToRemove(&$args, $post) + protected function getIdsToRemove(array &$args, ?array $post): array|int|null { if (isset($args['id'])) { return $args['id']; @@ -1038,7 +1016,7 @@ protected function getIdsToRemove(&$args, $post) /** * Get confirmation removal page title * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -1065,8 +1043,8 @@ public function confirmRemoveTitle(array $args): string /** * Remove object * - * @param array $args Route arguments - * @param array $post POST values + * @param array $args Route arguments + * @param array $post POST values * * @return boolean */ diff --git a/lib/GaletteObjectsLend/Controllers/Crud/StatusController.php b/lib/GaletteObjectsLend/Controllers/Crud/StatusController.php index bd6f122..9fc0841 100644 --- a/lib/GaletteObjectsLend/Controllers/Crud/StatusController.php +++ b/lib/GaletteObjectsLend/Controllers/Crud/StatusController.php @@ -1,15 +1,9 @@ . - * - * @category Controllers - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2021-05-12 */ namespace GaletteObjectsLend\Controllers\Crud; @@ -48,23 +33,16 @@ /** * Status controller * - * @category Controllers - * @name CategoriesController - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2021-05-09 + * @author Johan Cwiklinski */ class StatusController extends AbstractPluginController { /** - * @var array + * @var array */ #[Inject("Plugin Galette Objects Lend")] - protected $module_info; + protected array $module_info; // CRUD - Create @@ -100,14 +78,14 @@ public function doAdd(Request $request, Response $response): Response /** * List page * - * @param Request $request PSR Request - * @param Response $response PSR Response - * @param string $option One of 'page' or 'order' - * @param string|integer $value Value of the option + * @param Request $request PSR Request + * @param Response $response PSR Response + * @param string|null $option One of 'page' or 'order' + * @param integer|string|null $value Value of the option * * @return Response */ - public function list(Request $request, Response $response, $option = null, $value = null): Response + public function list(Request $request, Response $response, string $option = null, int|string $value = null): Response { if (isset($this->session->objectslend_filter_statuses)) { $filters = $this->session->objectslend_filter_statuses; @@ -231,7 +209,7 @@ public function filter(Request $request, Response $response): Response * * @return Response */ - public function edit(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function edit(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { if ($this->session->objectslend_status !== null) { $status = $this->session->objectslend_status; @@ -275,7 +253,7 @@ public function edit(Request $request, Response $response, int $id = null, $acti * * @return Response */ - public function doEdit(Request $request, Response $response, int $id = null, $action = 'edit'): Response + public function doEdit(Request $request, Response $response, int $id = null, string $action = 'edit'): Response { $post = $request->getParsedBody(); $status = new LendStatus($this->zdb, $id); @@ -331,7 +309,7 @@ public function doEdit(Request $request, Response $response, int $id = null, $ac /** * Get redirection URI * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -343,7 +321,7 @@ public function redirectUri(array $args): string /** * Get form URI * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -358,7 +336,7 @@ public function formUri(array $args): string /** * Get confirmation removal page title * - * @param array $args Route arguments + * @param array $args Route arguments * * @return string */ @@ -374,8 +352,8 @@ public function confirmRemoveTitle(array $args): string /** * Remove object * - * @param array $args Route arguments - * @param array $post POST values + * @param array $args Route arguments + * @param array $post POST values * * @return boolean */ diff --git a/lib/GaletteObjectsLend/Controllers/ImagesController.php b/lib/GaletteObjectsLend/Controllers/ImagesController.php index cb23a9c..08b74c0 100644 --- a/lib/GaletteObjectsLend/Controllers/ImagesController.php +++ b/lib/GaletteObjectsLend/Controllers/ImagesController.php @@ -1,15 +1,9 @@ . - * - * @category Entity - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org */ + */ namespace GaletteObjectsLend\Controllers; @@ -42,13 +29,7 @@ /** * Galette objects lend images controller * - * @category Controllers - * @name ImageController - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class ImagesController extends GImagesController diff --git a/lib/GaletteObjectsLend/Controllers/MainController.php b/lib/GaletteObjectsLend/Controllers/MainController.php index e1c9621..5d4ece5 100644 --- a/lib/GaletteObjectsLend/Controllers/MainController.php +++ b/lib/GaletteObjectsLend/Controllers/MainController.php @@ -1,15 +1,9 @@ . - * - * @category Controllers - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org */ + */ namespace GaletteObjectsLend\Controllers; @@ -44,22 +31,16 @@ /** * Galette objects lend main controller * - * @category Controllers - * @name MainController - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class MainController extends AbstractPluginController { /** - * @var array + * @var array */ #[Inject("Plugin Galette Objects Lend")] - protected $module_info; + protected array $module_info; /** * Objects lends preferences diff --git a/lib/GaletteObjectsLend/Controllers/PdfController.php b/lib/GaletteObjectsLend/Controllers/PdfController.php index fdbf1b7..b1fc821 100644 --- a/lib/GaletteObjectsLend/Controllers/PdfController.php +++ b/lib/GaletteObjectsLend/Controllers/PdfController.php @@ -1,15 +1,9 @@ . - * - * @category Controllers - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org */ + */ namespace GaletteObjectsLend\Controllers; @@ -47,13 +34,7 @@ /** * Galette objects lend PDF controller * - * @category Controllers - * @name PdfController - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2021-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class PdfController extends GPdfController diff --git a/lib/GaletteObjectsLend/Entity/CategoryPicture.php b/lib/GaletteObjectsLend/Entity/CategoryPicture.php index 8422694..a4824fb 100644 --- a/lib/GaletteObjectsLend/Entity/CategoryPicture.php +++ b/lib/GaletteObjectsLend/Entity/CategoryPicture.php @@ -1,39 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2020 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -44,15 +27,8 @@ /** * Picture for category * - * @name CategoryPicture - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski */ class CategoryPicture extends Picture { diff --git a/lib/GaletteObjectsLend/Entity/LendCategory.php b/lib/GaletteObjectsLend/Entity/LendCategory.php index 1a05281..5b03d3e 100644 --- a/lib/GaletteObjectsLend/Entity/LendCategory.php +++ b/lib/GaletteObjectsLend/Entity/LendCategory.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -46,17 +28,10 @@ use Laminas\Db\Sql\Predicate; /** - * Categories manageemnt + * Categories management * - * @name LendCategory - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski * * @property bool $is_active * @property string $name diff --git a/lib/GaletteObjectsLend/Entity/LendObject.php b/lib/GaletteObjectsLend/Entity/LendObject.php index 8cc0faa..a741429 100644 --- a/lib/GaletteObjectsLend/Entity/LendObject.php +++ b/lib/GaletteObjectsLend/Entity/LendObject.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -50,15 +32,8 @@ /** * Object * - * @name LendObject - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski * * @property ?int $object_id * @property ObjectPicture $picture diff --git a/lib/GaletteObjectsLend/Entity/LendPDF.php b/lib/GaletteObjectsLend/Entity/LendPDF.php index d8767e3..9846ea6 100644 --- a/lib/GaletteObjectsLend/Entity/LendPDF.php +++ b/lib/GaletteObjectsLend/Entity/LendPDF.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -45,15 +27,8 @@ /** * PDF creation * - * @name Picture - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski */ class LendPDF extends \Galette\IO\Pdf { diff --git a/lib/GaletteObjectsLend/Entity/LendRent.php b/lib/GaletteObjectsLend/Entity/LendRent.php index 328fd43..67a0f17 100644 --- a/lib/GaletteObjectsLend/Entity/LendRent.php +++ b/lib/GaletteObjectsLend/Entity/LendRent.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @Copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -47,15 +29,8 @@ /** * Rents * - * @name LendRent - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski * * @property integer $rent_id * @property integer $object_id diff --git a/lib/GaletteObjectsLend/Entity/LendStatus.php b/lib/GaletteObjectsLend/Entity/LendStatus.php index 2707ecb..e94c3fc 100644 --- a/lib/GaletteObjectsLend/Entity/LendStatus.php +++ b/lib/GaletteObjectsLend/Entity/LendStatus.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @Copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -46,15 +28,8 @@ /** * Lend status management * - * @name LendStatus - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski * * @property integer $status_id * @property string $status_text diff --git a/lib/GaletteObjectsLend/Entity/ObjectPicture.php b/lib/GaletteObjectsLend/Entity/ObjectPicture.php index 53ffdfe..58c3b1a 100644 --- a/lib/GaletteObjectsLend/Entity/ObjectPicture.php +++ b/lib/GaletteObjectsLend/Entity/ObjectPicture.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu - * @since Available since 0.7 */ namespace GaletteObjectsLend\Entity; @@ -45,15 +27,8 @@ /** * Picture for objects * - * @name ObjectPicture - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski */ class ObjectPicture extends Picture { diff --git a/lib/GaletteObjectsLend/Entity/Picture.php b/lib/GaletteObjectsLend/Entity/Picture.php index 522b245..e4b0f08 100644 --- a/lib/GaletteObjectsLend/Entity/Picture.php +++ b/lib/GaletteObjectsLend/Entity/Picture.php @@ -1,39 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -46,26 +29,19 @@ /** * Picture handling * - * @name Picture - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski */ class Picture extends \Galette\Core\Picture { - protected $max_width = 800; - protected $max_height = 800; + protected int $max_width = 800; + protected int $max_height = 800; - protected $thumb_max_width; - protected $thumb_max_height; + protected int $thumb_max_width; + protected int $thumb_max_height; - protected $thumb_optimal_height; - protected $thumb_optimal_width; + protected int $thumb_optimal_height; + protected int $thumb_optimal_width; protected Plugins $plugins; @@ -110,7 +86,7 @@ public function __construct(Plugins $plugins, $objectid = null) * * @return void */ - protected function getDefaultPicture() + protected function getDefaultPicture(): void { $this->file_path = realpath( $this->plugins->getTemplatesPathFromName('Galette Objects Lend') . @@ -255,7 +231,7 @@ private function createThumb($source, $ext, $dest = null) * * @return boolean true if image was successfully deleted, false otherwise */ - public function delete($transaction = true) + public function delete(bool $transaction = true): bool { //find and delete any thumb $ext = strlen(pathinfo($this->file_path, PATHINFO_EXTENSION)) + 1; @@ -273,13 +249,13 @@ public function delete($transaction = true) /** * Stores an image on the disk and in the database * - * @param object $file the uploaded file - * @param bool $ajax not used - * @param array $cropping not used + * @param array $file The uploaded file + * @param boolean $ajax If the image comes from an ajax call (dnd) + * @param ?array $cropping Cropping properties * - * @return true|false result of the storage process + * @return bool|int */ - public function store($file, $ajax = false, $cropping = null) + public function store($file, $ajax = false, $cropping = null): bool|int { $ext = strlen(pathinfo($this->file_path, PATHINFO_EXTENSION)) + 1; $filename = substr($this->file_path, 0, strlen($this->file_path) - strlen($ext)); @@ -415,9 +391,9 @@ private function setThumbSizes(Preferences $prefs) * * @return int optimal height */ - public function getOptimalThumbHeight(Preferences $prefs) + public function getOptimalThumbHeight(Preferences $prefs): int { - if (!$this->thumb_optimal_height) { + if (!isset($this->thumb_optimal_height)) { $this->setThumbSizes($prefs); } return (int)round($this->thumb_optimal_height, 1); @@ -430,9 +406,9 @@ public function getOptimalThumbHeight(Preferences $prefs) * * @return int optimal width */ - public function getOptimalThumbWidth(Preferences $prefs) + public function getOptimalThumbWidth(Preferences $prefs): int { - if (!$this->thumb_optimal_width) { + if (!isset($this->thumb_optimal_width)) { $this->setThumbSizes($prefs); } return (int)round($this->thumb_optimal_width, 1); @@ -443,7 +419,7 @@ public function getOptimalThumbWidth(Preferences $prefs) * * @return string */ - public function getDir() + public function getDir(): string { return $this->store_path; } diff --git a/lib/GaletteObjectsLend/Entity/Preferences.php b/lib/GaletteObjectsLend/Entity/Preferences.php index be20d49..6688ec0 100644 --- a/lib/GaletteObjectsLend/Entity/Preferences.php +++ b/lib/GaletteObjectsLend/Entity/Preferences.php @@ -1,40 +1,22 @@ . - * - * @category Plugins - * @package ObjectsLend - * - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @Copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu */ namespace GaletteObjectsLend\Entity; @@ -46,15 +28,8 @@ /** * Plugin preferences * - * @name Preferences - * @category Entity - * @package ObjectsLend - * @author Mélissa Djebel - * @author Johan Cwiklinski - * @copyright 2013-2016 Mélissa Djebel - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link https://galette.eu + * @author Mélissa Djebel + * @author Johan Cwiklinski * * @property bool $ENABLE_MEMBER_RENT_OBJECT * @property bool $AUTO_GENERATE_CONTRIBUTION diff --git a/lib/GaletteObjectsLend/Filters/CategoriesList.php b/lib/GaletteObjectsLend/Filters/CategoriesList.php index bab7d56..fc28906 100644 --- a/lib/GaletteObjectsLend/Filters/CategoriesList.php +++ b/lib/GaletteObjectsLend/Filters/CategoriesList.php @@ -1,15 +1,9 @@ . - * - * @category Filters - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @version SVN: $Id$ - * @link http://galette.tuxfamily.org - * @since 2017-02-10 */ namespace GaletteObjectsLend\Filters; @@ -45,14 +29,7 @@ /** * Categories list filters and paginator * - * @name CategoriesList - * @category Filters - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski * * @property ?string $filter_str * @property ?int $active_filter @@ -71,7 +48,8 @@ class CategoriesList extends Pagination protected $query; - protected $categorylist_fields = array( + /** @var array */ + protected array $categorylist_fields = array( 'filter_str', 'active_filter', 'not_empty', @@ -92,7 +70,7 @@ public function __construct() * * @return string field name */ - protected function getDefaultOrder() + protected function getDefaultOrder(): string { return 'name '; } @@ -102,7 +80,7 @@ protected function getDefaultOrder() * * @return void */ - public function reinit() + public function reinit(): void { parent::reinit(); $this->filter_str = null; @@ -118,7 +96,7 @@ public function reinit() * * @return mixed the called property */ - public function __get($name) + public function __get(string $name) { Analog::log( @@ -148,7 +126,7 @@ public function __get($name) * * @return void */ - public function __set($name, $value) + public function __set(string $name, $value): void { if (in_array($name, $this->pagination_fields)) { @@ -199,32 +177,19 @@ public function __set($name, $value) * * @return void */ - public function setLimit($select) + public function setLimit(Select $select): void { $this->setLimits($select); } - /** - * Set counter - * - * @param int $c Count - * - * @return void - */ - public function setCounter($c) - { - $this->counter = (int)$c; - $this->countPages(); - } - /** * Set objects filter * * @param ObjectsList $filters Filters for objects list * - * @return CategoriesList + * @return self */ - public function setObjectsFilter(ObjectsList $filters) + public function setObjectsFilter(ObjectsList $filters): self { $this->objects_filters = $filters; return $this; diff --git a/lib/GaletteObjectsLend/Filters/ObjectsList.php b/lib/GaletteObjectsLend/Filters/ObjectsList.php index 727afaa..2b86625 100644 --- a/lib/GaletteObjectsLend/Filters/ObjectsList.php +++ b/lib/GaletteObjectsLend/Filters/ObjectsList.php @@ -1,15 +1,9 @@ . - * - * @category Filters - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @version SVN: $Id$ - * @link http://galette.tuxfamily.org - * @since 2017-02-10 */ namespace GaletteObjectsLend\Filters; @@ -41,18 +25,12 @@ use Galette\Core\Pagination; use GaletteObjectsLend\Repository\Objects; use Laminas\Db\Sql\Select; +use Slim\Views\Twig; /** * Objects list filters and paginator * - * @name ObjectsList - * @category Filters - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski * * @property ?string $filter_str * @property ?int $category_filter @@ -73,7 +51,8 @@ class ObjectsList extends Pagination protected $query; - protected $objectslist_fields = array( + /** @var array */ + protected array $objectslist_fields = array( 'filter_str', 'category_filter', 'active_filter', @@ -95,7 +74,7 @@ public function __construct() * * @return string field name */ - protected function getDefaultOrder() + protected function getDefaultOrder(): string { return 'name'; } @@ -105,7 +84,7 @@ protected function getDefaultOrder() * * @return void */ - public function reinit() + public function reinit(): void { parent::reinit(); $this->filter_str = null; @@ -120,9 +99,9 @@ public function reinit() * * @param string $name Property name * - * @return object|void + * @return bool */ - public function __isset($name) + public function __isset(string $name): bool { if (in_array($name, $this->objectslist_fields)) { return true; @@ -138,7 +117,7 @@ public function __isset($name) * * @return mixed the called property */ - public function __get($name) + public function __get(string $name) { Analog::log( '[ObectsList] Getting property `' . $name . '`', @@ -167,7 +146,7 @@ public function __get($name) * * @return void */ - public function __set($name, $value) + public function __set(string $name, $value): void { if (in_array($name, $this->pagination_fields)) { @@ -254,33 +233,20 @@ public function __set($name, $value) * * @return void */ - public function setLimit($select) + public function setLimit(Select $select) { $this->setLimits($select); } - /** - * Set counter - * - * @param int $c Count - * - * @return void - */ - public function setCounter($c) - { - $this->counter = (int)$c; - $this->countPages(); - } - /** * Set commons filters for templates * * @param \GaletteObjectsLend\Entity\Preferences $prefs Preferences instance - * @param mixed $view Template reference + * @param Twig $view Template reference * * @return void */ - public function setViewCommonsFilters($prefs, $view) + public function setViewCommonsFilters($prefs, $view): void { $prefs = $prefs->getPreferences(); diff --git a/lib/GaletteObjectsLend/Filters/StatusList.php b/lib/GaletteObjectsLend/Filters/StatusList.php index 85255bf..96424e8 100644 --- a/lib/GaletteObjectsLend/Filters/StatusList.php +++ b/lib/GaletteObjectsLend/Filters/StatusList.php @@ -1,15 +1,9 @@ . - * - * @category Filters - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @version SVN: $Id$ - * @link http://galette.tuxfamily.org - * @since 2017-02-10 */ namespace GaletteObjectsLend\Filters; @@ -44,14 +28,7 @@ /** * Status list filters and paginator * - * @name StatusList - * @category Filters - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski * * @property ?string $filter_str * @property ?int $active_filter @@ -68,7 +45,8 @@ class StatusList extends Pagination protected $query; - protected $statuslist_fields = array( + /** @var array */ + protected array $statuslist_fields = array( 'filter_str', 'active_filter', 'stock_filter', @@ -80,7 +58,7 @@ class StatusList extends Pagination * * @return string field name */ - protected function getDefaultOrder() + protected function getDefaultOrder(): string { return 'status_text'; } @@ -90,7 +68,7 @@ protected function getDefaultOrder() * * @return void */ - public function reinit() + public function reinit(): void { parent::reinit(); $this->filter_str = null; @@ -105,7 +83,7 @@ public function reinit() * * @return mixed the called property */ - public function __get($name) + public function __get(string $name) { Analog::log( @@ -135,7 +113,7 @@ public function __get($name) * * @return void */ - public function __set($name, $value) + public function __set(string $name, $value): void { if (in_array($name, $this->pagination_fields)) { diff --git a/lib/GaletteObjectsLend/IO/PdfObject.php b/lib/GaletteObjectsLend/IO/PdfObject.php index 3abd94f..debf6e6 100644 --- a/lib/GaletteObjectsLend/IO/PdfObject.php +++ b/lib/GaletteObjectsLend/IO/PdfObject.php @@ -1,15 +1,9 @@ . - * - * @category IO - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org */ namespace GaletteObjectsLend\IO; @@ -49,13 +35,7 @@ /** * Object card PDF * - * @category IO - * @name PdfObject - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class PdfObject extends Pdf { diff --git a/lib/GaletteObjectsLend/IO/PdfObjects.php b/lib/GaletteObjectsLend/IO/PdfObjects.php index a7a2f10..76e2171 100644 --- a/lib/GaletteObjectsLend/IO/PdfObjects.php +++ b/lib/GaletteObjectsLend/IO/PdfObjects.php @@ -1,15 +1,9 @@ . - * - * @category IO - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org */ namespace GaletteObjectsLend\IO; @@ -48,13 +34,7 @@ /** * Object labels PDF * - * @category IO - * @name PDFObjects - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class PdfObjects extends Pdf { diff --git a/lib/GaletteObjectsLend/PluginGaletteObjectslend.php b/lib/GaletteObjectsLend/PluginGaletteObjectslend.php index 375ccfa..196d33a 100644 --- a/lib/GaletteObjectsLend/PluginGaletteObjectslend.php +++ b/lib/GaletteObjectsLend/PluginGaletteObjectslend.php @@ -1,15 +1,9 @@ . - * - * @category Plugins - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2022-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @version SVN: $Id$ - * @link http://galette.tuxfamily.org - * @since Available since 2.0.0dev - 2022-05-29 */ namespace GaletteObjectsLend; @@ -44,14 +28,7 @@ /** * Plugin Galette Objects Lend * - * @category Plugins - * @name PluginObjectsLend - * @package GaletteObjectsLend - * @author Johan Cwiklinski - * @copyright 2022-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since Available since 2.0.0dev - 2022-05-29 + * @author Johan Cwiklinski */ class PluginGaletteObjectslend extends GalettePlugin @@ -59,7 +36,7 @@ class PluginGaletteObjectslend extends GalettePlugin /** * Extra menus entries * - * @return array|array[] + * @return array> */ public static function getMenusContents(): array { @@ -120,7 +97,7 @@ public static function getMenusContents(): array /** * Extra public menus entries * - * @return array|array[] + * @return array> */ public static function getPublicMenusItemsList(): array { @@ -130,7 +107,7 @@ public static function getPublicMenusItemsList(): array /** * Get dashboards contents * - * @return array|array[] + * @return array> */ public static function getDashboardsContents(): array { @@ -142,7 +119,7 @@ public static function getDashboardsContents(): array * * @param Adherent $member Member instance * - * @return array|array[] + * @return array> */ public static function getListActionsContents(Adherent $member): array { @@ -154,7 +131,7 @@ public static function getListActionsContents(Adherent $member): array * * @param Adherent $member Member instance * - * @return array|array[] + * @return array> */ public static function getDetailedActionsContents(Adherent $member): array { @@ -164,7 +141,7 @@ public static function getDetailedActionsContents(Adherent $member): array /** * Get batch actions contents * - * @return array|array[] + * @return array> */ public static function getBatchActionsContents(): array { diff --git a/lib/GaletteObjectsLend/Repository/Categories.php b/lib/GaletteObjectsLend/Repository/Categories.php index b0f9a3f..fceb5bf 100644 --- a/lib/GaletteObjectsLend/Repository/Categories.php +++ b/lib/GaletteObjectsLend/Repository/Categories.php @@ -1,15 +1,9 @@ . - * - * @category Repository - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2017-02-10 */ namespace GaletteObjectsLend\Repository; @@ -55,14 +40,7 @@ /** * Categories list * - * @name Categories - * @category Repository - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class Categories { diff --git a/lib/GaletteObjectsLend/Repository/Objects.php b/lib/GaletteObjectsLend/Repository/Objects.php index 0899772..e8c9406 100644 --- a/lib/GaletteObjectsLend/Repository/Objects.php +++ b/lib/GaletteObjectsLend/Repository/Objects.php @@ -1,15 +1,9 @@ . - * - * @category Repository - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2017-02-10 */ namespace GaletteObjectsLend\Repository; @@ -55,14 +40,7 @@ /** * Objects list * - * @name Objects - * @category Repository - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2017-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class Objects { diff --git a/lib/GaletteObjectsLend/Repository/Status.php b/lib/GaletteObjectsLend/Repository/Status.php index 6aaaec1..70b9e34 100644 --- a/lib/GaletteObjectsLend/Repository/Status.php +++ b/lib/GaletteObjectsLend/Repository/Status.php @@ -1,15 +1,9 @@ . - * - * @category Repository - * @package Galette - * - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org - * @since 2018-01-07 */ namespace GaletteObjectsLend\Repository; @@ -54,14 +39,7 @@ /** * Status list * - * @name Status - * @category Repository - * @package GaletteObjectsLend - * - * @author Johan Cwiklinski - * @copyright 2018-2023 The Galette Team - * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version - * @link http://galette.tuxfamily.org + * @author Johan Cwiklinski */ class Status { diff --git a/templates/default/categories_list.html.twig b/templates/default/categories_list.html.twig index 4efb1c2..5bac5f6 100644 --- a/templates/default/categories_list.html.twig +++ b/templates/default/categories_list.html.twig @@ -1,3 +1,23 @@ +{# +/** + * Copyright © 2003-2024 The Galette Team + * + * This file is part of Galette (https://galette.eu). + * + * Galette is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Galette is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Galette. If not, see . + */ +#} {% extends 'elements/list.html.twig' %} {% import "macros.twig" as macros %} diff --git a/templates/default/category_edit.html.twig b/templates/default/category_edit.html.twig index 977613a..035e55f 100644 --- a/templates/default/category_edit.html.twig +++ b/templates/default/category_edit.html.twig @@ -1,3 +1,23 @@ +{# +/** + * Copyright © 2003-2024 The Galette Team + * + * This file is part of Galette (https://galette.eu). + * + * Galette is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Galette is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Galette. If not, see . + */ +#} {% extends "page.html.twig" %} {% block content %} diff --git a/templates/default/headers.html.twig b/templates/default/headers.html.twig index 0e45173..0c99f4f 100644 --- a/templates/default/headers.html.twig +++ b/templates/default/headers.html.twig @@ -1,3 +1,23 @@ +{# +/** + * Copyright © 2003-2024 The Galette Team + * + * This file is part of Galette (https://galette.eu). + * + * Galette is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Galette is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Galette. If not, see . + */ +#} {% if olendsprefs is defined and olendsprefs.showFullsize() %}