gadael/gadael

View on GitHub
public/js/services/departmentDays.js

Summary

Maintainability
B
6 hrs
Test Coverage

Function createDepartmentDays has 69 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    return function createDepartmentDays($q, $location) {

        /**
         * @return {Promise}  resolve to scope variable
         */
Severity: Major
Found in public/js/services/departmentDays.js - About 2 hrs to fix

    Function departmentDays has 67 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            return function departmentDays(collaboratorsResource, calendareventsResource, nbdays, department, startDate, adminLink) {
    
                var scopeOutput = {};
    
                if (undefined === startDate) {
    Severity: Major
    Found in public/js/services/departmentDays.js - About 2 hrs to fix

      Function createCollaboratorDays has 34 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          function createCollaboratorDays(collaborator, startDate, nbdays) {
              collaborator.days = {};
              var loopDate = new Date(startDate);
      
              loopDate.setHours(0,0,0,0);
      Severity: Minor
      Found in public/js/services/departmentDays.js - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status