mambax7/adslight

View on GitHub
class/Form/TypeForm.php

Summary

Maintainability
A
0 mins
Test Coverage

Missing class import via use statement (line '70', column '31').
Open

        $this->addElement(new \XoopsFormHidden('op', 'save'));
Severity: Minor
Found in class/Form/TypeForm.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

Missing class import via use statement (line '61', column '23').
Open

        $hidden = new \XoopsFormHidden('id_type', $this->targetObject->getVar('id_type'));
Severity: Minor
Found in class/Form/TypeForm.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

Missing class import via use statement (line '66', column '31').
Open

        $this->addElement(new \XoopsFormLabel(\AM_ADSLIGHT_TYPE_ID_TYPE, $this->targetObject->getVar('id_type'), 'id_type'));
Severity: Minor
Found in class/Form/TypeForm.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

Missing class import via use statement (line '71', column '31').
Open

        $this->addElement(new \XoopsFormButton('', 'submit', \_SUBMIT, 'submit'));
Severity: Minor
Found in class/Form/TypeForm.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

Missing class import via use statement (line '68', column '31').
Open

        $this->addElement(new \XoopsFormText(\AM_ADSLIGHT_TYPE_NOM_TYPE, 'nom_type', 50, 255, $this->targetObject->getVar('nom_type')), false);
Severity: Minor
Found in class/Form/TypeForm.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

A file should declare new symbols (classes, functions, constants, etc.) and cause no other side effects, or it should execute logic with side effects, but should not do both. The first symbol is defined on line 40 and the first side effect is on line 29.
Open

<?php declare(strict_types=1);
Severity: Minor
Found in class/Form/TypeForm.php by phpcodesniffer

There must be one USE keyword per declaration
Open

use XoopsModules\Adslight\{
Severity: Minor
Found in class/Form/TypeForm.php by phpcodesniffer

Line exceeds 120 characters; contains 143 characters
Open

        $this->addElement(new \XoopsFormText(\AM_ADSLIGHT_TYPE_NOM_TYPE, 'nom_type', 50, 255, $this->targetObject->getVar('nom_type')), false);
Severity: Minor
Found in class/Form/TypeForm.php by phpcodesniffer

Line exceeds 120 characters; contains 125 characters
Open

        $this->addElement(new \XoopsFormLabel(\AM_ADSLIGHT_TYPE_ID_TYPE, $this->targetObject->getVar('id_type'), 'id_type'));
Severity: Minor
Found in class/Form/TypeForm.php by phpcodesniffer

There are no issues that match your filters.

Category
Status