!function(e,i){"use strict";"function"==typeof define&&define.amd?define(["jquery","./grid.base"],function(t){return i(t,e)}):"object"==typeof module&&module.exports?module.exports=function(t,e){return t||(t=window),void 0===e&&(e="undefined"!=typeof window?require("jquery"):require("jquery")(t)),require("./grid.base"),i(e,t)}:i(jQuery,e)}("undefined"!=typeof window?window:this,function(m,t){"use strict";return t.tableToGrid=function(t,p){m(t).each(function(){var t,e,i,n,d,r,h,o,s=m(this),l=[],u=[],c=[],a=[],f=[];if(!this.grid){for(s.width("99%"),t=s.width(),e=m("tr td:first-child input[type=checkbox]:first",s),i=m("tr td:first-child input[type=radio]:first",s),d=!(n=0 tr",s).each(function(){var i={},n=0;m("td",m(this)).each(function(){if(0===n&&r){var t=m("input",m(this)),e=t.attr("value");a.push(e||c.length),t.is(":checked")&&f.push(e),i[l[n].name]=t.attr("value")}else i[l[n].name]=m(this).html();n++}),0