@@ -62,17 +62,17 @@ |
||
| 62 | 62 | } |
| 63 | 63 | |
| 64 | 64 | /** |
| 65 | - * @param array $statusOptions |
|
| 66 | - * @return UserStatusFieldset |
|
| 67 | - */ |
|
| 68 | - public function setStatusOptions(array $statusOptions) |
|
| 69 | - { |
|
| 70 | - $this->statusOptions = $statusOptions; |
|
| 65 | + * @param array $statusOptions |
|
| 66 | + * @return UserStatusFieldset |
|
| 67 | + */ |
|
| 68 | + public function setStatusOptions(array $statusOptions) |
|
| 69 | + { |
|
| 70 | + $this->statusOptions = $statusOptions; |
|
| 71 | 71 | |
| 72 | - return $this; |
|
| 73 | - } |
|
| 72 | + return $this; |
|
| 73 | + } |
|
| 74 | 74 | |
| 75 | - public function init() |
|
| 75 | + public function init() |
|
| 76 | 76 | { |
| 77 | 77 | $this->setName('status'); |
| 78 | 78 | |
@@ -87,7 +87,7 @@ |
||
| 87 | 87 | 'attributes' => [ |
| 88 | 88 | 'data-placeholder' => /*@translate*/ 'please select', |
| 89 | 89 | 'data-allowclear' => 'false', |
| 90 | - 'data-searchbox' => -1, // hide the search box |
|
| 90 | + 'data-searchbox' => -1, // hide the search box |
|
| 91 | 91 | 'required' => true, // mark label as required |
| 92 | 92 | ], |
| 93 | 93 | ] |
@@ -53,10 +53,10 @@ |
||
| 53 | 53 | public function __construct($status = self::ACTIVE) |
| 54 | 54 | { |
| 55 | 55 | if (!isset(static::$orderMap[$status])) { |
| 56 | - throw new \DomainException('Unknown status: ' . $status); |
|
| 56 | + throw new \DomainException('Unknown status: '.$status); |
|
| 57 | 57 | } |
| 58 | 58 | |
| 59 | - $constant = 'self::' . strtoupper($status); |
|
| 59 | + $constant = 'self::'.strtoupper($status); |
|
| 60 | 60 | $this->name = constant($constant); |
| 61 | 61 | $this->order = $this->getOrder(); |
| 62 | 62 | } |
@@ -84,9 +84,9 @@ |
||
| 84 | 84 | $imageStrategy = $infoContainer->getForm('info.image') |
| 85 | 85 | ->getHydrator() |
| 86 | 86 | ->getStrategy('image'); |
| 87 | - $fileEntity = $imageStrategy->getFileEntity(); |
|
| 88 | - $fileEntity->setUser($user); |
|
| 89 | - $imageStrategy->setFileEntity($fileEntity); |
|
| 87 | + $fileEntity = $imageStrategy->getFileEntity(); |
|
| 88 | + $fileEntity->setUser($user); |
|
| 89 | + $imageStrategy->setFileEntity($fileEntity); |
|
| 90 | 90 | |
| 91 | 91 | if ($this->request->isPost()) { |
| 92 | 92 | $formName = $params->fromQuery('form'); |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | /** |
| 41 | 41 | * @param UserRepository $userRepository |
| 42 | 42 | */ |
| 43 | - public function __construct(UserRepository $userRepository,$formManager,$viewHelper) |
|
| 43 | + public function __construct(UserRepository $userRepository, $formManager, $viewHelper) |
|
| 44 | 44 | { |
| 45 | 45 | $this->userRepository = $userRepository; |
| 46 | 46 | $this->formManager = $formManager; |
@@ -186,7 +186,7 @@ discard block |
||
| 186 | 186 | } |
| 187 | 187 | |
| 188 | 188 | $switcher = $this->plugin('Auth/User/Switcher'); |
| 189 | - $success = $switcher($this->params()->fromQuery('id'), [ 'ref' => urldecode($this->params()->fromQuery('ref')) ]); |
|
| 189 | + $success = $switcher($this->params()->fromQuery('id'), ['ref' => urldecode($this->params()->fromQuery('ref'))]); |
|
| 190 | 190 | |
| 191 | 191 | return new JsonModel(['success' => true]); |
| 192 | 192 | } |
@@ -215,8 +215,8 @@ |
||
| 215 | 215 | } |
| 216 | 216 | |
| 217 | 217 | /** |
| 218 | - * @param $response |
|
| 219 | - * @param $uri |
|
| 218 | + * @param \Zend\Stdlib\ResponseInterface $response |
|
| 219 | + * @param string $uri |
|
| 220 | 220 | * |
| 221 | 221 | * @return mixed |
| 222 | 222 | */ |
@@ -97,10 +97,10 @@ discard block |
||
| 97 | 97 | } |
| 98 | 98 | |
| 99 | 99 | $router = $e->getRouter(); |
| 100 | - $basePath=$router->getBaseUrl(); |
|
| 100 | + $basePath = $router->getBaseUrl(); |
|
| 101 | 101 | $match = []; |
| 102 | 102 | |
| 103 | - if (preg_match('~^' . $basePath . '/([a-z]{2})(?:/|$)~', $e->getRequest()->getRequestUri(), $match)) { |
|
| 103 | + if (preg_match('~^'.$basePath.'/([a-z]{2})(?:/|$)~', $e->getRequest()->getRequestUri(), $match)) { |
|
| 104 | 104 | /* It seems we have already a language in the URI |
| 105 | 105 | * Now there are two possibilities: |
| 106 | 106 | * |
@@ -182,8 +182,8 @@ discard block |
||
| 182 | 182 | setlocale( |
| 183 | 183 | LC_ALL, |
| 184 | 184 | array( |
| 185 | - $locale . ".utf8", |
|
| 186 | - $locale . ".iso88591", |
|
| 185 | + $locale.".utf8", |
|
| 186 | + $locale.".iso88591", |
|
| 187 | 187 | $locale, |
| 188 | 188 | substr($locale, 0, 2), |
| 189 | 189 | 'de_DE.utf8', |
@@ -61,11 +61,11 @@ |
||
| 61 | 61 | $paginatorManager = $this->serviceManager->get('Core/PaginatorService'); |
| 62 | 62 | $paginator = $paginatorManager->get($paginatorName); |
| 63 | 63 | if (!isset($paginator) || !$paginator instanceof ZendPaginator) { |
| 64 | - throw new \RuntimeException('Could not create paginator ' . $paginatorName); |
|
| 64 | + throw new \RuntimeException('Could not create paginator '.$paginatorName); |
|
| 65 | 65 | } |
| 66 | 66 | $adapter = $paginator->getAdapter(); |
| 67 | 67 | if (!isset($adapter) || !$adapter instanceof AdapterInterface) { |
| 68 | - throw new \RuntimeException('Paginator ' . $paginatorName . ' has no Adapter'); |
|
| 68 | + throw new \RuntimeException('Paginator '.$paginatorName.' has no Adapter'); |
|
| 69 | 69 | } |
| 70 | 70 | |
| 71 | 71 | $params = $usePostParams |
@@ -81,7 +81,7 @@ |
||
| 81 | 81 | |
| 82 | 82 | $adapter->setParams($params); |
| 83 | 83 | $paginator->setCurrentPageNumber($params->get('page', 1)) |
| 84 | - ->setItemCountPerPage($params->get('count', 10)); |
|
| 84 | + ->setItemCountPerPage($params->get('count', 10)); |
|
| 85 | 85 | |
| 86 | 86 | return $paginator; |
| 87 | 87 | } |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | * @param array $defaultParams |
| 47 | 47 | * @param bool $usePostParams |
| 48 | 48 | * |
| 49 | - * @return mixed |
|
| 49 | + * @return ZendPaginator |
|
| 50 | 50 | */ |
| 51 | 51 | public function __invoke($paginatorName, $defaultParams = array(), $usePostParams = false) |
| 52 | 52 | { |
@@ -106,7 +106,6 @@ discard block |
||
| 106 | 106 | } |
| 107 | 107 | |
| 108 | 108 | /** |
| 109 | - * @param ControllerManager $controllerManager |
|
| 110 | 109 | * @return CreatePaginatorService |
| 111 | 110 | */ |
| 112 | 111 | public static function factory(ContainerInterface $container) |
@@ -56,7 +56,7 @@ |
||
| 56 | 56 | */ |
| 57 | 57 | public function postDispatch(MvcEvent $e) |
| 58 | 58 | { |
| 59 | - // $view = $this->serviceLocator->get('view'); |
|
| 59 | + // $view = $this->serviceLocator->get('view'); |
|
| 60 | 60 | |
| 61 | 61 | } |
| 62 | 62 | |
@@ -32,11 +32,11 @@ |
||
| 32 | 32 | $this->serviceLocator = $serviceLocator; |
| 33 | 33 | } |
| 34 | 34 | |
| 35 | - public function attach(EventManagerInterface $events,$priority=1000) |
|
| 35 | + public function attach(EventManagerInterface $events, $priority = 1000) |
|
| 36 | 36 | { |
| 37 | 37 | $eventsApplication = $this->serviceLocator->get("Application")->getEventManager(); |
| 38 | 38 | |
| 39 | - $postDispatch = $events->attach(MvcEvent::EVENT_DISPATCH, array($this, 'postDispatch'),$priority); |
|
| 39 | + $postDispatch = $events->attach(MvcEvent::EVENT_DISPATCH, array($this, 'postDispatch'), $priority); |
|
| 40 | 40 | //$events->detach($postDispatch); |
| 41 | 41 | |
| 42 | 42 | return $this; |
@@ -214,7 +214,7 @@ discard block |
||
| 214 | 214 | public function __call($method, $args) |
| 215 | 215 | { |
| 216 | 216 | if (0 !== strpos($method, 'do')) { |
| 217 | - throw new \BadMethodCallException('Unknown method "' . $method . '"'); |
|
| 217 | + throw new \BadMethodCallException('Unknown method "'.$method.'"'); |
|
| 218 | 218 | } |
| 219 | 219 | |
| 220 | 220 | $name = substr($method, 2); |
@@ -248,7 +248,7 @@ discard block |
||
| 248 | 248 | } |
| 249 | 249 | |
| 250 | 250 | if ($method && method_exists($listener, $method)) { |
| 251 | - return call_user_func_array([ $listener, $method ], $args); |
|
| 251 | + return call_user_func_array([$listener, $method], $args); |
|
| 252 | 252 | } |
| 253 | 253 | |
| 254 | 254 | if (is_callable($listener)) { |
@@ -257,7 +257,7 @@ discard block |
||
| 257 | 257 | |
| 258 | 258 | throw new \UnexpectedValueException(sprintf( |
| 259 | 259 | 'Deferred listener %s%s is not callable.', |
| 260 | - get_class($listener), $method ? ' has no method "' . $method . '" and ' : '' |
|
| 260 | + get_class($listener), $method ? ' has no method "'.$method.'" and ' : '' |
|
| 261 | 261 | )); |
| 262 | 262 | } |
| 263 | 263 | |
@@ -31,7 +31,7 @@ |
||
| 31 | 31 | */ |
| 32 | 32 | public function __construct(LoginFilterService $loginFilter) |
| 33 | 33 | { |
| 34 | - $this->loginFilter = $loginFilter;; |
|
| 34 | + $this->loginFilter = $loginFilter; ; |
|
| 35 | 35 | } |
| 36 | 36 | |
| 37 | 37 | /** |
@@ -44,11 +44,11 @@ |
||
| 44 | 44 | } |
| 45 | 45 | |
| 46 | 46 | |
| 47 | - /** |
|
| 48 | - * @param ContainerInterface $container |
|
| 49 | - * |
|
| 50 | - * @return static |
|
| 51 | - */ |
|
| 47 | + /** |
|
| 48 | + * @param ContainerInterface $container |
|
| 49 | + * |
|
| 50 | + * @return static |
|
| 51 | + */ |
|
| 52 | 52 | public static function factory(ContainerInterface $container) |
| 53 | 53 | { |
| 54 | 54 | return new static($container->get('Auth/LoginFilter')); |
@@ -57,7 +57,7 @@ |
||
| 57 | 57 | protected function filterArrayStrings($array, $search, $replace) |
| 58 | 58 | { |
| 59 | 59 | $return = array(); |
| 60 | - foreach ((array)$array as $key => $value) { |
|
| 60 | + foreach ((array) $array as $key => $value) { |
|
| 61 | 61 | $key = str_replace($search, $replace, $key); |
| 62 | 62 | $value = is_array($value) |
| 63 | 63 | ? $this->filterArrayStrings($value, $search, $replace) |