| @@ -23,13 +23,8 @@ | ||
| 23 | 23 | |
| 24 | 24 | if(chart.library !== 'datatables'){ |
| 25 | 25 | return; |
| 26 | 26 | } |
| 27 | - | |
| 28 | - // Bail if the chart is already rendered or is being rendered. | |
| 29 | - if ( ! window.isResizeRequest && ( $('#' + id).hasClass('visualizer-chart-loaded') || ( 'canvas' !== id && $('#' + id).children( ':not(.loader, style)' ).length > 0 ) ) ) { | |
| 30 | - return; | |
| 31 | - } | |
| 32 | 27 | rendered_charts[id] = 'yes'; |
| 33 | 28 | |
| 34 | 29 | series = chart.series; |
| 35 | 30 | data = chart.data; |
| @@ -72,9 +67,9 @@ | ||
| 72 | 67 | delete chart.settings['scrollX']; |
| 73 | 68 | delete chart.settings['scrollY']; |
| 74 | 69 | delete chart.settings['scrollY_int']; |
| 75 | 70 | $.extend( settings, { |
| 76 | - scrollX: '100%', | |
| 71 | + scrollX: 150, | |
| 77 | 72 | scrollY: (( chart.settings['responsive_bool'] === 'true' ? 0.8 : 0.5 ) * parseInt($(container).css('height').replace('px',''))), |
| 78 | 73 | scrollCollapse: true |
| 79 | 74 | } ); |
| 80 | 75 | }else{ |
| @@ -82,9 +77,9 @@ | ||
| 82 | 77 | chart.settings['scrollY_int']; |
| 83 | 78 | } |
| 84 | 79 | delete chart.settings['scrollX']; |
| 85 | 80 | $.extend( settings, { |
| 86 | - scrollX: '100%', | |
| 81 | + scrollX: 150, | |
| 87 | 82 | scrollY: 180, |
| 88 | 83 | } ); |
| 89 | 84 | } |
| 90 | 85 | break; |
| @@ -251,13 +246,10 @@ | ||
| 251 | 246 | parts[0] = series.format.thousands; |
| 252 | 247 | } |
| 253 | 248 | if(typeof series.format.decimal !== ''){ |
| 254 | 249 | parts[1] = series.format.decimal; |
| 255 | - if ( '' === series.format.precision ) { | |
| 256 | - series.format.precision = 2; | |
| 257 | - } | |
| 258 | 250 | } |
| 259 | - if(typeof series.format.precision !== '' && parseInt(series.format.precision) > 0){ | |
| 251 | + if(typeof series.format.precision !== ''){ | |
| 260 | 252 | parts[2] = series.format.precision; |
| 261 | 253 | } |
| 262 | 254 | if(typeof series.format.prefix !== ''){ |
| 263 | 255 | parts[3] = series.format.prefix; |
| @@ -297,14 +289,9 @@ | ||
| 297 | 289 | } |
| 298 | 290 | |
| 299 | 291 | $('body').on('visualizer:render:chart:start', function(event, v){ |
| 300 | 292 | all_charts = v.charts; |
| 301 | - | |
| 302 | - if(v.is_front == true && typeof v.id !== 'undefined'){ // jshint ignore:line | |
| 303 | - renderChart(v.id, v); | |
| 304 | - } else { | |
| 305 | - render(v); | |
| 306 | - } | |
| 293 | + render(v); | |
| 307 | 294 | }); |
| 308 | 295 | |
| 309 | 296 | $('body').on('visualizer:render:specificchart:start', function(event, v){ |
| 310 | 297 | renderSpecificChart(v.id, v.chart, v.v); |