Showing 1,567 of 3,608 total issues
File questionnaire_helper.js
has 643 lines of code (exceeds 250 allowed). Consider refactoring. Open
//DW is the global name space for DataWinner
DW.init_inform_datasender_about_changes = function () {
var kwargs = {container: "#inform_datasender_about_changes",
is_continue: true,
title: gettext('Inform Your Data Senders about the Changes'),
Function daterangepicker
has a Cognitive Complexity of 72 (exceeds 5 allowed). Consider refactoring. Open
jQuery.fn.daterangepicker = function(settings){
var rangeInput = jQuery(this);
//defaults
var options = jQuery.extend({
- Read upRead up
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 getElementsBySelector
has a Cognitive Complexity of 71 (exceeds 5 allowed). Consider refactoring. Open
document.getElementsBySelector = function(selector) {
// Attempt to fail gracefully in lesser browsers
if (!document.getElementsByTagName) {
return new Array();
}
- Read upRead up
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
File daterangepicker.jQuery.custom.js
has 631 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**
* --------------------------------------------------------------------
* jQuery-Plugin "daterangepicker.jQuery.js"
* by Scott Jehl, scott@filamentgroup.com
* http://www.filamentgroup.com
Function api
has 278 lines of code (exceeds 25 allowed). Consider refactoring. Open
var api = (function () {
var isInitialized = 0,
configuration = ko.validation.configuration,
utils = ko.validation.utils;
Function api
has 278 lines of code (exceeds 25 allowed). Consider refactoring. Open
}());;var api = (function () {
var isInitialized = 0,
configuration = kv.configuration,
utils = kv.utils;
Function get_edited_details_for_field_set
has a Cognitive Complexity of 69 (exceeds 5 allowed). Consider refactoring. Open
def get_edited_details_for_field_set(edit_details, questionnaire, code, value):
if len(value['new_data']) == len(value['old_data']):
if value['old_data'] != value['new_data']:
for index, i in enumerate(value['new_data']):
for key, val in i.items():
- Read upRead up
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
File jquery-textntags.js
has 617 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*
* Text'N'Tags (textntags)
* Version 0.1.2
* Written by: Daniel Zahariev
*
File jquery-2.0.3.intellisense.js
has 614 lines of code (exceeds 250 allowed). Consider refactoring. Open
intellisense.annotate(jQuery, {
'ajax': function() {
/// <signature>
/// <summary>Perform an asynchronous HTTP (Ajax) request.</summary>
/// <param name="url" type="String">A string containing the URL to which the request is sent.</param>
File daterangepicker.jQuery.js
has 614 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**
* --------------------------------------------------------------------
* jQuery-Plugin "daterangepicker.jQuery.js"
* by Scott Jehl, scott@filamentgroup.com
* http://www.filamentgroup.com
Function load_sms_data_for_cli001
has 267 lines of code (exceeds 25 allowed). Consider refactoring. Open
def load_sms_data_for_cli001(manager):
FEB = datetime(2011, 02, 28, hour=12, minute=00, second=00, tzinfo=UTC)
MARCH = datetime(2011, 03, 01, tzinfo=UTC)
DEC_2010 = datetime(2010, 12, 28, hour=00, minute=00, second=59, tzinfo=UTC)
NOV_2010 = datetime(2010, 11, 26, hour=23, minute=59, second=59, tzinfo=UTC)
Function daterangepicker
has a Cognitive Complexity of 67 (exceeds 5 allowed). Consider refactoring. Open
jQuery.fn.daterangepicker = function(settings){
var rangeInput = jQuery(this);
//defaults
var options = jQuery.extend({
- Read upRead up
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
AllDataSendersPage
has 70 functions (exceeds 20 allowed). Consider refactoring. Open
class AllDataSendersPage(Page):
def __init__(self, driver):
Page.__init__(self, driver)
def navigate_to_add_a_data_sender_page(self):
Function json_parse
has 253 lines of code (exceeds 25 allowed). Consider refactoring. Open
var json_parse = (function () {
"use strict";
// This function creates a JSON parse function that uses a state machine rather
// than the dangerous eval function to parse a JSON text.
Function inlineEdit
has 245 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.inlineEdit = function(urls, options){
var editableUrls = urls;
var options = jQuery.extend({
File questionnaire_tab_page.py
has 575 lines of code (exceeds 250 allowed). Consider refactoring. Open
from time import sleep
from selenium.common.exceptions import NoSuchElementException
from selenium.webdriver.support.select import Select
from framework.utils.common_utils import by_css, by_id, generateId, CommonUtilities, by_xpath, by_name
Function ajax
has 240 lines of code (exceeds 25 allowed). Consider refactoring. Open
ajax: function( url, options ) {
// If url is an object, simulate pre-1.5 signature
if ( typeof url === "object" ) {
options = url;
Function highlightTextarea
has 235 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.highlightTextarea = function(element, options) {
this.options = options;
if (element instanceof jQuery) {
this.$textarea = element;
File dataTables.colVis.js
has 556 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*! ColVis 1.1.2
* ©2010-2015 SpryMedia Ltd - datatables.net/license
*/
/**
Function _init
has a Cognitive Complexity of 59 (exceeds 5 allowed). Consider refactoring. Open
_init: function () {
var self = this;
var q = this.options;
this.newly_added_question = ko.observable(q.newly_added_question);
this.range_min = DW.ko.createValidatableObservable({value: q.range.min});
- Read upRead up
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"