Browse Source

Divers

feature/ticket
Guillaume 3 years ago
parent
commit
4ee131b3f4
3 changed files with 10 additions and 11 deletions
  1. +2
    -2
      config/services.yaml
  2. +8
    -8
      src/Definition/MerchantSettingDefinition.php
  3. +0
    -1
      translations/admin.fr.yaml

+ 2
- 2
config/services.yaml View File

resource: '../src/Controller/' resource: '../src/Controller/'
tags: ['controller.service_arguments'] tags: ['controller.service_arguments']




carac.merchant.resolver: carac.merchant.resolver:
alias: Lc\CaracoleBundle\Resolver\MerchantResolver alias: Lc\CaracoleBundle\Resolver\MerchantResolver
public: true public: true
# add more service definitions when explicit configuration is needed # add more service definitions when explicit configuration is needed
# please note that last definitions always *replace* previous ones # please note that last definitions always *replace* previous ones


Lc\CaracoleBundle\Definition\MerchantSettingDefinition:
class: App\Definition\MerchantSettingDefinition

+ 8
- 8
src/Definition/MerchantSettingDefinition.php View File



namespace App\Definition; namespace App\Definition;


use Lc\CaracoleBundle\Definition\AbstractSettingDefinition;
use Lc\CaracoleBundle\Definition\MerchantSettingDefinitionInterface;
use Lc\CaracoleBundle\Definition\MerchantSettingDefinition as CaracMerchantSettingDefinition;
use Lc\CaracoleBundle\Model\Setting\MerchantSettingInterface;


class MerchantSettingDefinition extends AbstractSettingDefinition implements MerchantSettingDefinitionInterface
class MerchantSettingDefinition extends CaracMerchantSettingDefinition implements MerchantSettingInterface
{ {
const CATEGORY_GENERAL = 'general';
const CATEGORY_EMAIL = 'email'; const CATEGORY_EMAIL = 'email';


const SETTING_EXAMPLE_TEXT = 'exampleText'; const SETTING_EXAMPLE_TEXT = 'exampleText';
const SETTING_EXAMPLE_FILE = 'exampleFile'; const SETTING_EXAMPLE_FILE = 'exampleFile';
const SETTING_EXAMPLE_IMAGE = 'exampleImage'; const SETTING_EXAMPLE_IMAGE = 'exampleImage';



public function __construct() public function __construct()
{ {

parent::__construct() ;

// général // général
$this $this
->addSettingText( ->addSettingText(


public function getCategories() public function getCategories()
{ {
return [
self::CATEGORY_GENERAL,
return array_merge(parent::getCategories(), [
self::CATEGORY_EMAIL, self::CATEGORY_EMAIL,
];
]);
} }


} }

+ 0
- 1
translations/admin.fr.yaml View File

setting_definition: setting_definition:
merchant: merchant:
categories: categories:
general: Général
email: Email email: Email
settings: settings:
exampleText: Texte exampleText: Texte

Loading…
Cancel
Save