DerDu/SPHERE-Framework

View on GitHub

Showing 5,014 of 7,620 total issues

File E03.php has 298 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php
/**
 * Created by PhpStorm.
 * User: lehmann
 * Date: 27.06.2017
Severity: Minor
Found in Application/Api/Document/Standard/Repository/KamenzReportGym/E03.php - About 3 hrs to fix

    File MassReplaceTransfer.php has 297 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    <?php
    
    namespace SPHERE\Application\Api\People\Meta\Transfer;
    
    use SPHERE\Application\Api\MassReplace\ApiMassReplace;
    Severity: Minor
    Found in Application/Api/People/Meta/Transfer/MassReplaceTransfer.php - About 3 hrs to fix

      File E02.php has 297 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      <?php
      /**
       * Created by PhpStorm.
       * User: lehmann
       * Date: 27.06.2017
      Severity: Minor
      Found in Application/Api/Document/Standard/Repository/KamenzReportGym/E02.php - About 3 hrs to fix

        Method tableUsedSubject has 78 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public static function tableUsedSubject($DivisionId = null)
            {
        
                // get Content
                $tblDivision = DivisionAPP::useService()->getDivisionById($DivisionId);
        Severity: Major
        Found in Application/Api/Education/Division/SubjectSelect.php - About 3 hrs to fix

          Method getStudentTransferStudent has 78 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              private function getStudentTransferStudent()
              {
          
                  if ($this->FieldValue['Gender'] == 'Männlich') {
                      $GenderString = 'des Schülers';

            Method frontendClubMemberList has 78 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                public function frontendClubMemberList()
                {
            
                    $Stage = new Stage('ESZC Auswertung', 'Liste der Vereinsmitglieder');
                    $tblPersonList = array();
            Severity: Major
            Found in Application/Reporting/Custom/Chemnitz/Person/Frontend.php - About 3 hrs to fix

              Method frontendAddressRemove has 78 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function frontendAddressRemove($Id = null, $Confirm = false)
                  {
              
                      $Stage = new Stage('Adresslisten für Serienbriefe', 'Löschen');
                      if ($Id) {
              Severity: Major
              Found in Application/Reporting/SerialLetter/Frontend.php - About 3 hrs to fix

                Method frontendLectureshipEdit has 78 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function frontendLectureshipEdit($Id = null, $Data = null, $Visible = false)
                    {
                        $Stage = new Stage('Lehrauftrag', 'Bearbeiten');
                        $tblUntisImportLectureship = ( $Id !== null ? Import::useService()->getUntisImportLectureshipById($Id) : false );
                        if (!$tblUntisImportLectureship) {
                Severity: Major
                Found in Application/Transfer/Untis/Import/Lectureship.php - About 3 hrs to fix

                  Method formRelationshipToCompany has 78 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      public function formRelationshipToCompany($PersonId, $ToCompanyId = null, $setPost = false, $Search = '', IMessageInterface $message = null)
                      {
                          if (!($tblPerson = Person::useService()->getPersonById($PersonId))) {
                              return false;
                          }
                  Severity: Major
                  Found in Application/People/Relationship/Frontend.php - About 3 hrs to fix

                    Function __construct has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function __construct($Name, $Path, IIconInterface $Icon = null, $Data = array(), $ToolTip = false, $Anchor = null)
                        {
                    
                            if( !empty( $Anchor ) ) {
                                $this->setName($Name.' '.new Link() );
                    Severity: Minor
                    Found in Common/Frontend/Link/Repository/AbstractLink.php - About 3 hrs to fix

                    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 updateSettingList has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function updateSettingList(IFormInterface $form, $Data, $isSystem)
                        {
                            if ($Data == null) {
                                return $form;
                            }
                    Severity: Minor
                    Found in Application/Setting/Consumer/Service.php - About 3 hrs to fix

                    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 createPreset has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function createPreset($PresetName, $ViewType = TblWorkSpace::VIEW_TYPE_ALL)
                        {
                    
                            $tblWorkSpaceList = Individual::useService()->getWorkSpaceAll($ViewType);
                            if ($tblWorkSpaceList && $PresetName) {
                    Severity: Minor
                    Found in Application/Api/Reporting/Individual/ApiIndividual.php - About 3 hrs to fix

                    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 getBankAccountRadioBoxList has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public static function getBankAccountRadioBoxList($PersonDebtorList)
                        {
                    
                            $PostBankAccountId = false;
                            $RadioBoxListBankAccount['-1'] = new RadioBox('DebtorSelection[BankAccount]'
                    Severity: Minor
                    Found in Application/Api/Billing/Accounting/ApiDebtorSelection.php - About 3 hrs to fix

                    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 previewPdf has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function previewPdf($PrepareId = null, $PersonId = null, $Name = 'Zeugnis Muster', $Redirect = true)
                        {
                    
                            if ($Redirect) {
                                return self::displayWaitingPage('/Api/Education/Certificate/Generator/Preview', array(
                    Severity: Minor
                    Found in Application/Api/Education/Certificate/Generator/Creator.php - About 3 hrs to fix

                    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 getDivisionDisplayStringByPerson has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        private function getDivisionDisplayStringByPerson(TblPerson $tblPerson, TblDivision $tblDivision)
                        {
                    
                            $result = '';
                            $YearString = $tblDivision->getServiceTblYear()->getYear();
                    Severity: Minor
                    Found in Application/Reporting/Custom/Chemnitz/Person/Service.php - About 3 hrs to fix

                    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 getPhoneList has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        private function getPhoneList(TblPerson $tblPerson, $IsExcel = false)
                        {
                    
                            $tblToPersonList = Phone::useService()->getPhoneAllByPerson($tblPerson);
                    
                    
                    Severity: Minor
                    Found in Application/Reporting/Standard/Person/Service.php - About 3 hrs to fix

                    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 frontendAppointmentGradeUpload has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function frontendAppointmentGradeUpload(
                            UploadedFile $File = null,
                            $Period = null,
                            $TaskId = null
                        ) {
                    Severity: Minor
                    Found in Application/Transfer/Indiware/Export/AppointmentGrade/Frontend.php - About 3 hrs to fix

                    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 formDocument has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function formDocument($DocumentId = null, $setPost = false)
                        {
                            if ($DocumentId && ($tblDocument = Document::useService()->getDocumentById($DocumentId))) {
                                // beim Checken der Inputfeldern darf der Post nicht gesetzt werden
                                if ($setPost) {
                    Severity: Minor
                    Found in Application/Billing/Inventory/Document/Frontend.php - About 3 hrs to fix

                    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 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function runConvert($Row)
                        {
                    
                            $Result = array();
                            foreach ($Row as $Part) {
                    Severity: Minor
                    Found in Application/Billing/Inventory/Import/ImportGateway.php - About 3 hrs to fix

                    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 getMainDivisionByPersonAndYear has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function getMainDivisionByPersonAndYear(TblPerson $tblPerson, TblYear $tblYear)
                        {
                    
                            $tblDivisionStudentList = Division::useService()->getDivisionStudentAllByPerson($tblPerson);
                            if ($tblDivisionStudentList) {
                    Severity: Minor
                    Found in Application/People/Meta/Student/Service.php - About 3 hrs to fix

                    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

                    Severity
                    Category
                    Status
                    Source
                    Language