Conditions | 1 |
Paths | 1 |
Total Lines | 31 |
Code Lines | 20 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
20 | public function getConfigTreeBuilder() |
||
21 | { |
||
22 | $treeBuilder = new TreeBuilder(); |
||
23 | $rootNode = $treeBuilder->root('akeneo_measure'); |
||
24 | |||
25 | $rootNode->children() |
||
26 | ->arrayNode('measures_config') |
||
27 | ->prototype('array') |
||
28 | ->children() |
||
29 | |||
30 | // standard unit (used as reference for conversion) |
||
31 | ->scalarNode('standard') |
||
32 | ->isRequired() |
||
33 | ->end() |
||
34 | |||
35 | // units of this group |
||
36 | ->arrayNode('units') |
||
37 | ->prototype('array') |
||
38 | ->children() |
||
39 | |||
40 | ->append($this->addConvertNode()) |
||
41 | |||
42 | ->scalarNode('symbol') |
||
43 | ->isRequired() |
||
44 | ->end() |
||
45 | ->end() |
||
46 | |||
47 | ->end(); |
||
48 | |||
49 | return $treeBuilder; |
||
50 | } |
||
51 | |||
88 |