/*! battatech_excelexport 2014-11-25 */ !function(a){var b={containerid:null,datatype:"table",dataset:null,columns:null,returnUri:!1,worksheetName:"My Worksheet",encoding:"utf-8"},c=b;a.fn.battatech_excelexport=function(d){function e(){var a=c.datatype.toLowerCase();switch(f(a),a){case"table":l=i(g());break;case"json":l=i(h());break;case"xml":l=i(h());break;case"jqgrid":l=i(h())}return c.returnUri?l:void window.open(l)}function f(b){switch(b){case"table":break;case"json":m=c.dataset;break;case"xml":a(c.dataset).find("row").each(function(){var b={};null!=this.attributes&&this.attributes.length>0&&(a(this.attributes).each(function(){b[this.name]=this.value}),m.push(b))});break;case"jqgrid":a(c.dataset).find("rows > row").each(function(){var b={};null!=this.children&&this.children.length>0&&(a(this.children).each(function(){b[this.tagName]=a(this).text()}),m.push(b))})}}function g(){var b=a("
",b+=this.headertext,b+=" | ")}),b+="
---|
",b+=e[this.datafield],b+=" | ")}),b+="