MAKENTNU/web

View on GitHub

Showing 230 of 230 total issues

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

event_urlpatterns = [
path("", event_views.EventListView.as_view(), name='event_list'),
path("<int:pk>/", include(specific_event_urlpatterns)),
Severity: Major
Found in src/news/urls.py and 4 other locations - About 30 mins to fix
src/make_queue/urls.py on lines 21..23
src/make_queue/urls.py on lines 69..71
src/make_queue/urls.py on lines 82..84
src/news/urls.py on lines 64..66

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

time_place_adminpatterns = [
path("add/", event_views.TimePlaceCreateView.as_view(), name='time_place_create'),
path("<int:time_place_pk>/", include(specific_time_place_adminpatterns)),
Severity: Major
Found in src/news/urls.py and 4 other locations - About 30 mins to fix
src/make_queue/urls.py on lines 21..23
src/make_queue/urls.py on lines 69..71
src/make_queue/urls.py on lines 82..84
src/news/urls.py on lines 26..28

Avoid too many return statements within this function.
Open

return False
Severity: Major
Found in src/make_queue/models/reservation.py - About 30 mins to fix

    Avoid too many return statements within this function.
    Open

    return False
    Severity: Major
    Found in src/make_queue/models/reservation.py - About 30 mins to fix

      Avoid too many return statements within this function.
      Open

      return _("The reservation cannot start and end at the same time")
      Severity: Major
      Found in src/make_queue/views/reservation.py - About 30 mins to fix

        Avoid too many return statements within this function.
        Open

        return not fail_if_not_standalone
        Severity: Major
        Found in src/news/models.py - About 30 mins to fix

          Avoid too many return statements within this function.
          Open

          return False
          Severity: Major
          Found in src/make_queue/models/reservation.py - About 30 mins to fix

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

            reservation_rules_adminpatterns = [
            path("add/", reservation_rule_views.ReservationRuleCreateView.as_view(), name='reservation_rule_create'),
            path("<int:reservation_rule_pk>/", include(specific_reservation_rule_adminpatterns)),
            Severity: Major
            Found in src/make_queue/urls.py and 4 other locations - About 30 mins to fix
            src/make_queue/urls.py on lines 21..23
            src/make_queue/urls.py on lines 82..84
            src/news/urls.py on lines 26..28
            src/news/urls.py on lines 64..66

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

            machine_adminpatterns = [
            path("add/", machine_views.MachineCreateView.as_view(), name='machine_create'),
            path("<int:pk>/", include(specific_machine_adminpatterns)),
            Severity: Major
            Found in src/make_queue/urls.py and 4 other locations - About 30 mins to fix
            src/make_queue/urls.py on lines 21..23
            src/make_queue/urls.py on lines 69..71
            src/news/urls.py on lines 26..28
            src/news/urls.py on lines 64..66

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

            machine_urlpatterns = [
            path("", machine_views.MachineListView.as_view(), name='machine_list'),
            path("<int:pk>/", include(specific_machine_urlpatterns)),
            Severity: Major
            Found in src/make_queue/urls.py and 4 other locations - About 30 mins to fix
            src/make_queue/urls.py on lines 69..71
            src/make_queue/urls.py on lines 82..84
            src/news/urls.py on lines 26..28
            src/news/urls.py on lines 64..66

            Avoid too many return statements within this function.
            Open

            return false;
            Severity: Major
            Found in src/make_queue/static/make_queue/js/reservation_form.js - About 30 mins to fix

              Avoid too many return statements within this function.
              Open

              return False
              Severity: Major
              Found in src/make_queue/models/reservation.py - About 30 mins to fix

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

                specific_machinetype_adminpatterns = [
                path("reservationrules/", include(reservation_rules_adminpatterns)),
                path("usagerules/change/", machine_views.MachineUsageRuleUpdateView.as_view(), name='machine_usage_rule_update'),
                Severity: Minor
                Found in src/make_queue/urls.py and 1 other location - About 30 mins to fix
                src/news/urls.py on lines 35..37

                Avoid too many return statements within this function.
                Open

                return False
                Severity: Major
                Found in src/make_queue/models/reservation.py - About 30 mins to fix

                  Avoid too many return statements within this function.
                  Open

                  return ""
                  Severity: Major
                  Found in src/make_queue/templatetags/reservation_extra.py - About 30 mins to fix

                    Avoid too many return statements within this function.
                    Open

                    return _("The time slot is not available")
                    Severity: Major
                    Found in src/make_queue/views/reservation.py - About 30 mins to fix

                      Avoid too many return statements within this function.
                      Open

                      return user_details
                      Severity: Major
                      Found in src/dataporten/ldap_utils.py - About 30 mins to fix

                        Avoid too many return statements within this function.
                        Open

                        return _("The reservation can't start in the past")
                        Severity: Major
                        Found in src/make_queue/views/reservation.py - About 30 mins to fix

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

                          ticket_urlpatterns = [
                          path("<uuid:pk>/", include(specific_ticket_urlpatterns)),
                          path("me/", event_views.EventTicketMyListView.as_view(), name='event_ticket_my_list'),
                          Severity: Minor
                          Found in src/news/urls.py and 1 other location - About 30 mins to fix
                          src/make_queue/urls.py on lines 73..75

                          Avoid too many return statements within this function.
                          Open

                          return self.quota_can_create_reservation()
                          Severity: Major
                          Found in src/make_queue/models/reservation.py - About 30 mins to fix
                            Severity
                            Category
                            Status
                            Source
                            Language