DerDu/SPHERE-Framework

View on GitHub

Showing 5,014 of 7,620 total issues

Function loadMinimumGradeCountReporting has a Cognitive Complexity of 113 (exceeds 5 allowed). Consider refactoring.
Open

    public function loadMinimumGradeCountReporting($Data = null, $IsDivisionTeacher = null, $PersonId = null)
    {
        ini_set('memory_limit', '2G');

        $IsDivisionTeacher = $IsDivisionTeacher === 'true';

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

    public function frontendPrintClassList($DivisionId = null)
    {

        $Stage = new Stage('ESZC Auswertung', 'Klassenliste zum Ausdrucken');
        if (null !== $DivisionId) {
Severity: Minor
Found in Application/Reporting/Custom/Chemnitz/Person/Frontend.php - About 2 days 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 buildPages has 453 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function buildPages(TblPerson $tblPerson = null)
    {

        $personId = $tblPerson ? $tblPerson->getId() : 0;

Severity: Major
Found in Application/Api/Education/Certificate/Generator/Repository/BeMi.php - About 2 days to fix

    Function frontendSelectPrepare has a Cognitive Complexity of 112 (exceeds 5 allowed). Consider refactoring.
    Open

        public function frontendSelectPrepare($IsAllYears = false, $YearId = null)
        {
    
            $Stage = new Stage('Zeugnisse freigeben', 'Übersicht');
    
    
    Severity: Minor
    Found in Application/Education/Certificate/Approve/Frontend.php - About 2 days 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 AccidentReport.php has 908 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    <?php
    
    namespace SPHERE\Application\Api\Document\Standard\Repository\AccidentReport;
    
    use SPHERE\Application\Api\Document\AbstractDocument;

      Function getNavigation has a Cognitive Complexity of 110 (exceeds 5 allowed). Consider refactoring.
      Open

          public function getNavigation($ViewType = TblWorkSpace::VIEW_TYPE_ALL)
          {
      
              // remove every entry that is already chosen
              $WorkSpaceList = array();
      Severity: Minor
      Found in Application/Api/Reporting/Individual/ApiIndividual.php - About 2 days 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 updateDivisionTasks has a Cognitive Complexity of 110 (exceeds 5 allowed). Consider refactoring.
      Open

          public function updateDivisionTasks(IFormInterface $Stage = null, $Id, $Data = null)
          {
      
              /**
               * Skip to Frontend
      Severity: Minor
      Found in Application/Education/Graduation/Evaluation/Service.php - About 2 days 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 addSubjectWithGroups has a Cognitive Complexity of 110 (exceeds 5 allowed). Consider refactoring.
      Open

          public function addSubjectWithGroups(
              TblDivision $tblDivision,
              TblDivision $tblDivisionCopy
          ) {
      
      
      Severity: Minor
      Found in Application/Education/Lesson/Division/Service.php - About 2 days 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 ModTable has 442 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          $.fn.ModTable = function(options)
          {
      
              var Table;
      
      
      Severity: Major
      Found in Common/Script/ModTable.js - About 2 days to fix

        Function createClubsFromFile has a Cognitive Complexity of 109 (exceeds 5 allowed). Consider refactoring.
        Open

            public function createClubsFromFile(IFormInterface $Form = null, UploadedFile $File = null)
            {
        
                /**
                 * Skip to Frontend
        Severity: Minor
        Found in Application/Transfer/Import/Naundorf/Service.php - About 2 days 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 frontendTestTeacher has a Cognitive Complexity of 109 (exceeds 5 allowed). Consider refactoring.
        Open

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

            public function frontendAbsenceMonth($DivisionId = null, $Month = null, $Year = null, $BasicRoute = '')
            {
        
                $Stage = new Stage('Fehlzeiten', 'Monatsübersicht');
                $tblDivision = Division::useService()->getDivisionById($DivisionId);
        Severity: Minor
        Found in Application/Education/ClassRegister/Absence/Frontend.php - About 2 days 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 CmsStyle.php has 897 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        <?php
        
        namespace SPHERE\Application\Api\Education\Certificate\Generator\Repository\CMS;
        
        use SPHERE\Application\Api\Education\Certificate\Generator\Certificate;

          Function createClubMembersFromFile has a Cognitive Complexity of 108 (exceeds 5 allowed). Consider refactoring.
          Open

              public function createClubMembersFromFile(
                  IFormInterface $Form = null,
                  UploadedFile $File = null
              ) {
          
          
          Severity: Minor
          Found in Application/Transfer/Import/Hormersdorf/Service.php - About 2 days 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 setSchoolTypeLastYear has a Cognitive Complexity of 108 (exceeds 5 allowed). Consider refactoring.
          Open

              private static function setSchoolTypeLastYear(
                  &$Content,
                  $tblPastYearList,
                  TblPerson $tblPerson,
                  $tblCourse,
          Severity: Minor
          Found in Application/Document/Generator/Service/Kamenz/KamenzReportService.php - About 2 days 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

          Data has 112 functions (exceeds 20 allowed). Consider refactoring.
          Open

          class Data extends AbstractData
          {
          
              /**
               * @return false|ViewDivision[]
          Severity: Major
          Found in Application/Education/Lesson/Division/Service/Data.php - About 2 days to fix

            Function createDivisionsFromFile has a Cognitive Complexity of 107 (exceeds 5 allowed). Consider refactoring.
            Open

                public function createDivisionsFromFile(
                    IFormInterface $Form = null,
                    UploadedFile $File = null,
                    $TypeId = null,
                    $YearId = null
            Severity: Minor
            Found in Application/Transfer/Import/FuxMedia/Service.php - About 2 days 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 frontendSelectContent has a Cognitive Complexity of 107 (exceeds 5 allowed). Consider refactoring.
            Open

                public function frontendSelectContent(
                    $Division = null,
                    $Person = null,
                    $Certificate = null,
                    $Content = array(),
            Severity: Minor
            Found in Application/Education/Certificate/Generator/Frontend.php - About 2 days 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 processRow has 431 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                private function processRow(
                    PhpExcel $Document,
                    $Location,
                    $RunY,
                    $countPerson,
            Severity: Major
            Found in Application/Transfer/Import/LebensweltZwenkau/Service.php - About 2 days to fix

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

              <?php
              namespace SPHERE\Application\Education\Lesson\Term;
              
              use SPHERE\Application\Education\Lesson\Term\Service\Entity\TblHoliday;
              use SPHERE\Application\Education\Lesson\Term\Service\Entity\TblPeriod;
              Severity: Major
              Found in Application/Education/Lesson/Term/Frontend.php - About 2 days to fix
                Severity
                Category
                Status
                Source
                Language