Showing 5,014 of 7,620 total issues
Function getActiveBasketVerificationByDebtorSelection
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function getActiveBasketVerificationByDebtorSelection(TblDebtorSelection $tblDebtorSelection)
{
if(($tblBasketVerificationList = $this->getBasketVerificationAllByDebtorSelection($tblDebtorSelection))){
$BasketVerificationList = array();
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method updateBasket
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
TblBasket $tblBasket,
$Name,
$Description,
$TargetTime,
$BillTime,
Method changeBasket
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public function changeBasket(TblBasket $tblBasket, $Name, $Description, $TargetTime, $BillTime, $CreditorId = '')
Function getSepaRemark
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function getSepaRemark($ignoreDefault = false)
{
if($ignoreDefault){
return $this->SepaRemark;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function getDocumentPanel
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function getDocumentPanel(TblItem $tblItem, $Data, $Location, $Date)
{
$global = $this->getGlobal();
$tblDocumentList = Document::useService()->getDocumentAllByItem($tblItem);
if (!($tblDocument = Document::useService()->getDocumentById($Data['Document']))) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function runConvert
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function runConvert($Row)
{
$ColumnMatch = array(
// Muster in Spalte ?? gefunden
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Avoid deeply nested control flow statements. Open
if(($tblItemCalculation = Item::useService()->getItemCalculationNowByItemVariant($tblItemVariant))){
$ItemPriceString = $tblItemCalculation->getPriceString();
}
Method addPersonsToGroup
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
IFormInterface $Form,
TblGroup $tblGroup,
$DataAddPerson = null,
$DataRemovePerson = null,
TblGroup $tblFilterGroup = null,
Method addStudentSubject
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
TblStudent $tblStudent,
TblStudentSubjectType $tblStudentSubjectType,
TblStudentSubjectRanking $tblStudentSubjectRanking,
TblSubject $tblSubject,
TblLevel $tblLevelFrom = null,
Method updateAccount
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
TblAccount $tblAccount,
$Description,
$Number,
$IsActive,
TblAccountKey $tblAccountKey,
Avoid deeply nested control flow statements. Open
if($IsDebtorNumberNeed && !($tblDebtorNumber = Debtor::useService()->getDebtorNumberByPerson($tblPersonDebtor))){
$Debtor .= ' '.new DangerText(new ToolTip(new Info(),
'Keine Debitoren-Nr. hinterlegt'));
}
Function frontendDestroyGroup
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function frontendDestroyGroup($Id, $Confirm = false)
{
$Stage = new Stage('Gruppe', 'Löschen');
$Stage->addButton(new Standard('Zurück', '/People/Group', new ChevronLeft()));
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function directRoute
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
public function directRoute(IFormInterface &$Form, $GroupId = null, $Direction = '')
{
/**
* Skip to Frontend
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method createKey
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
public function createKey($ValidFrom, $Value, $ValidTo, $Description, $Code, TblAccountKeyType $tblAccountKeyType)
Method frontendGroupPersonAdd
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
$Id = null,
$DataAddPerson = null,
$DataRemovePerson = null,
$Filter = null,
$FilterGroupId = null,
Method updateStudentMedicalRecord
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
TblStudentMedicalRecord $tblStudentMedicalRecord,
$Disease,
$Medication,
$AttendingDoctor,
$InsuranceState,
Avoid deeply nested control flow statements. Open
if (($tblLevel = $tblDivision->getTblLevel())
&& !$tblLevel->getIsChecked()
) {
return $tblDivision;
}
Method addStudentSubject
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
TblStudent $tblStudent,
TblStudentSubjectType $tblStudentSubjectType,
TblStudentSubjectRanking $tblStudentSubjectRanking,
TblSubject $tblSubject,
TblLevel $tblLevelFrom = null,
Avoid deeply nested control flow statements. Open
if ($tblToPerson->getTblType()->getName() == "Sorgeberechtigt"
&& ($tblPersonFrom = $tblToPerson->getServiceTblPersonFrom())
&& ($tblPersonTo = $tblToPerson->getServiceTblPersonTo())
&& $tblPersonFrom->getId() == $tblPerson->getId()
) {
Avoid deeply nested control flow statements. Open
if (isset( $Meta['SubjectLevelTill'] ) && isset( $Meta['SubjectLevelTill'][$Category][$Ranking] )) {
if ($Meta['SubjectLevelTill'][$Category][$Ranking]) {
$tblLevelTill = Division::useService()->getLevelById($Meta['SubjectLevelTill'][$Category][$Ranking]);
}
}