maestro-server/client-app

View on GitHub

Showing 27 of 82 total issues

File script.js has 344 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/**
 * This component made by Sagalbot
 *
 * https://github.com/sagalbot/vue-select
 */
Severity: Minor
Found in src/components/bootue/forms/select/script.js - About 4 hrs to fix

    Function updateTypeFilter has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
    Open

        updateTypeFilter(val) {
          this.clearFilter();
    
          if (val) {
            const re = /^(.*) \((.*)\)/;

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

    export default function getJSON (url, header = []) {
      const request = new window.XMLHttpRequest()
      const data = {}
      // p (-simulated- promise)
      const p = {
    Severity: Minor
    Found in src/components/bootue/forms/typeahead/_utils/getJSON.js - About 2 hrs 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

    `` has 23 functions (exceeds 20 allowed). Consider refactoring.
    Open

      methods: {
        close () {
          this.displayDayView = this.displayMonthView = this.displayYearView = false
        },
        inputClick () {
    Severity: Minor
    Found in src/components/bootue/forms/datepicker/script.js - About 2 hrs to fix

      File script.js has 267 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      import translations from '../_texts/translations.js'
      
      export default {
        props: {
          value: { type: String },
      Severity: Minor
      Found in src/components/bootue/forms/datepicker/script.js - About 2 hrs to fix

        Function setItems has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
        Open

            setItems (data) {
              if (this.async) {
                this.items = this.asyncKey ? data[this.asyncKey] : data
                this.items = this.items.slice(0, this.limit)
              } else {
        Severity: Minor
        Found in src/components/bootue/forms/typeahead/script.js - About 2 hrs 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 transition has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
        Open

            transition (val, old) {
              if (val === old) { return }
              const el = this.$el
              const body = document.body
              if (val) {
        Severity: Minor
        Found in src/components/bootue/modal/script.js - About 2 hrs 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 FetcherData has 61 lines of code (exceeds 40 allowed). Consider refactoring.
        Open

        const FetcherData = Entity => (opts = {}, headers = {}) => {
          const tenant = tenantMananger.get();
          const k = _.get(Entity, "ename");
          const cache_key = _.get(opts, "cache_key", "d");
          const { path } = opts;
        Severity: Major
        Found in src/resources/services/fetchEntity.js - About 1 hr to fix

          Function data has 56 lines of code (exceeds 40 allowed). Consider refactoring.
          Open

            data() {
              return {
                limit: 300,
                results: {
                  servers: {
          Severity: Major
          Found in src/pages/dashboard/home/script.js - About 1 hr to fix

            Function beforeDestroy has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
            Open

              beforeDestroy () {
                if (this._tabGroup) {
                  this._tabGroup.tabs = this._tabGroup.tabs.filter(el => el !== this)
                }
                if (this._tabs) {
            Severity: Minor
            Found in src/components/bootue/tab/script.js - About 1 hr 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 data has 50 lines of code (exceeds 40 allowed). Consider refactoring.
            Open

              data() {
                const initData = {
                  name: null,
                  method: "GET",
                  endpoint: null,
            Severity: Minor
            Found in src/pages/dashboard/reports/scheduler/modalCreate/script.js - About 1 hr to fix

              Function getJSON has 47 lines of code (exceeds 40 allowed). Consider refactoring.
              Open

              export default function getJSON (url, header = []) {
                const request = new window.XMLHttpRequest()
                const data = {}
                // p (-simulated- promise)
                const p = {
              Severity: Minor
              Found in src/components/bootue/forms/typeahead/_utils/getJSON.js - About 1 hr to fix

                Function data has 46 lines of code (exceeds 40 allowed). Consider refactoring.
                Open

                  data() {
                    return {
                      cdb: 0,
                      family: "Database",
                      foptions: "Oracle",
                Severity: Minor
                Found in src/pages/dashboard/inventory/databases/modalOracle/script.js - About 1 hr to fix

                  Function data has 45 lines of code (exceeds 40 allowed). Consider refactoring.
                  Open

                    data: function() {
                      return {
                        entity: new Servers(),
                        columns: [
                          "name",
                  Severity: Minor
                  Found in src/pages/dashboard/inventory/servers/list/table/script.js - About 1 hr to fix

                    Function created has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
                    Open

                      created () {
                        this._isTab = true
                        let tabs = this
                        while (!this._tabs && tabs.$parent) {
                          if (tabs._isTabGroup) {
                    Severity: Minor
                    Found in src/components/bootue/tab/script.js - About 1 hr 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 data has 41 lines of code (exceeds 40 allowed). Consider refactoring.
                    Open

                      data: function() {
                        return {
                          model: {},
                          entity: Reports,
                          options: {
                    Severity: Minor
                    Found in src/pages/dashboard/reports/exports/view/table/script.js - About 1 hr to fix

                      Function action has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                      Open

                          action (val, p) {
                            if (this.sem) {
                              if (val === null) { return }
                              this.sem = false
                              if (val && this.callback instanceof Function) this.callback()
                      Severity: Minor
                      Found in src/components/bootue/modal/script.js - About 55 mins 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 select has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                      Open

                          select (option) {
                            if (this.isOptionSelected(option)) {
                              this.deselect(option)
                            } else {
                              if (this.taggable && !this.optionExists(option)) {
                      Severity: Minor
                      Found in src/components/bootue/forms/select/script.js - About 45 mins 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 toggleDropdown has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                      Open

                          toggleDropdown (e) {
                            if (e.target === this.$refs.openIndicator || e.target === this.$refs.search || e.target === this.$refs.toggle || e.target === this.$el) {
                              if (this.open) {
                                this.$refs.search.blur() // dropdown will close on blur
                              } else {
                      Severity: Minor
                      Found in src/components/bootue/forms/select/script.js - About 45 mins 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 mutableValue has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                      Open

                          mutableValue (val, old) {
                            if (this.multiple) {
                              this.onChange ? this.onChange(val) : null
                            } else {
                              this.onChange && val !== old ? this.onChange(val) : null
                      Severity: Minor
                      Found in src/components/bootue/forms/select/script.js - About 35 mins 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

                      Severity
                      Category
                      Status
                      Source
                      Language