myems-admin/js/plugins/flot/jquery.flot.time.js
Function init
has 164 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function init(plot) {
plot.hooks.processOptions.push(function (plot, options) {
$.each(plot.getAxes(), function(axisName, axis) {
var opts = axis.options;
Function tickGenerator
has 112 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
axis.tickGenerator = function(axis) {
var ticks = [];
var d = dateGenerator(axis.min, opts);
var minSize = 0;
File jquery.flot.time.js
has 308 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/* Pretty handling of time axes.
Copyright (c) 2007-2014 IOLA and Ole Laursen.
Licensed under the MIT license.
Function formatDate
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function formatDate(d, fmt, monthNames, dayNames) {
if (typeof d.strftime == "function") {
return d.strftime(fmt);
}
Consider simplifying this complex logical expression. Open
Open
if (opts.mode == "time") {
axis.tickGenerator = function(axis) {
var ticks = [];
var d = dateGenerator(axis.min, opts);
Function tickFormatter
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
axis.tickFormatter = function (v, axis) {
var d = dateGenerator(v, axis.options);
// first check global format
Avoid deeply nested control flow statements. Open
Open
if (span < timeUnitSize.year) {
fmt = "Q%q";
} else {
fmt = "Q%q %Y";
}