Complex expressions

Here is the list of the most complex expressions used in the code. A complex expression is an expression that requires more than 20 tokens to be build.

Literal arrays are omitted.

File Count Expression
/app/SelectManagers/Product.php:8321$where = ['type' => 'and''value' => [['type' => 'equals''attribute' => 'attributeId''value' => $row['attribute']], ['type' => 'isNotNull''attribute' => 'value'], ['type' => 'notEquals''attribute' => 'value''value' => ''], ['type' => 'notEquals''attribute' => 'value''value' => '[]']]]
/app/SelectManagers/Product.php:7921$where = ['type' => 'and''value' => [['type' => 'equals''attribute' => 'attributeId''value' => $row['attribute']], ['type' => 'or''value' => [['type' => 'isNull''attribute' => 'value'], ['type' => 'equals''attribute' => 'value''value' => ''], ['type' => 'equals''attribute' => 'value''value' => '[]']]],  ]]
/app/Services/ChannelsDashlet.php:581$result['list'][] = ['id' => $row['id'], 'name' => $row['name'], 'products' => (int) $row['totalActive'] + (int) $row['totalInactive'], 'active' => (int) $row['totalActive'], 'notActive' => (int) $row['totalInactive']]
/app/SelectManagers/Product.php:8701$where['value'][] = ['type' => 'and''value' => [['type' => 'equals''attribute' => 'attributeId''value' => $row['attribute']], ['type' => $row['type'], 'attribute' => $v'value' => $row['value']]]]
/app/Services/RevisionField.php:921$result['list'][] = ["id" => $note->get('id'), "date" => $note->get('createdAt'), "userId" => $note->get('createdById'), "userName" => $note->get('createdBy')->get('name'), "was" => $was"became" => $became"field" => $fieldName]
/app/Services/GeneralStatisticsDashlet.php:411$result['list'] = [['id' => 'product''name' => 'product''amount' => (int) $this->getRepository('Product')->select(['id'])->where(['type' => $this->getProductTypes( )])->count( )], ['id' => 'category''name' => 'category''amount' => (int) $this->getRepository('Category')->select(['id'])->count( )], ['id' => 'productFamily''name' => 'productFamily''amount' => (int) $this->getRepository('ProductFamily')->select(['id'])->count( )], ['id' => 'attribute''name' => 'attribute''amount' => (int) $this->getRepository('Attribute')->select(['id'])->count( )], ['id' => 'productWithoutAssociatedProduct''name' => 'productWithoutAssociatedProduct''amount' => $this->getAmountProductWithoutAssociatedProduct( )], ['id' => 'productWithoutCategory''name' => 'productWithoutCategory''amount' => $this->getAmountProductWithoutCategory( )]]
/app/Repositories/ProductAttributeValue.php:1712if(!$entity->isNew( ) && !empty($entity->get('attribute')->get('isMultilang')) && ($entity->isAttributeChanged('scope') || $entity->isAttributeChanged('channelsIds'))) { /**/ }
/app/Repositories/Attribute.php:3011if(!empty($entity->get('locale')) && in_array($entity->get('type'), ['enum''multiEnum']) && count($entity->get('typeValue')) != count($entity->get('parent')->get('typeValue'))) { /**/ }
/app/Repositories/ProductFamilyAttribute.php:2411if(($item['scope'] == $scope && $item['channels'] == $channels) || (!empty($entity->get('locale')) && $entity->get('locale') == $item['locale'])) { /**/ }
/app/Repositories/ProductFamilyAttribute.php:3972if(!$entity->isNew( ) && !empty($entity->get('attribute')->get('isMultilang')) && ($entity->isAttributeChanged('scope') || $entity->isAttributeChanged('channelsIds'))) { /**/ }
/app/Listeners/ProductAttributeValueEntity.php:2311if(self::$beforeSaveData['value'] != $entity->get('value') || ($entity->isAttributeChanged('data') && self::$beforeSaveData['data']->unit != $entity->get('data')->unit)) { /**/ }
/app/Services/Product.php:441if(empty($data->ids) || empty($data->foreignIds) || empty($data->associationId) || !is_array($data->ids) || !is_array($data->foreignIds) || empty($association $this->getEntityManager( )->getEntity("Association"$data->associationId))) { /**/ }
/app/Services/Product.php:1361if($backward->get('mainProductId') == $associatedProduct->get('relatedProductId') && $backward->get('relatedProductId') == $associatedProduct->get('mainProductId') && $backward->get('associationId') == $backwardAssociationId) { /**/ }