DerDu/SPHERE-Framework

View on GitHub

Showing 5,014 of 7,620 total issues

Function updatePrepareExamGrades has a Cognitive Complexity of 76 (exceeds 5 allowed). Consider refactoring.
Open

    public function updatePrepareExamGrades(
        IFormInterface $form,
        TblPrepareCertificate $tblPrepare,
        TblSubject $tblCurrentSubject,
        TblSubject $tblNextSubject = null,
Severity: Minor
Found in Application/Education/Certificate/Prepare/Service.php - About 1 day 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

Method getSecondLetterContent has 301 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    private function getSecondLetterContent($AccountId)
    {

        $Slice = new Slice();
        if ($this->FieldValue['IsParent']) {

    Method frontendEditProposalTestGrade has 301 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        public function frontendEditProposalTestGrade($DivisionId = null, $TaskId = null, $GradeTypeId = null, $Grade = null)
        {
            $stage = new Stage('Kopfnotenvorschlag des Klassenlehrers', 'Zensuren eintragen');
    
            if (!($tblDivision = Division::useService()->getDivisionById($DivisionId))) {
    Severity: Major
    Found in Application/Education/Graduation/Evaluation/Frontend.php - About 1 day to fix

      File Frontend.php has 668 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      <?php
      /**
       * Created by PhpStorm.
       * User: Kauschke
       * Date: 28.09.2016
      Severity: Major
      Found in Application/Education/Certificate/GradeInformation/Frontend.php - About 1 day to fix

        Method createClubMembersFromFile has 299 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function createClubMembersFromFile(
                IFormInterface $Form = null,
                UploadedFile $File = null
            ) {
        
        
        Severity: Major
        Found in Application/Transfer/Import/Radebeul/Service.php - About 1 day to fix

          File Creator.php has 664 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          <?php
          
          namespace SPHERE\Application\Api\Education\Certificate\Generator;
          
          use MOC\V\Component\Document\Component\Bridge\Repository\DomPdf;
          Severity: Major
          Found in Application/Api/Education/Certificate/Generator/Creator.php - About 1 day to fix

            Function frontendLayoutPersonNew has a Cognitive Complexity of 75 (exceeds 5 allowed). Consider refactoring.
            Open

                public function frontendLayoutPersonNew(TblPerson $tblPerson)
                {
            
                    $mailList = array();
                    if (($tblMailList = Mail::useService()->getMailAllByPerson($tblPerson))){
            Severity: Minor
            Found in Application/Contact/Mail/Frontend.php - About 1 day 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 frontendHeadmasterTest has a Cognitive Complexity of 75 (exceeds 5 allowed). Consider refactoring.
            Open

                public function frontendHeadmasterTest($IsAllYears = false, $YearId = null)
                {
            
                    $Stage = new Stage('Leistungsüberprüfung', 'Auswahl');
                    $Stage->setMessage(
            Severity: Minor
            Found in Application/Education/Graduation/Evaluation/Frontend.php - About 1 day 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 searchData has a Cognitive Complexity of 75 (exceeds 5 allowed). Consider refactoring.
            Open

                public function searchData($Search, $Timeout = 60)
                {
            
                    $ProbeList = $this->getProbeList();
            
            
            Severity: Minor
            Found in System/Database/Filter/Link/AbstractNode.php - About 1 day 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 frontendStudentCardSubjects has a Cognitive Complexity of 75 (exceeds 5 allowed). Consider refactoring.
            Open

                public function frontendStudentCardSubjects($Id = null, $Data = null)
                {
            
                    $Stage = new Stage('Schülerkartei Einstellungen', 'Fächer zuweisen');
                    $Stage->addButton(new Standard(
            Severity: Minor
            Found in Application/Document/Standard/StudentCard/Frontend.php - About 1 day 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

            File EzshKurshalbjahreszeugnis.php has 659 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            <?php
            /**
             * Created by PhpStorm.
             * User: Kauschke
             * Date: 14.11.2018

              Method frontendPersonAddressEdit has 295 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function frontendPersonAddressEdit($Id = null, $PersonId = null, $Route = '/Reporting/SerialLetter/Address', $Check = null)
                  {
              
                      $Stage = new Stage('Adresse(n)', 'Auswählen');
                      $tblSerialLetter = ( $Id === null ? false : SerialLetter::useService()->getSerialLetterById($Id) );
              Severity: Major
              Found in Application/Reporting/SerialLetter/Frontend.php - About 1 day to fix

                Method createPersonFromFile has 294 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    public function createPersonFromFile(
                        IFormInterface $Form = null,
                        UploadedFile $File = null
                    ) {
                
                
                Severity: Major
                Found in Application/Transfer/Import/Dresden/Service.php - About 1 day to fix

                  Method createInterestedPersonsFromFile has 294 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      public function createInterestedPersonsFromFile(
                          IFormInterface $Form = null,
                          UploadedFile $File = null
                      ) {
                  
                  
                  Severity: Major
                  Found in Application/Transfer/Import/Naundorf/Service.php - About 1 day to fix

                    Function frontendSelectTemplate has a Cognitive Complexity of 74 (exceeds 5 allowed). Consider refactoring.
                    Open

                        public function frontendSelectTemplate($PrepareId = null, $DivisionId = null, $Data = null)
                        {
                    
                            $Stage = new Stage('Zeugnis generieren', 'Zeugnisvorlagen auswählen');
                    
                    
                    Severity: Minor
                    Found in Application/Education/Certificate/Generate/Frontend.php - About 1 day 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

                    File Service.php has 656 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    <?php
                    namespace SPHERE\Application\Education\Lesson\Subject;
                    
                    use SPHERE\Application\Education\Lesson\Division\Division;
                    use SPHERE\Application\Education\Lesson\Division\Service\Entity\TblDivision;
                    Severity: Major
                    Found in Application/Education/Lesson/Subject/Service.php - About 1 day to fix

                      Method createInterestedPersonsFromFile has 292 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          public function createInterestedPersonsFromFile(
                              IFormInterface $Form = null,
                              UploadedFile $File = null
                          ) {
                      
                      
                      Severity: Major
                      Found in Application/Transfer/Import/Zwickau/Service.php - About 1 day to fix

                        Method createSerialLetterExcel has 291 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function createSerialLetterExcel(TblSerialLetter $tblSerialLetter)
                            {
                        
                                $tblPersonList = $this->getPersonAllBySerialLetter($tblSerialLetter);
                                $ExportData = array();
                        Severity: Major
                        Found in Application/Reporting/SerialLetter/Service.php - About 1 day to fix

                          File ApiBasket.php has 651 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          <?php
                          
                          namespace SPHERE\Application\Api\Billing\Bookkeeping;
                          
                          use SPHERE\Application\Api\ApiTrait;
                          Severity: Major
                          Found in Application/Api/Billing/Bookkeeping/ApiBasket.php - About 1 day to fix

                            Method frontendStudentGradebook has 290 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                public function frontendStudentGradebook($YearId = null, $ParentAccount = null)
                                {
                            
                                    $Stage = new Stage('Notenübersicht', 'Schüler/Eltern');
                                    $Stage->setMessage(
                            Severity: Major
                            Found in Application/Education/Graduation/Gradebook/Frontend.php - About 1 day to fix
                              Severity
                              Category
                              Status
                              Source
                              Language