diff --git a/vendors/datatables.net-buttons/.bower.json b/vendors/datatables.net-buttons/.bower.json
index 1ba81036..b8890c48 100644
--- a/vendors/datatables.net-buttons/.bower.json
+++ b/vendors/datatables.net-buttons/.bower.json
@@ -42,14 +42,15 @@
],
"homepage": "https://datatables.net",
"license": "MIT",
- "version": "1.2.1",
- "_release": "1.2.1",
+ "version": "1.2.2",
+ "_release": "1.2.2",
"_resolution": {
"type": "version",
- "tag": "1.2.1",
- "commit": "0518965e46150aa2a62d0132053f338cabe165fb"
+ "tag": "1.2.2",
+ "commit": "16f453f3c50ce39b44812ba056cbd10a1b1eb245"
},
"_source": "https://github.com/DataTables/Dist-DataTables-Buttons.git",
- "_target": "^1.1.2",
- "_originalSource": "datatables.net-buttons"
+ "_target": "1.2.2",
+ "_originalSource": "datatables.net-buttons",
+ "_direct": true
}
\ No newline at end of file
diff --git a/vendors/datatables.net-buttons/js/buttons.colVis.js b/vendors/datatables.net-buttons/js/buttons.colVis.js
index 08e42fae..d6490996 100755
--- a/vendors/datatables.net-buttons/js/buttons.colVis.js
+++ b/vendors/datatables.net-buttons/js/buttons.colVis.js
@@ -104,12 +104,11 @@ $.extend( DataTable.ext.buttons, {
},
init: function ( dt, button, conf ) {
var that = this;
- var col = dt.column( conf.columns );
dt
.on( 'column-visibility.dt'+conf.namespace, function (e, settings) {
if ( ! settings.bDestroying ) {
- that.active( col.visible() );
+ that.active( dt.column( conf.columns ).visible() );
}
} )
.on( 'column-reorder.dt'+conf.namespace, function (e, settings, details) {
@@ -129,7 +128,7 @@ $.extend( DataTable.ext.buttons, {
that.active( col.visible() );
} );
- this.active( col.visible() );
+ this.active( dt.column( conf.columns ).visible() );
},
destroy: function ( dt, button, conf ) {
dt
diff --git a/vendors/datatables.net-buttons/js/buttons.colVis.min.js b/vendors/datatables.net-buttons/js/buttons.colVis.min.js
index e007073b..16af2273 100644
--- a/vendors/datatables.net-buttons/js/buttons.colVis.min.js
+++ b/vendors/datatables.net-buttons/js/buttons.colVis.min.js
@@ -1,5 +1,5 @@
(function(g){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(d){return g(d,window,document)}):"object"===typeof exports?module.exports=function(d,e){d||(d=window);if(!e||!e.fn.dataTable)e=require("datatables.net")(d,e).$;e.fn.dataTable.Buttons||require("datatables.net-buttons")(d,e);return g(e,d,d.document)}:g(jQuery,window,document)})(function(g,d,e,h){d=g.fn.dataTable;g.extend(d.ext.buttons,{colvis:function(a,b){return{extend:"collection",
text:function(a){return a.i18n("buttons.colvis","Column visibility")},className:"buttons-colvis",buttons:[{extend:"columnsToggle",columns:b.columns}]}},columnsToggle:function(a,b){return a.columns(b.columns).indexes().map(function(a){return{extend:"columnToggle",columns:a}}).toArray()},columnToggle:function(a,b){return{extend:"columnVisibility",columns:b.columns}},columnsVisibility:function(a,b){return a.columns(b.columns).indexes().map(function(a){return{extend:"columnVisibility",columns:a,visibility:b.visibility}}).toArray()},
-columnVisibility:{columns:h,text:function(a,b,c){return c._columnText(a,c.columns)},className:"buttons-columnVisibility",action:function(a,b,c,f){a=b.columns(f.columns);b=a.visible();a.visible(f.visibility!==h?f.visibility:!(b.length&&b[0]))},init:function(a,b,c){var f=this,d=a.column(c.columns);a.on("column-visibility.dt"+c.namespace,function(a,b){b.bDestroying||f.active(d.visible())}).on("column-reorder.dt"+c.namespace,function(b,d,e){1===a.columns(c.columns).count()&&("number"===typeof c.columns&&
-(c.columns=e.mapping[c.columns]),b=a.column(c.columns),f.text(c._columnText(a,c.columns)),f.active(b.visible()))});this.active(d.visible())},destroy:function(a,b,c){a.off("column-visibility.dt"+c.namespace).off("column-reorder.dt"+c.namespace)},_columnText:function(a,b){var c=a.column(b).index();return a.settings()[0].aoColumns[c].sTitle.replace(/\n/g," ").replace(/<.*?>/g,"").replace(/^\s+|\s+$/g,"")}},colvisRestore:{className:"buttons-colvisRestore",text:function(a){return a.i18n("buttons.colvisRestore",
+columnVisibility:{columns:h,text:function(a,b,c){return c._columnText(a,c.columns)},className:"buttons-columnVisibility",action:function(a,b,c,f){a=b.columns(f.columns);b=a.visible();a.visible(f.visibility!==h?f.visibility:!(b.length&&b[0]))},init:function(a,b,c){var f=this;a.on("column-visibility.dt"+c.namespace,function(b,d){d.bDestroying||f.active(a.column(c.columns).visible())}).on("column-reorder.dt"+c.namespace,function(b,d,e){1===a.columns(c.columns).count()&&("number"===typeof c.columns&&
+(c.columns=e.mapping[c.columns]),b=a.column(c.columns),f.text(c._columnText(a,c.columns)),f.active(b.visible()))});this.active(a.column(c.columns).visible())},destroy:function(a,b,c){a.off("column-visibility.dt"+c.namespace).off("column-reorder.dt"+c.namespace)},_columnText:function(a,b){var c=a.column(b).index();return a.settings()[0].aoColumns[c].sTitle.replace(/\n/g," ").replace(/<.*?>/g,"").replace(/^\s+|\s+$/g,"")}},colvisRestore:{className:"buttons-colvisRestore",text:function(a){return a.i18n("buttons.colvisRestore",
"Restore visibility")},init:function(a,b,c){c._visOriginal=a.columns().indexes().map(function(b){return a.column(b).visible()}).toArray()},action:function(a,b,c,d){b.columns().every(function(a){a=b.colReorder&&b.colReorder.transpose?b.colReorder.transpose(a,"toOriginal"):a;this.visible(d._visOriginal[a])})}},colvisGroup:{className:"buttons-colvisGroup",action:function(a,b,c,d){b.columns(d.show).visible(!0,!1);b.columns(d.hide).visible(!1,!1);b.columns.adjust()},show:[],hide:[]}});return d.Buttons});
diff --git a/vendors/datatables.net-buttons/js/buttons.flash.js b/vendors/datatables.net-buttons/js/buttons.flash.js
index bbc3254f..695de992 100644
--- a/vendors/datatables.net-buttons/js/buttons.flash.js
+++ b/vendors/datatables.net-buttons/js/buttons.flash.js
@@ -891,7 +891,7 @@ var excelStrings = {
'
'+
'',
- "xl/styles.xml":
+ "xl/styles.xml":
''+
'
'+
''+
@@ -977,7 +977,7 @@ var excelStrings = {
''+
' '+
' '+
- ''+
+ ''+
' '+
' '+
' '+
@@ -1028,6 +1028,24 @@ var excelStrings = {
' '+
' '+
' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
' '+
''+
' '+
@@ -1193,11 +1211,7 @@ DataTable.ext.buttons.excelFlash = $.extend( {}, flashButton, {
// Replace non standard characters for text output
var text = ! row[i].replace ?
row[i] :
- row[i]
- .replace(/&(?!amp;)/g, '&')
- .replace(//g, '>')
- .replace(/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F-\x9F]/g, '');
+ row[i].replace(/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F-\x9F]/g, '');
cell = _createNode( rels, 'c', {
attr: {
@@ -1299,7 +1313,7 @@ DataTable.ext.buttons.pdfFlash = $.extend( {}, flashButton, {
_setText( flash, JSON.stringify( {
title: _filename(config, false),
- message: config.message,
+ message: typeof config.message == 'function' ? config.message(dt, button, config) : config.message,
colWidth: ratios.toArray(),
orientation: config.orientation,
size: config.pageSize,
diff --git a/vendors/datatables.net-buttons/js/buttons.flash.min.js b/vendors/datatables.net-buttons/js/buttons.flash.min.js
index 82fc495f..bc326407 100644
--- a/vendors/datatables.net-buttons/js/buttons.flash.min.js
+++ b/vendors/datatables.net-buttons/js/buttons.flash.min.js
@@ -1,29 +1,29 @@
-(function(g){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(i){return g(i,window,document)}):"object"===typeof exports?module.exports=function(i,k){i||(i=window);if(!k||!k.fn.dataTable)k=require("datatables.net")(i,k).$;k.fn.dataTable.Buttons||require("datatables.net-buttons")(i,k);return g(k,i,i.document)}:g(jQuery,window,document)})(function(g,i,k,o){function l(a,b,d){var c=a.createElement(b);d&&(d.attr&&g(c).attr(d.attr),d.children&&
-g.each(d.children,function(a,b){c.appendChild(b)}),d.text&&c.appendChild(a.createTextNode(d.text)));return c}function y(a,b){var d=a.header[b].length,c;a.footer&&a.footer[b].length>d&&(d=a.footer[b].length);for(var e=0,f=a.body.length;ed&&(d=c),40'+c),c=c.replace(/_dt_b_namespace_token_/g,":"));c=c.replace(//g,"");a[b]=c}})}var j=g.fn.dataTable,h={version:"1.0.4-TableTools2",clients:{},moviePath:"",nextId:1,$:function(a){"string"==typeof a&&(a=k.getElementById(a));a.addClass||(a.hide=function(){this.style.display="none"},a.show=function(){this.style.display=""},a.addClass=function(a){this.removeClass(a);this.className+=" "+a},a.removeClass=function(a){this.className=this.className.replace(RegExp("\\s*"+a+"\\s*")," ").replace(/^\s+/,"").replace(/\s+$/,"")},a.hasClass=
+(function(f){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(j){return f(j,window,document)}):"object"===typeof exports?module.exports=function(j,k){j||(j=window);if(!k||!k.fn.dataTable)k=require("datatables.net")(j,k).$;k.fn.dataTable.Buttons||require("datatables.net-buttons")(j,k);return f(k,j,j.document)}:f(jQuery,window,document)})(function(f,j,k,o){function l(a,b,d){var c=a.createElement(b);d&&(d.attr&&f(c).attr(d.attr),d.children&&
+f.each(d.children,function(a,b){c.appendChild(b)}),d.text&&c.appendChild(a.createTextNode(d.text)));return c}function z(a,b){var d=a.header[b].length,c;a.footer&&a.footer[b].length>d&&(d=a.footer[b].length);for(var e=0,g=a.body.length;ed&&(d=c),40'+c),c=c.replace(/_dt_b_namespace_token_/g,":"));c=c.replace(//g,"");a[b]=c}})}var i=f.fn.dataTable,h={version:"1.0.4-TableTools2",clients:{},moviePath:"",nextId:1,$:function(a){"string"==typeof a&&(a=k.getElementById(a));a.addClass||(a.hide=function(){this.style.display="none"},a.show=function(){this.style.display=""},a.addClass=function(a){this.removeClass(a);this.className+=" "+a},a.removeClass=function(a){this.className=this.className.replace(RegExp("\\s*"+a+"\\s*")," ").replace(/^\s+/,"").replace(/\s+$/,"")},a.hasClass=
function(a){return!!this.className.match(RegExp("\\s*"+a+"\\s*"))});return a},setMoviePath:function(a){this.moviePath=a},dispatch:function(a,b,d){(a=this.clients[a])&&a.receiveEvent(b,d)},log:function(a){console.log("Flash: "+a)},register:function(a,b){this.clients[a]=b},getDOMObjectPosition:function(a){var b={left:0,top:0,width:a.width?a.width:a.offsetWidth,height:a.height?a.height:a.offsetHeight};""!==a.style.width&&(b.width=a.style.width.replace("px",""));""!==a.style.height&&(b.height=a.style.height.replace("px",
""));for(;a;)b.left+=a.offsetLeft,b.top+=a.offsetTop,a=a.offsetParent;return b},Client:function(a){this.handlers={};this.id=h.nextId++;this.movieId="ZeroClipboard_TableToolsMovie_"+this.id;h.register(this.id,this);a&&this.glue(a)}};h.Client.prototype={id:0,ready:!1,movie:null,clipText:"",fileName:"",action:"copy",handCursorEnabled:!0,cssEffects:!0,handlers:null,sized:!1,sheetName:"",glue:function(a,b){this.domElement=h.$(a);var d=99;this.domElement.style.zIndex&&(d=parseInt(this.domElement.style.zIndex,
10)+1);var c=h.getDOMObjectPosition(this.domElement);this.div=k.createElement("div");var e=this.div.style;e.position="absolute";e.left="0px";e.top="0px";e.width=c.width+"px";e.height=c.height+"px";e.zIndex=d;"undefined"!=typeof b&&""!==b&&(this.div.title=b);0!==c.width&&0!==c.height&&(this.sized=!0);this.domElement&&(this.domElement.appendChild(this.div),this.div.innerHTML=this.getHTML(c.width,c.height).replace(/&/g,"&"))},positionElement:function(){var a=h.getDOMObjectPosition(this.domElement),
b=this.div.style;b.position="absolute";b.width=a.width+"px";b.height=a.height+"px";0!==a.width&&0!==a.height&&(this.sized=!0,b=this.div.childNodes[0],b.width=a.width,b.height=a.height)},getHTML:function(a,b){var d="",c="id="+this.id+"&width="+a+"&height="+b;if(navigator.userAgent.match(/MSIE/))var e=location.href.match(/^https/i)?"https://":"http://",d=d+(' ');else d+=' ';return d},hide:function(){this.div&&(this.div.style.left="-2000px")},show:function(){this.reposition()},destroy:function(){var a=this;this.domElement&&this.div&&(g(this.div).remove(),this.div=this.domElement=null,g.each(h.clients,function(b,d){d===a&&delete h.clients[b]}))},
+a+'" height="'+b+'" name="'+this.movieId+'" align="middle" allowScriptAccess="always" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" flashvars="'+c+'" wmode="transparent" />';return d},hide:function(){this.div&&(this.div.style.left="-2000px")},show:function(){this.reposition()},destroy:function(){var a=this;this.domElement&&this.div&&(f(this.div).remove(),this.div=this.domElement=null,f.each(h.clients,function(b,d){d===a&&delete h.clients[b]}))},
reposition:function(a){a&&((this.domElement=h.$(a))||this.hide());if(this.domElement&&this.div){var a=h.getDOMObjectPosition(this.domElement),b=this.div.style;b.left=""+a.left+"px";b.top=""+a.top+"px"}},clearText:function(){this.clipText="";this.ready&&this.movie.clearText()},appendText:function(a){this.clipText+=a;this.ready&&this.movie.appendText(a)},setText:function(a){this.clipText=a;this.ready&&this.movie.setText(a)},setFileName:function(a){this.fileName=a;this.ready&&this.movie.setFileName(a)},
setSheetData:function(a){this.ready&&this.movie.setSheetData(JSON.stringify(a))},setAction:function(a){this.action=a;this.ready&&this.movie.setAction(a)},addEventListener:function(a,b){a=a.toString().toLowerCase().replace(/^on/,"");this.handlers[a]||(this.handlers[a]=[]);this.handlers[a].push(b)},setHandCursor:function(a){this.handCursorEnabled=a;this.ready&&this.movie.setHandCursor(a)},setCSSEffects:function(a){this.cssEffects=!!a},receiveEvent:function(a,b){var d,a=a.toString().toLowerCase().replace(/^on/,
"");switch(a){case "load":this.movie=k.getElementById(this.movieId);if(!this.movie){d=this;setTimeout(function(){d.receiveEvent("load",null)},1);return}if(!this.ready&&navigator.userAgent.match(/Firefox/)&&navigator.userAgent.match(/Windows/)){d=this;setTimeout(function(){d.receiveEvent("load",null)},100);this.ready=!0;return}this.ready=!0;this.movie.clearText();this.movie.appendText(this.clipText);this.movie.setFileName(this.fileName);this.movie.setAction(this.action);this.movie.setHandCursor(this.handCursorEnabled);
break;case "mouseover":this.domElement&&this.cssEffects&&this.recoverActive&&this.domElement.addClass("active");break;case "mouseout":this.domElement&&this.cssEffects&&(this.recoverActive=!1,this.domElement.hasClass("active")&&(this.domElement.removeClass("active"),this.recoverActive=!0));break;case "mousedown":this.domElement&&this.cssEffects&&this.domElement.addClass("active");break;case "mouseup":this.domElement&&this.cssEffects&&(this.domElement.removeClass("active"),this.recoverActive=!1)}if(this.handlers[a])for(var c=
-0,e=this.handlers[a].length;c ',"xl/_rels/workbook.xml.rels":' ',
"[Content_Types].xml":' ',
"xl/workbook.xml":' ',
-"xl/worksheets/sheet1.xml":' ',"xl/styles.xml":' '};
-j.Buttons.swfPath="//cdn.datatables.net/buttons/1.2.0/swf/flashExport.swf";j.Api.register("buttons.resize()",function(){g.each(h.clients,function(a,b){b.domElement!==o&&b.domElement.parentNode&&b.positionElement()})});j.ext.buttons.copyFlash=g.extend({},s,{className:"buttons-copy buttons-flash",text:function(a){return a.i18n("buttons.copy","Copy")},action:function(a,b,d,c){c._fromFlash&&(a=c._flash,d=x(b,c),c=c.customize?c.customize(d.str,c):d.str,a.setAction("copy"),r(a,c),b.buttons.info(b.i18n("buttons.copyTitle",
-"Copy to clipboard"),b.i18n("buttons.copySuccess",{_:"Copied %d rows to clipboard",1:"Copied 1 row to clipboard"},d.rows),3E3))},fieldSeparator:"\t",fieldBoundary:""});j.ext.buttons.csvFlash=g.extend({},s,{className:"buttons-csv buttons-flash",text:function(a){return a.i18n("buttons.csv","CSV")},action:function(a,b,d,c){a=c._flash;b=x(b,c);b=c.customize?c.customize(b.str,c):b.str;a.setAction("csv");a.setFileName(q(c));r(a,b)},escapeChar:'"'});j.ext.buttons.excelFlash=g.extend({},s,{className:"buttons-excel buttons-flash",
-text:function(a){return a.i18n("buttons.excel","Excel")},action:function(a,b,d,c){var a=c._flash,e=0,f=g.parseXML(p["xl/worksheets/sheet1.xml"]),h=f.getElementsByTagName("sheetData")[0],d={_rels:{".rels":g.parseXML(p["_rels/.rels"])},xl:{_rels:{"workbook.xml.rels":g.parseXML(p["xl/_rels/workbook.xml.rels"])},"workbook.xml":g.parseXML(p["xl/workbook.xml"]),"styles.xml":g.parseXML(p["xl/styles.xml"]),worksheets:{"sheet1.xml":f}},"[Content_Types].xml":g.parseXML(p["[Content_Types].xml"])},b=b.buttons.exportData(c.exportOptions),
-i,k,j=function(a){i=e+1;k=l(f,"row",{attr:{r:i}});for(var b=0,c=a.length;b /g,">").replace(/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F-\x9F]/g,
-""),d=l(f,"c",{attr:{t:"inlineStr",r:d},children:{row:l(f,"is",{children:{row:l(f,"t",{text:j})}})}}));k.appendChild(d)}h.appendChild(k);e++};g("sheets sheet",d.xl["workbook.xml"]).attr("name",z(c));c.customizeData&&c.customizeData(b);c.header&&(j(b.header,e),g("row c",f).attr("s","2"));for(var m=0,n=b.body.length;m ',"xl/styles.xml":' '};
+i.Buttons.swfPath="//cdn.datatables.net/buttons/1.2.0/swf/flashExport.swf";i.Api.register("buttons.resize()",function(){f.each(h.clients,function(a,b){b.domElement!==o&&b.domElement.parentNode&&b.positionElement()})});i.ext.buttons.copyFlash=f.extend({},t,{className:"buttons-copy buttons-flash",text:function(a){return a.i18n("buttons.copy","Copy")},action:function(a,b,d,c){c._fromFlash&&(a=c._flash,d=y(b,c),c=c.customize?c.customize(d.str,c):d.str,a.setAction("copy"),s(a,c),b.buttons.info(b.i18n("buttons.copyTitle",
+"Copy to clipboard"),b.i18n("buttons.copySuccess",{_:"Copied %d rows to clipboard",1:"Copied 1 row to clipboard"},d.rows),3E3))},fieldSeparator:"\t",fieldBoundary:""});i.ext.buttons.csvFlash=f.extend({},t,{className:"buttons-csv buttons-flash",text:function(a){return a.i18n("buttons.csv","CSV")},action:function(a,b,d,c){a=c._flash;b=y(b,c);b=c.customize?c.customize(b.str,c):b.str;a.setAction("csv");a.setFileName(r(c));s(a,b)},escapeChar:'"'});i.ext.buttons.excelFlash=f.extend({},t,{className:"buttons-excel buttons-flash",
+text:function(a){return a.i18n("buttons.excel","Excel")},action:function(a,b,d,c){var a=c._flash,e=0,g=f.parseXML(p["xl/worksheets/sheet1.xml"]),h=g.getElementsByTagName("sheetData")[0],d={_rels:{".rels":f.parseXML(p["_rels/.rels"])},xl:{_rels:{"workbook.xml.rels":f.parseXML(p["xl/_rels/workbook.xml.rels"])},"workbook.xml":f.parseXML(p["xl/workbook.xml"]),"styles.xml":f.parseXML(p["xl/styles.xml"]),worksheets:{"sheet1.xml":g}},"[Content_Types].xml":f.parseXML(p["[Content_Types].xml"])},b=b.buttons.exportData(c.exportOptions),
+j,k,i=function(a){j=e+1;k=l(g,"row",{attr:{r:j}});for(var b=0,c=a.length;b '+
'',
- "xl/styles.xml":
+ "xl/styles.xml":
''+
''+
''+
@@ -759,7 +759,7 @@ var excelStrings = {
''+
' '+
' '+
- ''+
+ ''+
' '+
' '+
' '+
@@ -810,6 +810,24 @@ var excelStrings = {
' '+
' '+
' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
+ ''+
+ ' '+
+ ' '+
' '+
''+
' '+
@@ -865,19 +883,20 @@ DataTable.ext.buttons.copyHtml5 = {
textarea[0].select();
try {
- document.execCommand( 'copy' );
+ var successful = document.execCommand( 'copy' );
hiddenDiv.remove();
- dt.buttons.info(
- dt.i18n( 'buttons.copyTitle', 'Copy to clipboard' ),
- dt.i18n( 'buttons.copySuccess', {
- 1: "Copied one row to clipboard",
- _: "Copied %d rows to clipboard"
+ if (successful) {
+ dt.buttons.info(
+ dt.i18n( 'buttons.copyTitle', 'Copy to clipboard' ),
+ dt.i18n( 'buttons.copySuccess', {
+ 1: 'Copied one row to clipboard',
+ _: 'Copied %d rows to clipboard'
}, exportData.rows ),
- 2000
- );
-
- return;
+ 2000
+ );
+ return;
+ }
}
catch (t) {}
}
@@ -931,6 +950,8 @@ DataTable.ext.buttons.copyHtml5 = {
// CSV export
//
DataTable.ext.buttons.csvHtml5 = {
+ bom: false,
+
className: 'buttons-csv buttons-html5',
available: function () {
@@ -963,9 +984,14 @@ DataTable.ext.buttons.csvHtml5 = {
charset = '';
}
+ if ( config.bom ) {
+ output = '\ufeff' + output;
+ }
+
_saveAs(
new Blob( [output], {type: 'text/csv'+charset} ),
- _filename( config )
+ _filename( config ),
+ true
);
},
@@ -995,7 +1021,7 @@ DataTable.ext.buttons.excelHtml5 = {
className: 'buttons-excel buttons-html5',
available: function () {
- return window.FileReader !== undefined && jsZip !== undefined && ! _isSafari() && _serialiser;
+ return window.FileReader !== undefined && _jsZip() !== undefined && ! _isSafari() && _serialiser;
},
text: function ( dt ) {
@@ -1068,11 +1094,7 @@ DataTable.ext.buttons.excelHtml5 = {
// Replace non standard characters for text output
var text = ! row[i].replace ?
row[i] :
- row[i]
- .replace(/&(?!amp;)/g, '&')
- .replace(/
/g, '>')
- .replace(/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F-\x9F]/g, '');
+ row[i].replace(/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F-\x9F]/g, '');
cell = _createNode( rels, 'c', {
attr: {
@@ -1137,7 +1159,8 @@ DataTable.ext.buttons.excelHtml5 = {
config.customize( xlsx );
}
- var zip = new jsZip();
+ var jszip = _jsZip();
+ var zip = new jszip();
var zipConfig = {
type: 'blob',
mimeType: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
@@ -1180,7 +1203,7 @@ DataTable.ext.buttons.pdfHtml5 = {
className: 'buttons-pdf buttons-html5',
available: function () {
- return window.FileReader !== undefined && pdfMake;
+ return window.FileReader !== undefined && _pdfMake();
},
text: function ( dt ) {
@@ -1261,11 +1284,11 @@ DataTable.ext.buttons.pdfHtml5 = {
};
if ( config.message ) {
- doc.content.unshift( {
- text: config.message,
- style: 'message',
- margin: [ 0, 0, 0, 12 ]
- } );
+ doc.content.unshift( {
+ text: typeof config.message == 'function' ? config.message(dt, button, config) : config.message,
+ style: 'message',
+ margin: [ 0, 0, 0, 12 ]
+ } );
}
if ( config.title ) {
@@ -1280,7 +1303,7 @@ DataTable.ext.buttons.pdfHtml5 = {
config.customize( doc, config );
}
- var pdf = pdfMake.createPdf( doc );
+ var pdf = _pdfMake().createPdf( doc );
if ( config.download === 'open' && ! _isSafari() ) {
pdf.open();
diff --git a/vendors/datatables.net-buttons/js/buttons.html5.min.js b/vendors/datatables.net-buttons/js/buttons.html5.min.js
index 3fc13418..d0c96fed 100644
--- a/vendors/datatables.net-buttons/js/buttons.html5.min.js
+++ b/vendors/datatables.net-buttons/js/buttons.html5.min.js
@@ -1,26 +1,26 @@
-(function(g){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(j){return g(j,window,document)}):"object"===typeof exports?module.exports=function(j,i,q,r){j||(j=window);if(!i||!i.fn.dataTable)i=require("datatables.net")(j,i).$;i.fn.dataTable.Buttons||require("datatables.net-buttons")(j,i);return g(i,j,j.document,q,r)}:g(jQuery,window,document)})(function(g,j,i,q,r,m){function E(a,b){v===m&&(v=-1===y.serializeToString(g.parseXML(F["xl/worksheets/sheet1.xml"])).indexOf("xmlns:r"));
-g.each(b,function(b,c){if(g.isPlainObject(c)){var e=a.folder(b);E(e,c)}else{if(v){var e=c.childNodes[0],f,h,n=[];for(f=e.attributes.length-1;0<=f;f--){h=e.attributes[f].nodeName;var k=e.attributes[f].nodeValue;-1!==h.indexOf(":")&&(n.push({name:h,value:k}),e.removeAttribute(h))}f=0;for(h=n.length;f'+
-e),e=e.replace(/_dt_b_namespace_token_/g,":"));e=e.replace(//g,"");a.file(b,e)}})}function o(a,b,d){var c=a.createElement(b);d&&(d.attr&&g(c).attr(d.attr),d.children&&g.each(d.children,function(a,b){c.appendChild(b)}),d.text&&c.appendChild(a.createTextNode(d.text)));return c}function N(a,b){var d=a.header[b].length,c;a.footer&&a.footer[b].length>d&&(d=a.footer[b].length);for(var e=0,f=a.body.length;ed&&
-(d=c),400&&(b=b+f);b=b+(e?e+(""+a[c]).replace(g,h+e)+e:a[c])}return b},j=b.header?k(c.header)+d:"",i=b.footer&&c.footer?d+k(c.footer):"",u=[],D=0,l=c.body.length;D ',
-"xl/_rels/workbook.xml.rels":' ',"[Content_Types].xml":' ',
+(function(g){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(i){return g(i,window,document)}):"object"===typeof exports?module.exports=function(i,j,t,u){i||(i=window);if(!j||!j.fn.dataTable)j=require("datatables.net")(i,j).$;j.fn.dataTable.Buttons||require("datatables.net-buttons")(i,j);return g(j,i,i.document,t,u)}:g(jQuery,window,document)})(function(g,i,j,t,u,o){function E(a,b){v===o&&(v=-1===y.serializeToString(g.parseXML(F["xl/worksheets/sheet1.xml"])).indexOf("xmlns:r"));
+g.each(b,function(b,c){if(g.isPlainObject(c)){var f=a.folder(b);E(f,c)}else{if(v){var f=c.childNodes[0],e,h,l=[];for(e=f.attributes.length-1;0<=e;e--){h=f.attributes[e].nodeName;var n=f.attributes[e].nodeValue;-1!==h.indexOf(":")&&(l.push({name:h,value:n}),f.removeAttribute(h))}e=0;for(h=l.length;e'+
+f),f=f.replace(/_dt_b_namespace_token_/g,":"));f=f.replace(//g,"");a.file(b,f)}})}function p(a,b,d){var c=a.createElement(b);d&&(d.attr&&g(c).attr(d.attr),d.children&&g.each(d.children,function(a,b){c.appendChild(b)}),d.text&&c.appendChild(a.createTextNode(d.text)));return c}function N(a,b){var d=a.header[b].length,c;a.footer&&a.footer[b].length>d&&(d=a.footer[b].length);for(var f=0,e=a.body.length;fd&&
+(d=c),40 ',"xl/_rels/workbook.xml.rels":' ',
+"[Content_Types].xml":' ',
"xl/workbook.xml":' ',
-"xl/worksheets/sheet1.xml":' ',"xl/styles.xml":' '};
-s.ext.buttons.copyHtml5={className:"buttons-copy buttons-html5",text:function(a){return a.i18n("buttons.copy","Copy")},action:function(a,b,d,c){var a=L(b,c),e=a.str,d=g("
").css({height:1,width:1,overflow:"hidden",position:"fixed",top:0,left:0});c.customize&&(e=c.customize(e,c));c=g("").val(e).appendTo(d);if(i.queryCommandSupported("copy")){d.appendTo(b.table().container());c[0].focus();c[0].select();try{i.execCommand("copy");d.remove();b.buttons.info(b.i18n("buttons.copyTitle",
-"Copy to clipboard"),b.i18n("buttons.copySuccess",{1:"Copied one row to clipboard",_:"Copied %d rows to clipboard"},a.rows),2E3);return}catch(f){}}a=g(""+b.i18n("buttons.copyKeys","Press ctrl or ⌘ + C to copy the table data to your system clipboard. To cancel, click this message or press escape.")+" ").append(d);b.buttons.info(b.i18n("buttons.copyTitle","Copy to clipboard"),a,0);c[0].focus();c[0].select();var h=g(a).closest(".dt-button-info"),j=function(){h.off("click.buttons-copy");
-g(i).off(".buttons-copy");b.buttons.info(false)};h.on("click.buttons-copy",j);g(i).on("keydown.buttons-copy",function(a){a.keyCode===27&&j()}).on("copy.buttons-copy cut.buttons-copy",function(){j()})},exportOptions:{},fieldSeparator:"\t",fieldBoundary:"",header:!0,footer:!1};s.ext.buttons.csvHtml5={className:"buttons-csv buttons-html5",available:function(){return j.FileReader!==m&&j.Blob},text:function(a){return a.i18n("buttons.csv","CSV")},action:function(a,b,d,c){a=L(b,c).str;b=c.charset;c.customize&&
-(a=c.customize(a,c));if(b!==false){b||(b=i.characterSet||i.charset);b&&(b=";charset="+b)}else b="";p(new Blob([a],{type:"text/csv"+b}),x(c))},filename:"*",extension:".csv",exportOptions:{},fieldSeparator:",",fieldBoundary:'"',escapeChar:'"',charset:null,header:!0,footer:!1};s.ext.buttons.excelHtml5={className:"buttons-excel buttons-html5",available:function(){return j.FileReader!==m&&q!==m&&!M()&&y},text:function(a){return a.i18n("buttons.excel","Excel")},action:function(a,b,d,c){var e=0,a=function(a){return g.parseXML(F[a])},
-f=a("xl/worksheets/sheet1.xml"),h=f.getElementsByTagName("sheetData")[0],a={_rels:{".rels":a("_rels/.rels")},xl:{_rels:{"workbook.xml.rels":a("xl/_rels/workbook.xml.rels")},"workbook.xml":a("xl/workbook.xml"),"styles.xml":a("xl/styles.xml"),worksheets:{"sheet1.xml":f}},"[Content_Types].xml":a("[Content_Types].xml")},b=b.buttons.exportData(c.exportOptions),j,k,d=function(a){j=e+1;k=o(f,"row",{attr:{r:j}});for(var b=0,c=a.length;b=0;){i=String.fromCharCode(d%26+65)+i;d=Math.floor(d/
-26)-1}d=i+""+j;if(a[b]===null||a[b]===m)a[b]="";if(typeof a[b]==="number"||a[b].match&&g.trim(a[b]).match(/^-?\d+(\.\d+)?$/)&&!g.trim(a[b]).match(/^0\d+/))d=o(f,"c",{attr:{t:"n",r:d},children:[o(f,"v",{text:a[b]})]});else{i=!a[b].replace?a[b]:a[b].replace(/&(?!amp;)/g,"&").replace(//g,">").replace(/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F-\x9F]/g,"");d=o(f,"c",{attr:{t:"inlineStr",r:d},children:{row:o(f,"is",{children:{row:o(f,"t",{text:i})}})}})}k.appendChild(d)}h.appendChild(k);
-e++};g("sheets sheet",a.xl["workbook.xml"]).attr("name",Q(c));c.customizeData&&c.customizeData(b);if(c.header){d(b.header,e);g("row c",f).attr("s","2")}for(var i=0,l=b.body.length;i ',"xl/styles.xml":' '};
+r.ext.buttons.copyHtml5={className:"buttons-copy buttons-html5",text:function(a){return a.i18n("buttons.copy","Copy")},action:function(a,b,d,c){var a=L(b,c),f=a.str,d=g("
").css({height:1,width:1,overflow:"hidden",position:"fixed",top:0,left:0});c.customize&&(f=c.customize(f,c));c=g("").val(f).appendTo(d);if(j.queryCommandSupported("copy")){d.appendTo(b.table().container());c[0].focus();c[0].select();try{var e=j.execCommand("copy");d.remove();if(e){b.buttons.info(b.i18n("buttons.copyTitle",
+"Copy to clipboard"),b.i18n("buttons.copySuccess",{1:"Copied one row to clipboard",_:"Copied %d rows to clipboard"},a.rows),2E3);return}}catch(h){}}e=g(""+b.i18n("buttons.copyKeys","Press ctrl or ⌘ + C to copy the table data to your system clipboard. To cancel, click this message or press escape.")+" ").append(d);b.buttons.info(b.i18n("buttons.copyTitle","Copy to clipboard"),e,0);c[0].focus();c[0].select();var l=g(e).closest(".dt-button-info"),i=function(){l.off("click.buttons-copy");
+g(j).off(".buttons-copy");b.buttons.info(!1)};l.on("click.buttons-copy",i);g(j).on("keydown.buttons-copy",function(a){27===a.keyCode&&i()}).on("copy.buttons-copy cut.buttons-copy",function(){i()})},exportOptions:{},fieldSeparator:"\t",fieldBoundary:"",header:!0,footer:!1};r.ext.buttons.csvHtml5={bom:!1,className:"buttons-csv buttons-html5",available:function(){return i.FileReader!==o&&i.Blob},text:function(a){return a.i18n("buttons.csv","CSV")},action:function(a,b,d,c){a=L(b,c).str;b=c.charset;c.customize&&
+(a=c.customize(a,c));!1!==b?(b||(b=j.characterSet||j.charset),b&&(b=";charset="+b)):b="";c.bom&&(a=""+a);q(new Blob([a],{type:"text/csv"+b}),x(c),!0)},filename:"*",extension:".csv",exportOptions:{},fieldSeparator:",",fieldBoundary:'"',escapeChar:'"',charset:null,header:!0,footer:!1};r.ext.buttons.excelHtml5={className:"buttons-excel buttons-html5",available:function(){return i.FileReader!==o&&(t||i.JSZip)!==o&&!M()&&y},text:function(a){return a.i18n("buttons.excel","Excel")},action:function(a,b,
+d,c){var f=0,a=function(a){return g.parseXML(F[a])},e=a("xl/worksheets/sheet1.xml"),h=e.getElementsByTagName("sheetData")[0],a={_rels:{".rels":a("_rels/.rels")},xl:{_rels:{"workbook.xml.rels":a("xl/_rels/workbook.xml.rels")},"workbook.xml":a("xl/workbook.xml"),"styles.xml":a("xl/styles.xml"),worksheets:{"sheet1.xml":e}},"[Content_Types].xml":a("[Content_Types].xml")},b=b.buttons.exportData(c.exportOptions),l,j,d=function(a){l=f+1;j=p(e,"row",{attr:{r:l}});for(var b=0,c=a.length;b'+
- ''+config.message+'
'+
+ ''+
+ (typeof config.message === 'function' ?
+ config.message( dt, button, config ) :
+ config.message
+ )+
+ '
'+
html;
- // $(win.document.body).html(
- // ''+title+' '+
- // ''+config.message+'
'+
- // html
- // );
if ( config.customize ) {
config.customize( win );
diff --git a/vendors/datatables.net-buttons/js/buttons.print.min.js b/vendors/datatables.net-buttons/js/buttons.print.min.js
index 06a16d5c..90dd5d3a 100644
--- a/vendors/datatables.net-buttons/js/buttons.print.min.js
+++ b/vendors/datatables.net-buttons/js/buttons.print.min.js
@@ -1,4 +1,4 @@
-(function(e){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(d){return e(d,window,document)}):"object"===typeof exports?module.exports=function(d,a){d||(d=window);if(!a||!a.fn.dataTable)a=require("datatables.net")(d,a).$;a.fn.dataTable.Buttons||require("datatables.net-buttons")(d,a);return e(a,d,d.document)}:e(jQuery,window,document)})(function(e,d,a){var i=e.fn.dataTable,g=a.createElement("a");i.ext.buttons.print={className:"buttons-print",
-text:function(c){return c.i18n("buttons.print","Print")},action:function(c,b,a,f){c=b.buttons.exportData(f.exportOptions);a=function(c,a){for(var b="",d=0,e=c.length;d"+c[d]+""+a+">";return b+" "};b='';f.header&&(b+=""+a(c.header,"th")+" ");for(var b=b+"",j=0,i=c.body.length;j";f.footer&&c.footer&&(b+=""+a(c.footer,"th")+" ");var h=d.open("",""),c=f.title;
-"function"===typeof c&&(c=c());-1!==c.indexOf("*")&&(c=c.replace("*",e("title").text()));h.document.close();var k=""+c+" ";e("style, link").each(function(){var c=k,b=e(this).clone()[0],a;"link"===b.nodeName.toLowerCase()&&(g.href=b.href,a=g.host,-1===a.indexOf("/")&&0!==g.pathname.indexOf("/")&&(a+="/"),b.href=g.protocol+"//"+a+g.pathname+g.search);k=c+b.outerHTML});h.document.head.innerHTML=k;h.document.body.innerHTML=""+c+" "+f.message+"
"+b;f.customize&&f.customize(h);
-setTimeout(function(){f.autoPrint&&(h.print(),h.close())},250)},title:"*",message:"",exportOptions:{},header:!0,footer:!1,autoPrint:!0,customize:null};return i.Buttons});
+(function(f){"function"===typeof define&&define.amd?define(["jquery","datatables.net","datatables.net-buttons"],function(e){return f(e,window,document)}):"object"===typeof exports?module.exports=function(e,c){e||(e=window);if(!c||!c.fn.dataTable)c=require("datatables.net")(e,c).$;c.fn.dataTable.Buttons||require("datatables.net-buttons")(e,c);return f(c,e,e.document)}:f(jQuery,window,document)})(function(f,e,c){var i=f.fn.dataTable,h=c.createElement("a");i.ext.buttons.print={className:"buttons-print",
+text:function(b){return b.i18n("buttons.print","Print")},action:function(b,c,i,d){var a=c.buttons.exportData(d.exportOptions),k=function(b,a){for(var c="",d=0,e=b.length;d"+b[d]+""+a+">";return c+" "},b='';d.header&&(b+=""+k(a.header,"th")+" ");for(var b=b+"",l=0,m=a.body.length;l";d.footer&&a.footer&&(b+=""+k(a.footer,"th")+" ");var g=e.open("",""),
+a=d.title;"function"===typeof a&&(a=a());-1!==a.indexOf("*")&&(a=a.replace("*",f("title").text()));g.document.close();var j=""+a+" ";f("style, link").each(function(){var c=j,b=f(this).clone()[0],a;"link"===b.nodeName.toLowerCase()&&(h.href=b.href,a=h.host,-1===a.indexOf("/")&&0!==h.pathname.indexOf("/")&&(a+="/"),b.href=h.protocol+"//"+a+h.pathname+h.search);j=c+b.outerHTML});try{g.document.head.innerHTML=j}catch(n){f(g.document.head).html(j)}g.document.body.innerHTML=""+a+" "+
+("function"===typeof d.message?d.message(c,i,d):d.message)+"
"+b;d.customize&&d.customize(g);setTimeout(function(){d.autoPrint&&(g.print(),g.close())},250)},title:"*",message:"",exportOptions:{},header:!0,footer:!1,autoPrint:!0,customize:null};return i.Buttons});
diff --git a/vendors/datatables.net-buttons/js/dataTables.buttons.js b/vendors/datatables.net-buttons/js/dataTables.buttons.js
index 628e7a7f..470fc002 100644
--- a/vendors/datatables.net-buttons/js/dataTables.buttons.js
+++ b/vendors/datatables.net-buttons/js/dataTables.buttons.js
@@ -1,4 +1,4 @@
-/*! Buttons for DataTables 1.2.1
+/*! Buttons for DataTables 1.2.2
* ©2016 SpryMedia Ltd - datatables.net/license
*/
@@ -879,7 +879,9 @@ Buttons.background = function ( show, className, fade ) {
else {
$('body > div.'+className)
.fadeOut( fade, function () {
- $(this).remove();
+ $(this)
+ .removeClass( className )
+ .remove();
} );
}
};
@@ -1116,7 +1118,7 @@ Buttons.defaults = {
* @type {string}
* @static
*/
-Buttons.version = '1.2.1';
+Buttons.version = '1.2.2';
$.extend( _dtButtons, {
@@ -1187,7 +1189,10 @@ $.extend( _dtButtons, {
$('div.dt-button-background').on( 'click.dtb-collection', function () {} );
$('body').on( 'click.dtb-collection', function (e) {
- if ( ! $(e.target).parents().andSelf().filter( config._collection ).length ) {
+ // andSelf is deprecated in jQ1.8, but we want 1.7 compat
+ var back = $.fn.addBack ? 'addBack' : 'andSelf';
+
+ if ( ! $(e.target).parents()[back]().filter( config._collection ).length ) {
config._collection
.fadeOut( config.fade, function () {
config._collection.detach();
@@ -1314,7 +1319,9 @@ DataTable.Api.register( 'buttons()', function ( group, selector ) {
group = undefined;
}
- return this.iterator( true, 'table', function ( ctx ) {
+ this.selector.buttonGroup = group;
+
+ var res = this.iterator( true, 'table', function ( ctx ) {
if ( ctx._buttons ) {
return Buttons.buttonSelector(
Buttons.instanceSelector( group, ctx._buttons ),
@@ -1322,6 +1329,9 @@ DataTable.Api.register( 'buttons()', function ( group, selector ) {
);
}
}, true );
+
+ res._groupSelector = group;
+ return res;
} );
// Individual button selector
@@ -1408,25 +1418,40 @@ DataTable.Api.registerPlural( 'buttons().trigger()', 'button().trigger()', funct
} );
} );
-// Get the container elements for the button sets selected
+// Get the container elements
DataTable.Api.registerPlural( 'buttons().containers()', 'buttons().container()', function () {
var jq = $();
+ var groupSelector = this._groupSelector;
- // jQuery will automatically reduce duplicates to a single entry
- $( this.each( function ( set ) {
- jq = jq.add( set.inst.container() );
- } ) );
+ // We need to use the group selector directly, since if there are no buttons
+ // the result set will be empty
+ this.iterator( true, 'table', function ( ctx ) {
+ if ( ctx._buttons ) {
+ var insts = Buttons.instanceSelector( groupSelector, ctx._buttons );
+
+ for ( var i=0, ien=insts.length ; i 0 ? cells.length / columns : 0;
var body = new Array( rows );
@@ -1576,7 +1607,7 @@ var _exportData = function ( dt, inOpts )
var row = new Array( columns );
for ( var j=0 ; j ").addClass(this.c.dom.container.className)};this._constructor()};d.extend(m.prototype,{action:function(a,b){var c=this._nodeToButton(a);if(b===l)return c.conf.action;c.conf.action=b;return this},active:function(a,b){var c=this._nodeToButton(a),e=this.c.dom.button.active,c=d(c.node);if(b===l)return c.hasClass(e);c.toggleClass(e,b===l?!0:b);return this},add:function(a,b){var c=
+(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(n){return d(n,window,document)}):"object"===typeof exports?module.exports=function(n,o){n||(n=window);if(!o||!o.fn.dataTable)o=require("datatables.net")(n,o).$;return d(o,n,n.document)}:d(jQuery,window,document)})(function(d,n,o,m){var i=d.fn.dataTable,u=0,v=0,j=i.ext.buttons,l=function(a,b){!0===b&&(b={});d.isArray(b)&&(b={buttons:b});this.c=d.extend(!0,{},l.defaults,b);b.buttons&&(this.c.buttons=b.buttons);
+this.s={dt:new i.Api(a),buttons:[],listenKeys:"",namespace:"dtb"+u++};this.dom={container:d("<"+this.c.dom.container.tag+"/>").addClass(this.c.dom.container.className)};this._constructor()};d.extend(l.prototype,{action:function(a,b){var c=this._nodeToButton(a);if(b===m)return c.conf.action;c.conf.action=b;return this},active:function(a,b){var c=this._nodeToButton(a),e=this.c.dom.button.active,c=d(c.node);if(b===m)return c.hasClass(e);c.toggleClass(e,b===m?!0:b);return this},add:function(a,b){var c=
this.s.buttons;if("string"===typeof b){for(var e=b.split("-"),c=this.s,d=0,h=e.length-1;d").addClass(s.className);p.conf._collection=p.collection;this._expandButton(p.buttons,p.conf.buttons,!0,e)}j.init&&j.init.call(g.button(p.node),g,d(p.node),j);h++}}}},_buildButton:function(a,b){var c=this.c.dom.button,e=this.c.dom.buttonLiner,g=this.c.dom.collection,h=this.s.dt,f=function(b){return"function"===typeof b?b(h,j,a):b};b&&g.button&&(c=g.button);b&&g.buttonLiner&&(e=g.buttonLiner);if(a.available&&!a.available(h,a))return!1;var q=function(a,
-b,c,e){e.action.call(b.button(c),a,b,c,e);d(b.table().node()).triggerHandler("buttons-action.dt",[b.button(c),b,c,e])},j=d("<"+c.tag+"/>").addClass(c.className).attr("tabindex",this.s.dt.settings()[0].iTabIndex).attr("aria-controls",this.s.dt.table().node().id).on("click.dtb",function(b){b.preventDefault();!j.hasClass(c.disabled)&&a.action&&q(b,h,j,a);j.blur()}).on("keyup.dtb",function(b){b.keyCode===13&&!j.hasClass(c.disabled)&&a.action&&q(b,h,j,a)});"a"===c.tag.toLowerCase()&&j.attr("href","#");
-e.tag?(g=d("<"+e.tag+"/>").html(f(a.text)).addClass(e.className),"a"===e.tag.toLowerCase()&&g.attr("href","#"),j.append(g)):j.html(f(a.text));!1===a.enabled&&j.addClass(c.disabled);a.className&&j.addClass(a.className);a.titleAttr&&j.attr("title",a.titleAttr);a.namespace||(a.namespace=".dt-button-"+v++);e=(e=this.c.dom.buttonContainer)&&e.tag?d("<"+e.tag+"/>").addClass(e.className).append(j):j;this._addKey(a);return{conf:a,node:j.get(0),inserter:e,buttons:[],inCollection:b,collection:null}},_nodeToButton:function(a,
-b){b||(b=this.s.buttons);for(var c=0,d=b.length;c ").addClass(b).css("display","none").appendTo("body").fadeIn(c):d("body > div."+b).fadeOut(c,function(){d(this).remove()})};m.instanceSelector=function(a,b){if(!a)return d.map(b,function(a){return a.inst});var c=[],e=d.map(b,
-function(a){return a.name}),g=function(a){if(d.isArray(a))for(var f=0,q=a.length;fg&&e._collection.css("left",a.left-(c-g))):(a=e._collection.height()/2,a>d(o).height()/2&&(a=d(o).height()/2),e._collection.css("marginTop",-1*a));e.background&&m.background(!0,e.backgroundClassName,e.fade);setTimeout(function(){d("div.dt-button-background").on("click.dtb-collection",
-function(){});d("body").on("click.dtb-collection",function(a){if(!d(a.target).parents().andSelf().filter(e._collection).length){e._collection.fadeOut(e.fade,function(){e._collection.detach()});d("div.dt-button-background").off("click.dtb-collection");m.background(false,e.backgroundClassName,e.fade);d("body").off("click.dtb-collection");b.off("buttons-action.b-internal")}})},10);if(e.autoClose)b.on("buttons-action.b-internal",function(){d("div.dt-button-background").click()})},background:!0,collectionLayout:"",
-backgroundClassName:"dt-button-background",autoClose:!1,fade:400},copy:function(a,b){if(k.copyHtml5)return"copyHtml5";if(k.copyFlash&&k.copyFlash.available(a,b))return"copyFlash"},csv:function(a,b){if(k.csvHtml5&&k.csvHtml5.available(a,b))return"csvHtml5";if(k.csvFlash&&k.csvFlash.available(a,b))return"csvFlash"},excel:function(a,b){if(k.excelHtml5&&k.excelHtml5.available(a,b))return"excelHtml5";if(k.excelFlash&&k.excelFlash.available(a,b))return"excelFlash"},pdf:function(a,b){if(k.pdfHtml5&&k.pdfHtml5.available(a,
-b))return"pdfHtml5";if(k.pdfFlash&&k.pdfFlash.available(a,b))return"pdfFlash"},pageLength:function(a){var a=a.settings()[0].aLengthMenu,b=d.isArray(a[0])?a[0]:a,c=d.isArray(a[0])?a[1]:a,e=function(a){return a.i18n("buttons.pageLength",{"-1":"Show all rows",_:"Show %d rows"},a.page.len())};return{extend:"collection",text:e,className:"buttons-page-length",autoClose:!0,buttons:d.map(b,function(a,b){return{text:c[b],action:function(b,c){c.page.len(a).draw()},init:function(b,c,d){var e=this,c=function(){e.active(b.page.len()===
-a)};b.on("length.dt"+d.namespace,c);c()},destroy:function(a,b,c){a.off("length.dt"+c.namespace)}}}),init:function(a,b,c){var d=this;a.on("length.dt"+c.namespace,function(){d.text(e(a))})},destroy:function(a,b,c){a.off("length.dt"+c.namespace)}}}});i.Api.register("buttons()",function(a,b){b===l&&(b=a,a=l);return this.iterator(!0,"table",function(c){if(c._buttons)return m.buttonSelector(m.instanceSelector(a,c._buttons),b)},!0)});i.Api.register("button()",function(a,b){var c=this.buttons(a,b);1 ').html(a?""+a+" ":"").append(d("
")["string"===typeof b?"html":
-"append"](b)).css("display","none").appendTo("body").fadeIn();c!==l&&0!==c&&(r=setTimeout(function(){e.buttons.info(!1)},c));return this});i.Api.register("buttons.exportData()",function(a){if(this.context.length){for(var b=new i.Api(this.context[0]),c=d.extend(!0,{},{rows:null,columns:"",modifier:{search:"applied",order:"applied"},orthogonal:"display",stripHtml:!0,stripNewlines:!0,decodeEntities:!0,trim:!0,format:{header:function(a){return e(a)},footer:function(a){return e(a)},body:function(a){return e(a)}}},
-a),e=function(a){if("string"!==typeof a)return a;c.stripHtml&&(a=a.replace(/<[^>]*>/g,""));c.trim&&(a=a.replace(/^\s+|\s+$/g,""));c.stripNewlines&&(a=a.replace(/\n/g," "));c.decodeEntities&&(t.innerHTML=a,a=t.value);return a},a=b.columns(c.columns).indexes().map(function(a){return c.format.header(b.column(a).header().innerHTML,a)}).toArray(),g=b.table().footer()?b.columns(c.columns).indexes().map(function(a){var d=b.column(a).footer();return c.format.footer(d?d.innerHTML:"",a)}).toArray():null,h=
-b.rows(c.rows,c.modifier).indexes().toArray(),h=b.cells(h,c.columns).render(c.orthogonal).toArray(),f=a.length,k=0")[0];d.fn.dataTable.Buttons=m;d.fn.DataTable.Buttons=m;d(n).on("init.dt plugin-init.dt",function(a,b){if("dt"===a.namespace){var c=b.oInit.buttons||i.defaults.buttons;c&&!b._buttons&&(new m(b,c)).container()}});i.ext.feature.push({fnInit:function(a){var a=
-new i.Api(a),b=a.init().buttons||i.defaults.buttons;return(new m(a,b)).container()},cFeature:"B"});return m});
+b.conf.destroy&&b.conf.destroy.call(e.button(a),e,d(a),b.conf);this._removeKey(b.conf);d(b.node).remove();a=d.inArray(b,c);c.splice(a,1);return this},text:function(a,b){var c=this._nodeToButton(a),e=this.c.dom.collection.buttonLiner,e=c.inCollection&&e&&e.tag?e.tag:this.c.dom.buttonLiner.tag,g=this.s.dt,h=d(c.node),f=function(a){return"function"===typeof a?a(g,h,c.conf):a};if(b===m)return f(c.conf.text);c.conf.text=b;e?h.children(e).html(f(b)):h.html(f(b));return this},_constructor:function(){var a=
+this,b=this.s.dt,c=b.settings()[0],e=this.c.buttons;c._buttons||(c._buttons=[]);c._buttons.push({inst:this,name:this.c.name});for(var c=0,g=e.length;c").addClass(s.className);p.conf._collection=p.collection;this._expandButton(p.buttons,p.conf.buttons,!0,e)}k.init&&k.init.call(g.button(p.node),g,d(p.node),k);h++}}}},_buildButton:function(a,b){var c=this.c.dom.button,e=this.c.dom.buttonLiner,g=this.c.dom.collection,h=this.s.dt,f=function(b){return"function"===typeof b?b(h,k,a):b};b&&g.button&&(c=g.button);b&&g.buttonLiner&&(e=g.buttonLiner);if(a.available&&!a.available(h,a))return!1;var r=function(a,
+b,c,e){e.action.call(b.button(c),a,b,c,e);d(b.table().node()).triggerHandler("buttons-action.dt",[b.button(c),b,c,e])},k=d("<"+c.tag+"/>").addClass(c.className).attr("tabindex",this.s.dt.settings()[0].iTabIndex).attr("aria-controls",this.s.dt.table().node().id).on("click.dtb",function(b){b.preventDefault();!k.hasClass(c.disabled)&&a.action&&r(b,h,k,a);k.blur()}).on("keyup.dtb",function(b){b.keyCode===13&&!k.hasClass(c.disabled)&&a.action&&r(b,h,k,a)});"a"===c.tag.toLowerCase()&&k.attr("href","#");
+e.tag?(g=d("<"+e.tag+"/>").html(f(a.text)).addClass(e.className),"a"===e.tag.toLowerCase()&&g.attr("href","#"),k.append(g)):k.html(f(a.text));!1===a.enabled&&k.addClass(c.disabled);a.className&&k.addClass(a.className);a.titleAttr&&k.attr("title",a.titleAttr);a.namespace||(a.namespace=".dt-button-"+v++);e=(e=this.c.dom.buttonContainer)&&e.tag?d("<"+e.tag+"/>").addClass(e.className).append(k):k;this._addKey(a);return{conf:a,node:k.get(0),inserter:e,buttons:[],inCollection:b,collection:null}},_nodeToButton:function(a,
+b){b||(b=this.s.buttons);for(var c=0,e=b.length;c ").addClass(b).css("display","none").appendTo("body").fadeIn(c):d("body > div."+b).fadeOut(c,function(){d(this).removeClass(b).remove()})};l.instanceSelector=function(a,b){if(!a)return d.map(b,function(a){return a.inst});var c=
+[],e=d.map(b,function(a){return a.name}),g=function(a){if(d.isArray(a))for(var f=0,r=a.length;fg&&e._collection.css("left",a.left-(c-g))):(a=e._collection.height()/2,a>d(n).height()/2&&(a=d(n).height()/2),e._collection.css("marginTop",-1*a));e.background&&l.background(!0,e.backgroundClassName,e.fade);setTimeout(function(){d("div.dt-button-background").on("click.dtb-collection",
+function(){});d("body").on("click.dtb-collection",function(a){var c=d.fn.addBack?"addBack":"andSelf";if(!d(a.target).parents()[c]().filter(e._collection).length){e._collection.fadeOut(e.fade,function(){e._collection.detach()});d("div.dt-button-background").off("click.dtb-collection");l.background(false,e.backgroundClassName,e.fade);d("body").off("click.dtb-collection");b.off("buttons-action.b-internal")}})},10);if(e.autoClose)b.on("buttons-action.b-internal",function(){d("div.dt-button-background").click()})},
+background:!0,collectionLayout:"",backgroundClassName:"dt-button-background",autoClose:!1,fade:400},copy:function(a,b){if(j.copyHtml5)return"copyHtml5";if(j.copyFlash&&j.copyFlash.available(a,b))return"copyFlash"},csv:function(a,b){if(j.csvHtml5&&j.csvHtml5.available(a,b))return"csvHtml5";if(j.csvFlash&&j.csvFlash.available(a,b))return"csvFlash"},excel:function(a,b){if(j.excelHtml5&&j.excelHtml5.available(a,b))return"excelHtml5";if(j.excelFlash&&j.excelFlash.available(a,b))return"excelFlash"},pdf:function(a,
+b){if(j.pdfHtml5&&j.pdfHtml5.available(a,b))return"pdfHtml5";if(j.pdfFlash&&j.pdfFlash.available(a,b))return"pdfFlash"},pageLength:function(a){var a=a.settings()[0].aLengthMenu,b=d.isArray(a[0])?a[0]:a,c=d.isArray(a[0])?a[1]:a,e=function(a){return a.i18n("buttons.pageLength",{"-1":"Show all rows",_:"Show %d rows"},a.page.len())};return{extend:"collection",text:e,className:"buttons-page-length",autoClose:!0,buttons:d.map(b,function(a,b){return{text:c[b],action:function(b,c){c.page.len(a).draw()},init:function(b,
+c,e){var d=this,c=function(){d.active(b.page.len()===a)};b.on("length.dt"+e.namespace,c);c()},destroy:function(a,b,c){a.off("length.dt"+c.namespace)}}}),init:function(a,b,c){var d=this;a.on("length.dt"+c.namespace,function(){d.text(e(a))})},destroy:function(a,b,c){a.off("length.dt"+c.namespace)}}}});i.Api.register("buttons()",function(a,b){b===m&&(b=a,a=m);this.selector.buttonGroup=a;var c=this.iterator(!0,"table",function(c){if(c._buttons)return l.buttonSelector(l.instanceSelector(a,c._buttons),
+b)},!0);c._groupSelector=a;return c});i.Api.register("button()",function(a,b){var c=this.buttons(a,b);1 ').html(a?""+a+" ":"").append(d("
")["string"===typeof b?"html":"append"](b)).css("display","none").appendTo("body").fadeIn();c!==m&&0!==c&&(q=setTimeout(function(){e.buttons.info(!1)},c));return this});i.Api.register("buttons.exportData()",function(a){if(this.context.length){for(var b=new i.Api(this.context[0]),
+c=d.extend(!0,{},{rows:null,columns:"",modifier:{search:"applied",order:"applied"},orthogonal:"display",stripHtml:!0,stripNewlines:!0,decodeEntities:!0,trim:!0,format:{header:function(a){return e(a)},footer:function(a){return e(a)},body:function(a){return e(a)}}},a),e=function(a){if("string"!==typeof a)return a;c.stripHtml&&(a=a.replace(/<[^>]*>/g,""));c.trim&&(a=a.replace(/^\s+|\s+$/g,""));c.stripNewlines&&(a=a.replace(/\n/g," "));c.decodeEntities&&(t.innerHTML=a,a=t.value);return a},a=b.columns(c.columns).indexes().map(function(a){var d=
+b.column(a).header();return c.format.header(d.innerHTML,a,d)}).toArray(),g=b.table().footer()?b.columns(c.columns).indexes().map(function(a){var d=b.column(a).footer();return c.format.footer(d?d.innerHTML:"",a,d)}).toArray():null,h=b.rows(c.rows,c.modifier).indexes().toArray(),f=b.cells(h,c.columns).render(c.orthogonal).toArray(),h=b.cells(h,c.columns).nodes().toArray(),j=a.length,k=0")[0];d.fn.dataTable.Buttons=l;d.fn.DataTable.Buttons=l;d(o).on("init.dt plugin-init.dt",function(a,b){if("dt"===a.namespace){var c=b.oInit.buttons||i.defaults.buttons;c&&!b._buttons&&(new l(b,c)).container()}});i.ext.feature.push({fnInit:function(a){var a=new i.Api(a),b=a.init().buttons||i.defaults.buttons;return(new l(a,b)).container()},cFeature:"B"});return l});