o2xp/react-datatable

View on GitHub

Showing 9 of 79 total issues

File BodyActionsCell.js has 329 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import React, { Component, Fragment } from "react";
import {
Tooltip,
IconButton,
Checkbox,
Severity: Minor
Found in src/components/DatatableCore/Body/BodyActionsCell.js - About 3 hrs to fix

    Function render has 91 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    render() {
    const {
    rowsSelected,
    printText,
    printTitleText,
    Severity: Major
    Found in src/components/DatatableHeader/Widgets/Print.js - About 3 hrs to fix

      File DownloadData.js has 302 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      import React, { Component, Fragment } from "react";
      import { connect } from "react-redux";
      import { cloneDeep } from "lodash";
      import {
      IconButton,
      Severity: Minor
      Found in src/components/DatatableHeader/Widgets/DownloadData.js - About 3 hrs to fix

        File Print.js has 270 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        import React, { Component, Fragment } from "react";
        import { connect } from "react-redux";
        import {
        IconButton,
        Tooltip,
        Severity: Minor
        Found in src/components/DatatableHeader/Widgets/Print.js - About 2 hrs to fix

          Function saveRowEdited has 35 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          const saveRowEdited = (state, payload) => {
          const row = payload;
          delete row.idOfColumnErr;
          delete row.hasBeenEdited;
          const { data, rowsEdited, keyColumn, pagination, actions } = state;
          Severity: Minor
          Found in src/redux/reducers/datatableReducer.js - About 1 hr to fix

            Function render has 30 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            render() {
            const { canSelect, column, isScrolling } = this.props;
            const { checked } = this.state;
             
            return (
            Severity: Minor
            Found in src/components/DatatableCore/Header/HeaderActionsCell.js - About 1 hr to fix

              Function revertAllRowsToEdited has 29 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

              const revertAllRowsToEdited = state => {
              const { newRows, data, keyColumn, pagination, rowsDeleted, actions } = state;
              const newRowsId = newRows.map(r => r[keyColumn]);
              const { rows } = data;
               
               
              Severity: Minor
              Found in src/redux/reducers/datatableReducer.js - About 1 hr to fix

                Function setValue has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                Open

                export const setValue = ({
                date,
                value,
                dateFormat,
                rowId,
                Severity: Minor
                Found in src/components/DatatableCore/InputTypes/PickersFunction.js - About 35 mins to fix

                Function CreateInput has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                Open

                const CreateInput = ({
                cellVal,
                valueVerification,
                rowId,
                columnId,
                Severity: Minor
                Found in src/components/DatatableCore/InputTypes/CreateInput.js - About 25 mins to fix
                Severity
                Category
                Status
                Source
                Language