@@ -115,7 +115,7 @@ discard block |
||
| 115 | 115 | } |
| 116 | 116 | |
| 117 | 117 | $identity = $this->getIdentity(); |
| 118 | - $applicationId = '@' . $this->getApplicationIdentifier(); |
|
| 118 | + $applicationId = '@'.$this->getApplicationIdentifier(); |
|
| 119 | 119 | $applicationIdIndex = strrpos($identity, $applicationId); |
| 120 | 120 | //$login = (0 < $applicationIdIndex && strlen($identity) - strlen($applicationId) == $applicationIdIndex)?substr($identity, 0, $applicationIdIndex):$identity; |
| 121 | 121 | $login = $identity; |
@@ -128,8 +128,8 @@ discard block |
||
| 128 | 128 | $loginSuccess = false; |
| 129 | 129 | $loginResult = array(); |
| 130 | 130 | |
| 131 | - if (0 < $applicationIdIndex && strlen($identity) - strlen($applicationId) == $applicationIdIndex) { |
|
| 132 | - $this->serviceManager->get('Core/Log')->debug('User ' . $login . ', login with correct suffix: '); |
|
| 131 | + if (0 < $applicationIdIndex && strlen($identity) - strlen($applicationId) == $applicationIdIndex) { |
|
| 132 | + $this->serviceManager->get('Core/Log')->debug('User '.$login.', login with correct suffix: '); |
|
| 133 | 133 | // the login ends with the applicationID, therefore use the secret key |
| 134 | 134 | // the external login must be the form 'xxxxx@yyyy' where yyyy is the matching suffix to the external application key |
| 135 | 135 | if (isset($user)) { |
@@ -137,7 +137,7 @@ discard block |
||
| 137 | 137 | $loginSuccess = true; |
| 138 | 138 | } else { |
| 139 | 139 | $loginSuccess = false; |
| 140 | - $this->serviceManager->get('Core/Log')->info('User ' . $login . ', secret: ' . $user->getSecret() . ' != loginPassword: ' . $filter->filter($credential) . ' (' . $credential . ')'); |
|
| 140 | + $this->serviceManager->get('Core/Log')->info('User '.$login.', secret: '.$user->getSecret().' != loginPassword: '.$filter->filter($credential).' ('.$credential.')'); |
|
| 141 | 141 | } |
| 142 | 142 | } else { |
| 143 | 143 | $user = $users->create( |
@@ -153,17 +153,17 @@ discard block |
||
| 153 | 153 | $loginResult = array('firstLogin' => true); |
| 154 | 154 | } |
| 155 | 155 | } elseif (isset($user)) { |
| 156 | - $this->serviceManager->get('Core/Log')->debug('User ' . $login . ', login with incorrect suffix: '); |
|
| 156 | + $this->serviceManager->get('Core/Log')->debug('User '.$login.', login with incorrect suffix: '); |
|
| 157 | 157 | if ($user->getCredential() == $filter->filter($credential)) { |
| 158 | - $this->serviceManager->get('Core/Log')->debug('User ' . $login . ', credentials are equal'); |
|
| 158 | + $this->serviceManager->get('Core/Log')->debug('User '.$login.', credentials are equal'); |
|
| 159 | 159 | $loginSuccess = true; |
| 160 | 160 | } elseif (!empty($applicationId)) { |
| 161 | - $this->serviceManager->get('Core/Log')->debug('User ' . $login . ', credentials are not equal'); |
|
| 161 | + $this->serviceManager->get('Core/Log')->debug('User '.$login.', credentials are not equal'); |
|
| 162 | 162 | // TODO: remove this code as soon as the secret key has been fully established |
| 163 | 163 | // basically this does allow an external login with an applicationIndex match against the User-Password |
| 164 | 164 | // the way it had been used in the start |
| 165 | 165 | if ($user->getCredential() == $filter->filter($credential)) { |
| 166 | - $this->serviceManager->get('Core/Log')->debug('User ' . $login . ', credentials2 test'); |
|
| 166 | + $this->serviceManager->get('Core/Log')->debug('User '.$login.', credentials2 test'); |
|
| 167 | 167 | $loginSuccess = true; |
| 168 | 168 | } |
| 169 | 169 | } |
@@ -53,13 +53,13 @@ |
||
| 53 | 53 | if ($initialId) { |
| 54 | 54 | /* @var $serviceLocator \Zend\ServiceManager\AbstractPluginManager |
| 55 | 55 | * @var $repository \Organizations\Repository\Organization */ |
| 56 | - $repositories = $container->get('repositories'); |
|
| 56 | + $repositories = $container->get('repositories'); |
|
| 57 | 57 | $repository = $repositories->get('Organizations'); |
| 58 | - $organization = $repository->find($initialId); |
|
| 58 | + $organization = $repository->find($initialId); |
|
| 59 | 59 | $organizations[] = $organization; |
| 60 | 60 | } |
| 61 | 61 | |
| 62 | - $select = new OrganizationSelect(); |
|
| 62 | + $select = new OrganizationSelect(); |
|
| 63 | 63 | |
| 64 | 64 | $select->setSelectableOrganizations($organizations); |
| 65 | 65 | $select->setAttribute('data-ajax', '?ajax=jobs.admin.activeorganizations'); |
@@ -50,11 +50,11 @@ |
||
| 50 | 50 | $image = $org->getImage(); |
| 51 | 51 | $imageUrl = $image ? $image->getUri() : ''; |
| 52 | 52 | |
| 53 | - $options[] = [ 'id' => $org->getId(), |
|
| 54 | - 'text' => $name . '|' |
|
| 55 | - . $contact->getCity() . '|' |
|
| 56 | - . $contact->getStreet() . '|' |
|
| 57 | - . $contact->getHouseNumber() . '|' |
|
| 53 | + $options[] = ['id' => $org->getId(), |
|
| 54 | + 'text' => $name.'|' |
|
| 55 | + . $contact->getCity().'|' |
|
| 56 | + . $contact->getStreet().'|' |
|
| 57 | + . $contact->getHouseNumber().'|' |
|
| 58 | 58 | . $imageUrl |
| 59 | 59 | ]; |
| 60 | 60 | } |
@@ -78,7 +78,7 @@ discard block |
||
| 78 | 78 | |
| 79 | 79 | // ensures garbage removal |
| 80 | 80 | register_shutdown_function( |
| 81 | - function ($filename) { |
|
| 81 | + function($filename) { |
|
| 82 | 82 | @unlink($filename); |
| 83 | 83 | }, |
| 84 | 84 | $tmp |
@@ -92,10 +92,10 @@ discard block |
||
| 92 | 92 | |
| 93 | 93 | $return = ["file" => $tmp]; |
| 94 | 94 | |
| 95 | - foreach(['user', 'name', 'type'] as $key) { |
|
| 95 | + foreach (['user', 'name', 'type'] as $key) { |
|
| 96 | 96 | $v = $value->{"get$key"}(); |
| 97 | - if($v) { |
|
| 98 | - $return[$key]=$v; |
|
| 97 | + if ($v) { |
|
| 98 | + $return[$key] = $v; |
|
| 99 | 99 | } |
| 100 | 100 | } |
| 101 | 101 | |
@@ -122,7 +122,7 @@ discard block |
||
| 122 | 122 | |
| 123 | 123 | $entity = $this->getTargetEntity(); |
| 124 | 124 | |
| 125 | - foreach($value as $key=>$v) { |
|
| 125 | + foreach ($value as $key=>$v) { |
|
| 126 | 126 | $entity->{"set$key"}($v); |
| 127 | 127 | } |
| 128 | 128 | return $entity; |
@@ -42,7 +42,7 @@ |
||
| 42 | 42 | { |
| 43 | 43 | /* @var \Doctrine\ODM\MongoDB\Query\Builder $qb */ |
| 44 | 44 | $qb = $this->repository->createQueryBuilder(); |
| 45 | - $qb->field('title')->equals(new \MongoRegex('/' . addslashes($q) . '/i')); |
|
| 45 | + $qb->field('title')->equals(new \MongoRegex('/'.addslashes($q).'/i')); |
|
| 46 | 46 | $cursor = $qb->getQuery()->execute(); |
| 47 | 47 | |
| 48 | 48 | $adapter = new DoctrineMongoCursor($cursor); |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | */ |
| 23 | 23 | class JobSelect extends Select implements HeadscriptProviderInterface |
| 24 | 24 | { |
| 25 | - private $scripts = [ 'Applications/js/form.job-select.js' ]; |
|
| 25 | + private $scripts = ['Applications/js/form.job-select.js']; |
|
| 26 | 26 | |
| 27 | 27 | /** |
| 28 | 28 | * Sets the array of script names. |
@@ -17,7 +17,7 @@ |
||
| 17 | 17 | |
| 18 | 18 | use EmptySummaryAwareTrait, HydratorStrategyAwareTrait, ViewPartialProviderTrait; |
| 19 | 19 | |
| 20 | - private $defaultEmptySummaryNotice = /*@translate*/ 'Click here to enter your employment expectation'; |
|
| 20 | + private $defaultEmptySummaryNotice = /*@translate*/ 'Click here to enter your employment expectation'; |
|
| 21 | 21 | private $defaultPartial = 'cv/form/preferred-job-fieldset'; |
| 22 | 22 | |
| 23 | 23 | /** |
@@ -70,7 +70,7 @@ discard block |
||
| 70 | 70 | public function findByAssignedPermissionsResourceId($resourceId) |
| 71 | 71 | { |
| 72 | 72 | $criteria = $this->getIsDeletedCriteria( |
| 73 | - ['permissions.assigned.' . $resourceId => [ '$exists' => true]] |
|
| 73 | + ['permissions.assigned.'.$resourceId => ['$exists' => true]] |
|
| 74 | 74 | ); |
| 75 | 75 | |
| 76 | 76 | return $this->findBy($criteria); |
@@ -136,7 +136,7 @@ discard block |
||
| 136 | 136 | $qb = $this->createQueryBuilder(); |
| 137 | 137 | $qb->distinct('organization') |
| 138 | 138 | ->hydrate(true) |
| 139 | - ->field('status.name')->notIn([ StatusInterface::EXPIRED, StatusInterface::INACTIVE ]); |
|
| 139 | + ->field('status.name')->notIn([StatusInterface::EXPIRED, StatusInterface::INACTIVE]); |
|
| 140 | 140 | |
| 141 | 141 | $q = $qb->getQuery(); |
| 142 | 142 | $r = $q->execute(); |
@@ -145,7 +145,7 @@ discard block |
||
| 145 | 145 | $qb = $this->dm->createQueryBuilder('Organizations\Entity\Organization'); |
| 146 | 146 | $qb->field('_id')->in($r); |
| 147 | 147 | if ($term) { |
| 148 | - $qb->field('_organizationName')->equals(new \MongoRegex('/' . addslashes($term) . '/i')); |
|
| 148 | + $qb->field('_organizationName')->equals(new \MongoRegex('/'.addslashes($term).'/i')); |
|
| 149 | 149 | } |
| 150 | 150 | |
| 151 | 151 | $q = $qb->getQuery(); |
@@ -202,7 +202,7 @@ discard block |
||
| 202 | 202 | */ |
| 203 | 203 | public function createQueryBuilder($isDeleted = false) |
| 204 | 204 | { |
| 205 | - $qb = parent::createQueryBuilder(); |
|
| 205 | + $qb = parent::createQueryBuilder(); |
|
| 206 | 206 | |
| 207 | 207 | if (null !== $isDeleted) { |
| 208 | 208 | $qb->addAnd( |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | * for multiple paths. |
| 23 | 23 | * example https://github.com/doctrine/DoctrineORMModule |
| 24 | 24 | */ |
| 25 | - 'paths' => [ __DIR__ . '/../src/Geo/Entity'], |
|
| 25 | + 'paths' => [__DIR__.'/../src/Geo/Entity'], |
|
| 26 | 26 | ], |
| 27 | 27 | ], |
| 28 | 28 | ], |