YetiForceCompany/YetiForceCRM

View on GitHub
app/Fields/MultiDomain.php

Summary

Maintainability
A
0 mins
Test Coverage
F
0%

Missing class import via use statement (line '32', column '25').
Open

        $queryGenerator = new \App\QueryGenerator($moduleName);
Severity: Minor
Found in app/Fields/MultiDomain.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

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

            $queryGenerator->setFields(['id']);
Severity: Critical
Found in app/Fields/MultiDomain.php by phan

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

            $queryGenerator->addCondition($fieldName, $domain, 'a');
Severity: Critical
Found in app/Fields/MultiDomain.php by phan

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

        $queryGenerator = new \App\QueryGenerator($moduleName);
Severity: Critical
Found in app/Fields/MultiDomain.php by phan

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

            $ids = $queryGenerator->createQuery()->column();
Severity: Critical
Found in app/Fields/MultiDomain.php by phan

Reference to instance property permissions from undeclared class \App\QueryGenerator
Open

        $queryGenerator->permissions = false;
Severity: Minor
Found in app/Fields/MultiDomain.php by phan

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

        if ($queryGenerator->getModuleField($fieldName)) {
Severity: Critical
Found in app/Fields/MultiDomain.php by phan

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

        $queryGenerator = new \App\QueryGenerator($moduleName);
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

            $queryGenerator->addCondition($fieldName, $domain, 'a');
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     * Find crm ids with specified domain.
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     *
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     * @param string $fieldName
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     * @return int[]
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     */
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

        }
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

        if ($queryGenerator->getModuleField($fieldName)) {
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

    public static function findIdByDomain(string $moduleName, string $fieldName, string $domain)
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

            $ids = $queryGenerator->createQuery()->column();
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

    }
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

    /**
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     * @param string $moduleName
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     *
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

    {
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

     * @param string $domain
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

        $ids = [];
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

        $queryGenerator->permissions = false;
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

            $queryGenerator->setFields(['id']);
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

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

        return $ids;
Severity: Minor
Found in app/Fields/MultiDomain.php by phpcodesniffer

There are no issues that match your filters.

Category
Status