modules/Accounts/summary_blocks/CalculationsAccepted.php
Missing class import via use statement (line '18', column '21'). Open
Open
return (int) (new \App\Db\Query())->from('u_#__scalculations')
- Read upRead up
- Exclude checks
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 undeclared method \App\Db\Query::from
Open
Open
return (int) (new \App\Db\Query())->from('u_#__scalculations')
- Exclude checks
Each class must be in a namespace of at least one level (a top-level vendor name) Open
Open
class CalculationsAccepted
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
public $reference = 'SCalculations';
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
* @return int
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
public $sequence = 1;
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
* Process function.
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
{
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
return (int) (new \App\Db\Query())->from('u_#__scalculations')
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
public $name = 'Calculations accepted';
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
*
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
/**
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
* @param Vtiger_Record_Model $recordModel
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
}
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
*
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
*/
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
->where(['deleted' => 0, 'u_#__scalculations.accountid' => $recordModel->getId(), 'u_#__scalculations.scalculations_status' => 'PLL_ACCEPTED'])
- Exclude checks
Line exceeds 120 characters; contains 155 characters Open
Open
->where(['deleted' => 0, 'u_#__scalculations.accountid' => $recordModel->getId(), 'u_#__scalculations.scalculations_status' => 'PLL_ACCEPTED'])
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
->innerJoin('vtiger_crmentity', 'u_#__scalculations.scalculationsid = vtiger_crmentity.crmid')
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
public function process(Vtiger_Record_Model $recordModel)
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
->count(1);
- Exclude checks