|
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- <?php
-
- namespace Lc\SovBundle\Definition;
-
-
- class SiteSettingDefinition extends AbstractSettingDefinition implements SiteSettingDefinitionInterface
- {
- const CATEGORY_GENERAL = 'general';
- const CATEGORY_EMAIL = 'email';
-
- const SETTING_MAINTENANCE = 'maintenance';
- const SETTING_MAINTENANCE_IP_AUTHORIZED = 'maintenanceIpAuthorized';
-
- const SETTING_EMAIL_SUBJECT_PREFIX = 'emailSubjectPrefix';
- const SETTING_EMAIL_FROM = 'emailFrom';
- const SETTING_EMAIL_FROM_NAME = 'emailFromName';
-
- public function __construct()
- {
- // général
- $this->addSettingSelect(
- [
- 'category' => self::CATEGORY_GENERAL,
- 'name' => self::SETTING_MAINTENANCE,
- 'choices' => [
- 'Non' => 0,
- 'Oui' => 1,
- ]
- ]
- );
-
- $this->addSettingText(
- [
- 'category' => self::CATEGORY_GENERAL,
- 'name' => self::SETTING_MAINTENANCE_IP_AUTHORIZED,
- ]
- );
- }
-
- public function getCategories()
- {
- return [
- self::CATEGORY_GENERAL,
- ];
- }
-
- }
|