@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | $dir = dirname($this->getReflection()->getFileName()); |
160 | 160 | |
161 | 161 | // ...try to get base component template file |
162 | - $templateFile = $this->templateFile !== NULL && is_file($this->templateFile) ? $this->templateFile : $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . 'default.latte'; |
|
162 | + $templateFile = $this->templateFile !== NULL && is_file($this->templateFile) ? $this->templateFile : $dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.'default.latte'; |
|
163 | 163 | $this->template->setFile($templateFile); |
164 | 164 | } |
165 | 165 | |
@@ -287,7 +287,7 @@ discard block |
||
287 | 287 | $widget = $factory->create($data); |
288 | 288 | |
289 | 289 | // Add widget component to container/position |
290 | - $positionContainer->addComponent($widget, ($widget->getName() . spl_object_hash($data))); |
|
290 | + $positionContainer->addComponent($widget, ($widget->getName().spl_object_hash($data))); |
|
291 | 291 | } |
292 | 292 | |
293 | 293 | /** |
@@ -66,11 +66,11 @@ |
||
66 | 66 | $dir = dirname($this->getReflection()->getFileName()); |
67 | 67 | |
68 | 68 | // ...check if extension template is used |
69 | - if (is_file($dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile)) { |
|
70 | - $templateFile = $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile; |
|
69 | + if (is_file($dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.$templateFile)) { |
|
70 | + $templateFile = $dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.$templateFile; |
|
71 | 71 | |
72 | - } else if (is_file($dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile . '.latte')) { |
|
73 | - $templateFile = $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile . '.latte'; |
|
72 | + } else if (is_file($dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.$templateFile.'.latte')) { |
|
73 | + $templateFile = $dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.$templateFile.'.latte'; |
|
74 | 74 | |
75 | 75 | } else { |
76 | 76 | // ...if not throw exception |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | { |
79 | 79 | // Widget data must be loaded |
80 | 80 | if (!$this->data instanceof Entities\IData) { |
81 | - throw new \LogicException('Missing call ' . get_called_class() . '::setData($entity)'); |
|
81 | + throw new \LogicException('Missing call '.get_called_class().'::setData($entity)'); |
|
82 | 82 | } |
83 | 83 | |
84 | 84 | return $this->data->getTitle(); |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | { |
92 | 92 | // Widget data must be loaded |
93 | 93 | if (!$this->data instanceof Entities\IData) { |
94 | - throw new \LogicException('Missing call ' . get_called_class() . '::setData($entity)'); |
|
94 | + throw new \LogicException('Missing call '.get_called_class().'::setData($entity)'); |
|
95 | 95 | } |
96 | 96 | |
97 | 97 | return $this->data->getDescription(); |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | { |
105 | 105 | // Widget data must be loaded |
106 | 106 | if (!$this->data instanceof Entities\IData) { |
107 | - throw new \LogicException('Missing call ' . get_called_class() . '::setData($entity)'); |
|
107 | + throw new \LogicException('Missing call '.get_called_class().'::setData($entity)'); |
|
108 | 108 | } |
109 | 109 | |
110 | 110 | return $this->data->getPriority(); |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | { |
118 | 118 | // Widget data must be loaded |
119 | 119 | if (!$this->data instanceof Entities\IData) { |
120 | - throw new \LogicException('Missing call ' . get_called_class() . '::setData($entity)'); |
|
120 | + throw new \LogicException('Missing call '.get_called_class().'::setData($entity)'); |
|
121 | 121 | } |
122 | 122 | |
123 | 123 | return $this->data->getStatus(); |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | { |
131 | 131 | // Widget data must be loaded |
132 | 132 | if (!$this->data instanceof Entities\IData) { |
133 | - throw new \LogicException('Missing call ' . get_called_class() . '::setData($entity)'); |
|
133 | + throw new \LogicException('Missing call '.get_called_class().'::setData($entity)'); |
|
134 | 134 | } |
135 | 135 | |
136 | 136 | return $this->data->getPosition(); |
@@ -157,7 +157,7 @@ discard block |
||
157 | 157 | $dir = dirname($this->getReflection()->getFileName()); |
158 | 158 | |
159 | 159 | // ...try to get base component template file |
160 | - $templateFile = $this->templateFile !== NULL && is_file($this->templateFile) ? $this->templateFile : $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . 'default.latte'; |
|
160 | + $templateFile = $this->templateFile !== NULL && is_file($this->templateFile) ? $this->templateFile : $dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.'default.latte'; |
|
161 | 161 | $this->template->setFile($templateFile); |
162 | 162 | } |
163 | 163 | |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | ->render(); |
187 | 187 | |
188 | 188 | // Modify widget name |
189 | - $name = $name . mb_substr($this->data->getTitle(), $pos); |
|
189 | + $name = $name.mb_substr($this->data->getTitle(), $pos); |
|
190 | 190 | } |
191 | 191 | |
192 | 192 | // If widget name has subtitle... |
@@ -203,20 +203,20 @@ discard block |
||
203 | 203 | ->render(); |
204 | 204 | |
205 | 205 | // Split name to title & subtitle |
206 | - $name = $title . $subtitle; |
|
206 | + $name = $title.$subtitle; |
|
207 | 207 | } |
208 | 208 | |
209 | 209 | // Set badge if exists |
210 | 210 | if ($badge = $this->data->getBadge()) { |
211 | 211 | $badge = Utils\Html::el('span') |
212 | - ->addAttributes(['class' => 'badge badge-' . $badge]) |
|
212 | + ->addAttributes(['class' => 'badge badge-'.$badge]) |
|
213 | 213 | ->render(); |
214 | 214 | } |
215 | 215 | |
216 | 216 | // Set icon if exists |
217 | 217 | if ($icon = $this->data->getIcon()) { |
218 | 218 | $icon = Utils\Html::el('span') |
219 | - ->addAttributes(['class' => 'icon icon-' . $icon]) |
|
219 | + ->addAttributes(['class' => 'icon icon-'.$icon]) |
|
220 | 220 | ->render(); |
221 | 221 | } |
222 | 222 |
@@ -56,7 +56,7 @@ |
||
56 | 56 | $dir = dirname($this->getReflection()->getFileName()); |
57 | 57 | |
58 | 58 | // ...try to get base component template file |
59 | - $templateFile = $this->templateFile !== NULL && is_file($this->templateFile) ? $this->templateFile : $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . 'default.latte'; |
|
59 | + $templateFile = $this->templateFile !== NULL && is_file($this->templateFile) ? $this->templateFile : $dir.DIRECTORY_SEPARATOR.'template'.DIRECTORY_SEPARATOR.'default.latte'; |
|
60 | 60 | $this->template->setFile($templateFile); |
61 | 61 | } |
62 | 62 |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | |
105 | 105 | // Register widget to manager and group |
106 | 106 | foreach ($groups as $group) { |
107 | - $service->addSetup('register', ['@' . $serviceName, $serviceName, $group]); |
|
107 | + $service->addSetup('register', ['@'.$serviceName, $serviceName, $group]); |
|
108 | 108 | } |
109 | 109 | } |
110 | 110 | |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | // Get all registered widgets decorators |
115 | 115 | foreach (array_keys($builder->findByTag(self::TAG_WIDGET_DECORATOR)) as $serviceName) { |
116 | 116 | // Register decorator to manager |
117 | - $service->addSetup('register', ['@' . $serviceName, $serviceName]); |
|
117 | + $service->addSetup('register', ['@'.$serviceName, $serviceName]); |
|
118 | 118 | } |
119 | 119 | |
120 | 120 | // Get widgets control provider |