YetiForceCompany/YetiForceCRM

View on GitHub
modules/Accounts/models/Relation.php

Summary

Maintainability
A
0 mins
Test Coverage
F
0%

Call to method addJoin from undeclared class \App\QueryGenerator (Did you mean class \Tests\App\QueryGenerator)
Open

        $queryGenerator->addJoin(['INNER JOIN', 'vtiger_seproductsrel', 'vtiger_products.productid = vtiger_seproductsrel.productid']);
Severity: Critical
Found in modules/Accounts/models/Relation.php by phan

Call to method addNativeCondition from undeclared class \App\QueryGenerator (Did you mean class \Tests\App\QueryGenerator)
Open

        $queryGenerator->addNativeCondition(['vtiger_seproductsrel.crmid' => $this->get('parentRecord')->getId()]);
Severity: Critical
Found in modules/Accounts/models/Relation.php by phan

Each class must be in a namespace of at least one level (a top-level vendor name)
Open

class Accounts_Relation_Model extends Vtiger_Relation_Model

The class Accounts_Relation_Model is not named in CamelCase.
Open

class Accounts_Relation_Model extends Vtiger_Relation_Model
{
    /**
     * Get products.
     */
Severity: Minor
Found in modules/Accounts/models/Relation.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

Spaces must be used to indent lines; tabs are not allowed
Open

     */

Spaces must be used to indent lines; tabs are not allowed
Open

        $queryGenerator = $this->getQueryGenerator();

Line exceeds 120 characters; contains 135 characters
Open

        $queryGenerator->addJoin(['INNER JOIN', 'vtiger_seproductsrel', 'vtiger_products.productid = vtiger_seproductsrel.productid']);

Spaces must be used to indent lines; tabs are not allowed
Open

     * Get products.

Spaces must be used to indent lines; tabs are not allowed
Open

    }

Spaces must be used to indent lines; tabs are not allowed
Open

    public function getProducts()

Spaces must be used to indent lines; tabs are not allowed
Open

        $queryGenerator->addNativeCondition(['vtiger_seproductsrel.crmid' => $this->get('parentRecord')->getId()]);

Spaces must be used to indent lines; tabs are not allowed
Open

    {

Spaces must be used to indent lines; tabs are not allowed
Open

    /**

Spaces must be used to indent lines; tabs are not allowed
Open

        $queryGenerator->addJoin(['INNER JOIN', 'vtiger_seproductsrel', 'vtiger_products.productid = vtiger_seproductsrel.productid']);

Class name "Accounts_Relation_Model" is not in camel caps format
Open

class Accounts_Relation_Model extends Vtiger_Relation_Model

There are no issues that match your filters.

Category
Status