Completed
Push — master ( cc4cee...40bddf )
by Mewes
09:51
created
DependencyInjection/MewesKTwigExcelExtension.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     protected function loadInternal(array $mergedConfig, ContainerBuilder $container)
21 21
     {
22
-        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
22
+        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
23 23
         $loader->load('services.xml');
24 24
 
25 25
         $container->setParameter('mewes_k_twig_excel.pre_calculate_formulas', $mergedConfig['pre_calculate_formulas']);
Please login to merge, or discard this patch.
Wrapper/XlsDocumentWrapper.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@
 block discarded – undo
140 140
             $format = $this->attributes['format'];
141 141
         }
142 142
 
143
-         // try Symfony request
143
+            // try Symfony request
144 144
         else if (array_key_exists('app', $this->context)) {
145 145
             /**
146 146
              * @var $appVariable AppVariable
Please login to merge, or discard this patch.
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -58,61 +58,61 @@  discard block
 block discarded – undo
58 58
 
59 59
     protected function initializeMappings()
60 60
     {
61
-        $this->mappings['category'] = function ($value) {
61
+        $this->mappings['category'] = function($value) {
62 62
             $this->object->getProperties()->setCategory($value);
63 63
         };
64
-        $this->mappings['company'] = function ($value) {
64
+        $this->mappings['company'] = function($value) {
65 65
             $this->object->getProperties()->setCompany($value);
66 66
         };
67
-        $this->mappings['created'] = function ($value) {
67
+        $this->mappings['created'] = function($value) {
68 68
             $this->object->getProperties()->setCreated($value);
69 69
         };
70
-        $this->mappings['creator'] = function ($value) {
70
+        $this->mappings['creator'] = function($value) {
71 71
             $this->object->getProperties()->setCreator($value);
72 72
         };
73
-        $this->mappings['defaultStyle'] = function ($value) {
73
+        $this->mappings['defaultStyle'] = function($value) {
74 74
             $this->object->getDefaultStyle()->applyFromArray($value);
75 75
         };
76
-        $this->mappings['description'] = function ($value) {
76
+        $this->mappings['description'] = function($value) {
77 77
             $this->object->getProperties()->setDescription($value);
78 78
         };
79
-        $this->mappings['format'] = function ($value) {
79
+        $this->mappings['format'] = function($value) {
80 80
             $this->attributes['format'] = $value;
81 81
         };
82
-        $this->mappings['keywords'] = function ($value) {
82
+        $this->mappings['keywords'] = function($value) {
83 83
             $this->object->getProperties()->setKeywords($value);
84 84
         };
85
-        $this->mappings['lastModifiedBy'] = function ($value) {
85
+        $this->mappings['lastModifiedBy'] = function($value) {
86 86
             $this->object->getProperties()->setLastModifiedBy($value);
87 87
         };
88
-        $this->mappings['manager'] = function ($value) {
88
+        $this->mappings['manager'] = function($value) {
89 89
             $this->object->getProperties()->setManager($value);
90 90
         };
91
-        $this->mappings['modified'] = function ($value) {
91
+        $this->mappings['modified'] = function($value) {
92 92
             $this->object->getProperties()->setModified($value);
93 93
         };
94
-        $this->mappings['security']['lockRevision'] = function ($value) {
94
+        $this->mappings['security']['lockRevision'] = function($value) {
95 95
             $this->object->getSecurity()->setLockRevision($value);
96 96
         };
97
-        $this->mappings['security']['lockStructure'] = function ($value) {
97
+        $this->mappings['security']['lockStructure'] = function($value) {
98 98
             $this->object->getSecurity()->setLockStructure($value);
99 99
         };
100
-        $this->mappings['security']['lockWindows'] = function ($value) {
100
+        $this->mappings['security']['lockWindows'] = function($value) {
101 101
             $this->object->getSecurity()->setLockWindows($value);
102 102
         };
103
-        $this->mappings['security']['revisionsPassword'] = function ($value) {
103
+        $this->mappings['security']['revisionsPassword'] = function($value) {
104 104
             $this->object->getSecurity()->setRevisionsPassword($value);
105 105
         };
106
-        $this->mappings['security']['workbookPassword'] = function ($value) {
106
+        $this->mappings['security']['workbookPassword'] = function($value) {
107 107
             $this->object->getSecurity()->setWorkbookPassword($value);
108 108
         };
109
-        $this->mappings['subject'] = function ($value) {
109
+        $this->mappings['subject'] = function($value) {
110 110
             $this->object->getProperties()->setSubject($value);
111 111
         };
112
-        $this->mappings['template'] = function ($value) {
112
+        $this->mappings['template'] = function($value) {
113 113
             $this->attributes['template'] = $value;
114 114
         };
115
-        $this->mappings['title'] = function ($value) {
115
+        $this->mappings['title'] = function($value) {
116 116
             $this->object->getProperties()->setTitle($value);
117 117
         };
118 118
     }
@@ -239,7 +239,7 @@  discard block
 block discarded – undo
239 239
             foreach ($loader->getNamespaces() as $namespace) {
240 240
                 if (strpos($path, $namespace) === 1) {
241 241
                     foreach ($loader->getPaths($namespace) as $namespacePath) {
242
-                        $expandedPathAttribute = str_replace('@' . $namespace, $namespacePath, $path);
242
+                        $expandedPathAttribute = str_replace('@'.$namespace, $namespacePath, $path);
243 243
                         if (file_exists($expandedPathAttribute)) {
244 244
                             return $expandedPathAttribute;
245 245
                         }
Please login to merge, or discard this patch.
Braces   +38 added lines, -19 removed lines patch added patch discarded remove patch
@@ -58,61 +58,80 @@
 block discarded – undo
58 58
 
59 59
     protected function initializeMappings()
60 60
     {
61
-        $this->mappings['category'] = function ($value) {
61
+        $this->mappings['category'] = function ($value)
62
+        {
62 63
             $this->object->getProperties()->setCategory($value);
63 64
         };
64
-        $this->mappings['company'] = function ($value) {
65
+        $this->mappings['company'] = function ($value)
66
+        {
65 67
             $this->object->getProperties()->setCompany($value);
66 68
         };
67
-        $this->mappings['created'] = function ($value) {
69
+        $this->mappings['created'] = function ($value)
70
+        {
68 71
             $this->object->getProperties()->setCreated($value);
69 72
         };
70
-        $this->mappings['creator'] = function ($value) {
73
+        $this->mappings['creator'] = function ($value)
74
+        {
71 75
             $this->object->getProperties()->setCreator($value);
72 76
         };
73
-        $this->mappings['defaultStyle'] = function ($value) {
77
+        $this->mappings['defaultStyle'] = function ($value)
78
+        {
74 79
             $this->object->getDefaultStyle()->applyFromArray($value);
75 80
         };
76
-        $this->mappings['description'] = function ($value) {
81
+        $this->mappings['description'] = function ($value)
82
+        {
77 83
             $this->object->getProperties()->setDescription($value);
78 84
         };
79
-        $this->mappings['format'] = function ($value) {
85
+        $this->mappings['format'] = function ($value)
86
+        {
80 87
             $this->attributes['format'] = $value;
81 88
         };
82
-        $this->mappings['keywords'] = function ($value) {
89
+        $this->mappings['keywords'] = function ($value)
90
+        {
83 91
             $this->object->getProperties()->setKeywords($value);
84 92
         };
85
-        $this->mappings['lastModifiedBy'] = function ($value) {
93
+        $this->mappings['lastModifiedBy'] = function ($value)
94
+        {
86 95
             $this->object->getProperties()->setLastModifiedBy($value);
87 96
         };
88
-        $this->mappings['manager'] = function ($value) {
97
+        $this->mappings['manager'] = function ($value)
98
+        {
89 99
             $this->object->getProperties()->setManager($value);
90 100
         };
91
-        $this->mappings['modified'] = function ($value) {
101
+        $this->mappings['modified'] = function ($value)
102
+        {
92 103
             $this->object->getProperties()->setModified($value);
93 104
         };
94
-        $this->mappings['security']['lockRevision'] = function ($value) {
105
+        $this->mappings['security']['lockRevision'] = function ($value)
106
+        {
95 107
             $this->object->getSecurity()->setLockRevision($value);
96 108
         };
97
-        $this->mappings['security']['lockStructure'] = function ($value) {
109
+        $this->mappings['security']['lockStructure'] = function ($value)
110
+        {
98 111
             $this->object->getSecurity()->setLockStructure($value);
99 112
         };
100
-        $this->mappings['security']['lockWindows'] = function ($value) {
113
+        $this->mappings['security']['lockWindows'] = function ($value)
114
+        {
101 115
             $this->object->getSecurity()->setLockWindows($value);
102 116
         };
103
-        $this->mappings['security']['revisionsPassword'] = function ($value) {
117
+        $this->mappings['security']['revisionsPassword'] = function ($value)
118
+        {
104 119
             $this->object->getSecurity()->setRevisionsPassword($value);
105 120
         };
106
-        $this->mappings['security']['workbookPassword'] = function ($value) {
121
+        $this->mappings['security']['workbookPassword'] = function ($value)
122
+        {
107 123
             $this->object->getSecurity()->setWorkbookPassword($value);
108 124
         };
109
-        $this->mappings['subject'] = function ($value) {
125
+        $this->mappings['subject'] = function ($value)
126
+        {
110 127
             $this->object->getProperties()->setSubject($value);
111 128
         };
112
-        $this->mappings['template'] = function ($value) {
129
+        $this->mappings['template'] = function ($value)
130
+        {
113 131
             $this->attributes['template'] = $value;
114 132
         };
115
-        $this->mappings['title'] = function ($value) {
133
+        $this->mappings['title'] = function ($value)
134
+        {
116 135
             $this->object->getProperties()->setTitle($value);
117 136
         };
118 137
     }
Please login to merge, or discard this patch.
Twig/Node/XlsCellNode.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -33,16 +33,16 @@
 block discarded – undo
33 33
         $compiler->addDebugInfo($this)
34 34
             ->write('$context[\'phpExcel\']->setCellIndex(')
35 35
             ->subcompile($this->getNode('index'))
36
-            ->raw(');' . PHP_EOL)
36
+            ->raw(');'.PHP_EOL)
37 37
             ->write("ob_start();\n")
38 38
             ->subcompile($this->getNode('body'))
39
-            ->write('$cellValue = trim(ob_get_clean());' . PHP_EOL)
39
+            ->write('$cellValue = trim(ob_get_clean());'.PHP_EOL)
40 40
             ->write('$cellProperties = ')
41 41
             ->subcompile($this->getNode('properties'))
42
-            ->raw(';' . PHP_EOL)
43
-            ->write('$context[\'phpExcel\']->startCell($cellValue, $cellProperties);' . PHP_EOL)
44
-            ->write('unset($cellIndex, $cellValue, $cellProperties);' . PHP_EOL)
45
-            ->write('$context[\'phpExcel\']->endCell();' . PHP_EOL);
42
+            ->raw(';'.PHP_EOL)
43
+            ->write('$context[\'phpExcel\']->startCell($cellValue, $cellProperties);'.PHP_EOL)
44
+            ->write('unset($cellIndex, $cellValue, $cellProperties);'.PHP_EOL)
45
+            ->write('$context[\'phpExcel\']->endCell();'.PHP_EOL);
46 46
     }
47 47
 
48 48
     /**
Please login to merge, or discard this patch.
Twig/Node/XlsCenterNode.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -28,12 +28,12 @@
 block discarded – undo
28 28
     public function compile(Twig_Compiler $compiler)
29 29
     {
30 30
         $compiler->addDebugInfo($this)
31
-            ->write('$context[\'phpExcel\']->startAlignment(\'center\');' . PHP_EOL)
31
+            ->write('$context[\'phpExcel\']->startAlignment(\'center\');'.PHP_EOL)
32 32
             ->write("ob_start();\n")
33 33
             ->subcompile($this->getNode('body'))
34
-            ->write('$centerValue = trim(ob_get_clean());' . PHP_EOL)
35
-            ->write('$context[\'phpExcel\']->endAlignment($centerValue);' . PHP_EOL)
36
-            ->write('unset($centerValue);' . PHP_EOL);
34
+            ->write('$centerValue = trim(ob_get_clean());'.PHP_EOL)
35
+            ->write('$context[\'phpExcel\']->endAlignment($centerValue);'.PHP_EOL)
36
+            ->write('unset($centerValue);'.PHP_EOL);
37 37
     }
38 38
 
39 39
     /**
Please login to merge, or discard this patch.
Twig/Node/XlsDrawingNode.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -32,13 +32,13 @@
 block discarded – undo
32 32
         $compiler->addDebugInfo($this)
33 33
             ->write('$drawingPath = ')
34 34
             ->subcompile($this->getNode('path'))
35
-            ->raw(';' . PHP_EOL)
35
+            ->raw(';'.PHP_EOL)
36 36
             ->write('$drawingProperties = ')
37 37
             ->subcompile($this->getNode('properties'))
38
-            ->raw(';' . PHP_EOL)
39
-            ->write('$context[\'phpExcel\']->startDrawing($drawingPath, $drawingProperties);' . PHP_EOL)
40
-            ->write('unset($drawingPath, $drawingProperties);' . PHP_EOL)
41
-            ->write('$context[\'phpExcel\']->endDrawing();' . PHP_EOL);
38
+            ->raw(';'.PHP_EOL)
39
+            ->write('$context[\'phpExcel\']->startDrawing($drawingPath, $drawingProperties);'.PHP_EOL)
40
+            ->write('unset($drawingPath, $drawingProperties);'.PHP_EOL)
41
+            ->write('$context[\'phpExcel\']->endDrawing();'.PHP_EOL);
42 42
     }
43 43
 
44 44
     /**
Please login to merge, or discard this patch.
Twig/Node/XlsFooterNode.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -33,16 +33,16 @@
 block discarded – undo
33 33
         $compiler->addDebugInfo($this)
34 34
             ->write('$footerType = ')
35 35
             ->subcompile($this->getNode('type'))
36
-            ->raw(';' . PHP_EOL)
37
-            ->write('$footerType = $footerType ? $footerType : \'footer\';' . PHP_EOL)
36
+            ->raw(';'.PHP_EOL)
37
+            ->write('$footerType = $footerType ? $footerType : \'footer\';'.PHP_EOL)
38 38
             ->write('$footerProperties = ')
39 39
             ->subcompile($this->getNode('properties'))
40
-            ->raw(';' . PHP_EOL)
41
-            ->write('$context[\'phpExcel\']->startHeaderFooter($footerType, $footerProperties);' . PHP_EOL)
42
-            ->write('unset($footerType, $footerProperties);' . PHP_EOL)
40
+            ->raw(';'.PHP_EOL)
41
+            ->write('$context[\'phpExcel\']->startHeaderFooter($footerType, $footerProperties);'.PHP_EOL)
42
+            ->write('unset($footerType, $footerProperties);'.PHP_EOL)
43 43
             ->subcompile($this->getNode('body'))
44 44
             ->addDebugInfo($this)
45
-            ->write('$context[\'phpExcel\']->endHeaderFooter();' . PHP_EOL);
45
+            ->write('$context[\'phpExcel\']->endHeaderFooter();'.PHP_EOL);
46 46
     }
47 47
 
48 48
     /**
Please login to merge, or discard this patch.
Twig/Node/XlsHeaderNode.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -33,16 +33,16 @@
 block discarded – undo
33 33
         $compiler->addDebugInfo($this)
34 34
             ->write('$headerType = ')
35 35
             ->subcompile($this->getNode('type'))
36
-            ->raw(';' . PHP_EOL)
37
-            ->write('$headerType = $headerType ? $headerType : \'header\';' . PHP_EOL)
36
+            ->raw(';'.PHP_EOL)
37
+            ->write('$headerType = $headerType ? $headerType : \'header\';'.PHP_EOL)
38 38
             ->write('$headerProperties = ')
39 39
             ->subcompile($this->getNode('properties'))
40
-            ->raw(';' . PHP_EOL)
41
-            ->write('$context[\'phpExcel\']->startHeaderFooter($headerType, $headerProperties);' . PHP_EOL)
42
-            ->write('unset($headerType, $headerProperties);' . PHP_EOL)
40
+            ->raw(';'.PHP_EOL)
41
+            ->write('$context[\'phpExcel\']->startHeaderFooter($headerType, $headerProperties);'.PHP_EOL)
42
+            ->write('unset($headerType, $headerProperties);'.PHP_EOL)
43 43
             ->subcompile($this->getNode('body'))
44 44
             ->addDebugInfo($this)
45
-            ->write('$context[\'phpExcel\']->endHeaderFooter();' . PHP_EOL);
45
+            ->write('$context[\'phpExcel\']->endHeaderFooter();'.PHP_EOL);
46 46
     }
47 47
 
48 48
     /**
Please login to merge, or discard this patch.
Twig/Node/XlsLeftNode.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -28,12 +28,12 @@
 block discarded – undo
28 28
     public function compile(Twig_Compiler $compiler)
29 29
     {
30 30
         $compiler->addDebugInfo($this)
31
-            ->write('$context[\'phpExcel\']->startAlignment(\'left\');' . PHP_EOL)
31
+            ->write('$context[\'phpExcel\']->startAlignment(\'left\');'.PHP_EOL)
32 32
             ->write("ob_start();\n")
33 33
             ->subcompile($this->getNode('body'))
34
-            ->write('$leftValue = trim(ob_get_clean());' . PHP_EOL)
35
-            ->write('$context[\'phpExcel\']->endAlignment($leftValue);' . PHP_EOL)
36
-            ->write('unset($leftValue);' . PHP_EOL);
34
+            ->write('$leftValue = trim(ob_get_clean());'.PHP_EOL)
35
+            ->write('$context[\'phpExcel\']->endAlignment($leftValue);'.PHP_EOL)
36
+            ->write('unset($leftValue);'.PHP_EOL);
37 37
     }
38 38
 
39 39
     /**
Please login to merge, or discard this patch.
Twig/Node/XlsRightNode.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -28,12 +28,12 @@
 block discarded – undo
28 28
     public function compile(Twig_Compiler $compiler)
29 29
     {
30 30
         $compiler->addDebugInfo($this)
31
-            ->write('$context[\'phpExcel\']->startAlignment(\'right\');' . PHP_EOL)
31
+            ->write('$context[\'phpExcel\']->startAlignment(\'right\');'.PHP_EOL)
32 32
             ->write("ob_start();\n")
33 33
             ->subcompile($this->getNode('body'))
34
-            ->write('$rightValue = trim(ob_get_clean());' . PHP_EOL)
35
-            ->write('$context[\'phpExcel\']->endAlignment($rightValue);' . PHP_EOL)
36
-            ->write('unset($rightValue);' . PHP_EOL);
34
+            ->write('$rightValue = trim(ob_get_clean());'.PHP_EOL)
35
+            ->write('$context[\'phpExcel\']->endAlignment($rightValue);'.PHP_EOL)
36
+            ->write('unset($rightValue);'.PHP_EOL);
37 37
     }
38 38
 
39 39
     /**
Please login to merge, or discard this patch.