/*! ColReorder 1.2.0 ©2010-2014 SpryMedia Ltd - datatables.net/license */ (function(n,p,r){function o(d){for(var h=[],g=0,a=d.length;gc||c>=h)this.oApi._fnLog(a,1,"ColReorder 'from' index is out of bounds: "+c);else if(0>e||e>=h)this.oApi._fnLog(a,1,"ColReorder 'to' index is out of bounds: "+e);else{k=[];b=0;for(f=h;bthis.s.fixed-1&&bMath.pow(Math.pow(a.pageX-this.s.mouse.startX,2)+Math.pow(a.pageY- this.s.mouse.startY,2),0.5))return;this._fnCreateDragNode()}this.dom.drag.css({left:a.pageX-this.s.mouse.offsetX,top:a.pageY-this.s.mouse.offsetY});for(var c=!1,d=this.s.mouse.toIndex,b=1,f=this.s.aoTargets.length;b").addClass("DTCR_pointer").css({position:"absolute",top:a?d("div.dataTables_scroll",this.s.dt.nTableWrapper).offset().top:d(this.s.dt.nTable).offset().top,height:a?d("div.dataTables_scroll",this.s.dt.nTableWrapper).height():d(this.s.dt.nTable).height()}).appendTo("body")},_fnSetColumnIndexes:function(){d.each(this.s.dt.aoColumns,function(a,c){d(c.nTh).attr("data-column-index",a)})}};g.defaults= {aiOrder:null,bRealtime:!0,iFixedColumnsLeft:0,iFixedColumnsRight:0,fnReorderCallback:null};g.version="1.2.0";d.fn.dataTable.ColReorder=g;d.fn.DataTable.ColReorder=g;"function"==typeof d.fn.dataTable&&"function"==typeof d.fn.dataTableExt.fnVersionCheck&&d.fn.dataTableExt.fnVersionCheck("1.10.8")?d.fn.dataTableExt.aoFeatures.push({fnInit:function(a){var c=a.oInstance;a._colReorder?c.oApi._fnLog(a,1,"ColReorder attempted to initialise twice. Ignoring second"):(c=a.oInit,new g(a,c.colReorder||c.oColReorder|| {}));return null},cFeature:"R",sFeature:"ColReorder"}):alert("Warning: ColReorder requires DataTables 1.10.8 or greater - www.datatables.net/download");d(p).on("preInit.dt.colReorder",function(a,c){if("dt"===a.namespace){var e=c.oInit.colReorder,b=h.defaults.colReorder;if(e||b)b=d.extend({},e,b),!1!==e&&new g(c,b)}});d.fn.dataTable.Api.register("colReorder.reset()",function(){return this.iterator("table",function(a){a._colReorder.fnReset()})});d.fn.dataTable.Api.register("colReorder.order()",function(a){return a? this.iterator("table",function(c){c._colReorder.fnOrder(a)}):this.context.length?this.context[0]._colReorder.fnOrder():null});return g};"function"===typeof define&&define.amd?define(["jquery","datatables"],n):"object"===typeof exports?n(require("jquery"),require("datatables")):jQuery&&!jQuery.fn.dataTable.ColReorder&&n(jQuery,jQuery.fn.dataTable)})(window,document);