partkeepr/PartKeepr

View on GitHub

Showing 922 of 922 total issues

Similar blocks of code found in 3 locations. Consider refactoring.
Open

    callPutAction: function (action, parameters, callback, reload)
    {
        var proxy = this.getProxy();

        proxy.callAction(this, action, "PUT", parameters, callback, reload);
src/PartKeepr/FrontendBundle/Resources/public/js/Data/CallActions.js on lines 32..37
src/PartKeepr/FrontendBundle/Resources/public/js/Data/CallActions.js on lines 50..55

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 46.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

    callGetAction: function (action, parameters, callback, reload)
    {
        var proxy = this.getProxy();

        proxy.callAction(this, action, "GET", parameters, callback, reload);
src/PartKeepr/FrontendBundle/Resources/public/js/Data/CallActions.js on lines 14..19
src/PartKeepr/FrontendBundle/Resources/public/js/Data/CallActions.js on lines 50..55

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 46.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        Ext.Object.merge(config, {
            autoLoad: false,
            model: "PartKeepr.ProjectBundle.Entity.ProjectPart",
            autoSync: false, // Do not change. If true, new (empty) records would be immediately committed to the database.
            remoteFilter: false,
src/PartKeepr/FrontendBundle/Resources/public/js/Components/ProjectRun/ProjectRunEditor.js on lines 37..43

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 46.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Avoid too many return statements within this function.
Open

                return real_create_object_URL.call(real_URL, blob);
Severity: Major
Found in src/PartKeepr/FrontendBundle/Resources/public/js/Util/Blob.js - About 30 mins to fix

    Avoid too many return statements within this function.
    Open

                        return false;

      Avoid too many return statements within this function.
      Open

              return true;

        Avoid too many return statements within this function.
        Open

                        return false;

          Avoid too many return statements within this function.
          Open

                  return true;

            Avoid too many return statements within this function.
            Open

                            return false;

              Avoid too many return statements within this function.
              Open

                              return false;

                Avoid too many return statements within this function.
                Open

                            return;

                  Avoid too many return statements within this function.
                  Open

                          return result;

                    Avoid too many return statements within this function.
                    Open

                                    return tmp.getFieldType(parts.join("."));
                    Severity: Major
                    Found in src/PartKeepr/FrontendBundle/Resources/public/js/Data/HydraModel.js - About 30 mins to fix

                      Avoid too many return statements within this method.
                      Open

                                      return 'array';
                      Severity: Major
                      Found in src/PartKeepr/DoctrineReflectionBundle/Services/ReflectionService.php - About 30 mins to fix

                        Avoid too many return statements within this method.
                        Open

                                        return $this->em->getExpressionBuilder()->like($alias, $paramName);
                        Severity: Major
                        Found in src/PartKeepr/DoctrineReflectionBundle/Services/FilterService.php - About 30 mins to fix

                          Avoid too many return statements within this function.
                          Open

                                  return ret;
                          Severity: Major
                          Found in src/PartKeepr/FrontendBundle/Resources/public/js/Data/HydraModel.js - About 30 mins to fix

                            Avoid too many return statements within this method.
                            Open

                                    return null;
                            Severity: Major
                            Found in src/PartKeepr/ImportBundle/Configuration/ManyToOneConfiguration.php - About 30 mins to fix

                              Avoid too many return statements within this method.
                              Open

                                              return $this->em->getExpressionBuilder()->lte($alias, $paramName);
                              Severity: Major
                              Found in src/PartKeepr/DoctrineReflectionBundle/Services/FilterService.php - About 30 mins to fix

                                Avoid too many return statements within this method.
                                Open

                                                return 'boolean';
                                Severity: Major
                                Found in src/PartKeepr/DoctrineReflectionBundle/Services/ReflectionService.php - About 30 mins to fix

                                  Avoid too many return statements within this method.
                                  Open

                                                  return 'number';
                                  Severity: Major
                                  Found in src/PartKeepr/DoctrineReflectionBundle/Services/ReflectionService.php - About 30 mins to fix
                                    Severity
                                    Category
                                    Status
                                    Source
                                    Language