Showing 169 of 403 total issues
Function createCol
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Handsontable.DataMap.prototype.createCol = function (index, amount, createdAutomatically) {
if (this.instance.dataType === 'object' || this.instance.getSettings().columns) {
throw new Error("Cannot create new column. When data source in an object, " +
"you can only have as much columns as defined in first data row, data schema or in the 'columns' setting." +
"If you want to be able to add new columns, you have to use array datasource.");
Function createRow
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Handsontable.DataMap.prototype.createRow = function (index, amount, createdAutomatically) {
var row
, colCount = this.instance.countCols()
, numberOfCreatedRows = 0
, currentIndex;
Function prepareBorder
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var prepareBorder = function (range, place) {
if (range.from.row == range.to.row && range.from.col == range.to.col){
if(place == "noBorders"){
removeBorder.call(this, range.from.row, range.from.col);
} else {
Function handsontable
has 36 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.fn.handsontable = function (action) {
var i
, ilen
, args
, output
Function parse
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
parse: function (str) {
var r, rlen, rows, arr = [], a = 0, c, clen, multiline, last;
rows = str.split('\n');
if (rows.length > 1 && rows[rows.length - 1] === '') {
rows.pop();
Function Storage
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function Storage(prefix) {
var savedKeys;
var saveSavedKeys = function () {
Function _generate
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function _generate(mirror, obj, patches, path) {
var newKeys = _objectKeys(obj);
var oldKeys = _objectKeys(mirror);
var changed = false;
var deleted = false;
Function Walkontable
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function Walkontable(settings) {
var originalHeaders = [];
this.guid = 'wt_' + walkontableRandomString(); //this is the namespace for global events
Function init
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
this.init = function (source) {
var instance = this;
var sortingSettings = instance.getSettings().columnSorting;
var sortingColumn, sortingOrder;
Function prepareBorderFromCustomAddedRange
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var prepareBorderFromCustomAddedRange = function (rowObj) {
var range = rowObj.range;
for (var row = range.from.row; row <= range.to.row; row ++) {
for (var col = range.from.col; col<= range.to.col; col++){
Function filter
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Array.prototype.filter = function (fun, thisp) {
"use strict";
if (typeof this === "undefined" || this === null) {
throw new TypeError();
Function unformatNumeral
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function unformatNumeral (n, string) {
var stringOriginal = string,
thousandRegExp,
millionRegExp,
billionRegExp,
Function isMetaKey
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Handsontable.helper.isMetaKey = function (keyCode) {
var keyCodes = Handsontable.helper.keyCode;
var metaKeys = [
keyCodes.ARROW_DOWN,
keyCodes.ARROW_UP,
Function Search
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Handsontable.Search = function Search(instance) {
this.query = function (queryStr, callback, queryMethod) {
var rowCount = instance.countRows();
var colCount = instance.countCols();
var queryResult = [];
Function open
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
AutocompleteEditor.prototype.open = function () {
Handsontable.editors.HandsontableEditor.prototype.open.apply(this, arguments);
this.$textarea[0].style.visibility = 'visible';
Function draw
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
WalkontableSelection.prototype.draw = function () {
var corners, r, c, source_r, source_c,
instance = this.instance,
visibleRows = instance.wtTable.getRowStrategy().countVisible(),
renderedColumns = instance.wtTable.getColumnStrategy().cellCount,
Function apply
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function apply(tree, patches) {
var result = false, p = 0, plen = patches.length, patch;
while (p < plen) {
patch = patches[p];
Function resetFixedPosition
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
WalkontableCornerScrollbarNative.prototype.resetFixedPosition = function () {
if (!this.instance.wtTable.holder.parentNode) {
return; //removed from DOM
}
var elem = this.clone.wtTable.holder.parentNode;
Function refreshStretching
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
WalkontableTableRenderer.prototype.refreshStretching = function () {
if (this.wtTable.isWorkingOnClone()) {
return;
}
Function query
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
this.query = function (queryStr, callback, queryMethod) {
var rowCount = instance.countRows();
var colCount = instance.countCols();
var queryResult = [];