55 Commits

Author SHA1 Message Date
Marijn 281462fab8 Added Gedmo stuff, fix translations (#117)
* Added Gedmo stuff, fix translations

* Add CSRF token validation across backoffice forms

- Added CSRF validations to candidate correction, penalty, answer saving, and elimination forms.
- Updated corresponding Twig templates to include CSRF token inputs.
- Adjusted column count in `tab_result` template to maintain layout consistency.

* Add unique index constraint for `quiz_candidate` with soft delete support

- Updated migration to include a unique index on `quiz_candidate` table that excludes soft-deleted records.
- Adjusted `QuizCandidate` entity to reflect the new unique constraint with `deleted_at` condition.

* Add CSRF token validation for quiz-related actions

- Added CSRF validation to `enableQuiz`, `clearQuiz`, `deleteQuiz`, `toggleCandidate`, and `prepareElimination` actions.
- Updated Twig templates to replace links with POST forms to include CSRF tokens.
- Set HTTP method restrictions for related endpoints to `POST`.

* Fix unique index condition for `quiz_candidate` with soft deletes

- Updated condition in unique index definition of `quiz_candidate` to add parentheses for clarity.
- Adjusted related migration to reflect the revised condition.

* Remove if for post an use methods in Route instead

* Refactor CSRF token validation in backoffice controllers

- Applied `#[IsCsrfTokenValid]` attribute for CSRF checks to simplify and standardize validation.
- Removed manual `isCsrfTokenValid` calls and associated exception throwing.
- Updated method signatures across affected endpoints to remove unnecessary `Request` dependency.
- Ensured consistency in route HTTP method restrictions where applicable.

* Add rector and phpstan

* Add validation for answering incorrect quiz question

- Added logic to prevent candidates from answering questions out of sequence in `QuizController`.
- Updated Dutch translations to include the new error message.

* Things
2026-05-24 19:43:30 +02:00
Marijn 03425024fe Fix Remember me (#111) 2026-05-21 21:38:31 +02:00
Marijn 55bbe962c1 Fix/answer without selected (#104)
* Fix a bug when click clicking next

* Disable autocomplete for name
2026-05-21 20:19:18 +02:00
Marijn d3bb8d7c57 Fix question order (#99) 2026-05-16 13:33:44 +02:00
Marijn 86e7d07078 Actual hotfix 2026-05-09 17:21:04 +02:00
Marijn 1c1ce5e071 Update composer.lock with dependency upgrades and improvements (#79)
* Update composer.lock with dependency upgrades and improvements

Updated multiple dependencies in `composer.lock` to their latest versions, including upgrades for Doctrine, PHPUnit, Symfony components, and extended PostgreSQL support.

* Fix sass compile
2026-03-22 22:26:56 +00:00
Marijn 18a6090366 Answer on candidate (#72)
* Add Penalty Seconds on tests

* Refactors and start of candidate answer relation

* Add breadcrumbs and UI consistency updates across backoffice templates

* Add breadcrumbs and UI consistency updates across backoffice templates

* Add Dutch translations for email verification and security messages

* Rector

* Refactor for code consistency and type safety assertions across repositories and entities

* Refactor candidate-related logic to optimize queries, improve template separation, and add "Answer Mapping" functionality.

* Cleanup

* Update Symfony

* Add coderabbit config

* Fixes from coderabbit
2026-03-22 22:40:25 +01:00
Marijn bcd6a157a8 Create Testcoverage and upgrade Symfomy and PHP
CI / Tests (push) Failing after 1m8s
CI / Build and deploy to ${{ startsWith(github.ref, 'refs/tags/') && 'production' || (github.ref == 'refs/heads/main' && 'acceptance' || '') }} (push) Has been skipped
* Some tests

* More tests!

* Tests 3

* Move getScores from Candidate to Quiz

* Add some suggestions for future refactoring

* - **Add Gedmo doctrine-extensions and Stof bundle integration**
  - Added `stof/doctrine-extensions-bundle` and `gedmo/doctrine-extensions` dependencies.
  - Integrated `Timestampable` behavior for `Created` fields in entities.
  - Updated `bundles.php` to register StofDoctrineExtensionsBundle.
  - Added configuration for the Stof bundle.
  - Simplified `SeasonVoter` with `match` expression and added new tests.
  - Minor fixes and adjustments across various files.

* WIP

* All the tests

* Base64 tests

* Symfomny 7.4.0

* Update

* Update recipe

* PHP 8.5

* Rector changes

* More 8.5

* Things
2025-11-28 22:56:09 +01:00
Marijn b66d2f9e86 Refactor entities and codebase for native property usage
CI / Tests (push) Failing after 35s
CI / Deploy (push) Has been skipped
- Replaced getters/setters with direct property access across entities and repositories.
- Added and configured `martin-georgiev/postgresql-for-doctrine` for PostgreSQL enhancements.
- Updated Doctrine configuration with types, mappings, and JSONB query functions.
- Removed unused `EliminationService` and related YAML configurations.
2025-10-08 20:50:33 +02:00
Marijn ca460cca7f - Refactor ORM annotations across entities for consistency.
- Adjusted migrations to align with refactored ORM annotations.
- Added new PHPStan and PHP-CS-Fixer configurations, including stricter rules.
- Introduced `tests/object-manager.php` to improve test environment setup.
2025-10-04 12:40:45 +02:00
Marijn 3e39550c90 Remove EasyAdmin integration
- Removed EasyAdmin controllers and configurations.
- Uninstalled `easycorp/easyadmin-bundle` and related dependencies.
- Cleaned up all associated routes, bundles, and vendor references.
2025-10-03 22:37:45 +02:00
Marijn 81e471a760 Change namespace to Tvdt 2025-09-28 18:14:58 +02:00
Marijn b7a570928a Update dependencies 2025-09-08 19:50:23 +02:00
Marijn f31a7d527d Fix scores? 2025-06-14 21:34:52 +02:00
Marijn ed3cf7644f Correct sorting for scores 2025-06-14 12:32:18 +02:00
Marijn 77d21b004f Update backoffice templates to dynamically include titles and improve candidate handling in SeasonController 2025-06-14 12:32:18 +02:00
Marijn 2bfef94bbe Add settings management for seasons, update templates, migrations, and commands 2025-06-10 23:06:59 +02:00
Marijn a8c4cba968 Disable Turbo for now 2025-06-09 15:52:15 +02:00
Marijn d5566d4737 Refactor repositories to use DQL queries, simplify logic, and enhance query efficiency 2025-06-09 14:19:10 +02:00
Marijn 79b24b0d44 Refine error handling 2025-06-07 23:45:40 +02:00
Marijn 7f93680987 Allow mail send fail 2025-06-07 23:43:52 +02:00
Marijn ebadc24b59 PHP 8.4 2025-06-07 22:24:38 +02:00
Marijn e0075fdcdc Rector upgrades 2025-06-07 22:24:38 +02:00
Marijn 06aafefffc Upgrade to Symfony 7.3 2025-06-07 22:24:38 +02:00
Marijn ff6534fa81 Improve links 2025-06-07 22:24:38 +02:00
Marijn 6a77df402d Add quiz clearing and deletion functionality with UI enhancements
This commit introduces the ability to clear quiz results and delete quizzes directly from the backoffice. It includes new routes, controllers, modals for user confirmation, and updates to translations. The `QuizRepository` now supports dedicated methods for clearing results and deleting quizzes along with error handling. Related database migrations and front-end adjustments are also included.
2025-06-07 20:59:01 +02:00
Marijn 79236d84e9 Add correction management to backoffice, refactor security voter logic, and enhance candidate scoring
This commit introduces functionality to manage candidate corrections in the backoffice, with updated templates and a new route handler. The SeasonVoter is refactored to support additional entities, and scoring logic is updated to incorporate corrections consistently. Includes test coverage for voter logic and UI improvements for score tables.
2025-06-07 16:09:13 +02:00
Marijn beb8d13dde Refactor Candidate and Quiz entities, rename Correction to QuizCandidate, and update related workflows
This commit removes nullable Uuid properties for consistency, transitions the Correction entity to QuizCandidate with associated migrations, refactors queries and repositories, adjusts related routes and controllers to use the new entity, updates front-end assets for elimination workflows, and standardizes route requirements and naming conventions.
2025-06-06 23:06:47 +02:00
Marijn 3e724ff1fb Add Turbo 2025-06-06 20:12:54 +02:00
Marijn e131d3b8d9 Fix cs 2025-06-06 19:33:54 +02:00
Marijn c6f9b57c60 Refactor translations to XLIFF format, enhance elimination workflows, and update compose configuration
This commit switches translations from YAML to XLIFF format for better standardization, updates the elimination preparation process with UI and functionality improvements, tweaks form structures, adjusts compose.override.yaml for improved asset handling, and optimizes back office usability with refined translation handling.
2025-06-01 21:28:56 +02:00
Marijn 25aa8b8622 Introduce importmap, enhance elimination workflows, and update assets
This commit adds initial importmap configuration to manage assets, updates the elimination preparation workflow with form enhancements and database changes, introduces new styles and JS assets, refines translations, and improves entity handling with an input bag update method.
2025-06-01 15:40:47 +02:00
Marijn d3e5cb0569 Refactor elimination feature and improve backoffice usability
This commit introduces a refactored EliminationFactory for better modularity, updates the elimination preparation process, and adds functionality to view eliminations. Backoffice templates and forms have been reorganized, minor translations were corrected, and additional assets like styles and flashes were included for enhanced user experience.
2025-06-01 15:40:47 +02:00
Marijn e0350c8c31 WIP 2025-06-01 15:40:47 +02:00
Marijn 09d74ed327 Add lost file 2025-04-29 07:55:17 +02:00
Marijn 49b7c0f5d5 Add Sheet upload function 2025-04-28 23:01:37 +02:00
Marijn 4712c01688 Add quiz management features and improve UI 2025-04-23 23:23:22 +02:00
Marijn 0f07e7eabf Phpstan 2025-04-22 23:42:07 +02:00
Marijn 7b05e52d95 A lot 2025-04-22 22:25:18 +02:00
Marijn 66b57ea84a Secure admin 2025-04-21 19:12:48 +02:00
Marijn 057bc778ed Fixes 2025-04-21 18:03:54 +02:00
Marijn f44b63a91f Error code for wrong season code 2025-04-21 15:47:27 +02:00
Marijn 4bcab2724a Implement email verification feature, add registration form, and update user entity for verification status 2025-04-20 19:34:27 +02:00
Marijn c70f713f7e Refactor Base64 encoding/decoding methods for consistency, update controller routes, and improve CI configuration
CI / Tests (push) Failing after 9m39s
CI / Docker Lint (push) Successful in 4s
2025-04-14 18:30:18 +02:00
Marijn 31e6ed406b Refactor routes for consistency, update season codes, and add Justfile for Docker commands 2025-04-02 22:12:55 +02:00
Marijn acf5c06fcc Refactor code for improved readability and consistency; add flash message handling and enhance quiz functionality
CI / Tests (push) Failing after 9s
CI / Docker Lint (push) Successful in 4s
2025-03-12 23:18:13 +01:00
Marijn 448daed6ea wip 12-03-2025
CI / Tests (push) Failing after 11s
CI / Docker Lint (push) Successful in 3s
2025-03-12 09:28:36 +01:00
Marijn f7b4b98da4 Refactor YAML and Twig files for consistent indentation and formatting
CI / Tests (push) Failing after 10m32s
CI / Docker Lint (push) Successful in 9s
2025-03-05 22:47:59 +01:00
Marijn 0ccce51af8 Add AbstractController, implement flash message handling, and refactor repositories 2025-03-05 21:01:57 +01:00
Marijn 29bc74fe4f Implement flash messages, refactor candidate retrieval, and enhance quiz functionality 2025-03-04 22:20:35 +01:00