@@ -17,7 +17,7 @@ |
||
| 17 | 17 | */ |
| 18 | 18 | public function testCreateAccount() |
| 19 | 19 | { |
| 20 | - $accountName = 'Account_'.mt_rand(); |
|
| 20 | + $accountName = 'Account_' . mt_rand(); |
|
| 21 | 21 | |
| 22 | 22 | $login = $this->login(); |
| 23 | 23 | /** @var Accounts $login */ |
@@ -55,7 +55,7 @@ |
||
| 55 | 55 | $id = $request['id']; |
| 56 | 56 | $result = array_filter( |
| 57 | 57 | $result, |
| 58 | - function ($a) use ($id) { |
|
| 58 | + function($a) use ($id) { |
|
| 59 | 59 | return $a['id'] == $id; |
| 60 | 60 | } |
| 61 | 61 | ); |
@@ -51,7 +51,7 @@ discard block |
||
| 51 | 51 | $filters = $config->offsetGetByPath(self::FILTERS_PATH, array()); |
| 52 | 52 | |
| 53 | 53 | foreach ($enumValues as $id => $text) { |
| 54 | - $label = $id.'Count'; |
|
| 54 | + $label = $id . 'Count'; |
|
| 55 | 55 | $selects[] = sprintf($selectTemplate, $id, $label); |
| 56 | 56 | $grandTotals[$label] = ['expr' => sprintf($grandTotalTemplate, $id)]; |
| 57 | 57 | $columns[$label] = ['label' => $text, 'frontend_type' => 'integer']; |
@@ -65,10 +65,10 @@ discard block |
||
| 65 | 65 | } |
| 66 | 66 | } |
| 67 | 67 | |
| 68 | - $selects[] = 'COUNT(o.id) as '.self::TOTALOPS_LABEL; |
|
| 68 | + $selects[] = 'COUNT(o.id) as ' . self::TOTALOPS_LABEL; |
|
| 69 | 69 | $grandTotals[self::TOTALOPS_LABEL] = ['expr' => 'COUNT(o.id)']; |
| 70 | 70 | $columns[self::TOTALOPS_LABEL] = [ |
| 71 | - 'label' => 'oro.reportcrm.datagrid.columns.'.self::TOTALOPS_LABEL, |
|
| 71 | + 'label' => 'oro.reportcrm.datagrid.columns.' . self::TOTALOPS_LABEL, |
|
| 72 | 72 | 'frontend_type' => 'integer' |
| 73 | 73 | ]; |
| 74 | 74 | $sorters[self::TOTALOPS_LABEL] = ['data_name' => self::TOTALOPS_LABEL]; |
@@ -258,7 +258,7 @@ discard block |
||
| 258 | 258 | $isoCode = $data['Country']; |
| 259 | 259 | $country = array_filter( |
| 260 | 260 | $this->countries, |
| 261 | - function (Country $a) use ($isoCode) { |
|
| 261 | + function(Country $a) use ($isoCode) { |
|
| 262 | 262 | return $a->getIso2Code() == $isoCode; |
| 263 | 263 | } |
| 264 | 264 | ); |
@@ -272,7 +272,7 @@ discard block |
||
| 272 | 272 | $regions = $country->getRegions(); |
| 273 | 273 | |
| 274 | 274 | $region = $regions->filter( |
| 275 | - function (Region $a) use ($idRegion) { |
|
| 275 | + function(Region $a) use ($idRegion) { |
|
| 276 | 276 | return $a->getCode() == $idRegion; |
| 277 | 277 | } |
| 278 | 278 | ); |
@@ -13,7 +13,7 @@ |
||
| 13 | 13 | */ |
| 14 | 14 | public function testCreateContact() |
| 15 | 15 | { |
| 16 | - $contactName = 'Contact_'.mt_rand(); |
|
| 16 | + $contactName = 'Contact_' . mt_rand(); |
|
| 17 | 17 | |
| 18 | 18 | $login = $this->login(); |
| 19 | 19 | /** @var Contacts $login */ |
@@ -39,7 +39,7 @@ |
||
| 39 | 39 | */ |
| 40 | 40 | public function getDependencies() |
| 41 | 41 | { |
| 42 | - return ['Oro\Bundle\DemoDataBundle\Migrations\Data\Demo\ORM\LoadContactData',]; |
|
| 42 | + return ['Oro\Bundle\DemoDataBundle\Migrations\Data\Demo\ORM\LoadContactData', ]; |
|
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | /** |
@@ -37,8 +37,7 @@ |
||
| 37 | 37 | $qb = $this->_em->createQueryBuilder(); |
| 38 | 38 | |
| 39 | 39 | $entityName = $this->isPrecalculatedStatisticEnabled() ? |
| 40 | - 'OroTrackingBundle:UniqueTrackingVisit' : |
|
| 41 | - 'OroTrackingBundle:TrackingVisit'; |
|
| 40 | + 'OroTrackingBundle:UniqueTrackingVisit' : 'OroTrackingBundle:TrackingVisit'; |
|
| 42 | 41 | |
| 43 | 42 | $qb->select('COUNT(visit.id)') |
| 44 | 43 | ->from($entityName, 'visit') |
@@ -81,7 +81,7 @@ discard block |
||
| 81 | 81 | ->setParameter('to', $to); |
| 82 | 82 | } |
| 83 | 83 | |
| 84 | - return (int) $this->aclHelper->apply($queryBuilder)->getSingleScalarResult(); |
|
| 84 | + return (int)$this->aclHelper->apply($queryBuilder)->getSingleScalarResult(); |
|
| 85 | 85 | } catch (NoResultException $ex) { |
| 86 | 86 | return 0; |
| 87 | 87 | } |
@@ -128,7 +128,7 @@ discard block |
||
| 128 | 128 | ->setParameter('to', $to); |
| 129 | 129 | } |
| 130 | 130 | |
| 131 | - return (int) $this->aclHelper->apply($queryBuilder)->getSingleScalarResult(); |
|
| 131 | + return (int)$this->aclHelper->apply($queryBuilder)->getSingleScalarResult(); |
|
| 132 | 132 | } catch (NoResultException $ex) { |
| 133 | 133 | return 0; |
| 134 | 134 | } |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | ->getQuery() |
| 167 | 167 | ->getSingleResult(); |
| 168 | 168 | |
| 169 | - $count = (int) $result['cnt']; |
|
| 169 | + $count = (int)$result['cnt']; |
|
| 170 | 170 | $first = new \DateTimeImmutable($result['first']); |
| 171 | 171 | $last = new \DateTimeImmutable($result['last']); |
| 172 | 172 | $daysDiff = $last->diff($first)->d; |
@@ -66,7 +66,7 @@ |
||
| 66 | 66 | ); |
| 67 | 67 | $this->applyDateFiltering($visitsQb, 'visit.firstActionTime', $start, $end); |
| 68 | 68 | |
| 69 | - return (int) $this->aclHelper->apply($visitsQb)->getSingleScalarResult(); |
|
| 69 | + return (int)$this->aclHelper->apply($visitsQb)->getSingleScalarResult(); |
|
| 70 | 70 | } |
| 71 | 71 | |
| 72 | 72 | /** |