|
@@ 33-46 (lines=14) @@
|
| 30 |
|
$this->configureController($config, $container); |
| 31 |
|
} |
| 32 |
|
|
| 33 |
|
protected function configureExchangeRateService(array $config, ContainerBuilder $container) |
| 34 |
|
{ |
| 35 |
|
if ($container->hasDefinition('run_open_code.exchange_rate')) { |
| 36 |
|
$definition = $container->getDefinition('run_open_code.exchange_rate'); |
| 37 |
|
|
| 38 |
|
$definition->setArguments(array( |
| 39 |
|
$config['base_currency'], |
| 40 |
|
new Reference($config['repository']), |
| 41 |
|
new Reference('run_open_code.exchange_rate.registry.sources'), |
| 42 |
|
new Reference('run_open_code.exchange_rate.registry.processors'), |
| 43 |
|
new Reference('run_open_code.exchange_rate.registry.rates') |
| 44 |
|
)); |
| 45 |
|
} |
| 46 |
|
} |
| 47 |
|
|
| 48 |
|
protected function configureSourcesRegistry(array $config, ContainerBuilder $container) |
| 49 |
|
{ |
|
@@ 162-174 (lines=13) @@
|
| 159 |
|
} |
| 160 |
|
} |
| 161 |
|
|
| 162 |
|
public function configureController(array $config, ContainerBuilder $container) |
| 163 |
|
{ |
| 164 |
|
if ($container->has('run_open_code.exchange_rate.controller')) { |
| 165 |
|
$definition = $container->getDefinition('run_open_code.exchange_rate.controller'); |
| 166 |
|
$definition->setArguments(array( |
| 167 |
|
new Reference('security.csrf.token_manager'), |
| 168 |
|
new Reference('translator'), |
| 169 |
|
new Reference($config['repository']), |
| 170 |
|
$config['base_currency'], |
| 171 |
|
$config['view'] |
| 172 |
|
)); |
| 173 |
|
} |
| 174 |
|
} |
| 175 |
|
|
| 176 |
|
/** |
| 177 |
|
* {@inheritdoc} |