Skip to content

Conversation

@CySSoO
Copy link
Contributor

@CySSoO CySSoO commented Dec 19, 2025

Motivation

  • Provide a modern Symfony-based admin UI for Everblock configuration while preserving backward compatibility with legacy admin controllers.
  • Encapsulate configuration logic into a service to prepare for progressive migration away from HelperForm/ObjectModel usage.
  • Ensure all new Symfony files are whitelisted in config/allowed_files.php so the module cleanup mechanism does not remove them.

Description

  • Add a Symfony admin controller: src/Controller/Admin/EverblockConfigurationController.php that renders and processes a Symfony form and redirects back on success. It uses EverblockConfigurationManager and TranslatorInterface.
  • Add a Symfony form type: src/Form/Type/EverblockConfigurationType.php using TranslateType, TextType and IntegerType with validation constraints for key configuration inputs.
  • Add a configuration service: src/Service/Configuration/EverblockConfigurationManager.php which uses ConfigurationAdapter, ShopContext and LanguageDataProvider to read/update multishop and multilanguage configuration safely.
  • Add routing and DI wiring: created config/routes.yml (route everblock_admin_configuration) and updated config/services.yml to autowire the new Controller, Form and Service/Configuration namespaces. The route includes _legacy_controller/_legacy link to preserve permissions/legacy tab behavior.
  • Whitelist new files: updated config/allowed_files.php to include all newly added files and the new route file plus the Twig template at views/templates/admin/symfony/configuration.html.twig.
  • Add index/guard files for new directories: src/Controller/index.php, src/Controller/Admin/index.php, src/Form/index.php, src/Form/Type/index.php, src/Service/Configuration/index.php, and a Twig template for the new admin form.

Testing

  • Automated tests: none executed for this change (no unit or integration tests were run in this rollout).
  • Note: The change is limited to adding files, wiring services/routes and updating the whitelist; manual verification of files creation and config/allowed_files.php updates was performed during the rollout.

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants