@@ -67,13 +67,13 @@ |
||
| 67 | 67 | $file = "jobs.categories.$type.php"; |
| 68 | 68 | |
| 69 | 69 | foreach ($this->globalConfigPaths as $path) { |
| 70 | - if (file_exists($path . $file)) { |
|
| 71 | - return include $path . $file; |
|
| 70 | + if (file_exists($path.$file)) { |
|
| 71 | + return include $path.$file; |
|
| 72 | 72 | } |
| 73 | 73 | } |
| 74 | 74 | |
| 75 | - if (file_exists($this->moduleConfigPath . $file)) { |
|
| 76 | - return include $this->moduleConfigPath . $file; |
|
| 75 | + if (file_exists($this->moduleConfigPath.$file)) { |
|
| 76 | + return include $this->moduleConfigPath.$file; |
|
| 77 | 77 | } |
| 78 | 78 | |
| 79 | 79 | return false; |
@@ -167,7 +167,7 @@ |
||
| 167 | 167 | 'label' => $label, |
| 168 | 168 | ], |
| 169 | 169 | 'attributes' => [ |
| 170 | - 'class' => 'btn btn-' . ('submit' == $type ? 'primary' : 'default'), |
|
| 170 | + 'class' => 'btn btn-'.('submit' == $type ? 'primary' : 'default'), |
|
| 171 | 171 | 'type' => $type, |
| 172 | 172 | ], |
| 173 | 173 | ] |
@@ -69,7 +69,7 @@ |
||
| 69 | 69 | |
| 70 | 70 | $response = $this->client->send(); |
| 71 | 71 | if ($response->getStatusCode() !== 200) { |
| 72 | - throw new \RuntimeException('Query failed, because ' . $response->getReasonPhrase()); |
|
| 72 | + throw new \RuntimeException('Query failed, because '.$response->getReasonPhrase()); |
|
| 73 | 73 | } |
| 74 | 74 | |
| 75 | 75 | $result = $response->getBody(); |
@@ -96,18 +96,18 @@ discard block |
||
| 96 | 96 | $replyTo = $this->stringFromMailHeader($this->getReplyTo()); |
| 97 | 97 | |
| 98 | 98 | return str_pad($template, 30) |
| 99 | - . 'to: ' . str_pad($to, 50) |
|
| 100 | - . 'cc: ' . str_pad($cc, 50) |
|
| 101 | - . 'bcc: ' . str_pad($bcc, 50) |
|
| 102 | - . 'from: ' . str_pad($from, 50) |
|
| 103 | - . 'replyTo: ' . str_pad($replyTo, 50) |
|
| 99 | + . 'to: '.str_pad($to, 50) |
|
| 100 | + . 'cc: '.str_pad($cc, 50) |
|
| 101 | + . 'bcc: '.str_pad($bcc, 50) |
|
| 102 | + . 'from: '.str_pad($from, 50) |
|
| 103 | + . 'replyTo: '.str_pad($replyTo, 50) |
|
| 104 | 104 | //. str_pad(implode(',', ArrayUtils::iteratorToArray($this->getSender())),50) |
| 105 | - . 'subject: ' . str_pad($this->getSubject(), 50); |
|
| 105 | + . 'subject: '.str_pad($this->getSubject(), 50); |
|
| 106 | 106 | } |
| 107 | 107 | |
| 108 | 108 | public function template($template) |
| 109 | 109 | { |
| 110 | - $controller = get_class($this->controller); |
|
| 110 | + $controller = get_class($this->controller); |
|
| 111 | 111 | $services = $this->serviceManager; |
| 112 | 112 | |
| 113 | 113 | $event = new Event(); |
@@ -124,11 +124,11 @@ discard block |
||
| 124 | 124 | $controllerIdentifier = strtolower(substr($controller, 0, strpos($controller, '\\'))); |
| 125 | 125 | $viewResolver = $this->serviceManager->get('ViewResolver'); |
| 126 | 126 | |
| 127 | - $templateHalf = 'mail/' . $template; |
|
| 127 | + $templateHalf = 'mail/'.$template; |
|
| 128 | 128 | $resource = $viewResolver->resolve($templateHalf); |
| 129 | 129 | |
| 130 | 130 | if (empty($resource)) { |
| 131 | - $templateFull = $controllerIdentifier . '/mail/' . $template; |
|
| 131 | + $templateFull = $controllerIdentifier.'/mail/'.$template; |
|
| 132 | 132 | $resource = $viewResolver->resolve($templateFull); |
| 133 | 133 | } |
| 134 | 134 | |
@@ -155,7 +155,7 @@ discard block |
||
| 155 | 155 | unset($__vars[$key]); |
| 156 | 156 | } |
| 157 | 157 | } |
| 158 | - unset($__vars['content'],$__vars['controllerIdentifier'],$__vars['controller'],$__vars['resource'],$__vars['template'],$__vars['viewResolver']); |
|
| 158 | + unset($__vars['content'], $__vars['controllerIdentifier'], $__vars['controller'], $__vars['resource'], $__vars['template'], $__vars['viewResolver']); |
|
| 159 | 159 | $this->config = $__vars; |
| 160 | 160 | } |
| 161 | 161 | } |
@@ -180,20 +180,20 @@ discard block |
||
| 180 | 180 | if (isset($this->config['from'])) { |
| 181 | 181 | $from = $this->config['from']; |
| 182 | 182 | } else { |
| 183 | - $log->err('A from email address must be provided (Variable $from) in Template: ' . $template); |
|
| 184 | - throw new \InvalidArgumentException('A from email address must be provided (Variable $from) in Template: ' . $template); |
|
| 183 | + $log->err('A from email address must be provided (Variable $from) in Template: '.$template); |
|
| 184 | + throw new \InvalidArgumentException('A from email address must be provided (Variable $from) in Template: '.$template); |
|
| 185 | 185 | } |
| 186 | 186 | if (isset($this->config['fromName'])) { |
| 187 | 187 | $fromName = $this->config['fromName']; |
| 188 | 188 | } else { |
| 189 | - $log->err('A from name must be provided (Variable $fromName) in Template: ' . $template); |
|
| 190 | - throw new \InvalidArgumentException('A from name must be provided (Variable $fromName) in Template: ' . $template); |
|
| 189 | + $log->err('A from name must be provided (Variable $fromName) in Template: '.$template); |
|
| 190 | + throw new \InvalidArgumentException('A from name must be provided (Variable $fromName) in Template: '.$template); |
|
| 191 | 191 | } |
| 192 | 192 | if (isset($this->config['subject'])) { |
| 193 | 193 | $subject = $this->config['subject']; |
| 194 | 194 | } else { |
| 195 | - $log->err('A subject must be provided (Variable $subject) in Template: ' . $template); |
|
| 196 | - throw new \InvalidArgumentException('A subject must be provided (Variable $subject) in Template: ' . $template); |
|
| 195 | + $log->err('A subject must be provided (Variable $subject) in Template: '.$template); |
|
| 196 | + throw new \InvalidArgumentException('A subject must be provided (Variable $subject) in Template: '.$template); |
|
| 197 | 197 | } |
| 198 | 198 | $this->setFrom($from, $fromName); |
| 199 | 199 | $this->setSubject($subject); |
@@ -215,7 +215,7 @@ discard block |
||
| 215 | 215 | $erg = true; |
| 216 | 216 | $log->info($this); |
| 217 | 217 | } catch (\Exception $e) { |
| 218 | - $log->err('Mail failure ' . $e->getMessage()); |
|
| 218 | + $log->err('Mail failure '.$e->getMessage()); |
|
| 219 | 219 | //$this->serviceManager->get('Core/Log')->warn('Mail failure ' . $e->getMessage()); |
| 220 | 220 | } |
| 221 | 221 | //} |
@@ -61,7 +61,7 @@ |
||
| 61 | 61 | * |
| 62 | 62 | * @return self |
| 63 | 63 | */ |
| 64 | - public function addViewModel($name, $model, $priority=0) |
|
| 64 | + public function addViewModel($name, $model, $priority = 0) |
|
| 65 | 65 | { |
| 66 | 66 | $this->models->insert($name, $model, $priority); |
| 67 | 67 | |
@@ -130,7 +130,7 @@ |
||
| 130 | 130 | |
| 131 | 131 | protected function checkEntityType($entity) |
| 132 | 132 | { |
| 133 | - if ( !($entity instanceOf $this->entityPrototype) ) { |
|
| 133 | + if (!($entity instanceOf $this->entityPrototype)) { |
|
| 134 | 134 | throw new \InvalidArgumentException(sprintf( |
| 135 | 135 | 'Entity must be of type %s but recieved %s instead', |
| 136 | 136 | get_class($this->entityPrototype), |
@@ -40,12 +40,12 @@ |
||
| 40 | 40 | */ |
| 41 | 41 | public function attachShared(SharedEventManagerInterface $events) |
| 42 | 42 | { |
| 43 | - $events->attach('*', NotificationEvent::EVENT_NOTIFICATION_ADD, array($this,'add'), 1); |
|
| 44 | - $events->attach('Zend\Mvc\Application', MvcEvent::EVENT_DISPATCH, array($this,'renderJSON'), -240); |
|
| 45 | - $events->attach('Zend\Mvc\Application', MvcEvent::EVENT_DISPATCH, array($this,'renderHTML'), -250); |
|
| 43 | + $events->attach('*', NotificationEvent::EVENT_NOTIFICATION_ADD, array($this, 'add'), 1); |
|
| 44 | + $events->attach('Zend\Mvc\Application', MvcEvent::EVENT_DISPATCH, array($this, 'renderJSON'), -240); |
|
| 45 | + $events->attach('Zend\Mvc\Application', MvcEvent::EVENT_DISPATCH, array($this, 'renderHTML'), -250); |
|
| 46 | 46 | // Sometimes the Dispatch-Event is not reached, for instance with a route-direct |
| 47 | 47 | // but also for Events, that are happening after the Dispatch |
| 48 | - $events->attach('Zend\Mvc\Application', MvcEvent::EVENT_FINISH, array($this,'renderHTML'), -250); |
|
| 48 | + $events->attach('Zend\Mvc\Application', MvcEvent::EVENT_FINISH, array($this, 'renderHTML'), -250); |
|
| 49 | 49 | return $this; |
| 50 | 50 | } |
| 51 | 51 | |
@@ -26,7 +26,7 @@ discard block |
||
| 26 | 26 | if (null === $buttonContent) { |
| 27 | 27 | throw new Exception\DomainException( |
| 28 | 28 | sprintf( |
| 29 | - '%s expects either button content as the second argument, ' . |
|
| 29 | + '%s expects either button content as the second argument, '. |
|
| 30 | 30 | 'or that the element provided has a label value; neither found', |
| 31 | 31 | __METHOD__ |
| 32 | 32 | ) |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | $checkedBoole = ($value == 1 || $value == 'on'); |
| 47 | 47 | |
| 48 | 48 | |
| 49 | - $checkedClass = $checkedBoole?'active"':''; |
|
| 49 | + $checkedClass = $checkedBoole ? 'active"' : ''; |
|
| 50 | 50 | |
| 51 | 51 | $hiddenElement = ''; |
| 52 | 52 | if ($element->useHiddenElement()) { |
@@ -63,11 +63,11 @@ discard block |
||
| 63 | 63 | $element->setUseHiddenElement(false); |
| 64 | 64 | } |
| 65 | 65 | |
| 66 | - $buttonContent = $hiddenElement . PHP_EOL |
|
| 67 | - . '<div class="btn-group" data-toggle="buttons">' . PHP_EOL |
|
| 68 | - . '<label class="btn btn-default ' . $checkedClass . '">' . PHP_EOL |
|
| 69 | - . parent::render($element) . $buttonContent . PHP_EOL . '</label>' . PHP_EOL |
|
| 70 | - . '</div>' . PHP_EOL; |
|
| 66 | + $buttonContent = $hiddenElement.PHP_EOL |
|
| 67 | + . '<div class="btn-group" data-toggle="buttons">'.PHP_EOL |
|
| 68 | + . '<label class="btn btn-default '.$checkedClass.'">'.PHP_EOL |
|
| 69 | + . parent::render($element).$buttonContent.PHP_EOL.'</label>'.PHP_EOL |
|
| 70 | + . '</div>'.PHP_EOL; |
|
| 71 | 71 | |
| 72 | 72 | return $buttonContent; |
| 73 | 73 | } |
@@ -72,7 +72,7 @@ |
||
| 72 | 72 | * @throws \Core\Entity\Exception\OutOfBoundsException if the property does not exists. |
| 73 | 73 | * @since 0.25 |
| 74 | 74 | */ |
| 75 | - public function notEmpty($property, array $args=[]); |
|
| 75 | + public function notEmpty($property, array $args = []); |
|
| 76 | 76 | |
| 77 | 77 | /** |
| 78 | 78 | * Checks, if this entity has a property. |