jspreadsheet 8.0.61 → 8.0.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +2 -0
- package/dist/index.js +404 -404
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Jspreadsheet v8.0.
|
|
2
|
+
* Jspreadsheet v8.0.62
|
|
3
3
|
*
|
|
4
4
|
* Website: https://jspreadsheet.com
|
|
5
5
|
* Description: Create amazing web based spreadsheets.
|
|
@@ -19,15 +19,15 @@ var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.arrayIteratorImpl=function(z){v
|
|
|
19
19
|
$jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(z,D,F){if(z==Array.prototype||z==Object.prototype)return z;z[D]=F.value;return z};$jscomp.getGlobal=function(z){z=["object"==typeof globalThis&&globalThis,z,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var D=0;D<z.length;++D){var F=z[D];if(F&&F.Math==Math)return F}throw Error("Cannot find global object");};$jscomp.global=$jscomp.getGlobal(this);
|
|
20
20
|
$jscomp.IS_SYMBOL_NATIVE="function"===typeof Symbol&&"symbol"===typeof Symbol("x");$jscomp.TRUST_ES6_POLYFILLS=!$jscomp.ISOLATE_POLYFILLS||$jscomp.IS_SYMBOL_NATIVE;$jscomp.polyfills={};$jscomp.propertyToPolyfillSymbol={};$jscomp.POLYFILL_PREFIX="$jscp$";var $jscomp$lookupPolyfilledValue=function(z,D){var F=$jscomp.propertyToPolyfillSymbol[D];if(null==F)return z[D];F=z[F];return void 0!==F?F:z[D]};
|
|
21
21
|
$jscomp.polyfill=function(z,D,F,O){D&&($jscomp.ISOLATE_POLYFILLS?$jscomp.polyfillIsolated(z,D,F,O):$jscomp.polyfillUnisolated(z,D,F,O))};$jscomp.polyfillUnisolated=function(z,D,F,O){F=$jscomp.global;z=z.split(".");for(O=0;O<z.length-1;O++){var M=z[O];if(!(M in F))return;F=F[M]}z=z[z.length-1];O=F[z];D=D(O);D!=O&&null!=D&&$jscomp.defineProperty(F,z,{configurable:!0,writable:!0,value:D})};
|
|
22
|
-
$jscomp.polyfillIsolated=function(z,D,F,O){var M=z.split(".");z=1===M.length;O=M[0];O=!z&&O in $jscomp.polyfills?$jscomp.polyfills:$jscomp.global;for(var
|
|
22
|
+
$jscomp.polyfillIsolated=function(z,D,F,O){var M=z.split(".");z=1===M.length;O=M[0];O=!z&&O in $jscomp.polyfills?$jscomp.polyfills:$jscomp.global;for(var V=0;V<M.length-1;V++){var K=M[V];if(!(K in O))return;O=O[K]}M=M[M.length-1];F=$jscomp.IS_SYMBOL_NATIVE&&"es6"===F?O[M]:null;D=D(F);null!=D&&(z?$jscomp.defineProperty($jscomp.polyfills,M,{configurable:!0,writable:!0,value:D}):D!==F&&(void 0===$jscomp.propertyToPolyfillSymbol[M]&&(F=1E9*Math.random()>>>0,$jscomp.propertyToPolyfillSymbol[M]=$jscomp.IS_SYMBOL_NATIVE?
|
|
23
23
|
$jscomp.global.Symbol(M):$jscomp.POLYFILL_PREFIX+F+"$"+M),$jscomp.defineProperty(O,$jscomp.propertyToPolyfillSymbol[M],{configurable:!0,writable:!0,value:D})))};$jscomp.initSymbol=function(){};$jscomp.iteratorPrototype=function(z){z={next:z};z[Symbol.iterator]=function(){return this};return z};
|
|
24
|
-
$jscomp.iteratorFromArray=function(z,D){z instanceof String&&(z+="");var F=0,O=!1,M={next:function(){if(!O&&F<z.length){var
|
|
25
|
-
var _$
|
|
24
|
+
$jscomp.iteratorFromArray=function(z,D){z instanceof String&&(z+="");var F=0,O=!1,M={next:function(){if(!O&&F<z.length){var V=F++;return{value:D(V,z[V]),done:!1}}O=!0;return{done:!0,value:void 0}}};M[Symbol.iterator]=function(){return M};return M};$jscomp.polyfill("Array.prototype.values",function(z){return z?z:function(){return $jscomp.iteratorFromArray(this,function(D,F){return F})}},"es8","es3");
|
|
25
|
+
var _$_ac43=["use strict","{","}","","8.0.62","Base","https://jspreadsheet.com","Unlicensed","Jspreadsheet Pro\r\n"," edition ","\r\n","set","=","undefined","number","fullscreen","block","string","readonly","jss_hidden_index","div","right","10px","pointer","/v8",",","localhost",".","v8"," (Expired)","Licensed to: ","Premium","License required","A valid license is required","This version is not included on the scope of this license","Your license is expired","jspreadsheet","img","/jspreadsheet/","logo.png",
|
|
26
26
|
"none","status","data-x","data-y","px","X","goto","jss_scroll","jss_control","hidden","jss_freezed","get","colspan","center","300px","Jspreadsheet Pro","text","autocomplete","dropdown","GET","json","Jspreadsheet Alert: secureFormulas is set to false.","setConfig","insertRow","deleteRow","insertColumn","deleteColumn","moveRow","moveColumn","setMerge","removeMerge","setStyle","resetStyle","setWidth","setHeight","setHeader","setComments","setProperty","orderBy","setValue","renameWorksheet","moveWorksheet",
|
|
27
27
|
"onundo","onredo","object","function","contextMenu","toolbar","Jspreadsheet: cursor not in the viewport","oneditionstart","oncreateeditor","jss_focus","jss_formula","oneditionend","data-mask","data-value","inputmode","0","style","jss_input","contentEditable","onevent","setRowId","onchangerowid","setBorder","resetBorders","updateCells","setFormula","updateData","onbeforesave","POST","Authorization","Bearer ","disconected",": ","Sorry, something went wrong, refreshing your spreadsheet...","_top","onsave",
|
|
28
28
|
"persistence","?","?worksheet=","&worksheet=","add","remove","jss_cursor","selected","main","copying","onblur","onfocus","selection","onselection"," ","'","'!","!",":","jss_border","cloning","jss_border_","15","-2000px","#ccc","transparent","0px","tr","jss_group_container","td"," ",".jss_group","jss_group","+","width","Jspreadsheet: This column is part of a merged cell.","jss_dragging","1px","jss_helper_col","Jspreadsheet: This row is part of a merged cell","Jspreadsheet: Please clear your search before perform this action",
|
|
29
29
|
"51px","jss_helper_row","No cell selected","Invalid merged properties","onmerge","rowspan","Column name","data-title","onchangeheader","jss_filters_icon","col","setFooter","onchangefooter","setFooterValue","onchangefootervalue","resetFooter","setNestedHeaders","onchangenested","jss_nested","resetNestedHeaders","setNestedCell","onchangenestedcell","data-nested-x","data-nested-y","align","calendar","-","00:00:00",'"',"g",'""',"\t","oncopy","copy","color: initial","JSS: For better results, please allow pagination or tableOverflow.",
|
|
30
|
-
"onbeforepaste","onpaste","Export not allowed","\ufeff","text/csv;charset=utf-8;",".csv","a","download","setDefinedNames","#1a237e","#b71c1c","#880e4f","#1b5e20","#ff6f00","/","*","^","(","[","|","<",">","data-token","jss_picker","jss_object","input","contenteditable","
|
|
30
|
+
"onbeforepaste","onpaste","Export not allowed","\ufeff","text/csv;charset=utf-8;",".csv","a","download","setDefinedNames","#1a237e","#b71c1c","#880e4f","#1b5e20","#ff6f00","/","*","^","(","[","|","<",">","data-token","jss_picker","jss_object","input","contenteditable","active","last",'<b class="','" data-token="','">',"</b>","data-single","true","b","&",")","]","var "," = {};"," = ",";\n","; return ","#LOOP","Reference loop detected","#SELF","Self Reference detected","#ERROR","Table does not exist or is not loaded yet",
|
|
31
31
|
"#SPILL!","#REF!","$","Something went wrong","onafterchanges","checkbox","autonumber","radio","email","url","color","progressbar","rating","onbeforechange","onchange","oncreatecell","values","mergeCells",";","title","jss_unlocked","oncreaterow","jss_row","Jspreadsheet: Invalid origin or destination","onmoverow","Jspreadsheet: Insert row is not enabled in the table configuration","onbeforeinsertrow","onbeforeinsertrow returned false","oninsertrow","Jspreadsheet: Delete row is not enabled in the table configuration",
|
|
32
32
|
"onbeforedeleterow","onbeforedeleterow returned false","meta","cells","comments","ondeleterow","Jspreadsheet: Invalid origin","Jspreadsheet: Invalid destination","onmovecolumn","Jspreadsheet: Insert column is not enabled in the table configuration","onbeforeinsertcolumn","onbeforeinsertcolumn returned false","col_","oninsertcolumn","Jspreadsheet: Delete column is not enabled in the table configuration","Jspreadsheet: it is not possible to delete the last column","onbeforedeletecolumn","onbeforedeletecolumn returned false",
|
|
33
33
|
"ondeletecolumn","Jspreadsheet: Column does not exists.","; ","onchangestyle","No cell provided","onresetstyle","onbeforecomments","oncomments","setMeta","onchangemeta","resetMeta","onresetmeta","arrow-down","percent","numeric","onbeforesort","This action will destroy any existing merged cells. Are you sure?","onsort","arrow-up","jss_pagination","Jspreadsheet: No pagination defined","Jspreadsheet: pagination not defined","onbeforechangepage","onchangepage","No records found","jss_page","jss_page_selected",
|
|
@@ -38,410 +38,410 @@ var _$_5e7a=["use strict","{","}","","8.0.61","Base","https://jspreadsheet.com",
|
|
|
38
38
|
"format_align_center","format_align_right","format_align_justify",'<i class="material-icons">',"</i>","text-align","_","format_bold","font-weight","bold","format_color_text","format_color_fill","background-color","height","50px","Normal","Medium","Large","Extra","jss_row_medium","jss_row_large","jss_row_extra","fullscreen_exit","Toggle Fullscreen","border_all","border_outer","border_inner","border_horizontal","border_vertical","border_left","border_top","border_right","border_bottom","border_clear",
|
|
39
39
|
"black","border-left: ","px solid ","border-left: ; ","border-right: ","border-right: ; ","border-top: ","border-top: ; ","border-bottom: ","border-bottom: ; ","material-icons","color_lens",'<div style="height: ','px; width: 50px; background-color: black;"></div>',"80px","1","search","search_off","Toggle Search","onbeforecreateworksheet","There is one existing worksheet with the same name.","createWorksheet","oncreateworksheet","deleteWorksheet","ondeleteworksheet","It was not possible to rename worksheet due conflict name",
|
|
40
40
|
"onrenameworksheet","onmoveworksheet","onopenworksheet","jss_","TABLE","Element is not a table","colgroup > col","data-celltype","readOnly","name","id",":scope > thead > tr",":scope > tr, :scope > tbody > tr","data-formula","class","styleBold","; font-weight:bold;","font-weight:bold;","tfoot tr","\r","\n","jss_ignore","THEAD","TBODY","TFOOT","selectall","header-group","jtabs-headers","filters","footer","jtoolbar","DIV","data-current","html","jss_nowrap","insertHTML","<br/>\n","Process","A","mailto:",
|
|
41
|
-
"_blank","onclick","jclose","col-resize","row-resize","move","Cloud plugin not loaded.","jtabs","
|
|
42
|
-
"
|
|
43
|
-
(function(z,D){typeof exports===_$
|
|
44
|
-
{version:_$
|
|
45
|
-
a[k].name:k},K=function(k,a,c){var b;if(b=this.options.data[a]){var d=0<=k?
|
|
46
|
-
b=this.parent.element,d=this;else c=this.config,b=this.element,d=t.current?t.current:null;typeof k===_$
|
|
47
|
-
a){if(typeof k===_$
|
|
48
|
-
a.style.textAlign=_$
|
|
49
|
-
r)}var w=l(
|
|
50
|
-
7,u.license=f[1].name+_$
|
|
51
|
-
d.src=F().host+_$
|
|
52
|
-
25?(this.content.scrollLeft=this.content.scrollWidth,0<this.options.freezeColumns&&
|
|
53
|
-
ja.getWidth.call(this),e=this.content.offsetWidth,f=this.content.offsetHeight;this.width=b.width.call(this)+(d?d:1);this.height=b.height.call(this);this.tfoot.offsetHeight&&(this.height+=this.tfoot.offsetHeight+26);this.scrollX.firstChild.style.width=this.width+_$
|
|
54
|
-
this.height>f?_$
|
|
55
|
-
b.setY.call(this,b.height.call(this,d));c.call(this)}};b.setX=function(d){b.ignore=!0;this.scrollX.scrollLeft=d};b.setY=function(d){b.ignore=!0;this.scrollY.scrollTop=d};b.update=function(d,e){e==_$
|
|
56
|
-
5))),this.tbody.textContent=_$
|
|
57
|
-
0;h<this.options.columns.length;h++){if(d===h)return g;!1!==f[h].visible&&f[h].type!==_$
|
|
58
|
-
if(f>=e)return g}return e?g:f};return b}(),C=function(){var k=function(){k.reset.call(this,!0);k.renderX.call(this,0);k.renderY.call(this,0);ja.headers.call(this);0<this.options.pagination&&qa.update.call(this);T.update.call(this);this.refreshBorders();P.call(this)};k.limited=function(){return 1==this.options.tableOverflow||1==this.parent.config.fullscreen};k.refresh=function(){if(!this.tbody.lastChild)return!1;var a=parseInt(this.thead.lastChild.lastChild.getAttribute(_$
|
|
41
|
+
"_blank","onclick","jclose","col-resize","row-resize","move","Cloud plugin not loaded.","jtabs","jss_dialog","#","decimal","data-locale","%","jss_percent","\\[Red\\]","red","\\(","jss_notes","145px","tag","jss_dropdown_tags","jss_dropdown","multiple","image","<div class='jss_dropdown_icon' style='background-color: ","'></div>","orange","<div class='jss_dropdown_tag' style='background-color: ","'>","</div>","<","timepicker","YYYY-MM-DD","square","100px","false","FALSE","disabled","TRUE","jss_progressbar",
|
|
42
|
+
"min","max","jss_rating"," stars","star","href","IMG","round","100%","absolute","jfile",'<img src="','" alt="">',"jss_richtext","jss_tags","40px","#NOTFOUND","<img src='","' class='round small' />","Jspreadsheet: worksheet not found "];
|
|
43
|
+
(function(z,D){typeof exports===_$_ac43[84]&&typeof module!==_$_ac43[13]?module.exports=D():typeof define===_$_ac43[85]&&define.amd?define(D):z.jspreadsheet=z.jexcel=D()})(this,function(){_$_ac43[0];var z=function(k,a){k=jSuites.translate(k);if(a&&a.length)for(var c=0;c<a.length;c++)k=k.replace(_$_ac43[1]+c+_$_ac43[2],a[c]);return k},D=function(k,a){Array.isArray(k)&&(k=k[0]);k=k.replace(new RegExp(/'/g),_$_ac43[3]).toUpperCase();if(void 0===a)return window[k]?window[k]:null;window[k]=a},F=function(){var k=
|
|
44
|
+
{version:_$_ac43[4],edition:_$_ac43[5],host:_$_ac43[6],license:_$_ac43[7],print:function(){return[_$_ac43[8]+this.edition+_$_ac43[9]+this.version+_$_ac43[10]+this.host+_$_ac43[10]+this.license]}};return function(){return k}}(),O=function(k){var a=parseInt(k.y);if(k.id)var c=parseInt(k.id);else k.value&&(c=parseInt(k.value));0<c&&(this.rows[a].id=c,pa[_$_ac43[11]].call(this,c))},M=function(k){return(_$_ac43[3]+k).substr(0,1)===_$_ac43[12]},V=function(k){var a=this.options.columns;return a[k]&&a[k].name?
|
|
45
|
+
a[k].name:k},K=function(k,a,c){var b;if(b=this.options.data[a]){var d=0<=k?V.call(this,k):k;typeof c===_$_ac43[13]?c=typeof d===_$_ac43[14]?b[k]:jSuites.path.call(b,_$_ac43[3]+d):(typeof d===_$_ac43[14]?b[k]=c:jSuites.path.call(b,_$_ac43[3]+d,c),!M(c)&&this.records[a][k]&&(this.records[a][k].v=c))}else c=null;return c},N=function(k){return 0==this.config.editable||k&&0==k.options.editable?!1:(k=Da.call(this))?7<=k?!0:!1:!0},Ea=function(k){var a=_$_ac43[15];if(this.parent)var c=this.parent.config,
|
|
46
|
+
b=this.parent.element,d=this;else c=this.config,b=this.element,d=t.current?t.current:null;typeof k===_$_ac43[13]&&(k=!b.classList.contains(a));k?(b.classList.add(a),c.fullscreen=!0):(b.classList.remove(a),c.fullscreen=!1);d&&(d.tbody.innerHTML=_$_ac43[3],C.call(d),P.refresh.call(d),ca.update.call(d.parent,d))},Fa=function(k){var a=this.loading;null===k&&(k=a.style.display==_$_ac43[16]?!0:!1);a.style.display=k?_$_ac43[16]:_$_ac43[3];setTimeout(function(){a.style.display=_$_ac43[3]},1E3)},Aa=function(k,
|
|
47
|
+
a){if(typeof k===_$_ac43[17]){var c=A.getCoordsFromColumnName(k);c=this.records[c[1]][c[0]];if(c.element)k=c.element;else return typeof a===_$_ac43[13]?c.readonly:c.readonly=a?!0:!1}c=_$_ac43[18];k=k.classList;if(typeof a===_$_ac43[13])return k.contains(c)?!0:!1;a?k.add(c):k.remove(c)},Ga=function(k){var a=_$_ac43[19],c=this.table.classList;typeof k==_$_ac43[13]&&(k=!c.contains(a));k?c.remove(a):c.add(a);this.refreshBorders()},Da=function(k){if(void 0===k)return this.status;var a=document.createElement(_$_ac43[20]);
|
|
48
|
+
a.style.textAlign=_$_ac43[21];a.style.fontSize=_$_ac43[22];a.style.cursor=_$_ac43[23];a.onclick=function(){window.location.href=F().host+_$_ac43[24]};var c=null,b=[74,50,48,50,48,33].join(_$_ac43[3]);(function(e){c=1;try{if(e){var f=window.atob(e);f=f.split(_$_ac43[25]);if(f[1]){f[1]=window.atob(f[1]);var g=f[0];e=b;var h=f[1],l=jSuites.sha512,n=_$_ac43[3],p=_$_ac43[3];128<e.length&&(e=l(e));for(var q=0;128>q;q++){var r=e[q]?e[q].charCodeAt(0):0;n+=String.fromCharCode(54^r);p+=String.fromCharCode(92^
|
|
49
|
+
r)}var w=l(p+l(n+h));if(g!=w)c=3;else if(f[1]=JSON.parse(f[1]),f[1].date){var m=window.location.hostname||_$_ac43[26],v=m.split(_$_ac43[27]);m=m.split(_$_ac43[27]);2<m.length&&!jSuites.isNumeric(m[m.length-1])&&v.shift();v=v.join(_$_ac43[27]);m=m.join(_$_ac43[27]);if(-1==f[1].domain.indexOf(v)&&-1==f[1].domain.indexOf(m))c=4;else if(f[1].scope&&0<=f[1].scope.indexOf(_$_ac43[28])){m=new Date;v=parseInt(m.getTime()/1E3);var u=F();f[1].date<v?(c=f[1].date+2592E3<v&&!f[1].plan||f[1].date+15552E3<v?6:
|
|
50
|
+
7,u.license=f[1].name+_$_ac43[29]):(c=8,u.license=_$_ac43[30]+f[1].name,u.edition=3==f[1].plan||6==f[1].plan?_$_ac43[31]:_$_ac43[5])}else c=5}else c=4}else c=2}}catch(x){}})(k);k=_$_ac43[3];if(1==c)k=_$_ac43[32];else if(2==c||3==c||4==c)k=_$_ac43[33];else if(5==c)k=_$_ac43[34];else if(6==c||7==c)k=_$_ac43[35];a.appendChild(document.createTextNode(k));if(8>c)try{if(typeof sessionStorage!==_$_ac43[13]&&!sessionStorage.getItem(_$_ac43[36])){sessionStorage.setItem(_$_ac43[36],!0);var d=document.createElement(_$_ac43[37]);
|
|
51
|
+
d.src=F().host+_$_ac43[38]+_$_ac43[39];d.style.display=_$_ac43[40];a.appendChild(d)}}catch(e){}Object.defineProperty(this,_$_ac43[41],{value:c,writable:!1,configurable:!1,enumerable:!1,extensible:!1});F().edition===_$_ac43[31]&&(this.edition=1);return a},P=function(){var k=function(){if(this.edition){var d=this.edition.getAttribute(_$_ac43[42]),e=this.edition.getAttribute(_$_ac43[43]);Z.position.call(this,d,e)}},a=function(){this.scrollX.scrollWidth<this.scrollX.scrollLeft+this.scrollX.offsetWidth+
|
|
52
|
+
25?(this.content.scrollLeft=this.content.scrollWidth,0<this.options.freezeColumns&&da.refresh.call(this)):this.content.scrollLeft=0;k.call(this)},c=function(){var d=this.scrollY.scrollTop+this.scrollY.offsetHeight+13,e=this.tbody.lastChild.getAttribute(_$_ac43[43]),f=this.results?this.rows[this.results[this.results.length-1]].y:this.rows[this.rows.length-1].y;this.content.scrollTop=this.scrollY.scrollHeight<d&&e==f?this.content.scrollHeight:0;k.call(this)},b=function(){if(C.limited.call(this)){var d=
|
|
53
|
+
ja.getWidth.call(this),e=this.content.offsetWidth,f=this.content.offsetHeight;this.width=b.width.call(this)+(d?d:1);this.height=b.height.call(this);this.tfoot.offsetHeight&&(this.height+=this.tfoot.offsetHeight+26);this.scrollX.firstChild.style.width=this.width+_$_ac43[44];this.scrollY.firstChild.style.height=this.height+_$_ac43[44];this.scrollX.style.width=e+_$_ac43[44];this.scrollY.style.height=f+_$_ac43[44];this.scrollX.style.display=this.width>e?_$_ac43[3]:_$_ac43[40];this.scrollY.style.display=
|
|
54
|
+
this.height>f?_$_ac43[3]:_$_ac43[40]}else this.scrollX.style.display=_$_ac43[40],this.scrollY.style.display=_$_ac43[40]};b.refresh=function(){this.scrollY.scrollTop=0;this.scrollX.scrollLeft=0;b.call(this)};b.updateX=function(){if(b.event)return!1;var d=parseInt(this.thead.lastChild.children[(this.options.freezeColumns||0)+1].getAttribute(_$_ac43[42]));b.setX.call(this,b.width.call(this,d));a.call(this)};b.updateY=function(){if(b.event)return!1;if(this.tbody.firstChild){var d=parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43]));
|
|
55
|
+
b.setY.call(this,b.height.call(this,d));c.call(this)}};b.setX=function(d){b.ignore=!0;this.scrollX.scrollLeft=d};b.setY=function(d){b.ignore=!0;this.scrollY.scrollTop=d};b.update=function(d,e){e==_$_ac43[45]?(d=b.width.call(this,null,d.target.scrollLeft/(d.target.scrollWidth-this.content.offsetWidth)*this.width),C.reset.call(this),C[_$_ac43[46]].call(this,null,d),a.call(this)):(d=b.height.call(this,null,d.target.scrollTop/(d.target.scrollHeight-this.content.offsetHeight)*(this.height-(this.tbody.offsetHeight-
|
|
56
|
+
5))),this.tbody.textContent=_$_ac43[3],C[_$_ac43[46]].call(this,d),c.call(this))};b.build=function(d){var e=this,f=document.createElement(_$_ac43[20]),g=document.createElement(_$_ac43[20]);f.className=_$_ac43[47]+d;g.className=_$_ac43[48]+d;f.appendChild(g);d==_$_ac43[45]?f.style.height=_$_ac43[22]:f.style.width=_$_ac43[22];f.onscroll=function(h){if(b.ignore)return b.ignore=!1;b.event=!0;b.update.call(e,h,d);b.event=!1};return f};b.width=function(d,e){for(var f=this.options.columns,g=0,h=this.options.freezeColumns||
|
|
57
|
+
0;h<this.options.columns.length;h++){if(d===h)return g;!1!==f[h].visible&&f[h].type!==_$_ac43[49]&&(g+=parseInt(f[h].width));if(g>=e)return h}return e?h:g};b.height=function(d,e){var f=0,g=0;this.options.defaultRowHeight||(this.options.defaultRowHeight=26);for(var h=this.results?this.results:this.rows,l=0;l<h.length;l++){g=l;this.results&&(g=h[l]);if(d===g)return f;this.rows[g]&&!1!==this.rows[g].visible&&(f=this.rows[g].height?f+parseInt(this.rows[g].height):f+parseInt(this.options.defaultRowHeight));
|
|
58
|
+
if(f>=e)return g}return e?g:f};return b}(),C=function(){var k=function(){k.reset.call(this,!0);k.renderX.call(this,0);k.renderY.call(this,0);ja.headers.call(this);0<this.options.pagination&&qa.update.call(this);T.update.call(this);this.refreshBorders();P.call(this)};k.limited=function(){return 1==this.options.tableOverflow||1==this.parent.config.fullscreen};k.refresh=function(){if(!this.tbody.lastChild)return!1;var a=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_ac43[42]))+1,c=parseInt(this.tbody.lastChild.getAttribute(_$_ac43[43]));
|
|
59
59
|
this.results?(c=this.results.indexOf(c),c<this.results.length-1&&c++,c=this.results[c]):c++;k.renderX.call(this,a);k.renderY.call(this,c);k.adjustX.call(this,!1);k.adjustY.call(this,!1);P.call(this)};k.renderX=function(a,c,b){var d=this.options.columns,e=0,f=[],g=(this.options.freezeColumns||0)+1;1==this.parent.config.fullscreen?e=this.content.offsetWidth:1==this.options.tableOverflow&&(e=parseInt(this.options.tableWidth));var h=this.headerContainer.offsetWidth||0;for(b||(b=0);d[a]&&(!e||h<e||0<b);){!1!==
|
|
60
|
-
d[a].visible&&d[a].type!==_$
|
|
61
|
-
var g=parseInt(this.headerContainer.children[(this.options.freezeColumns||0)+1].getAttribute(_$
|
|
62
|
-
this.rows[a].height?(r.offsetHeight!==this.rows[a].height&&(this.rows[a].height=r.offsetHeight,
|
|
63
|
-
d[a],b,c)}if(this.options.footers)for(b=0;b<this.options.footers.length;b++)d=
|
|
64
|
-
if(this.tbody.children.length)for(b=0;b<this.tbody.children.length;b++)d=parseInt(this.tbody.children[b].getAttribute(_$
|
|
65
|
-
var f=ua.create.call(this,a,d);if(f.children.length)for(;f.children[e+1];)f.removeChild(f.lastChild);if(0<e){for(var g=0;g<e;g++)f.appendChild(I[_$
|
|
66
|
-
a;)a--;a++}this.tbody.textContent=_$
|
|
67
|
-
_$
|
|
68
|
-
if(c){a=null;var e=this.results?this.results[0]:0}else this.results?(e=this.results.indexOf(d),0<e&&e--,e=this.results[e]):(e=d,0<e&&e--);if(e<d){if(null==a)this.tbody.textContent=_$
|
|
69
|
-
function(a,c,b){var d=parseInt(this.tbody.lastChild.getAttribute(_$
|
|
70
|
-
e,c,a);k.adjustY.call(this,!0);b&&b.preventDefault();P.updateY.call(this)}this.refreshBorders()};k.removeColumns=function(a,c){var b=null===c?this.headerContainer.lastChild:this.headerContainer.children[c];if(b)b=parseInt(b.getAttribute(_$
|
|
71
|
-
d.length)for(e=0;e<d.length;e++)for(g=ka.getColumns.call(this,e),f=0;f<a;f++)if(void 0!==g[b+f]&&this.nested.content[e][g[b+f]]){var h=this.nested.content[e][g[b+f]].element,l=h.getAttribute(_$
|
|
60
|
+
d[a].visible&&d[a].type!==_$_ac43[49]&&(h+=parseInt(d[a].width));0<b&&b--;var l=X.getWidth.call(this,a,f);l>b&&(b=l);c?(k.renderColumn.call(this,a,g),a--):(k.renderColumn.call(this,a),a++)}X.batch.call(this,f)};k.renderY=function(a,c,b){var d=0,e=[];1==this.parent.config.fullscreen?d=this.content.offsetHeight:1==this.options.tableOverflow&&(d=parseInt(this.options.tableHeight));d&&(d-=this.thead.offsetHeight+4,this.tfoot.offsetHeight&&(d-=this.tfoot.offsetHeight+14));var f=this.tbody.offsetHeight;
|
|
61
|
+
var g=parseInt(this.headerContainer.children[(this.options.freezeColumns||0)+1].getAttribute(_$_ac43[42])),h=parseInt(this.headerContainer.lastChild.getAttribute(_$_ac43[42])),l=this.results?this.results.indexOf(a):a,n=parseInt(this.options.pagination)||0,p=this.tbody.children.length||0,q=!1;for(b||(b=0);this.options.data&&this.options.data[a]&&(!n||p<n||0<b)&&(!d||f<=d||0<b);){var r=k.renderRow.call(this,a,g,h);c?(this.tbody.insertBefore(r,this.tbody.firstChild),l--):(this.tbody.appendChild(r),l++);
|
|
62
|
+
this.rows[a].height?(r.offsetHeight!==this.rows[a].height&&(this.rows[a].height=r.offsetHeight,q=!0),f+=this.rows[a].height):(f+=this.rows[a].height=r.offsetHeight,q=!0);0<b&&b--;a=X.getHeight.call(this,a,e);a>b&&(b=a);a=this.results?this.results[l]:l;p++}X.batch.call(this,e);q&&P.call(this)};k.renderColumn=function(a,c,b){this.headers[a]||wa.create.call(this,a);if(this.options.nestedHeaders)for(b=0;b<this.options.nestedHeaders.length;b++){var d=ka.getColumns.call(this,b);void 0!==d[a]&&ka.renderCell.call(this,
|
|
63
|
+
d[a],b,c)}if(this.options.footers)for(b=0;b<this.options.footers.length;b++)d=W.create.call(this,a,b),null===c?this.tfoot.children[b].appendChild(d):this.tfoot.children[b].insertBefore(d,this.tfoot.children[b].children[c]);null===c?(this.headerContainer.appendChild(this.headers[a]),this.colgroupContainer.appendChild(this.colgroup[a])):(this.headerContainer.insertBefore(this.headers[a],this.headerContainer.children[c]),this.colgroupContainer.insertBefore(this.colgroup[a],this.colgroupContainer.children[c]));
|
|
64
|
+
if(this.tbody.children.length)for(b=0;b<this.tbody.children.length;b++)d=parseInt(this.tbody.children[b].getAttribute(_$_ac43[43])),(d=I[_$_ac43[51]].call(this,a,d))&&(null===c?this.tbody.children[b].appendChild(d):this.tbody.children[b].insertBefore(d,this.tbody.children[b].children[c]))};k.renderRow=function(a,c,b,d){var e=this.options.freezeColumns||0;null==c&&(c=parseInt(this.headerContainer.children[e+1].getAttribute(_$_ac43[42])));null==b&&(b=parseInt(this.headerContainer.lastChild.getAttribute(_$_ac43[42])));
|
|
65
|
+
var f=ua.create.call(this,a,d);if(f.children.length)for(;f.children[e+1];)f.removeChild(f.lastChild);if(0<e){for(var g=0;g<e;g++)f.appendChild(I[_$_ac43[51]].call(this,g,a));ja.update.call(this,a)}for(g=c;g<=b;g++)c=I[_$_ac43[51]].call(this,g,a,d),f.appendChild(c);return f};k.resetY=function(){if(this.options.pagination){this.pageNumber||(this.pageNumber=0);var a=this.options.pagination*this.pageNumber}else a=0;var c=0;if(this.merged.rows[a]){for(c=this.options.pagination;this.merged.rows[a]&&0<=
|
|
66
|
+
a;)a--;a++}this.tbody.textContent=_$_ac43[3];this.results&&this.results.length&&(a=this.results[a]);(!this.results||0<this.results.length)&&C.renderY.call(this,a,0,c);0<this.options.pagination&&qa.update.call(this);P.call(this);this.refreshBorders()};k[_$_ac43[46]]=function(a,c){if(null!==a&&0<=a)if(0<this.options.pagination)this.page(this.whichPage(a));else if(this.rows[a]||(a=this.options.data.length-1),!ua.attached.call(this,a)){if(this.merged.rows[a]){for(;this.merged.rows[a]&&0<=a;)a--;a++}this.tbody.textContent=
|
|
67
|
+
_$_ac43[3];k.renderY.call(this,a);0<a&&k.renderY.call(this,a-1,!0);P.updateY.call(this)}if(null!==c&&0<=c&&(this.options.columns[c]||(c=this.options.columns.length-1),a||(a=k.getY.call(this)),!I.attached.call(this,c,a))){if(this.merged.cols[c]){for(var b=a=0;b<this.rows.length;b++)this.records[b][c].merged&&(a=this.records[b][c].merged[0]);c-=a}k.reset.call(this);k.renderX.call(this,c);0<c&&k.renderX.call(this,c-1,!0);P.updateX.call(this)}this.refreshBorders()};k.pageUp=function(a,c,b){var d=parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43]));
|
|
68
|
+
if(c){a=null;var e=this.results?this.results[0]:0}else this.results?(e=this.results.indexOf(d),0<e&&e--,e=this.results[e]):(e=d,0<e&&e--);if(e<d){if(null==a)this.tbody.textContent=_$_ac43[3];else{d=a;if(this.options.mergeCells){var f=parseInt(this.tbody.lastChild.getAttribute(_$_ac43[43]));d+=X.getHeight.call(this,f)}for(f=0;f<d;f++)this.tbody.removeChild(this.tbody.lastChild)}k.renderY.call(this,e,!c,a);k.adjustY.call(this,!1);b&&b.preventDefault();P.updateY.call(this)}this.refreshBorders()};k.pageDown=
|
|
69
|
+
function(a,c,b){var d=parseInt(this.tbody.lastChild.getAttribute(_$_ac43[43]));if(c){a=null;var e=this.results?this.results[this.results.length-1]:this.rows.length-1}else this.results?(e=this.results.indexOf(d),e<this.results.length-1&&e++,e=this.results[e]):(e=d,d<this.options.data.length-1&&e++);if(e>d){if(null==a)this.tbody.textContent=_$_ac43[3];else{d=a;if(this.options.mergeCells){var f=parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43]));d+=X.getHeight.call(this,f)}for(f=0;f<d;f++)this.tbody.removeChild(this.tbody.firstChild)}k.renderY.call(this,
|
|
70
|
+
e,c,a);k.adjustY.call(this,!0);b&&b.preventDefault();P.updateY.call(this)}this.refreshBorders()};k.removeColumns=function(a,c){var b=null===c?this.headerContainer.lastChild:this.headerContainer.children[c];if(b)b=parseInt(b.getAttribute(_$_ac43[42]));else return!1;if(this.options.mergeCells){for(var d=0,e=b,f=0;f<a;f++){var g=X.getWidth.call(this,e);g>d&&(d=g);null===c?e--:e++}a+=d}a>=this.headerContainer.children.length&&(a=this.headerContainer.children.length-1);if((d=this.options.nestedHeaders)&&
|
|
71
|
+
d.length)for(e=0;e<d.length;e++)for(g=ka.getColumns.call(this,e),f=0;f<a;f++)if(void 0!==g[b+f]&&this.nested.content[e][g[b+f]]){var h=this.nested.content[e][g[b+f]].element,l=h.getAttribute(_$_ac43[52]);0<l&&l--;0<l?h.setAttribute(_$_ac43[52],l):h.parentNode&&this.thead.children[e].removeChild(h)}for(f=0;f<a;f++)null===c?(this.headerContainer.removeChild(this.headerContainer.lastChild),this.colgroupContainer.removeChild(this.colgroupContainer.lastChild)):this.headerContainer.children[c]&&(this.headerContainer.removeChild(this.headerContainer.children[c]),
|
|
72
72
|
this.colgroupContainer.removeChild(this.colgroupContainer.children[c]));for(e=0;e<this.tbody.children.length;e++)for(f=0;f<a;f++)null===c?this.tbody.children[e].removeChild(this.tbody.children[e].lastChild):this.tbody.children[e].children[c]&&this.tbody.children[e].removeChild(this.tbody.children[e].children[c]);for(e=0;e<this.tfoot.children.length;e++)for(f=0;f<a;f++)null===c?this.tfoot.children[e].removeChild(this.tfoot.children[e].lastChild):this.tfoot.children[e].removeChild(this.tfoot.children[e].children[c])};
|
|
73
|
-
k.pageLeft=function(a,c){var b=this.options.freezeColumns||0;if(c){a=null;var d=b}else d=parseInt(this.thead.lastChild.children[b+1].getAttribute(_$
|
|
74
|
-
1;d<this.options.columns.length&&(null==a?k.reset.call(this):k.removeColumns.call(this,a,b+1),k.renderX.call(this,d,c,a),k.adjustX.call(this,!0),P.updateX.call(this));this.refreshBorders()};k.reset=function(a){1<this.headerContainer.children.length&&(a=a?0:this.options.freezeColumns||0,k.removeColumns.call(this,this.headerContainer.children.length-(a+1),a+1))};k.getX=function(){if(this.thead.lastChild)return parseInt(this.thead.lastChild.children[1].getAttribute(_$
|
|
75
|
-
k.adjustX=function(a,c){var b=this.options.freezeColumns||0;if(a){c=this.options.columns.length-1;var d=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$
|
|
76
|
-
parseInt(this.tbody.lastChild.getAttribute(_$
|
|
77
|
-
var h=this.records[g][f];h.merged&&(f-=h.merged[0],g-=h.merged[1],a=this.records[g][f].element);g=this.content.getBoundingClientRect();h=a.getBoundingClientRect();var l=ja.getWidth.call(this),n=g.left+l,
|
|
78
|
-
!0,this.scrollY.scrollTop-=c-this.content.scrollTop)),!1;if(!l||!a.classList.contains(_$
|
|
79
|
-
null;k<d.length-1;)if(k++,!1!==d[k].visible&&d[k].type!==_$
|
|
80
|
-
_$
|
|
81
|
-
1,e),ua.attached.call(this,d)||C[_$
|
|
82
|
-
(h=this.results.indexOf(h),-1==h)){d=l;break a}for(;0<h;){h--;var
|
|
83
|
-
(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,1,e,f,b),this.updateSelectionFromCoords(c,d,e,f))};a.down=function(c,b,d){if(c)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var g=e,h=f,l=h,n=null;if(this.results){h=this.results.indexOf(h);if(-1==h){d=l;break a}var
|
|
84
|
-
this.rows[
|
|
73
|
+
k.pageLeft=function(a,c){var b=this.options.freezeColumns||0;if(c){a=null;var d=b}else d=parseInt(this.thead.lastChild.children[b+1].getAttribute(_$_ac43[42]))-1;d>=b&&(null==a?k.reset.call(this):k.removeColumns.call(this,a,null),k.renderX.call(this,d,!c,a),k.adjustX.call(this,!1),P.updateX.call(this));this.refreshBorders()};k.pageRight=function(a,c){var b=this.options.freezeColumns||0;if(c){a=null;var d=this.options.columns.length-1}else d=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_ac43[42]))+
|
|
74
|
+
1;d<this.options.columns.length&&(null==a?k.reset.call(this):k.removeColumns.call(this,a,b+1),k.renderX.call(this,d,c,a),k.adjustX.call(this,!0),P.updateX.call(this));this.refreshBorders()};k.reset=function(a){1<this.headerContainer.children.length&&(a=a?0:this.options.freezeColumns||0,k.removeColumns.call(this,this.headerContainer.children.length-(a+1),a+1))};k.getX=function(){if(this.thead.lastChild)return parseInt(this.thead.lastChild.children[1].getAttribute(_$_ac43[42]))};k.getY=function(){if(this.tbody.firstChild)return parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43]))};
|
|
75
|
+
k.adjustX=function(a,c){var b=this.options.freezeColumns||0;if(a){c=this.options.columns.length-1;var d=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$_ac43[42]));b=parseInt(this.tbody.firstChild.children[b+1].getAttribute(_$_ac43[42]))}else c=b,d=parseInt(this.tbody.firstChild.children[b+1].getAttribute(_$_ac43[42])),b=parseInt(this.tbody.firstChild.lastChild.getAttribute(_$_ac43[42]));d===c&&(a?b--:b++,k.renderX.call(this,b,a))};k.adjustY=function(a,c){if(a){c=this.rows.length-1;var b=
|
|
76
|
+
parseInt(this.tbody.lastChild.getAttribute(_$_ac43[43])),d=parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43]))}else c=0,b=parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43])),d=parseInt(this.tbody.lastChild.getAttribute(_$_ac43[43]));b==c&&(this.results?(c=this.results.indexOf(d),d=a?this.results[c-1]:this.results[c+1]):a?d--:d++,k.renderY.call(this,d,a))};k.isVisible=function(a,c){var b=this.thead.clientHeight;c||(c=1);var d=!1,e=!1,f=a.getAttribute(_$_ac43[42]),g=a.getAttribute(_$_ac43[43]);
|
|
77
|
+
var h=this.records[g][f];h.merged&&(f-=h.merged[0],g-=h.merged[1],a=this.records[g][f].element);g=this.content.getBoundingClientRect();h=a.getBoundingClientRect();var l=ja.getWidth.call(this),n=g.left+l,p=g.left+g.width;f=g.top+b;var q=g.top+g.height;var r=0;g=h.top;g>=f&&g<=q||(r++,d=!0);g=h.top+h.height;g>=f&&g<=q||r++;if(r>=c)return 2>c&&(c=this.content.scrollTop,0==d?q-f>h.height&&(this.content.scrollTop+=g-q+3,P.ignore=!0,this.scrollY.scrollTop+=g-q+3):(this.content.scrollTop=a.offsetTop-b,P.ignore=
|
|
78
|
+
!0,this.scrollY.scrollTop-=c-this.content.scrollTop)),!1;if(!l||!a.classList.contains(_$_ac43[50]))if(r=0,f=h.left,f>=n&&f<=p||(r++,e=!0),f=h.left+h.width,f>=n&&f<p||r++,r>=c)return 2>c&&(c=this.content.scrollLeft,0==e?p-n>h.width&&(this.content.scrollLeft+=f-p+3,P.ignore=!0,this.scrollX.scrollLeft+=f-p+3):(this.content.scrollLeft=a.offsetLeft-n-50,P.ignore=!0,this.scrollX.scrollLeft-=c-this.content.scrollLeft)),!1;return!0};return k}(),Ha=function(k,a,c,b){for(var d=this.options.columns,e=k,f,g=
|
|
79
|
+
null;k<d.length-1;)if(k++,!1!==d[k].visible&&d[k].type!==_$_ac43[49]){f=this.records[a]&&this.records[a][k].v===_$_ac43[3]?!1:!0;null===g&&(g=f);if(this.records[a]&&this.records[a][k].element&&this.records[a][k].element.style.display==_$_ac43[40]){if(this.records[a][k].merged){if(k==k+this.records[a][k].merged[0]&&(e=k,!c))break;f=!1}}else{if(c&&f!==g&&!b)break;if(c)e=k;else return k}g=f}return e},Ia=function(k,a,c,b){for(var d=this.options.columns,e=k,f,g=null;0<k;)if(k--,!1!==d[k].visible&&d[k].type!==
|
|
80
|
+
_$_ac43[49]){f=this.records[a]&&this.records[a][k].v===_$_ac43[3]?!1:!0;null===g&&(g=f);if(this.records[a]&&this.records[a][k].element&&this.records[a][k].element.style.display==_$_ac43[40]){if(this.records[a][k].merged){e=k-this.records[a][k].merged[0];if(!c)break;f=!0}}else{if(c&&f!==g&&!b)break;if(c)e=k;else return k}g=f}return e},Na=function(){var k=function(c,b,d,e){1==c||3==c?ua.attached.call(this,d)||(0<this.options.pagination?this.page(this.whichPage(d)):(1==c?C.pageUp.call(this,1,e):C.pageDown.call(this,
|
|
81
|
+
1,e),ua.attached.call(this,d)||C[_$_ac43[46]].call(this,d))):I.attached.call(this,b,d)||(0==c?C.pageLeft.call(this,1,e):C.pageRight.call(this,1,e),I.attached.call(this,b,d)||C[_$_ac43[46]].call(this,d,b))},a=function(c){c.up=a.up;c.down=a.down;c.right=a.right;c.left=a.left;c.last=a.last;c.first=a.first};a.up=function(c,b,d){if(c)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var g=e,h=f,l=h,n=null;if(this.results&&
|
|
82
|
+
(h=this.results.indexOf(h),-1==h)){d=l;break a}for(;0<h;){h--;var p=this.results?this.results[h]:h;if(!1!==this.rows[p].visible){var q=this.records[p][g].v===_$_ac43[3]?!1:!0;null===n&&(n=q);if(this.records[p][g].element&&this.records[p][g].element.style.display==_$_ac43[40]){if(this.records[p][g].merged){l=p-this.records[p][g].merged[1];if(!b)break;q=!0}}else if(b&&q!==n&&!d){d=l;break a}else if(b)l=this.records[p][g].merged?p-this.records[p][g].merged[1]:p;else{d=p;break a}n=q}}d=l}d!=f&&(f=d,c?
|
|
83
|
+
(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,1,e,f,b),this.updateSelectionFromCoords(c,d,e,f))};a.down=function(c,b,d){if(c)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);a:{var g=e,h=f,l=h,n=null;if(this.results){h=this.results.indexOf(h);if(-1==h){d=l;break a}var p=this.results.length-1}else p=this.rows.length-1;for(;h<p;){h++;var q=this.results?this.results[h]:h;if(!1!==
|
|
84
|
+
this.rows[q].visible){var r=this.records[q][g].v===_$_ac43[3]?!1:!0;null===n&&(n=r);if(this.records[q][g].element&&this.records[q][g].element.style.display==_$_ac43[40]){if(this.records[q][g].merged){if(!this.records[q][g].merged[1]&&(l=q,!b))break;r=!0}}else if(b&&r!==n&&!d){d=l;break a}else if(b)l=q;else{d=q;break a}n=r}}d=l}d!=f&&(f=d,c?(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,3,e,f,b),this.updateSelectionFromCoords(c,d,e,f))};a.right=function(c,b,d){if(c)var e=
|
|
85
85
|
parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);d=Ha.call(this,e,f,b,d);d!=e&&(e=d,c?(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,2,e,f,b),this.updateSelectionFromCoords(c,d,e,f))};a.left=function(c,b,d){if(c)var e=parseInt(this.selectedCell[2]),f=parseInt(this.selectedCell[3]);else e=parseInt(this.selectedCell[0]),f=parseInt(this.selectedCell[1]);d=Ia.call(this,e,f,b,d);d!=e&&(e=
|
|
86
86
|
d,c?(c=this.selectedCell[0],d=this.selectedCell[1]):(c=e,d=f,e=c,f=d),k.call(this,0,e,f,b),this.updateSelectionFromCoords(c,d,e,f))};a.first=function(c,b){b?a.up.call(this,c,!0,!0):a.left.call(this,c,!0,!0)};a.last=function(c,b){b?a.down.call(this,c,!0,!0):a.right.call(this,c,!0,!0)};return a}(),Oa=function(){return function(k){k.save=Ja;k.fullscreen=Ea;k.setReadOnly=Aa;k.getReadOnly=Aa;k.isReadOnly=Aa;k.setPlugins=function(a){la.call(this.parent,a)};k.showIndex=function(){Ga.call(this,!0)};k.hideIndex=
|
|
87
|
-
function(){Ga.call(this,!1)};k[_$
|
|
88
|
-
this.options.tableHeight);this.tbody.innerHTML=_$
|
|
89
|
-
rowResize:!0,rowDrag:!0,editable:!0,allowInsertRow:!0,allowManualInsertRow:!0,allowInsertColumn:!0,allowManualInsertColumn:!0,allowDeleteRow:!0,allowDeletingAllRows:!1,allowDeleteColumn:!0,allowRenameColumn:!0,allowComments:!0,selectionCopy:!0,mergeCells:{},search:!1,pagination:!1,paginationOptions:null,textOverflow:!1,tableOverflow:!1,tableHeight:_$
|
|
90
|
-
filters:!1,footers:null,validations:null,formify:null,applyMaskOnFooters:!1,pluginOptions:null,locked:!1,selectUnLockedCells:!0,selectLockedCells:!0},a={application:_$
|
|
87
|
+
function(){Ga.call(this,!1)};k[_$_ac43[46]]=C[_$_ac43[46]];k.undo=function(){Q.undo.call(k.parent)};k.redo=function(){Q.redo.call(k.parent)};k.isEditable=function(){return N.call(k.parent,k)};k.dispatch=function(){return B.apply(this.parent,arguments)};k.setViewport=function(a,c){this.options.tableOverflow=!0;a=parseInt(a);c=parseInt(c);100<a&&(this.options.tableWidth=a+_$_ac43[44],this.content.style.maxWidth=this.options.tableWidth);100<c&&(this.options.tableHeight=parseInt(c)+_$_ac43[44],this.content.style.maxHeight=
|
|
88
|
+
this.options.tableHeight);this.tbody.innerHTML=_$_ac43[3];C.call(this);P.refresh.call(this);ca.update.call(this.parent,this)}}}(),xa=function(){var k={logo:null,url:null,persistence:!1,sequence:!0,data:null,json:null,rows:[],columns:[],cells:{},role:null,nestedHeaders:null,defaultColWidth:100,defaultRowHeight:0,defaultColAlign:_$_ac43[53],minSpareRows:0,minSpareCols:0,minDimensions:[0,0],csv:null,csvFileName:_$_ac43[36],csvHeaders:!0,csvDelimiter:_$_ac43[25],columnSorting:!0,columnDrag:!0,columnResize:!0,
|
|
89
|
+
rowResize:!0,rowDrag:!0,editable:!0,allowInsertRow:!0,allowManualInsertRow:!0,allowInsertColumn:!0,allowManualInsertColumn:!0,allowDeleteRow:!0,allowDeletingAllRows:!1,allowDeleteColumn:!0,allowRenameColumn:!0,allowComments:!0,selectionCopy:!0,mergeCells:{},search:!1,pagination:!1,paginationOptions:null,textOverflow:!1,tableOverflow:!1,tableHeight:_$_ac43[54],tableWidth:null,comments:null,meta:null,style:{},freezeColumns:0,orderBy:null,worksheetId:_$_ac43[3],worksheetName:null,worksheetState:null,
|
|
90
|
+
filters:!1,footers:null,validations:null,formify:null,applyMaskOnFooters:!1,pluginOptions:null,locked:!1,selectUnLockedCells:!0,selectLockedCells:!0},a={application:_$_ac43[55],cloud:null,root:null,definedNames:{},sorting:null,server:null,toolbar:null,editable:!0,allowExport:!0,includeHeadersOnDownload:!1,forceUpdateOnPaste:!1,loadingSpin:!1,fullscreen:!1,secureFormulas:!0,parseFormulas:!0,debugFormulas:!1,editorFormulas:!0,autoIncrement:!0,autoCasting:!0,stripHTML:!1,tabs:!1,allowDeleteWorksheet:!0,
|
|
91
91
|
allowRenameWorksheet:!0,allowMoveWorksheet:!0,onevent:null,onclick:null,onload:null,onundo:null,onredo:null,onbeforesave:null,onsave:null,onbeforechange:null,onchange:null,onafterchanges:null,oncopy:null,onbeforepaste:null,onpaste:null,onbeforeinsertrow:null,oninsertrow:null,onbeforedeleterow:null,ondeleterow:null,onbeforeinsertcolumn:null,oninsertcolumn:null,onbeforedeletecolumn:null,ondeletecolumn:null,onmoverow:null,onmovecolumn:null,onresizerow:null,onresizecolumn:null,onselection:null,onbeforecomments:null,
|
|
92
92
|
oncomments:null,onbeforesort:null,onsort:null,onfocus:null,onblur:null,onmerge:null,onchangeheader:null,onchangefooter:null,onchangefootervalue:null,onchangenested:null,onchangenestedcell:null,oncreateeditor:null,oneditionstart:null,oneditionend:null,onchangestyle:null,onchangemeta:null,onbeforechangepage:null,onchangepage:null,onbeforecreateworksheet:null,oncreateworksheet:null,onrenameworksheet:null,ondeleteworksheet:null,onmoveworksheet:null,onopenworksheet:null,onchangerowid:null,onbeforesearch:null,
|
|
93
|
-
onsearch:null,onbeforefilter:null,onfilter:null,oncreatecell:null,oncreaterow:null,updateTable:null,contextMenu:null,parseTableFirstRowAsHeader:!1,parseTableAutoCellType:!1,plugins:null,wordWrap:!0,about:!0,license:null,worksheets:null},c=function(e,f){f=JSON.parse(JSON.stringify(f));var g={},h;for(h in f)e&&e.hasOwnProperty(h)?g[h]=e[h]:g[h]=f[h];return g},b=function(e){e&&(typeof e==_$
|
|
94
|
-
(this.options.data=[]);e=this.options.columns.length;if(this.options.data&&typeof this.options.data[0]!==_$
|
|
95
|
-
{type:_$
|
|
96
|
-
jSuites.ajax({url:this.options.columns[g].url,index:g,method:_$
|
|
97
|
-
group:f.parent.name,success:function(g){g=A.parseCSV(g,f.options.csvDelimiter);if(1==f.options.csvHeaders&&0<g.length)for(var h=g.shift(),l=0;l<h.length;l++)f.options.columns[l]||(f.options.columns[l]={type:_$
|
|
98
|
-
g)}}):b.call(f)};d[_$
|
|
99
|
-
(f=parseInt(e.minDimensions[0])-this.headers.length,0<f&&this.insertColumn(f),f=parseInt(e.minDimensions[1])-this.rows.length,0<f&&this.insertRow(f));G.call(this,_$
|
|
100
|
-
this.history[this.historyIndex--];if(a){this.ignoreHistory=!0;var c=a.worksheet;c.openWorksheet();var b=[];if(a.action==_$
|
|
101
|
-
a.data,a.extra),I.setAttributes.call(c,a.attributes);else if(a.action==_$
|
|
102
|
-
_$
|
|
103
|
-
_$
|
|
104
|
-
a.action==_$
|
|
105
|
-
a.newValue):a.action==_$
|
|
106
|
-
!1;B.call(this,_$
|
|
107
|
-
function(a,c){if(this.plugins){var b=Object.keys(this.plugins);if(b.length)for(var d=0;d<b.length;d++)if(typeof this.plugins[b[d]][a]==_$
|
|
108
|
-
a]};k.open=function(a,c,b){if(!N.call(this.parent,this))return!1;if(1!=a.classList.contains(_$
|
|
109
|
-
!1;C[_$
|
|
110
|
-
this.edition=a,f.classList.add(_$
|
|
111
|
-
b.element.innerText==_$
|
|
112
|
-
(b.onblur=null);b.children[0]&&b.children[0].onblur&&(b.children[0].onblur=null);b.update&&(b.update=null);
|
|
113
|
-
(e.setAttribute(_$
|
|
114
|
-
c.target.classList.add(_$
|
|
115
|
-
k.getId;a.setRowId=k.setId;a.getRowById=k.getRowById};k[_$
|
|
116
|
-
if(a.length){for(var d=0;d<a.length;d++)c=b[a[d]],this.rows[a[d]].id=c,k[_$
|
|
117
|
-
b[g]||(b[g]={id:h,row:g,data:{}});f=
|
|
118
|
-
h)return!1;if(h=B.call(f,_$
|
|
119
|
-
l.success?typeof e===_$
|
|
120
|
-
k=-1==k.indexOf(_$
|
|
121
|
-
d=b[0],e=b[1],f=b[2];b=b[3];k=k?_$
|
|
122
|
-
k.all;a.isSelected=k.isSelected;a.getHighlighted=k.getHighlighted;a.getRange=k.getRange};k.getHighlighted=function(){var a=this.borders;return(a=a.main)?[a.x1,a.y1,a.x2,a.y2]:null};k.isSelected=function(a,c,b){if(!b&&(b=this.getHighlighted(),!b))return!1;var d=b[0],e=b[1],f=b[2];b=b[3];f||(f=d);b||(b=e);return null==a?c>=e&&c<=b:null==c?a>=d&&a<=f:a>=d&&a<=f&&c>=e&&c<=b};k.reset=function(){if(this.selectedCell)a=1,this.edition&&
|
|
123
|
-
this.resetBorders(_$
|
|
124
|
-
a,c,b,d))return!1;if(null!=a){if(parseInt(a)<parseInt(b))var h=parseInt(a),l=parseInt(b);else h=parseInt(b),l=parseInt(a);if(parseInt(c)<parseInt(d))var n=parseInt(c),
|
|
125
|
-
h&&(h=
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
document.createElement(_$
|
|
129
|
-
|
|
130
|
-
this.thead.lastChild.children[1].style.display==_$
|
|
131
|
-
this.headers[u].offsetWidth,w=!0):n=this.thead.lastChild.children[r].offsetLeft+this.thead.lastChild.children[r].offsetWidth,l.element.style.borderRightColor=g==_$
|
|
132
|
-
this.rows[x].element.offsetHeight,l.element.style.borderBottomColor=g==_$
|
|
133
|
-
e>h&&(e-=h,e>n?h=
|
|
134
|
-
_$
|
|
135
|
-
b!=_$
|
|
136
|
-
k[_$
|
|
137
|
-
function(a,c){};return k}(),sa=function(){var k={start:function(a){if(!N.call(this.parent,this))return!1;if(null!==a.target.getAttribute(_$
|
|
138
|
-
this.getSelectedRows(!0);a=d.indexOf(parseInt(k.event.y));if(d.length&&-1<a)for(var e=0;e<d.length;e++)c.push(parseInt(this.rows[d[e]].element.offsetHeight));else d=[];-1==a?(d.push(k.event.y),c.push(k.event.h)):c[a]=k.event.h;this.setHeight(d,b,c)}else if(null!=k.event.x){b=parseInt(this.colgroup[k.event.x].getAttribute(_$
|
|
139
|
-
-1==a?(d.push(k.event.x),c.push(k.event.w)):c[a]=k.event.w;this.setWidth(d,b,c)}k.event=null},update:function(a){null!=k.event.y?(a=a.pageY-k.event.p,0<k.event.h+a&&(this.rows[k.event.y].element.style.height=k.event.h+a+_$
|
|
140
|
-
Ka=function(){var k={start:function(a){var c=this.parent.helper;a=parseInt(a.target.getAttribute(_$
|
|
141
|
-
c.style.display=_$
|
|
142
|
-
k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$
|
|
143
|
-
this.content.getBoundingClientRect();this.parent.helper.style.left=(a?c.left:c.right)-b.left+_$
|
|
144
|
-
b=this.rows[b].element.getBoundingClientRect(),c.style.display=_$
|
|
145
|
-
this.tbody.children[a].getAttribute(_$
|
|
146
|
-
null!=k.event.d&&k.event.y!=k.event.d&&(this.moveRow(k.event.y,k.event.d),this.updateSelectionFromCoords(0,k.event.d,this.options.columns.length-1,k.event.d)),this.parent.helper.classList.remove(_$
|
|
147
|
-
k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$
|
|
148
|
-
b=this.parent.element.getBoundingClientRect(),c=this.rows[c].element.getBoundingClientRect(),this.parent.helper.style.top=(d?c.top:c.bottom)-b.top+_$
|
|
149
|
-
this.parent.helper.style.left=(c?b.left:b.right)-d.left+_$
|
|
150
|
-
this.records[a][e].element&&!this.records[a][e].merged?!0:!1))}return d-1};k.getWidth=function(a,c){var b,d=1;if(this.merged.cols[a])for(var e=0;e<this.options.data.length;e++){var f=A.getColumnNameFromCoords(a,e);if(f=this.merged.cells[f])if(b=this.options.mergeCells[f])c&&void 0!==c[f]||(b[0]>d&&(d=b[0]),c&&(c[f]=this.records[e][a].element&&!this.records[e][a].merged?!0:!1))}return d-1};k[_$
|
|
151
|
-
c,b){if(!N.call(this.parent,this))return!1;this.options.mergeCells||(this.options.mergeCells={});var d,e=null,f={},g={},h={},l=!1;typeof a==_$
|
|
152
|
-
|
|
153
|
-
(l&&C[_$
|
|
154
|
-
{},d={};typeof a==_$
|
|
155
|
-
a=A.getCoordsFromColumnName(a);if(!this.records[a[1]][a[0]].merged||1==c)if(b=I[_$
|
|
156
|
-
_$
|
|
93
|
+
onsearch:null,onbeforefilter:null,onfilter:null,oncreatecell:null,oncreaterow:null,updateTable:null,contextMenu:null,parseTableFirstRowAsHeader:!1,parseTableAutoCellType:!1,plugins:null,wordWrap:!0,about:!0,license:null,worksheets:null},c=function(e,f){f=JSON.parse(JSON.stringify(f));var g={},h;for(h in f)e&&e.hasOwnProperty(h)?g[h]=e[h]:g[h]=f[h];return g},b=function(e){e&&(typeof e==_$_ac43[17]&&(e=JSON.parse(e)),this.options.data=e);this.options.json&&(this.options.data=this.options.json);this.options.data||
|
|
94
|
+
(this.options.data=[]);e=this.options.columns.length;if(this.options.data&&typeof this.options.data[0]!==_$_ac43[13]){var f=this.options.data[0].data&&0<Object.keys(this.options.data[0].data).length?Object.keys(this.options.data[0].data):Object.keys(this.options.data[0]);f.length>e&&(e=f.length)}this.options.minDimensions[0]>e&&(e=this.options.minDimensions[0]);e||(e=8);for(var g=0;g<e;g++)this.options.columns[g]?this.options.columns[g].type||(this.options.columns[g].type=_$_ac43[56]):this.options.columns[g]=
|
|
95
|
+
{type:_$_ac43[56]},this.options.columns[g].type==_$_ac43[57]&&(this.options.columns[g].type=_$_ac43[58],this.options.columns[g].autocomplete=!0),!this.options.columns[g].name&&f&&f[g]&&Number(f[g])!=f[g]&&(this.options.columns[g].name=f[g]),this.options.columns[g].width||(this.options.columns[g].width=this.options.defaultColWidth),this.options.columns[g].type!=_$_ac43[58]||this.options.columns[g].source||(this.options.columns[g].source=[]),this.options.columns[g].type==_$_ac43[58]&&this.options.columns[g].url&&
|
|
96
|
+
jSuites.ajax({url:this.options.columns[g].url,index:g,method:_$_ac43[59],dataType:_$_ac43[60],worksheet:this,group:this.parent.name,success:function(h){this.worksheet.options.columns[this.index].source=h}})},d=function(e){e.getConfig=d[_$_ac43[51]];e.setConfig=d[_$_ac43[11]]};d.spreadsheet=function(e){this.config=c(e,a);1!=this.config.secureFormulas&&console.log(_$_ac43[61])};d.worksheet=function(e){var f=this;f.options=c(e,k);f.options.csv?jSuites.ajax({url:f.options.csv,method:_$_ac43[59],dataType:_$_ac43[56],
|
|
97
|
+
group:f.parent.name,success:function(g){g=A.parseCSV(g,f.options.csvDelimiter);if(1==f.options.csvHeaders&&0<g.length)for(var h=g.shift(),l=0;l<h.length;l++)f.options.columns[l]||(f.options.columns[l]={type:_$_ac43[56],align:f.options.defaultColAlign,width:f.options.defaultColWidth}),typeof f.options.columns[l].title===_$_ac43[13]&&(f.options.columns[l].title=h[l]);b.call(f,g)}}):f.options.url?jSuites.ajax({url:f.options.url,method:_$_ac43[59],dataType:_$_ac43[60],group:f.parent.name,success:function(g){b.call(f,
|
|
98
|
+
g)}}):b.call(f)};d[_$_ac43[51]]=function(){return this.options};d[_$_ac43[11]]=function(e){typeof e==_$_ac43[17]&&(e=JSON.parse(e));if(this.parent){f=Object.keys(e);for(g=0;g<f.length;g++)typeof k[f[g]]!==_$_ac43[13]&&(this.options[f[g]]=e[f[g]]);!0===e.filters?Y.show.call(this):!1===e.filters&&Y.hide.call(this);!0===e.search?ma.show.call(this):!1===e.search&&ma.hide.call(this);!0===e.toolbar?ca.show.call(this.parent):!1===e.toolbar&&ca.hide.call(this.parent);e.minDimensions&&e.minDimensions[0]&&
|
|
99
|
+
(f=parseInt(e.minDimensions[0])-this.headers.length,0<f&&this.insertColumn(f),f=parseInt(e.minDimensions[1])-this.rows.length,0<f&&this.insertRow(f));G.call(this,_$_ac43[62],{data:JSON.stringify(e)})}else for(var f=Object.keys(e),g=0;g<f.length;g++)typeof a[f[g]]!==_$_ac43[13]&&(this.config[f[g]]=e[f[g]])};return d}(),Q=function(k){k=function(a){if(1!=this.ignoreHistory){var c=++this.historyIndex;this.history=this.history.slice(0,c+1);this.history[c]=a}};k.undo=function(){if(0<=this.historyIndex)var a=
|
|
100
|
+
this.history[this.historyIndex--];if(a){this.ignoreHistory=!0;var c=a.worksheet;c.openWorksheet();var b=[];if(a.action==_$_ac43[63])c.deleteRow(a.insertBefore?a.rowNumber:a.rowNumber+1,a.numOfRows);else if(a.action==_$_ac43[64])c.insertRow(a.numOfRows,a.rowNumber,1,a.data),I.setAttributes.call(c,a.attributes);else if(a.action==_$_ac43[65])c.deleteColumn(a.insertBefore?a.columnNumber:a.columnNumber+1,a.numOfColumns);else if(a.action==_$_ac43[66])c.insertColumn(a.numOfColumns,a.columnNumber,1,a.properties,
|
|
101
|
+
a.data,a.extra),I.setAttributes.call(c,a.attributes);else if(a.action==_$_ac43[67])c.moveRow(a.newValue,a.oldValue);else if(a.action==_$_ac43[68])c.moveColumn(a.newValue,a.oldValue);else if(a.action==_$_ac43[69])c.removeMerge(a.newValue,!0),c.setMerge(a.oldValue);else if(a.action==_$_ac43[70])c.setMerge(a.oldValue);else if(a.action==_$_ac43[71])c.setStyle(a.oldValue,null,null,1);else if(a.action==_$_ac43[72])c.setStyle(a.oldValue);else if(a.action==_$_ac43[73])c.setWidth(a.column,a.oldValue);else if(a.action==
|
|
102
|
+
_$_ac43[74])c.setHeight(a.row,a.oldValue);else if(a.action==_$_ac43[75])c.setHeader(a.column,a.oldValue);else if(a.action==_$_ac43[76])c.setComments(a.oldValue);else if(a.action==_$_ac43[77])c.setProperty(a.column,a.oldValue);else if(a.action==_$_ac43[78])c.orderBy(a.column,a.direction?0:1,a.oldValue);else if(a.action==_$_ac43[79]){for(var d=0;d<a.records.length;d++){var e={x:a.records[d].x,y:a.records[d].y,value:a.records[d].oldValue};a.records[d].oldStyle&&(e.style=a.records[d].oldStyle);b.push(e)}c.setValue(b)}else a.action==
|
|
103
|
+
_$_ac43[80]?c.renameWorksheet(a.index,a.oldValue):a.action==_$_ac43[81]&&c.moveWorksheet(a.t,a.f);a.selection&&c.updateSelectionFromCoords(a.selection);this.ignoreHistory=!1;B.call(this,_$_ac43[82],c,a)}};k.redo=function(){if(this.historyIndex<this.history.length-1)var a=this.history[++this.historyIndex];if(a){this.ignoreHistory=!0;var c=a.worksheet;c.openWorksheet();a.action==_$_ac43[63]?c.insertRow(a.numOfRows,a.rowNumber,a.insertBefore,a.data):a.action==_$_ac43[64]?c.deleteRow(a.rowNumber,a.numOfRows):
|
|
104
|
+
a.action==_$_ac43[65]?c.insertColumn(a.numOfColumns,a.columnNumber,a.insertBefore,a.properties,a.data):a.action==_$_ac43[66]?c.deleteColumn(a.columnNumber,a.numOfColumns):a.action==_$_ac43[67]?c.moveRow(a.oldValue,a.newValue):a.action==_$_ac43[68]?c.moveColumn(a.oldValue,a.newValue):a.action==_$_ac43[69]?c.setMerge(a.newValue):a.action==_$_ac43[70]?c.removeMerge(a.newValue):a.action==_$_ac43[71]?c.setStyle(a.newValue,null,null,1):a.action==_$_ac43[72]?c.resetStyle(a.cells):a.action==_$_ac43[73]?c.setWidth(a.column,
|
|
105
|
+
a.newValue):a.action==_$_ac43[74]?c.setHeight(a.row,a.newValue):a.action==_$_ac43[75]?c.setHeader(a.column,a.newValue):a.action==_$_ac43[76]?c.setComments(a.newValue):a.action==_$_ac43[77]?c.setProperty(a.column,a.newValue):a.action==_$_ac43[78]?c.orderBy(a.column,a.direction,a.newValue):a.action==_$_ac43[79]?c.setValue(a.records):a.action==_$_ac43[80]?c.renameWorksheet(a.index,a.newValue):a.action==_$_ac43[81]&&c.moveWorksheet(a.f,a.t);a.selection&&c.updateSelectionFromCoords(a.selection);this.ignoreHistory=
|
|
106
|
+
!1;B.call(this,_$_ac43[83],c,a)}};return k}(),la=function(){var k=function(a){var c=null;if(Array.isArray(a))c=a;else if(typeof a==_$_ac43[84]){c=[];var b=Object.keys(a);for(var d=0;d<b.length;d++)c.push({name:b[d],plugin:a[b[d]],options:{}})}if(c&&c.length)for(d=0;d<c.length;d++){if(c[d].name&&c[d].plugin){var e=c[d].name;var f=c[d].plugin;var g=c[d].options}typeof f===_$_ac43[85]&&(this.plugins[e]=f.call(t,this,g,this.config),typeof f.license==_$_ac43[85]&&t.license&&f.license(t.license))}};k.execute=
|
|
107
|
+
function(a,c){if(this.plugins){var b=Object.keys(this.plugins);if(b.length)for(var d=0;d<b.length;d++)if(typeof this.plugins[b[d]][a]==_$_ac43[85]){var e=this.plugins[b[d]][a].apply(this.plugins[b[d]],c);e&&(a==_$_ac43[86]&&(c[4]=e),a==_$_ac43[87]&&(c[0]=e))}return c}};return k}(),Z=function(){var k=function(a){a.getEditor=k[_$_ac43[51]];a.openEditor=k.open;a.closeEditor=k.close};k[_$_ac43[51]]=function(a,c){a=Ba.getOptions.call(this,a,c);return[a.type&&typeof a.type==_$_ac43[84]?a.type:t.editors[a.type],
|
|
108
|
+
a]};k.open=function(a,c,b){if(!N.call(this.parent,this))return!1;if(1!=a.classList.contains(_$_ac43[18])){var d=parseInt(a.getAttribute(_$_ac43[42])),e=parseInt(a.getAttribute(_$_ac43[43]));if(!0===this.options.locked){var f=A.getColumnNameFromCoords(d,e);if(!this.options.cells||!this.options.cells[f]||!1!==this.options.cells[f].locked)return!1}if(f=this.records[e][d].merged)d-=f[0],e-=f[1],a=this.records[e][d].element;if(!I.attached.call(this,d,e)){if(this.results&&0<this.results.length)return console.error(_$_ac43[88]),
|
|
109
|
+
!1;C[_$_ac43[46]].call(this,e,d)}k.position.call(this,d,e);f=this.parent.input;f.innerText=_$_ac43[3];B.call(this.parent,_$_ac43[89],this,a,d,e);c=1==c?_$_ac43[3]:K.call(this,d,e);var g=k[_$_ac43[51]].call(this,d,e),h=!0;typeof g[0].openEditor==_$_ac43[85]&&(!1===g[0].openEditor(a,c,d,e,this,g[1],b)?h=!1:B.call(this.parent,_$_ac43[90],this,a,d,e,f,g[1]));h&&(1==this.options.textOverflow&&(this.records[e][d].element.style.overflow=_$_ac43[49],0<d&&(this.records[e][d-1].element.style.overflow=_$_ac43[49])),
|
|
110
|
+
this.edition=a,f.classList.add(_$_ac43[91]),1==this.parent.config.editorFormulas&&M(c)&&(f.classList.add(_$_ac43[92]),fa.parse.call(this,f),a=document.createTextNode(_$_ac43[3]),f.appendChild(a),jSuites.focus(f)))}};k.close=function(a,c){null===a&&(a=this.edition);this.parent.input.classList.contains(_$_ac43[92])&&fa.close.call(this,this.parent.input);var b,d=parseInt(a.getAttribute(_$_ac43[42])),e=parseInt(a.getAttribute(_$_ac43[43]));1==this.options.textOverflow&&(b=this.records[e][d+1])&&b.element&&
|
|
111
|
+
b.element.innerText==_$_ac43[3]&&(this.records[e][d].element.style.overflow=_$_ac43[3]);b=k[_$_ac43[51]].call(this,d,e);if(1==c){var f=null;if(typeof b[0].closeEditor==_$_ac43[85]){var g=b[0].closeEditor(a,!0,d,e,this,b[1]);void 0!==g&&(f=g)}null!==f&&K.call(this,d,e)!=f&&this.setValue(a,f)}else b[0].closeEditor(a,!1,d,e,this,b[1]);B.call(this.parent,_$_ac43[93],this,a,d,e,f,c);b[1]&&typeof b[1].render==_$_ac43[85]&&b[1].render.call(this,a,this.records[e][d].v,d,e,this,b[1]);b=this.parent.input;b.onblur&&
|
|
112
|
+
(b.onblur=null);b.children[0]&&b.children[0].onblur&&(b.children[0].onblur=null);b.update&&(b.update=null);Z.build(this.parent);b.removeAttribute(_$_ac43[94]);b.removeAttribute(_$_ac43[95]);b.removeAttribute(_$_ac43[96]);this.edition=b.mask=null;this.refreshBorders()};k.position=function(a,c){var b=null;if(b=this.records[c][a].element){var d=this.parent.element.getBoundingClientRect();b=b.getBoundingClientRect();var e=this.parent.input;e.x=a;e.y=c;0==b.width&&0==b.height?e.style.opacity=_$_ac43[97]:
|
|
113
|
+
(e.setAttribute(_$_ac43[98],_$_ac43[3]),a=b.top-d.top+1,c=b.left-d.left+1,e.style.top=a+_$_ac43[44],e.style.left=c+_$_ac43[44],e.style.minWidth=b.width-1+_$_ac43[44],e.style.minHeight=b.height-1+_$_ac43[44],setTimeout(function(){e.focus()},0))}};k.build=function(a){a.input||(a.input=document.createElement(_$_ac43[20]));a.input.className=_$_ac43[99];a.input.setAttribute(_$_ac43[100],!0);a.input.innerText=_$_ac43[3];a.input.oninput=function(c){t.current.parent.config.editorFormulas=!0;M(c.target.innerText)?
|
|
114
|
+
c.target.classList.add(_$_ac43[92]):c.target.classList.contains(_$_ac43[92])&&fa.close.call(t.current,this)};return a.input};return k}(),B=function(k){if(!this.ignoreEvents){if(typeof this.config.onevent==_$_ac43[85])var a=this.config.onevent.apply(this,arguments);typeof this.config[k]==_$_ac43[85]&&(a=this.config[k].apply(this,Array.prototype.slice.call(arguments,1)));la.execute.call(this,_$_ac43[101],arguments)}return a},pa=function(){var k=function(a){a.sequence=0;a.getNextSequence=k.next;a.getRowId=
|
|
115
|
+
k.getId;a.setRowId=k.setId;a.getRowById=k.getRowById};k[_$_ac43[51]]=function(){return this.sequence};k[_$_ac43[11]]=function(a,c){if(a>this.sequence||c)this.sequence=a};k.next=function(){return 1==this.options.sequence?++this.sequence:null};k.reset=function(){this.sequence=0};k.getId=function(a){if(this.rows[a]&&this.rows[a].id)return this.rows[a].id;var c=this.getPrimaryKey();if(!1!==c)return K.call(this,c,a)};k.setId=function(a,c){if(void 0!==c&&0<=parseInt(a)){var b={};b[a]=c}else b=a;a=Object.keys(b);
|
|
116
|
+
if(a.length){for(var d=0;d<a.length;d++)c=b[a[d]],this.rows[a[d]].id=c,k[_$_ac43[11]].call(this,c);G.call(this,_$_ac43[102],[b]);B.call(this.parent,_$_ac43[103],this,b)}};k.getRowById=function(a,c){for(var b=0;b<this.rows.length;b++)if(k.getId.call(this,b)==a)return!0===c?this.rows[b]:this.options.data[b];return!1};return k}(),Ja=function(){var k=function(c){for(var b=[],d={},e=0;e<c.length;e++){var f=c[e].x,g=c[e].y,h=pa.getId.call(this,g);if(!h)if(d[g])h=d[g];else if(h=pa.next.call(this))d[g]=h;
|
|
117
|
+
b[g]||(b[g]={id:h,row:g,data:{}});f=V.call(this,f);b[g].data[f]=c[e].value}pa.setId.call(this,d);return b.filter(function(l){return null!=l})},a=function(c){var b=c[0];if(0<=[_$_ac43[104],_$_ac43[105],_$_ac43[102],_$_ac43[106]].indexOf(b))return!1;var d={};b==_$_ac43[79]||b==_$_ac43[107]?(b=_$_ac43[108],d[b]=k.call(this,c[1].data)):Array.isArray(c[1])&&1==c[1].length?d[b]=c[1][0]:d[b]=c[1];return d};return function(c,b,d,e){var f=this.parent,g=this;d=null;var h=a.call(this,b);if(h)b=h;else if(!1===
|
|
118
|
+
h)return!1;if(h=B.call(f,_$_ac43[109],f,g,b))b=h;else if(!1===h)return!1;Fa.call(f,!0);jSuites.ajax({url:c,method:_$_ac43[110],dataType:_$_ac43[60],data:{data:JSON.stringify(b)},queue:!0,beforeSend:function(l){d&&l.setRequestHeader(_$_ac43[111],_$_ac43[112]+d)},success:function(l){f.element.classList.contains(_$_ac43[113])&&f.element.classList.remove(_$_ac43[113]);l&&(l.message&&(l.name=f.config.application,jSuites.notification.isVisible()?console.log(l.name+_$_ac43[114]+l.message):jSuites.notification(l)),
|
|
119
|
+
l.success?typeof e===_$_ac43[85]?e(l):l.data&&Array.isArray(l.data)&&I.updateAll.call(g,l.data):l.error&&(alert(_$_ac43[115]),window.open(window.location.href,_$_ac43[116])));B.call(f,_$_ac43[117],f,g,b,l)},error:function(){f.element.classList.add(_$_ac43[113])}})}}(),G=function(){return function(){la.execute.call(this.parent,_$_ac43[118],[this,arguments[0],arguments[1]]);if(!this.parent.ignorePersistence){var k=null;if(this.parent.config.server){var a=this.parent.worksheets.indexOf(this);k=this.parent.config.server;
|
|
120
|
+
k=-1==k.indexOf(_$_ac43[119])?k+(_$_ac43[120]+a):k+(_$_ac43[121]+a)}else this.options.persistence&&(k=typeof this.options.persistence==_$_ac43[17]?this.options.persistence:this.options.url);k&&Ja.call(this,k,arguments)}}}(),ya=function(k){if(this.selectedCell){var a=this.selectedCell[0],c=this.selectedCell[1];this.records&&this.records[c]&&this.records[c][a]&&this.records[c][a].element||(this.selectedCell=this.getHighlighted(),a=this.selectedCell[0],c=this.selectedCell[1]);var b=this.getHighlighted(),
|
|
121
|
+
d=b[0],e=b[1],f=b[2];b=b[3];k=k?_$_ac43[122]:_$_ac43[123];if(this.records[c]&&this.records[c][a]&&this.records[c][a].element)this.records[c][a].element.classList[k](_$_ac43[124]);for(a=d;a<=f;a++)if(this.headers[a])this.headers[a].classList[k](_$_ac43[125]);for(;e<=b;e++)if(this.rows[e]&&this.rows[e].element)this.rows[e].element.classList[k](_$_ac43[125])}},ta=function(){var k=function(a){a.resetSelection=k.reset;a.updateSelection=k.fromElements;a.updateSelectionFromCoords=k[_$_ac43[11]];a.selectAll=
|
|
122
|
+
k.all;a.isSelected=k.isSelected;a.getHighlighted=k.getHighlighted;a.getRange=k.getRange};k.getHighlighted=function(){var a=this.borders;return(a=a.main)?[a.x1,a.y1,a.x2,a.y2]:null};k.isSelected=function(a,c,b){if(!b&&(b=this.getHighlighted(),!b))return!1;var d=b[0],e=b[1],f=b[2];b=b[3];f||(f=d);b||(b=e);return null==a?c>=e&&c<=b:null==c?a>=d&&a<=f:a>=d&&a<=f&&c>=e&&c<=b};k.reset=function(){if(this.selectedCell)a=1,this.edition&&Z.close.call(this,this.edition,!0),this.resetBorders(_$_ac43[126],!0),
|
|
123
|
+
this.resetBorders(_$_ac43[127],!0),this.selectedCell=null,1==a&&B.call(this.parent,_$_ac43[128],this);else var a=0;return a};k.refresh=function(){this.selectedCell&&k[_$_ac43[11]].call(this,this.selectedCell)};k.isValid=function(a,c,b,d){return!(a>=this.options.columns.length||c>=this.rows.length||b>=this.options.columns.length||d>=this.rows.length)};k[_$_ac43[11]]=function(a,c,b,d,e,f,g){f||(f=_$_ac43[126]);Array.isArray(a)&&(d=a[3],b=a[2],c=a[1],a=a[0]);null==b&&(b=a);null==d&&(d=c);if(!k.isValid.call(this,
|
|
124
|
+
a,c,b,d))return!1;if(null!=a){if(parseInt(a)<parseInt(b))var h=parseInt(a),l=parseInt(b);else h=parseInt(b),l=parseInt(a);if(parseInt(c)<parseInt(d))var n=parseInt(c),p=parseInt(d);else n=parseInt(d),p=parseInt(c);var q;var r={};if(this.options.mergeCells){for(var w=n;w<=p;w++)for(var m=h;m<=l;m++)if(q=this.records[w][m].merged)q=A.getColumnNameFromCoords(m-q[0],w-q[1]),r[q]=!0;w=Object.keys(r);if(w.length)for(m=0;m<w.length;m++)q=A.getCoordsFromColumnName(w[m]),r=this.options.mergeCells[w[m]],q[0]<
|
|
125
|
+
h&&(h=q[0]),q[0]+r[0]-1>l&&(l=q[0]+r[0]-1),q[1]<n&&(n=q[1]),q[1]+r[1]-1>p&&(p=q[1]+r[1]-1)}}f==_$_ac43[126]&&(this.selectedCell?(ya.call(this,!1),q=1):q=0,this.selectedCell=[a,c,b,d],this.records[d][b].element&&C.isVisible.call(this,this.records[d][b].element),Z.position.call(this,a,c),0==q&&B.call(this.parent,_$_ac43[129],this));da[_$_ac43[11]].call(this,h,n,l,p,f,g);f==_$_ac43[126]&&(la.execute.call(this.parent,_$_ac43[130],[this,h,n,l,p,e]),B.call(this.parent,_$_ac43[131],this,h,n,l,p,e),ca.update.call(this.parent,
|
|
126
|
+
t.current,this.selectedCell))};k.fromElements=function(a,c,b){var d=a.getAttribute(_$_ac43[42]);a=a.getAttribute(_$_ac43[43]);if(c){var e=c.getAttribute(_$_ac43[42]);c=c.getAttribute(_$_ac43[43])}else e=d,c=a;this.updateSelectionFromCoords(d,a,e,c,b)};k.all=function(){k[_$_ac43[11]].call(this,0,0,this.options.columns.length-1,this.records.length-1)};k.getRange=function(){var a=this.selectedCell;if(!a)return _$_ac43[3];var c=A.getColumnNameFromCoords(a[0],a[1]);a=A.getColumnNameFromCoords(a[2],a[3]);
|
|
127
|
+
var b=this.options.worksheetName;b=-1!=b.indexOf(_$_ac43[132])?_$_ac43[133]+b+_$_ac43[134]:b+_$_ac43[135];return c==a?b+c:b+t.helpers.getRangeFromTokens(t.helpers.getTokensFromRange(c+_$_ac43[136]+a))};return k}(),da=function(){var k=function(b){b.borders=[];b.setBorder=k[_$_ac43[11]];b.getBorder=k[_$_ac43[51]];b.resetBorders=k.reset;b.refreshBorders=k.refresh};k[_$_ac43[51]]=function(b){return this.borders[b]};var a=function(b,d,e,f,g,h){g||(g=0);if(!ta.isValid.call(this,b,d,e,f))return!1;if(this.borders[g])l=
|
|
128
|
+
this.borders[g];else{var l={};l.element=document.createElement(_$_ac43[20]);l.element.classList.add(_$_ac43[137]);g==_$_ac43[127]||g==_$_ac43[138]||g==_$_ac43[126]?l.element.classList.add(_$_ac43[139]+g):(h=h?h:jSuites.randomColor(!0),l.color=h,l.element.style.backgroundColor=h+_$_ac43[140],l.element.style.borderColor=h);this.content.appendChild(l.element)}l.x1=b;l.y1=d;l.x2=e;l.y2=f;h=this.headers[b]?this.headers[b].offsetLeft:0;var n=this.headers[e]?this.headers[e].offsetLeft:0,p=this.rows[d].element?
|
|
129
|
+
this.rows[d].element.offsetTop:0,q=this.rows[f].element?this.rows[f].element.offsetTop:0;l.element.style.top=_$_ac43[141];l.element.style.left=_$_ac43[141];l.active=0;var r=this.options.freezeColumns||0,w=!1,m=null,v=null,u=null,x=null;this.tbody.firstChild&&(v=parseInt(this.tbody.firstChild.getAttribute(_$_ac43[43])),x=parseInt(this.tbody.lastChild.getAttribute(_$_ac43[43])));this.thead.lastChild&&(m=parseInt(this.thead.lastChild.children[r+1].getAttribute(_$_ac43[42])),u=parseInt(this.thead.lastChild.lastChild.getAttribute(_$_ac43[42])),
|
|
130
|
+
this.thead.lastChild.children[1].style.display==_$_ac43[40]&&(m=Ha.call(this,m,v)),this.thead.lastChild.lastChild.style.display==_$_ac43[40]&&(u=Ia.call(this,u,x)));null==m||e<m&&b>=r||b>u||f<v||d>x||(h?l.element.style.borderLeftColor=l.color?l.color:_$_ac43[3]:(h=this.thead.lastChild.children[r+1].offsetLeft,l.element.style.borderLeftColor=g==_$_ac43[127]?_$_ac43[142]:_$_ac43[143]),n?(n+=this.headers[e].offsetWidth,l.element.style.borderRightColor=l.color?l.color:_$_ac43[3]):(e>u?(n=this.headers[u].offsetLeft+
|
|
131
|
+
this.headers[u].offsetWidth,w=!0):n=this.thead.lastChild.children[r].offsetLeft+this.thead.lastChild.children[r].offsetWidth,l.element.style.borderRightColor=g==_$_ac43[127]?_$_ac43[142]:_$_ac43[143]),n=n-h-1,p?l.element.style.borderTopColor=l.color?l.color:_$_ac43[3]:(p=this.tbody.firstChild.offsetTop,l.element.style.borderTopColor=g==_$_ac43[127]?_$_ac43[142]:_$_ac43[143]),q?(q+=this.rows[f].element.offsetHeight,l.element.style.borderBottomColor=l.color?l.color:_$_ac43[3]):(q=this.rows[x].element.offsetTop+
|
|
132
|
+
this.rows[x].element.offsetHeight,l.element.style.borderBottomColor=g==_$_ac43[127]?_$_ac43[142]:_$_ac43[143],w=!0),q=q-p-1,this.options.freezeColumns&&(l.element.style.borderLeftWidth=_$_ac43[3],l.element.style.borderRightWidth=_$_ac43[3],d=0<this.content.scrollLeft?ja.getWidth.call(this):0)&&(b=b<this.options.freezeColumns,e=e<this.options.freezeColumns,b&&e||!b&&e||(b&&!e?(e=d+this.content.scrollLeft,e>h+n&&(l.element.style.borderRightWidth=_$_ac43[144],n+=e-(h+n))):(e=d+this.content.scrollLeft,
|
|
133
|
+
e>h&&(e-=h,e>n?h=p=-2E3:(h=h+e+1,n-=e,l.element.style.borderLeftWidth=_$_ac43[144]))))),l.element.style.top=p+_$_ac43[44],l.element.style.left=h+_$_ac43[44],l.element.style.width=n+_$_ac43[44],l.element.style.height=q+_$_ac43[44],l.t=p,l.l=h,l.w=n,l.h=q,l.active=1);g==_$_ac43[126]&&(l.active&&1!=w?(this.corner.style.top=p+q-2+_$_ac43[44],this.corner.style.left=h+n-2+_$_ac43[44]):(this.corner.style.top=_$_ac43[141],this.corner.style.left=_$_ac43[141]));this.borders[g]=l},c=function(b,d){b.element.style.top=
|
|
134
|
+
_$_ac43[141];b.element.style.left=_$_ac43[141];b.active=0;d&&(b.x1=null,b.y1=null,b.x2=null,b.y2=null)};k[_$_ac43[11]]=function(b,d,e,f,g,h){a.call(this,b,d,e,f,g,h);g==_$_ac43[126]&&(ya.call(this,!0),G.call(this,_$_ac43[104],{x1:b,y1:d,x2:e,y2:f}))};k.reset=function(b,d){b&&b!=_$_ac43[126]||(this.corner.style.top=_$_ac43[141],this.corner.style.left=_$_ac43[141],ya.call(this,!1));if(b)this.borders[b]&&c(this.borders[b],d);else{d=Object.keys(this.borders);for(var e=0;e<d.length;e++)c(this.borders[d[e]])}b&&
|
|
135
|
+
b!=_$_ac43[126]||G.call(this,_$_ac43[105])};k.refresh=function(b){var d=this.borders;if(b)d[b]&&null!=d[b].x1&&a.call(this,d[b].x1,d[b].y1,d[b].x2,d[b].y2,b);else{b=Object.keys(d);for(var e=0;e<b.length;e++)d[b[e]]&&null!=d[b[e]].x1&&a.call(this,d[b[e]].x1,d[b[e]].y1,d[b[e]].x2,d[b[e]].y2,b[e])}this.edition&&(d=this.parent.input,Z.position.call(this,d.x,d.y))};k.destroy=function(b){var d;if(d=this.borders[b])d.element.remove(),delete this.borders[b]};return k}(),Pa=function(){var k=function(a){a.setGroup=
|
|
136
|
+
k[_$_ac43[11]];a.unsetGroup=k.unset};k[_$_ac43[11]]=function(a,c,b){0==a&&(b=document.createElement(_$_ac43[145]),b.classList.add(_$_ac43[146]),this.thead.insertBefore(b,this.thead.firstChild),a=document.createElement(_$_ac43[147]),a.innerHTML=_$_ac43[148],b.appendChild(a),a=document.createElement(_$_ac43[147]),b.appendChild(a),c=this.headers[c])&&(c=c.querySelector(_$_ac43[149]),c||(c=document.createElement(_$_ac43[20]),c.classList.add(_$_ac43[150]),c.innerText=_$_ac43[151],a.appendChild(c)))};k.unset=
|
|
137
|
+
function(a,c){};return k}(),sa=function(){var k={start:function(a){if(!N.call(this.parent,this))return!1;if(null!==a.target.getAttribute(_$_ac43[43])){var c=a.target.getAttribute(_$_ac43[43]);k.event={y:parseInt(c),h:a.target.offsetHeight,p:a.pageY}}else null!==a.target.getAttribute(_$_ac43[42])&&(c=a.target.getAttribute(_$_ac43[42]),k.event={x:parseInt(c),w:a.target.offsetWidth,p:a.pageX})},end:function(a){var c=[];if(null!=k.event.y){var b=parseInt(this.rows[k.event.y].element.offsetHeight);var d=
|
|
138
|
+
this.getSelectedRows(!0);a=d.indexOf(parseInt(k.event.y));if(d.length&&-1<a)for(var e=0;e<d.length;e++)c.push(parseInt(this.rows[d[e]].element.offsetHeight));else d=[];-1==a?(d.push(k.event.y),c.push(k.event.h)):c[a]=k.event.h;this.setHeight(d,b,c)}else if(null!=k.event.x){b=parseInt(this.colgroup[k.event.x].getAttribute(_$_ac43[152]));d=this.getSelectedColumns();a=d.indexOf(parseInt(k.event.x));if(d.length&&-1<a)for(e=0;e<d.length;e++)c.push(parseInt(this.options.columns[d[e]].width));else d=[];
|
|
139
|
+
-1==a?(d.push(k.event.x),c.push(k.event.w)):c[a]=k.event.w;this.setWidth(d,b,c)}k.event=null},update:function(a){null!=k.event.y?(a=a.pageY-k.event.p,0<k.event.h+a&&(this.rows[k.event.y].element.style.height=k.event.h+a+_$_ac43[44],this.refreshBorders())):null!=k.event.x&&(a=a.pageX-k.event.p,0<k.event.w+a&&(this.colgroup[k.event.x].setAttribute(_$_ac43[152],k.event.w+a),0<this.options.freezeColumns&&ja[_$_ac43[11]].call(this),this.refreshBorders()))},cancel:function(){k.end.call(this)}};return k}(),
|
|
140
|
+
Ka=function(){var k={start:function(a){var c=this.parent.helper;a=parseInt(a.target.getAttribute(_$_ac43[42]));if(this.merged.cols[a])console.error(_$_ac43[153]);else{k.event={x:a,d:a};this.headers[a].classList.add(_$_ac43[154]);for(var b=0;b<this.tbody.children.length;b++){var d=this.tbody.children[b].getAttribute(_$_ac43[43]);this.records[d][a].element.classList.add(_$_ac43[154])}b=this.parent.element.getBoundingClientRect();a=this.headers[a].getBoundingClientRect();d=this.content.getBoundingClientRect();
|
|
141
|
+
c.style.display=_$_ac43[16];c.style.top=d.top-b.top+_$_ac43[44];c.style.left=a.left-d.left+_$_ac43[44];c.style.width=_$_ac43[155];c.style.height=d.height+_$_ac43[44];c.classList.add(_$_ac43[156])}},end:function(){this.headers[k.event.x].classList.remove(_$_ac43[154]);for(var a=0;a<this.tbody.children.length;a++){var c=this.tbody.children[a].getAttribute(_$_ac43[43]);this.records[c][k.event.x].element.classList.remove(_$_ac43[154])}null!=k.event.d&&k.event.x!=k.event.d&&(this.moveColumn(k.event.x,
|
|
142
|
+
k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$_ac43[156]);this.parent.helper.style.display=_$_ac43[3];k.event=null},cancel:function(){k.event.d=null;k.end.call(this)},update:function(a){var c=a.target.getAttribute(_$_ac43[42]);if(null!=c)if(c=parseInt(c),this.merged.cols[c])console.error(_$_ac43[153]);else{a=a.target.clientWidth/2>a.offsetX;k.event.d=a?k.event.x<c?parseInt(c)-1:parseInt(c):k.event.x>c?parseInt(c)+1:parseInt(c);c=this.headers[c].getBoundingClientRect();var b=
|
|
143
|
+
this.content.getBoundingClientRect();this.parent.helper.style.left=(a?c.left:c.right)-b.left+_$_ac43[44]}}};return k}(),na=function(){var k={start:function(a){if(N.call(this.parent,this)){this.resetSelection();var c=this.parent.helper;if(null!==a.target.getAttribute(_$_ac43[43])){var b=parseInt(a.target.getAttribute(_$_ac43[43]));this.merged.rows[b]?console.error(_$_ac43[157]):this.results?console.error(_$_ac43[158]):(k.event={y:b,d:b},this.rows[b].element.classList.add(_$_ac43[154]),a=this.parent.element.getBoundingClientRect(),
|
|
144
|
+
b=this.rows[b].element.getBoundingClientRect(),c.style.display=_$_ac43[16],c.style.top=b.top-a.top+_$_ac43[44],c.style.left=_$_ac43[159],c.style.width=this.content.offsetWidth-50+_$_ac43[44],c.style.height=_$_ac43[155],c.classList.add(_$_ac43[160]))}else if(null!==a.target.getAttribute(_$_ac43[42]))if(b=parseInt(a.target.getAttribute(_$_ac43[42])),this.merged.cols[b])console.error(_$_ac43[153]);else{k.event={x:b,d:b};this.headers[b].classList.add(_$_ac43[154]);for(a=0;a<this.tbody.children.length;a++){var d=
|
|
145
|
+
this.tbody.children[a].getAttribute(_$_ac43[43]);this.records[d][b].element.classList.add(_$_ac43[154])}a=this.parent.element.getBoundingClientRect();b=this.headers[b].getBoundingClientRect();d=this.content.getBoundingClientRect();c.style.display=_$_ac43[16];c.style.top=d.top-a.top+_$_ac43[44];c.style.left=b.left-d.left+_$_ac43[44];c.style.width=_$_ac43[155];c.style.height=d.height+_$_ac43[44];c.classList.add(_$_ac43[156])}}else return!1},end:function(){if(null!=k.event.y)this.rows[k.event.y].element.classList.remove(_$_ac43[154]),
|
|
146
|
+
null!=k.event.d&&k.event.y!=k.event.d&&(this.moveRow(k.event.y,k.event.d),this.updateSelectionFromCoords(0,k.event.d,this.options.columns.length-1,k.event.d)),this.parent.helper.classList.remove(_$_ac43[160]);else if(null!=k.event.x){this.headers[k.event.x].classList.remove(_$_ac43[154]);for(var a=0;a<this.tbody.children.length;a++){var c=this.tbody.children[a].getAttribute(_$_ac43[43]);this.records[c][k.event.x].element.classList.remove(_$_ac43[154])}null!=k.event.d&&k.event.x!=k.event.d&&(this.moveColumn(k.event.x,
|
|
147
|
+
k.event.d),this.refreshBorders());this.parent.helper.classList.remove(_$_ac43[156])}this.parent.helper.style.display=_$_ac43[3];k.event=null},cancel:function(){k.event.d=null;k.end.call(this)},update:function(a){if(null!=k.event.y){var c=a.target.getAttribute(_$_ac43[43]);if(null!=c){var b=c=parseInt(c),d=a.target.clientHeight/2>a.offsetY;d?k.event.y<c&&(b=c-1):k.event.y>c&&(b=c+1);a=!1;this.merged.rows[b]&&(k.event.y>b?this.merged.rows[b-1]&&(a=!0):this.merged.rows[b+1]&&(a=!0));a||(k.event.d=b,
|
|
148
|
+
b=this.parent.element.getBoundingClientRect(),c=this.rows[c].element.getBoundingClientRect(),this.parent.helper.style.top=(d?c.top:c.bottom)-b.top+_$_ac43[44])}}else d=a.target.getAttribute(_$_ac43[42]),null!=d&&(b=d=parseInt(d),(c=a.target.clientWidth/2>a.offsetX)?k.event.x<d&&(b=d-1):k.event.x>d&&(b=d+1),a=!1,this.merged.cols[b]&&(k.event.x>b?this.merged.cols[b-1]&&(a=!0):this.merged.cols[b+1]&&(a=!0)),a||(k.event.d=b,b=this.headers[d].getBoundingClientRect(),d=this.content.getBoundingClientRect(),
|
|
149
|
+
this.parent.helper.style.left=(c?b.left:b.right)-d.left+_$_ac43[44]))}};return k}(),X=function(){var k=function(a){a.getMerge=k[_$_ac43[51]];a.setMerge=k[_$_ac43[11]];a.updateMerge=k.update;a.removeMerge=k.remove;a.destroyMerged=a.destroyMerge=k.destroy};k.getHeight=function(a,c){var b,d=1;if(this.merged.rows[a])for(var e=0;e<this.options.columns.length;e++){var f=A.getColumnNameFromCoords(e,a);if(f=this.merged.cells[f])if(b=this.options.mergeCells[f])c&&void 0!==c[f]||(b[1]>d&&(d=b[1]),c&&(c[f]=
|
|
150
|
+
this.records[a][e].element&&!this.records[a][e].merged?!0:!1))}return d-1};k.getWidth=function(a,c){var b,d=1;if(this.merged.cols[a])for(var e=0;e<this.options.data.length;e++){var f=A.getColumnNameFromCoords(a,e);if(f=this.merged.cells[f])if(b=this.options.mergeCells[f])c&&void 0!==c[f]||(b[0]>d&&(d=b[0]),c&&(c[f]=this.records[e][a].element&&!this.records[e][a].merged?!0:!1))}return d-1};k[_$_ac43[51]]=function(a){return a?this.options.mergeCells[a]:this.options.mergeCells};k[_$_ac43[11]]=function(a,
|
|
151
|
+
c,b){if(!N.call(this.parent,this))return!1;this.options.mergeCells||(this.options.mergeCells={});var d,e=null,f={},g={},h={},l=!1;typeof a==_$_ac43[17]?h[a]=[c,b]:typeof a==_$_ac43[84]?h=a:((e=this.getHighlighted())?e=[A.getColumnNameFromCoords(e[0],e[1]),e[2]-e[0]+1,e[3]-e[1]+1]:(jSuites.notification({message:z(_$_ac43[161])}),e=!1),e&&(h[e[0]]=[e[1],e[2]]));c=Object.keys(h);if(c.length){for(b=0;b<c.length;b++){var n=c[b],p=h[c[b]][0],q=h[c[b]][1];p=parseInt(p);q=parseInt(q);if((!p||2>p)&&(!q||2>
|
|
152
|
+
q))console.log(z(_$_ac43[162])+_$_ac43[136]+n);else if(this.options.mergeCells[n])g[n]=[p,q],f[n]=this.options.mergeCells[n],k.update.call(this,n,p,q);else{e=A.getCoordsFromColumnName(n);for(var r=e[1];r<e[1]+q;r++)for(var w=e[0];w<e[0]+p;w++)a=A.getColumnNameFromCoords(w,r),(d=this.merged.cells[a])&&this.options.mergeCells[d]&&(f[d]=this.options.mergeCells[d],k.applyDestroy.call(this,d));g[n]=this.options.mergeCells[n]=[p,q];k.applyCreate.call(this,n);I.attached.call(this,e[0],e[1])||(l=e)}}Object.keys(g).length&&
|
|
153
|
+
(l&&C[_$_ac43[46]].call(this,e[1],e[0]),Q.call(this.parent,{worksheet:this,action:_$_ac43[69],newValue:g,oldValue:f}),G.call(this,_$_ac43[69],[g]),k.build.call(this),ta.refresh.call(this),da.refresh.call(this),B.call(this.parent,_$_ac43[163],this,g,f))}};k.update=function(a,c,b){var d=this.options.mergeCells;if(d[a]){var e=d[a][1];if(c!==d[a][0]||e!==b)k.applyDestroy.call(this,a),c&&b&&(d[a]=[c,b],k.applyCreate.call(this,a))}};k.remove=function(a,c){if(!N.call(this.parent,this))return!1;c={};var b=
|
|
154
|
+
{},d={};typeof a==_$_ac43[17]?d[a]=!0:typeof a==_$_ac43[84]&&(d=a);a=Object.keys(d);for(d=0;d<a.length;d++)this.options.mergeCells[a[d]]&&(c[a[d]]=this.options.mergeCells[a[d]],b[a[d]]=!0,k.applyDestroy.call(this,a[d],!0));Q.call(this.parent,{worksheet:this,action:_$_ac43[70],newValue:b,oldValue:c});G.call(this,_$_ac43[70],{data:b})};k.destroy=function(){k.remove.call(this,this.options.mergeCells,!0)};k.applyCreate=function(a,c){var b=this.options.mergeCells;if(b[a]){var d=b[a][0]||1,e=b[a][1]||1;
|
|
155
|
+
a=A.getCoordsFromColumnName(a);if(!this.records[a[1]][a[0]].merged||1==c)if(b=I[_$_ac43[51]].call(this,a[0],a[1])){b.style.display=_$_ac43[3];1<d?b.setAttribute(_$_ac43[52],d):b.removeAttribute(_$_ac43[52]);1<e?b.setAttribute(_$_ac43[164],e):b.removeAttribute(_$_ac43[164]);1==this.options.textOverflow&&(b.style.overflow=_$_ac43[49]);for(var f=0;f<e;f++)for(var g=0;g<d;g++){c=a[0]+g;var h=a[1]+f;if(b=this.records[h][c])if(b.merged=[g,f,b.v,b.v],0!=g||0!=f)b.element||I[_$_ac43[51]].call(this,c,h),b.element.style.display=
|
|
156
|
+
_$_ac43[40],b.merged[3]=b.element.innerText,b.element.innerText=_$_ac43[3],K.call(this,c,h,_$_ac43[3])}}}};k.applyDestroy=function(a,c){var b=this.options.mergeCells;if(b[a]){var d=A.getCoordsFromColumnName(a),e=d[0];d=d[1];var f=b[a][0],g=b[a][1];delete this.options.mergeCells[a];for(a=0;a<g;a++)for(var h=0;h<f;h++)if(b=this.records[d+a][e+h])b.element&&(0==h&&0==a?(b.element.removeAttribute(_$_ac43[52]),b.element.removeAttribute(_$_ac43[164])):(b.element.style.display=_$_ac43[3],1==c&&(K.call(this,
|
|
157
157
|
e+h,d+a,b.merged[2]),b.element.innerHTML=b.merged[3]))),b.merged&&delete b.merged}};k.updateConfig=function(a,c,b,d){if(1==c)var e=[b];else{e=[];for(var f=b;f<b+d;f++)e.push(f)}var g=this.options.mergeCells,h=Object.keys(g),l={};for(f=0;f<h.length;f++){b=A.getCoordsFromColumnName(h[f]);for(var n=b[a];n<b[a]+g[h[f]][a];n++)-1!==e.indexOf(n)&&(l[h[f]]||(l[h[f]]=[g[h[f]][0],g[h[f]][1]],1==c&&(l[h[f]][a]+=d)),0==c&&l[h[f]][a]--)}h=Object.keys(l);for(f=0;f<h.length;f++)k.update.call(this,h[f],l[h[f]][0],
|
|
158
158
|
l[h[f]][1]);k.build.call(this)};k.build=function(){var a=this.options.mergeCells;this.merged={cols:[],rows:[],cells:[]};if(a)for(var c=Object.keys(a),b=0;b<c.length;b++){for(var d=A.getCoordsFromColumnName(c[b]),e=parseInt(a[c[b]][0]),f=parseInt(a[c[b]][1]),g=0;g<e;g++)this.merged.cols[d[0]+g]=!0;for(var h=0;h<f;h++)this.merged.rows[d[1]+h]=!0;for(h=0;h<f;h++)for(g=0;g<e;g++){var l=A.getColumnNameFromCoords(d[0]+g,d[1]+h);this.merged.cells[l]=c[b]}}};k.batch=function(a){var c=Object.keys(a);if(c.length)for(var b=
|
|
159
|
-
0;b<c.length;b++)!1===a[c[b]]&&k.applyCreate.call(this,c[b])};return k}(),wa=function(){var k=function(a){a.getHeader=k[_$
|
|
160
|
-
if(b=this.options.columns[a]){var d=k[_$
|
|
161
|
-
f=document.createElement(_$
|
|
162
|
-
this.headers[a]=f;this.colgroup[a]=d};return k}(),
|
|
163
|
-
this.parent.config.stripHTML?f.innerText=d:f.innerHTML=d)},a=function(c){c.getFooter=a[_$
|
|
164
|
-
B.call(this.parent,_$
|
|
165
|
-
_$
|
|
166
|
-
(d.element.style.display=_$
|
|
167
|
-
_$
|
|
168
|
-
c;
|
|
169
|
-
ka=function(){var k=function(a){a.setNestedCell=k.cell;a.getNestedCell=k.cell;a.setNestedHeaders=k[_$
|
|
170
|
-
this.options.nestedHeaders=null;for(var b=0;b<c.length;b++)c[b].classList.contains(_$
|
|
171
|
-
b.colspan&&(d.colspan=b.colspan,e.setAttribute(_$
|
|
172
|
-
a[b].colspan,e=0;e<d;e++)c.push(b);return c};k.create=function(a,c){if(this.nested.content[c][a])return this.nested.content[c][a].element;var b=this.options.nestedHeaders[c][a]||{},d=this.nested.content[c][a]={};b.colspan||(b.colspan=1);b.align||(b.align=_$
|
|
173
|
-
(e.title=b.tooltip);return d.element=e};k.build=function(){this.nested||(this.nested={content:[]});if(this.options.nestedHeaders)for(var a=0;a<this.options.nestedHeaders.length;a++){this.nested.content[a]=[];var c=document.createElement(_$
|
|
174
|
-
0;d<this.thead.lastChild.children.length;d++){a=this.thead.lastChild.children[d].getAttribute(_$
|
|
175
|
-
(d.classList.add(_$
|
|
176
|
-
_$
|
|
177
|
-
r,this.rows[
|
|
178
|
-
parseInt(n)+1,c),a=parseInt(a)):(f=parseInt(a),a=e.call(this,parseInt(h)-1,c)),0<c-g?(d=d.call(this,parseInt(g)),c=parseInt(c)):(d=parseInt(c),c=b.call(this,parseInt(l))),a-f<=c-d?(f=parseInt(h),a=parseInt(n)):(d=parseInt(l),c=parseInt(g)),this.setBorder(f,d,a,c,_$
|
|
179
|
-
1].y)+1,d=d[d.length-1].x,e=this.options.data.length-1;else return!1;var f,g=0,h=[],l=[],n=!1,
|
|
180
|
-
(u=a<
|
|
181
|
-
y.setDate(y.getDate()+v),y=y.getFullYear()+_$
|
|
182
|
-
!1;ha.execute.call(this,!0)};k.cancel=function(a){ha.event=!1;this.resetBorders(_$
|
|
183
|
-
k[_$
|
|
184
|
-
(r.match(b)||r.match(/\n/)||r.match(/"/))&&(r=r.replace(new RegExp(_$
|
|
185
|
-
typeof f[g].row==_$
|
|
186
|
-
Object.keys(a[0]).length-this.options.columns.length;0<e&&this.insertRow(e);var f=a.length-this.options.data.length;0<f&&this.insertRow(f);for(var g=0;g<this.options.data.length;g++){void 0===a[g]&&(a[g]={row:g,data:[]});for(var h=0;h<this.options.columns.length;h++)a[g].data[h]||(a[g].data[h]=_$
|
|
187
|
-
(e=parseInt(l[h])),null!==e&&b.push({x:e,y:f,value:a[g].data[l[h]]});a[g].id&&(c[f]=a[g].id)}pa.setId.call(this,c);
|
|
188
|
-
this.tbody.innerText=_$
|
|
189
|
-
jSuites.ajax({url:this.options.url,method:_$
|
|
190
|
-
k.setRowData=function(a,c,b){for(var d=[],e=0;e<this.options.columns.length;e++)typeof c[e]===_$
|
|
191
|
-
_$
|
|
192
|
-
d());return e};k.paste=function(a,c,b){if(!N.call(this.parent,this))return!1;var d=this,e=function(){d.borders.copying&&(d.resetBorders(_$
|
|
193
|
-
|
|
194
|
-
0;for(r=f[1];r<=f[3];r++)if(!this.results||-1!=this.results.indexOf(r)){g=[];m=[];for(w=f[0];w<=f[2];w++)g.push(b[x][u]),
|
|
195
|
-
style:_$
|
|
196
|
-
m,u,
|
|
197
|
-
window.navigator&&window.navigator.msSaveOrOpenBlob?window.navigator.msSaveOrOpenBlob(c,this.options.csvFileName+_$
|
|
198
|
-
for(var c=0;c<a.length;c++){var b={};Array.isArray(a[c])||void 0==a[c].data?b.data=a[c]:b=a[c];b.row=void 0==a[c].row?c:a[c].row;a[c]=b}return a};return k}(),Qa=function(){var k=function(a){a.getLabel=k[_$
|
|
199
|
-
k[_$
|
|
200
|
-
d)}}};k.updateWorksheetName=function(a,c){var b,d={};if(b=this.parent.config.definedNames){var e=Object.keys(b);if(e.length){for(var f=0;f<e.length;f++){var g=S.updateWorksheetName(b[e[f]],a,c);g!==b[e[f]]&&(d[e[f]]=g)}k[_$
|
|
201
|
-
_$
|
|
202
|
-
|
|
203
|
-
_$
|
|
204
|
-
h;g&&(g.tagName?n.setStart(g.firstChild,
|
|
205
|
-
n)):f};e.range=function(f,g,h,l,n){f=e.getName.call(this,f,g,h,l,n);g=document.createElement(_$
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
_$
|
|
209
|
-
h[w]==_$
|
|
210
|
-
1])&&-1==
|
|
211
|
-
|
|
212
|
-
b.getTokensFromRange.call(this,h[n]);l=l.replace(h[n],_$
|
|
213
|
-
this.parent.processing)return null!==l&&null!==n&&this.parent.queue.push([this,l,n]),_$
|
|
214
|
-
|
|
215
|
-
A.getCoordsFromColumnName(L);L=E[0];E=E[1];var oa=void 0!==R.records[E][L].v?R.records[E][L].v:K.call(R,L,E);m[
|
|
216
|
-
null,x=0;x<v.length;x++)for(var y=0;y<v[x].length;y++)null===u&&(0<x&&x>y&&this.options.data[n+x][l+y]?u=_$
|
|
217
|
-
_$
|
|
218
|
-
w(r):(r=w(r.replace(/\$/g,_$
|
|
219
|
-
H);if(!n[H]){var L=v.getValue(H);M(L)?l.push([H,L,b.getTokens.call(v,L,u)]):(y=!0,v.formula[x][m]=null);
|
|
220
|
-
function(h,l){var n,
|
|
221
|
-
x)for(
|
|
222
|
-
|
|
223
|
-
(h[0]=_$
|
|
224
|
-
b.shiftFormula=function(h,l,n){var
|
|
225
|
-
h(r[1]);else{var w=r[1].split(_$
|
|
226
|
-
r[0],w=
|
|
227
|
-
p=A.getCoordsFromColumnName(p);return
|
|
228
|
-
h[n].indexOf(_$
|
|
229
|
-
a=A.getCoordsFromColumnName(a),d=a[0],a=a[1];return k.getFromCoords.call(b,d,a,c)};k.getFromCoords=function(a,c,b){var d=null;null!=a&&null!=c&&(d=b?k.processed.call(this,a,c):K.call(this,a,c));return d};k[_$
|
|
230
|
-
(d=
|
|
231
|
-
g);T.update.call(this,!0);this.refreshBorders();var n=this;setTimeout(function(){
|
|
232
|
-
function(){for(var a=[],c=this.getSelected(),b=0;b<c.length;b++){var d=c[b].x,e=c[b].y;if(!this.options.columns[d].readOnly&&this.options.columns[d].type==_$
|
|
233
|
-
c.style;b.oldStyle=d&&d[h]?d[h]:_$
|
|
234
|
-
d=1==this.parent.config.stripHTML?this.records[c][a].element.innerText:this.records[c][a].element.innerHTML:((_$
|
|
235
|
-
d=c[1],c=D(c[0])):(d=a[e],c=this),d=A.getCoordsFromColumnName(d),I.update.call(c,d[0],d[1],b[a[e]],!0)};return k}(),I=function(){var k=function(a){a.getCell=k[_$
|
|
236
|
-
|
|
237
|
-
d.push(A.getColumnNameFromCoords(h,f)):d.push(this.records[f][h]);return d};k.selected=function(a,c){return k.getFromCoords.call(this,this.getHighlighted(),a,c)};k.getSelectedColumns=function(){var a=[],c=this.getHighlighted();if(c)for(var b=c[0];b<=c[2];b++)a.push(b);
|
|
238
|
-
a[d].y,a[d].value,a[d].force));G.call(this,_$
|
|
239
|
-
e,a,c),B.call(this.parent,_$
|
|
240
|
-
k.applyProperties.call(this,e,a,c,d);k.applyOverflow.call(this,e,a,c);B.call(this.parent,_$
|
|
241
|
-
a&&a.cells&&this.setCells(a.cells);a&&a.mergeCells&&this.setMerge(a.mergeCells);a&&a.values&&k.batch.call(this,a.values);a&&a.formulas&&k.batch.call(this,a.formulas,!0)};k.applyProperties=function(a,c,b,d){if(!d){d=A.getColumnNameFromCoords(c,
|
|
242
|
-
a.classList.add(_$
|
|
243
|
-
1&&(a.style.overflow=_$
|
|
244
|
-
a[d[e]],!0);b[f]||(b[f]=[]);b[f].push(h)}if(1==c&&(d=Object.keys(b),d.length))for(e=0;e<d.length;e++)g=D(d[e]),G.call(g,_$
|
|
245
|
-
_$
|
|
246
|
-
[],d=this.getHighlighted();if(d)for(var e=d[1];e<=d[3];e++)c?b.push(e):b.push(this.rows[e].element);return b};a.create=function(c,b){if(this.rows[c]&&this.rows[c].element)return this.rows[c].element;this.rows[c]||ia.row.call(this,
|
|
247
|
-
_$
|
|
248
|
-
c=parseInt(c);b=parseInt(b);if(!this.rows[b]||!this.rows[c])return console.error(_$
|
|
249
|
-
this.rows[
|
|
250
|
-
newValue:b});B.call(this.parent,_$
|
|
251
|
-
!1;this.resetBorders();c=d?b:b+1;for(var l,n,
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
!1;var d=null,e={},f=[],g=0;void 0==c&&(b=this.getSelectedRows(),b[0]?(c=parseInt(b[0].getAttribute(_$
|
|
256
|
-
|
|
257
|
-
(this.rows[h].element.parentNode.removeChild(this.rows[h].element),g++);d=[];for(h=c;h<c+b;h++)d.push({id:this.getRowId(h),row:h,data:this.getRowData(h)});this.rows.splice(c,
|
|
258
|
-
|
|
259
|
-
(this.colgroup[d].style.width=c?parseInt(e.width||this.options.defaultColWidth)+_$
|
|
260
|
-
c.setProperty=a.properties;c.showColumn=k.bind(c,!0);c.hideColumn=k.bind(c,!1)};a[_$
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
this.
|
|
264
|
-
this.
|
|
265
|
-
0
|
|
266
|
-
1)[0]);G.call(this,_$
|
|
267
|
-
0;n<c.length;n++)f[n]=[c[n]]}f||(f=[]);d=d?!0:!1;c=this.options.columns.length-1;if(void 0==b||b>c||0>b)b=c,d=!1;l||(l=1);if(!1===B.call(this.parent,_$
|
|
268
|
-
_$
|
|
269
|
-
|
|
270
|
-
(r=this.options.data[m].splice(
|
|
271
|
-
(this
|
|
272
|
-
|
|
273
|
-
console.error(_$
|
|
274
|
-
c;
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
{column:c,options:b});return!0}return this.options.columns[c]}console.error(_$
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
c){if(!N.call(this.parent,this))return!1;if(typeof a==_$
|
|
288
|
-
(
|
|
289
|
-
|
|
290
|
-
_$
|
|
291
|
-
|
|
292
|
-
_$
|
|
293
|
-
action:_$
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
function(
|
|
297
|
-
if(d){if(null==a||-1==a)a=Math.ceil((this.results?this.results:this.rows).length/d)-1;if(!1===B.call(this.parent,_$
|
|
298
|
-
this.rows.length;if(a){a=Math.ceil(a/this.options.pagination);if(6>this.pageNumber)var c=1,b=10>a?a:10;else 5>a-this.pageNumber?(c=a-9,b=a,1>c&&(c=1)):(c=this.pageNumber-4,b=this.pageNumber+5);if(1<c){var d=
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
a+=this.options.columns[b].width}else k.reset.call(this)};k[_$
|
|
302
|
-
this.rows[
|
|
303
|
-
function(b,d){if(this.options[b]){for(var e={},f=Object.keys(this.options[b]),g=0;g<f.length;g++)e[d&&void 0!=d[f[g]]?d[f[g]]:f[g]]=this.options[b][f[g]];this.options[b]=e}},a=function(){if(0<this.options.minSpareRows){for(var b=
|
|
304
|
-
1;0<=f;f--){e=!1;for(d=0;d<this.rows.length;d++)K.call(this,f,d)&&(e=!0);if(e)break;else b++}0<this.options.minSpareCols-b&&this.insertColumn(this.options.minSpareCols-b)}},c=function(){};c.build=function(){var b=this;this.content=
|
|
305
|
-
1,null,f):C.pageRight.call(b,1,null,f):0>f.deltaY?C.pageUp.call(b,1,null,f):C.pageDown.call(b,1,null,f)}});this.content.addEventListener(_$
|
|
306
|
-
|
|
307
|
-
this.
|
|
308
|
-
|
|
309
|
-
this.options.tableOverflow&&(this.options.tableHeight||(this.options.tableHeight=300),this.options.tableWidth||(this.options.tableWidth=document.body.offsetWidth-8),this.content.style.maxHeight=parseInt(this.options.tableHeight)+_$
|
|
310
|
-
C.call(this);
|
|
311
|
-
this.options.rows[l]&&this.options.rows[l].title?this.options.rows[l].title:n+1,g.element.children[0].innerHTML=f));var
|
|
312
|
-
|
|
313
|
-
_$
|
|
314
|
-
b.config.license);a.spreadsheet=b;a.jspreadsheet=a.jexcel=b.worksheets;t.spreadsheet.push(b);b.name||(b.name=jSuites.guid());k.bind(b.config.root?b.config.root:document);var d=b.config.tabs;typeof d!==_$
|
|
315
|
-
h&&b.openWorksheet(h)};d.onchangeposition=function(f,g,h){b.updateWorksheet(g,h)};jSuites.tabs(a,d);a.classList.add(_$
|
|
316
|
-
b.loading.classList.add(_$
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
Ba(b);Sa(b);Ra(b);wa(b);
|
|
320
|
-
f){b.options.worksheetState===_$
|
|
321
|
-
this.options.rows[a].height&&(this.rows[a].height=this.options.rows[a].height);this.records[a]||(this.records[a]=[]);this.options.data[a]||(this.options.data[a]=this.dataType?{}:[]);for(c=0;c<this.options.columns.length;c++)k.cell.call(this,c,a)},cell:function(a,c,b){typeof b==_$
|
|
322
|
-
_$
|
|
323
|
-
return a};k[_$
|
|
324
|
-
action:_$
|
|
325
|
-
this.rows[c].height:this.rows[c].element.offsetHeight||this.options.defaultRowHeight;this.rows[c].element.style.height=b+_$
|
|
326
|
-
a.call(this,c,b),1==f&&(d=e);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$
|
|
327
|
-
g.element.firstChild)}g.element.firstChild.checked=g.selected;return g.element},a=null,c=null,b=[],d=0,e=null,f=function(g){g.setFilter=f[_$
|
|
328
|
-
g.filters=null);f.update.call(this)};f[_$
|
|
329
|
-
l+_$
|
|
330
|
-
h.length;l++)b[h[l][0]]={value:h[l][1],element:null};void 0!==b[_$
|
|
331
|
-
g.push(e[h])}f[_$
|
|
332
|
-
|
|
333
|
-
g,!0)};f.hide=function(g){f.updateDOM.call(this,g,!1,!0);f.update.call(this)};f.search=function(g){for(var h=this.parent.filter.children[1];h.children[1];)h.removeChild(h.lastChild);h.currentSelection.firstChild.checked=!1;if(g){e=[];g=new RegExp(g,_$
|
|
334
|
-
Object.keys(b);if(g=this.options.columns[a].filters)for(n=0;n<e.length;n++)b[e[n]].selected=!1,0<=g.indexOf(e[n])&&(b[e[n]].selected=!0);else for(n=0;n<e.length;n++)b[e[n]].selected=!0;h.firstChild.checked=g?!1:!0}for(n=d=0;n<e.length;n++)200>n&&(g=d++,h.appendChild(k(g)))};f.build=function(){var g=document.createElement(_$
|
|
335
|
-
(q=!1);this.children[0].children[0].checked=
|
|
336
|
-
g.selectAll=document.createElement(_$
|
|
337
|
-
f.updateDOM=function(g,h,l){var n=this.headers,
|
|
338
|
-
return f}(),ma=function(){var k=function(c){var b=document.createElement(_$
|
|
339
|
-
e.innerHTML=c.options.paginationOptions[d];c.paginationDropdown.appendChild(e)}c.paginationDropdown.value=c.options.pagination;b.appendChild(document.createTextNode(z(_$
|
|
340
|
-
(this.searchInput.value=c);this.pageNumber=0;var d=[],e=null;b=
|
|
341
|
-
this.resetBorders();var b=a.execute.call(this,c);if(typeof this.parent.config.onbeforesearch==_$
|
|
342
|
-
a.show=function(){this.options.search=!0;this.searchContainer.style.display=_$
|
|
343
|
-
this.searchInput.classList.add(_$
|
|
344
|
-
d=a.target.getAttribute(_$
|
|
345
|
-
_$
|
|
346
|
-
g,{title:
|
|
347
|
-
a.paste(a.selectedCell[0],a.selectedCell[1],
|
|
348
|
-
h.push({title:z(_$
|
|
349
|
-
onclick:function(){a.
|
|
350
|
-
A.getColumnNameFromCoords(f,g),r=prompt(z(_$
|
|
351
|
-
|
|
352
|
-
k.getDefault());typeof a.responsive==_$
|
|
353
|
-
this.config.fullscreen)b=a.element.offsetWidth;c.options.maxWidth=b;c.refresh()}};k.build=function(){for(var a=k[_$
|
|
354
|
-
a.items[c].onclick=function(d,e,f){f.color||jSuites.color(f,{onchange:function(g,h){t.current.setStyle(t.current.getSelected(),f.k,h)}}).open()}):!a.items[c].onclick&&a.items[c].k&&(a.items[c].onclick=function(){t.current.setStyle(t.current.getSelected(),this.k,this.v)});(c=la.execute.call(this,_$
|
|
355
|
-
function(){return[{content:_$
|
|
356
|
-
|
|
357
|
-
_$
|
|
358
|
-
|
|
359
|
-
_$
|
|
360
|
-
|
|
361
|
-
e[
|
|
362
|
-
d.classList.add(_$
|
|
363
|
-
c,b){b.children[0].innerText==_$
|
|
364
|
-
|
|
365
|
-
(c=e[f].options.worksheetName.match(/(\d+)/))&&(c=parseInt(c[0])+1,c>a&&(a=c))}return a};k.createWorksheet=function(a){if(!N.call(this))return!1;a||(a={});var c=this.worksheets.length,b=B.call(this,_$
|
|
366
|
-
message:_$
|
|
367
|
-
c=c.replace(/[^0-9A-Za-z_\s^]+/gi,_$
|
|
368
|
-
0,b.splice(a,1)[0]);Q.call(this,{worksheet:b[c],action:_$
|
|
369
|
-
t.current),B.call(this,_$
|
|
370
|
-
_$
|
|
371
|
-
return c},invert:function(a){for(var c=[],b=Object.keys(a),d=0;d<b.length;d++)c[a[b[d]]]=b[d];return c},getColumnName:function(a){var c=_$
|
|
372
|
-
0,d=0;d<c[0].length;d++)b+=parseInt(c[0].charCodeAt(d)-64)*Math.pow(26,c[0].length-1-d);b--;0>b&&(b=0);a=parseInt(/[0-9]+$/.exec(a))||null;0<a&&a--;return[b,a]}}};k.shiftFormula=S.shiftFormula;k.createFromTable=function(a,
|
|
373
|
-
|
|
374
|
-
x};var f=[],g=a.querySelectorAll(_$
|
|
375
|
-
h[
|
|
376
|
-
(
|
|
377
|
-
[];for(d=0;d<h[b].children.length;d++)e.push(h[b].children[d].innerText);a.push(e)}0<Object.keys(a).length&&(c.footers=a)}if(1==c.parseTableAutoCellType)for(a=[],d=0;d<c.columns.length;d++){f=e=!0;a[d]=[];for(b=0;b<c.data.length;b++)if(m=
|
|
378
|
-
_$
|
|
379
|
-
n++):l=!0;continue}e[d][b]+=a[n]}else{g=null;l=h=!1;if(e[d][b][0]==_$
|
|
380
|
-
(J.classList.contains(_$
|
|
381
|
-
|
|
382
|
-
_$
|
|
383
|
-
H,u,x,E,
|
|
384
|
-
(t.current&&t.current.resetSelection(),t.current=v[1].jexcel):(m=v[0].tabs.getActive(),0<=m&&(t.current=v[0].spreadsheet.worksheets[m])):t.current&&!jSuites.findElement(m.target,_$
|
|
385
|
-
_$
|
|
386
|
-
|
|
387
|
-
t.current.
|
|
388
|
-
|
|
389
|
-
else if(
|
|
390
|
-
t.current.
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
m,v,u,x,y))return!1;if(t.current.edition)t.current.closeEditor(t.current.edition,!0);else if(b&&b!==H)return!1;
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
m.
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
m.target,t.current.cursor.style.cursor=_$
|
|
402
|
-
1
|
|
403
|
-
m.clientX,E=m.clientY;50>H.height-(E-H.top)?C.pageDown.call(t.current,1,null,m):80>E-H.top&&C.pageUp.call(t.current,1,null,m);50>H.width-(L-H.left)?C.pageRight.call(t.current,
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
t=function(k,a,c){a||(a={});if(a.cloud&&!c)typeof a.plugins.cloud==_$
|
|
408
|
-
f[2],K.call(f[0],f[1],f[2]),!0);b.config.toolbar&&
|
|
409
|
-
|
|
410
|
-
k.spreadsheet=null,k.jexcel=null,k.innerHTML=_$
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
_$
|
|
414
|
-
f;if(null!==
|
|
415
|
-
|
|
416
|
-
e,f));g instanceof Element||g instanceof HTMLDocument||!l||b(g)||!(f=d(l))||(e=jSuites.mask.render(g,f,!0),n&&f.mask&&(f=f.mask.split(_$
|
|
417
|
-
f};return c}();k.text=k.general;k.number=k.general;k.numeric=k.general;k.percent=k.general;k.notes=function(){var c={},b=null;c.updateCell=function(d,e,f,g,h,l){d&&(f=document.createElement(_$
|
|
418
|
-
e,f,g,h,l);b=jSuites.editor(b,n)};c.closeEditor=function(d,e,f,g,h,l){return e?b.getData():_$
|
|
419
|
-
f,g,h),b.innerHTML=l):b.innerHTML=_$
|
|
420
|
-
|
|
421
|
-
_$
|
|
422
|
-
[],d[f[0]]=!0,e=d);if(h.source&&typeof h.source[0]!==_$
|
|
423
|
-
_$
|
|
424
|
-
{},b=null;c.updateCell=function(d,e,f,g,h,l){if(d){f=e;l=c.getFormat(l);0<e&&Number(e)==e&&(f=jSuites.calendar.numToDate(e));g=_$
|
|
425
|
-
function(d,e,f,g,h,l){l=Object.create(l);typeof l.filterOptions==_$
|
|
426
|
-
b.value?!0:!1);d=b.value?d:_$
|
|
427
|
-
e,d.innerText=e))};c.createCell=c.updateCell;c.openEditor=function(d,e,f,g,h,l){l=Object.create(l);typeof l.filterOptions==_$
|
|
428
|
-
e;return d.outerHTML};return c}();k.checkbox=function(){var c={createCell:function(b,d,e,f,g,h){d=d&&d!=_$
|
|
429
|
-
d,e,f,g){d=b.children[0].checked?!1:!0;g.setValue(b,d);return!1},closeEditor:function(b,d){return!1}};c[_$
|
|
430
|
-
e.setAttribute(_$
|
|
431
|
-
return c}();k.autonumber=function(){var c={},b=null;c.createCell=function(d,e,f,g,h,l){(e=parseInt(e))||0<parseInt(d.innerText)&&(e=parseInt(d.innerText));l.sequence||(l.sequence=0);e?c.isValid(e,f,g,h)||(e=_$
|
|
432
|
-
c.isValid=function(d,e,f,g){for(var h,l=0;l<g.options.data.length;l++)if(h=g.value(e,l),h==d&&l!=f)return!1;return!0};return c}();k.progressbar=function(){var c={},b=null;c.createCell=function(d,e){e=parseInt(e);if(100<e)e=100;else if(!e||0>
|
|
433
|
-
f.setAttribute(_$
|
|
434
|
-
l){return c.setCell(d,e,l)};c.destroyCell=function(d){d.classList.remove(_$
|
|
435
|
-
var g=document.createElement(_$
|
|
436
|
-
(e=document.createElement(_$
|
|
437
|
-
_$
|
|
438
|
-
(f.style.maxHeight=parseInt(l.options.height)+_$
|
|
439
|
-
l){if(e&&(d=b.children[0]))return d.tagName==_$
|
|
440
|
-
n.focus=!0;n.value=e;n.border=!1;n.height=_$
|
|
441
|
-
k.tags=function(){var c={},b=null;c.createCell=function(d,e){d.classList.add(_$
|
|
442
|
-
function(d,e,f,g,h,l){d=b.getValue();if(e)return d};return c}();k.record=function(){var c={},b=null;c.createCell=function(d,e,f,g,h,l){d.classList.add(_$
|
|
443
|
-
_$
|
|
444
|
-
e&&(f.value=(_$
|
|
445
|
-
e).split(_$
|
|
446
|
-
{id:g.getRowId(d),name:h},void 0!=e.worksheetImage&&(h.image=g.value(e.worksheetImage,d)),l.push(h)}else console.error(_$
|
|
447
|
-
_$
|
|
159
|
+
0;b<c.length;b++)!1===a[c[b]]&&k.applyCreate.call(this,c[b])};return k}(),wa=function(){var k=function(a){a.getHeader=k[_$_ac43[51]];a.setHeader=k[_$_ac43[11]];a.getHeaders=k.all};k[_$_ac43[51]]=function(a){var c;if(c=this.options.columns)return c[a].title||A.getColumnName(a)};k.all=function(a){for(var c=[],b=0;b<this.options.columns.length;b++)c.push(k[_$_ac43[51]].call(this,b));return a?c:c.join(this.options.csvDelimiter)};k[_$_ac43[11]]=function(a,c){if(!N.call(this.parent,this))return!1;var b;
|
|
160
|
+
if(b=this.options.columns[a]){var d=k[_$_ac43[51]].call(this,a);if(!c&&(c=prompt(z(_$_ac43[165]),d),!c))return!1;b.title=c;if(b=this.headers[a])b.innerHTML=c,b.setAttribute(_$_ac43[166],c);Q.call(this.parent,{worksheet:this,action:_$_ac43[75],column:a,oldValue:d,newValue:c});G.call(this,_$_ac43[75],{column:a,title:c});B.call(this.parent,_$_ac43[167],this,a,c,d)}};k.create=function(a){var c=this.options.columns[a],b=c.width||this.options.defaultColWidth,d=c.align||_$_ac43[53],e=c.title||A.getColumnName(a),
|
|
161
|
+
f=document.createElement(_$_ac43[147]);this.parent.config.stripHTML?f.innerText=e:f.innerHTML=e;f.setAttribute(_$_ac43[42],a);f.style.textAlign=d;c.title&&f.setAttribute(_$_ac43[166],f.innerText);c.tooltip&&(f.title=c.tooltip);d=this.options.filters;!0===c.filter&&(d=!0);!1===c.filter&&(d=!1);!0===d&&f.classList.add(_$_ac43[168]);!1===c.visible&&(b=_$_ac43[97]);d=document.createElement(_$_ac43[169]);d.setAttribute(_$_ac43[152],b);c.type==_$_ac43[49]&&(f.style.display=_$_ac43[40],d.style.display=_$_ac43[40]);
|
|
162
|
+
this.headers[a]=f;this.colgroup[a]=d};return k}(),W=function(){var k=function(c,b,d){var e=this.footers.content,f;e&&e[b]&&e[b][c]&&(f=e[b][c].element)&&(M(d)&&1==this.parent.config.parseFormulas?d=S.execute.call(this,d,c,null,!1):d||(e=this.options.footers,d=e[b]&&e[b][c]?e[b][c]:_$_ac43[3]),this.options.applyMaskOnFooters&&(e=Z[_$_ac43[51]].call(this,c),d=t.editors.general.parseValue(c,b,d,this,e[1],f)),d instanceof Element||d instanceof HTMLDocument?(f.innerHTML=_$_ac43[3],f.appendChild(d)):1==
|
|
163
|
+
this.parent.config.stripHTML?f.innerText=d:f.innerHTML=d)},a=function(c){c.getFooter=a[_$_ac43[51]];c.setFooter=a[_$_ac43[11]];c.resetFooter=a.reset;c.refreshFooter=a.refresh;c.getFooterValue=a.value;c.setFooterValue=a.value};a[_$_ac43[51]]=function(){return this.options.footers};a[_$_ac43[11]]=function(c){if(c){var b=this.options.footers;this.options.footers=c}this.options.footers!=b&&(W.build.call(this),C.limited.call(this)?C.refresh.call(this):a.render.call(this),G.call(this,_$_ac43[170],{data:this.options.footers}),
|
|
164
|
+
B.call(this.parent,_$_ac43[171],this,this.options.footers,b))};a.refresh=function(){var c=this.options.footers;if(c&&c.length)for(var b=0;b<c.length;b++)for(var d=0;d<c[b].length;d++)k.call(this,d,b,c[b][d])};a.value=function(c,b,d){if(void 0===d)return this.options.footers[b][c];k.call(this,c,b,d);G.call(this,_$_ac43[172],{x:c,y:b,value:d});B.call(this.parent,_$_ac43[173],this,c,b,d)};a.reset=function(){var c=this.options.footers;this.options.footers=null;this.footers.content=null;this.tfoot.innerHTML=
|
|
165
|
+
_$_ac43[3];G.call(this,_$_ac43[174],{});B.call(this.parent,_$_ac43[171],this,null,c)};a.create=function(c,b){var d=this.footers.content[b][c];if(d&&d.element)return d.element;d=this.footers.content[b][c]={};var e=this.options.columns[c].align?this.options.columns[c].align:_$_ac43[53];d.element=document.createElement(_$_ac43[147]);d.element.style.textAlign=e;d.element.setAttribute(_$_ac43[42],c);d.element.setAttribute(_$_ac43[43],b);k.call(this,c,b,null);this.options.columns[c].type==_$_ac43[49]&&
|
|
166
|
+
(d.element.style.display=_$_ac43[40]);return d.element};a.build=function(){this.footers={element:this.tfoot,content:[]};if(this.options.footers)for(var c=0;c<this.options.footers.length;c++){if(!this.footers.content[c]){this.footers.content[c]=[];var b=document.createElement(_$_ac43[145]),d=document.createElement(_$_ac43[147]);d.innerHTML=_$_ac43[148];b.appendChild(d);this.footers.element.appendChild(b)}for(b=0;b<this.options.columns.length;b++)this.options.footers[c][b]||(this.options.footers[c][b]=
|
|
167
|
+
_$_ac43[3]),this.footers.content[c][b]||(this.footers.content[c][b]={})}};a.render=function(){for(var c=this.options.footers,b=0;b<c.length;b++)for(var d=0;d<c[b].length;d++){var e=W.create.call(this,d,b);this.tfoot.children[b].appendChild(e)}};a.adjust=function(c,b,d){var e=[],f=this.options.footers,g=this.footers.content;if(f)if(1==d){if(this.headers[c]&&this.headers[c].parentNode)var h=this.headers[c]==this.thead.lastChild.lastChild?!0:!1,l=!0;for(d=0;d<f.length;d++){for(var n=f[d].splice(c),p=
|
|
168
|
+
c;p<c+b;p++)f[d][p]=_$_ac43[3];f[d]=f[d].concat(n);n=g[d].splice(c);for(p=c;p<c+b;p++)g[d][p]={element:a.create.call(this,p,d)},l&&(1==h?this.tfoot.children[d].appendChild(g[d][p].element):this.tfoot.children[d].insertBefore(g[d][p].element,this.tfoot.children[d].children[c].nextSibling));g[d]=g[d].concat(n)}}else for(d=0;d<f.length;d++){for(p=c;p<c+b;p++)(h=this.footers.content[d][p].element)&&h.parentNode&&h.parentNode.removeChild(h);g[d].splice(c,b);e[d]=f[d].splice(c,b)}return e};return a}(),
|
|
169
|
+
ka=function(){var k=function(a){a.setNestedCell=k.cell;a.getNestedCell=k.cell;a.setNestedHeaders=k[_$_ac43[11]];a.getNestedHeaders=k[_$_ac43[51]];a.resetNestedHeaders=k.reset};k[_$_ac43[51]]=function(){return this.options.nestedHeaders};k[_$_ac43[11]]=function(a){k.reset.call(this);this.options.nestedHeaders=a;k.build.call(this);k.render.call(this);da.refresh.call(this);P.call(this);G.call(this,_$_ac43[175],{data:a});B.call(this.parent,_$_ac43[176],this,a)};k.reset=function(){var a=[],c=this.thead.children;
|
|
170
|
+
this.options.nestedHeaders=null;for(var b=0;b<c.length;b++)c[b].classList.contains(_$_ac43[177])&&a.push(c[b]);if(a.length)for(;c=a.shift();)c.remove();this.nested=null;da.refresh.call(this);P.call(this);G.call(this,_$_ac43[178]);B.call(this.parent,_$_ac43[176],this,[])};k.cell=function(a,c,b){if(b){if(!N.call(this.parent,this))return!1;var d=this.options.nestedHeaders[c][a],e=this.nested.content[c][a].element;void 0!==b.title&&(e.innerText=b.title);void 0!==b.tooltip&&(e.title=b.tooltip);void 0!==
|
|
171
|
+
b.colspan&&(d.colspan=b.colspan,e.setAttribute(_$_ac43[52],b.colspan),e.style.display=0==d.colspan?_$_ac43[40]:_$_ac43[3]);G.call(this,_$_ac43[179],{x:a,y:c,properties:b});B.call(this.parent,_$_ac43[180],this,a,c,b)}else return this.nested.content[c][a].element};k.range=function(a){a=this.options.nestedHeaders[a];for(var c=[],b=0,d=0;d<a.length;d++){var e=parseInt(a[d].colspan);c[d]=[b,b+e-1];b+=e}return c};k.getColumns=function(a){a=this.options.nestedHeaders[a];for(var c=[],b=0;b<a.length;b++)for(var d=
|
|
172
|
+
a[b].colspan,e=0;e<d;e++)c.push(b);return c};k.create=function(a,c){if(this.nested.content[c][a])return this.nested.content[c][a].element;var b=this.options.nestedHeaders[c][a]||{},d=this.nested.content[c][a]={};b.colspan||(b.colspan=1);b.align||(b.align=_$_ac43[53]);b.title||(b.title=_$_ac43[3]);var e=document.createElement(_$_ac43[147]);e.setAttribute(_$_ac43[181],a);e.setAttribute(_$_ac43[182],c);e.setAttribute(_$_ac43[52],b.colspan);e.setAttribute(_$_ac43[183],b.align);e.innerHTML=b.title;b.tooltip&&
|
|
173
|
+
(e.title=b.tooltip);return d.element=e};k.build=function(){this.nested||(this.nested={content:[]});if(this.options.nestedHeaders)for(var a=0;a<this.options.nestedHeaders.length;a++){this.nested.content[a]=[];var c=document.createElement(_$_ac43[147]);c.innerHTML=_$_ac43[148];var b=document.createElement(_$_ac43[145]);b.classList.add(_$_ac43[177]);b.appendChild(c);this.thead.insertBefore(b,this.thead.lastChild)}};k.render=function(){for(var a,c=this.options.nestedHeaders,b=0;b<c.length;b++)for(var d=
|
|
174
|
+
0;d<this.thead.lastChild.children.length;d++){a=this.thead.lastChild.children[d].getAttribute(_$_ac43[42]);var e=k.getColumns.call(this,b);void 0!==e[a]&&k.renderCell.call(this,e[a],b)}};k.renderCell=function(a,c,b){var d=ka.create.call(this,a,c);d.parentNode?(a=d.getAttribute(_$_ac43[52]),a++,d.setAttribute(_$_ac43[52],a)):(d.setAttribute(_$_ac43[52],1),b?this.thead.children[c].insertBefore(d,this.thead.children[c].children[b]):this.thead.children[c].appendChild(d),0==a&&0<this.options.freezeColumns&&
|
|
175
|
+
(d.classList.add(_$_ac43[50]),d.style.left=_$_ac43[159]))};k.adjust=function(a,c,b,d){var e=this.options.nestedHeaders;if(e)if(1==b)if(d&&d.nested)for(b=0;b<e.length;b++)for(var f=0;f<e[b].length;f++)k.cell.call(this,f,b,{colspan:d.nested[b][f]});else for(b=0;b<e.length;b++){if(f=k.getColumns.call(this,b)){f=f[a];var g=parseInt(e[b][f].colspan)+c;k.cell.call(this,f,b,{colspan:g})}}else{d=[];for(b=0;b<e.length;b++)if(g=k.getColumns.call(this,b)){d[b]=[];for(f=0;f<c;f++){var h=g[a+f];typeof d[b][h]==
|
|
176
|
+
_$_ac43[13]&&(d[b][h]=e[b][h].colspan);e[b][h].colspan--}g=Object.keys(d[b]);for(f=0;f<g.length;f++)k.cell.call(this,g[f],b,{colspan:e[b][g[f]].colspan})}return d}};return k}(),ha=function(){var k=function(a,c){var b=function(p){var q;(q=this.results)?p=q.indexOf(p):q=this.rows;p--;for(var r=p;0<=r;r--)if(p=this.results?q[r]:r,this.rows[p]&&this.rows[p].element)return p;return 0},d=function(p){var q;(q=this.results)?p=q.indexOf(p):q=this.rows;p++;for(var r=p;r<q.length;r++)if(p=this.results?q[r]:
|
|
177
|
+
r,this.rows[p]&&this.rows[p].element)return p;return q[q.length-1]},e=function(p,q){for(;0<=p;p--)if(this.records[q][p].element&&this.records[q][p].element.style.display!=_$_ac43[40])return p;return 0},f=function(p,q){for(;p<this.options.columns.length;p++)if(this.records[q][p].element&&this.records[q][p].element.style.display!=_$_ac43[40])return p;return this.options.columns-1},g=this.getHighlighted(),h=g[0],l=g[1],n=g[2];g=g[3];a=parseInt(a);c=parseInt(c);null!=a&&null!=c&&(0<a-n?(f=f.call(this,
|
|
178
|
+
parseInt(n)+1,c),a=parseInt(a)):(f=parseInt(a),a=e.call(this,parseInt(h)-1,c)),0<c-g?(d=d.call(this,parseInt(g)),c=parseInt(c)):(d=parseInt(c),c=b.call(this,parseInt(l))),a-f<=c-d?(f=parseInt(h),a=parseInt(n)):(d=parseInt(l),c=parseInt(g)),this.setBorder(f,d,a,c,_$_ac43[138]))};k.execute=function(a){if(!N.call(this.parent,this))return!1;var c=this.borders.cloning;if(a)if(c&&c.active){a=c.x1;var b=c.y1,d=c.x2,e=c.y2}else return!1;else if(d=this.getSelected(),d.length)a=d[0].x,b=parseInt(d[d.length-
|
|
179
|
+
1].y)+1,d=d[d.length-1].x,e=this.options.data.length-1;else return!1;var f,g=0,h=[],l=[],n=!1,p=this.getHighlighted(),q=za[_$_ac43[51]].call(this,p,!1,!1),r=this.getSelected();if(f=this.getStyle(r,!0)){var w=Object.keys(f);if(w.length)for(var m=0;m<w.length;m++)h.push(f[w[m]])}if(p[0]==a)var v=b<p[1]?b-p[1]:1,u=0;else u=a<p[0]?a-p[0]:1,v=0;w=0;a=parseInt(a);d=parseInt(d);b=parseInt(b);e=parseInt(e);for(var x=b;x<=e;x++)if(!this.results||-1!=this.results.indexOf(x)){void 0==q[g]&&(g=0);f=0;p[0]!=a&&
|
|
180
|
+
(u=a<p[0]?a-p[0]:1);for(m=a;m<=d;m++){if(!(0!=n||this.records[x][m].element&&this.records[x][m].element.classList.contains(_$_ac43[18]))){if((!c||1!=c.active)&&K.call(this,m,x)){n=!0;continue}void 0==q[g]?f=0:void 0==q[g][f]&&(f=0);var y=q[g][f];y&&!q[1]&&1==this.parent.config.autoIncrement&&(this.options.columns[m].type==_$_ac43[56]||this.options.columns[m].type==_$_ac43[14]?M(y)?y=S.shiftFormula(y,u,x-p[1]):y==Number(y)&&(y=Number(y)+v):this.options.columns[m].type==_$_ac43[184]&&(y=new Date(y),
|
|
181
|
+
y.setDate(y.getDate()+v),y=y.getFullYear()+_$_ac43[185]+jSuites.two(parseInt(y.getMonth()+1))+_$_ac43[185]+jSuites.two(y.getDate())+_$_ac43[132]+_$_ac43[186]));y={x:m,y:x,value:y};h&&null!=h[w]&&(y.style=h[w],w++,w>=h.length&&(w=0));l.push(y)}f++;p[0]!=a&&u++}g++;v++}l.length&&(r[0].x<a&&(a=r[0].x),r[0].y<b&&(b=r[0].y),r[r.length-1].x>d&&(d=r[r.length-1].x),r[r.length-1].y>e&&(e=r[r.length-1].y),this.setValue(l),this.resetBorders(_$_ac43[138],!0),this.updateSelectionFromCoords(a,b,d,e))};k.end=function(a){ha.event=
|
|
182
|
+
!1;ha.execute.call(this,!0)};k.cancel=function(a){ha.event=!1;this.resetBorders(_$_ac43[138],!0)};return k}(),za=function(){var k=function(a){a.getData=k[_$_ac43[51]];a.getJson=k[_$_ac43[51]];a.setData=k[_$_ac43[11]];a.loadData=k.load;a.getRowData=k.getRowData;a.setRowData=k.setRowData;a.getColumnData=k.getColumnData;a.setColumnData=k.setColumnData;a.updateData=k.update;a.refresh=k.refresh;a.data=k[_$_ac43[51]];a.download=k.download;a.copy=k.copy;a.paste=k.paste;a.cut=function(){return a.copy(!0)}};
|
|
183
|
+
k[_$_ac43[51]]=function(a,c,b){!0===a&&(a=this.getHighlighted());for(var d=a?!0:!1,e,f=[],g=this.options.columns.length,h=this.options.data.length,l,n=this.dataType&&typeof b==_$_ac43[13]?1:0,p=0;p<h;p++){l=null;e=n?{}:[];for(var q=0;q<g;q++){var r;if(!(r=!d)){r=a[1];var w=a[2],m=a[3];r=q>=a[0]&&q<=w&&p>=r&&p<=m?!0:!1}if(r&&(!d||!this.results||-1!=this.results.indexOf(p))){r=K.call(this,q,p);if(c){if(d&&!1===this.rows[p].visible)continue;l=aa.processed.call(this,q,p);void 0!==l&&(r=l)}b&&r.match&&
|
|
184
|
+
(r.match(b)||r.match(/\n/)||r.match(/"/))&&(r=r.replace(new RegExp(_$_ac43[187],_$_ac43[188]),_$_ac43[189]),r=_$_ac43[187]+r+_$_ac43[187]);n?jSuites.path.call(e,_$_ac43[3]+V.call(this,q),r):e.push(r);l=!0}}l&&(b?f.push(e.join(b)):f.push(e))}return b?f.join(_$_ac43[10])+_$_ac43[10]:f};k.parse=function(){for(var a,c={},b=0,d,e=[],f=this.options.data,g=0;g<f.length;g++)a=null,d=g,f[g].data&&(Array.isArray(f[g].data)||typeof f[g].data==_$_ac43[84])&&(typeof f[g].id==_$_ac43[14]&&(a=parseInt(f[g].id)),
|
|
185
|
+
typeof f[g].row==_$_ac43[14]&&(d=f[g].row),e[d]=f[g].data,f[g]=[]),d>b&&(b=d),a&&(c[d]=a);if(Object.keys(e).length)for(g=0;g<=b;g++)e[g]&&(f[g]=e[g]);b=this.getPrimaryKey();if(!1!==b)for(b=V.call(this,b),g=0;g<f.length;g++)c[g]||!1===b||(a=parseInt(f[g][b]),0<a&&(c[g]=a));return c};k.type=function(){for(var a=this.dataType=0;a<this.options.columns.length;a++)typeof this.options.columns[a].name!==_$_ac43[13]&&(this.dataType=1)};k[_$_ac43[11]]=function(a){a=k.standardize(a);var c={},b=[],d={};var e=
|
|
186
|
+
Object.keys(a[0]).length-this.options.columns.length;0<e&&this.insertRow(e);var f=a.length-this.options.data.length;0<f&&this.insertRow(f);for(var g=0;g<this.options.data.length;g++){void 0===a[g]&&(a[g]={row:g,data:[]});for(var h=0;h<this.options.columns.length;h++)a[g].data[h]||(a[g].data[h]=_$_ac43[3])}for(h=0;h<this.options.columns.length;h++){var l=V.call(this,h);d[l]=h}for(g=0;g<a.length;g++){f=a[g].row;l=Object.keys(a[g].data);for(h=0;h<l.length;h++)e=null,void 0!==d[l[h]]?e=d[l[h]]:-1<l[h]&&
|
|
187
|
+
(e=parseInt(l[h])),null!==e&&b.push({x:e,y:f,value:a[g].data[l[h]]});a[g].id&&(c[f]=a[g].id)}pa.setId.call(this,c);aa[_$_ac43[11]].call(this,b,null,!0)};k.build=function(){this.results=null;this.rows=[];this.records=[];this.sequence=0;if(this.options.data){var a=k.parse.call(this),c=this.options.data.length;this.options.minDimensions[1]>c&&(c=this.options.minDimensions[1]);for(var b=0;b<c;b++){var d=a[b]?a[b]:null;ia.row.call(this,b,d)}}k.type.call(this)};k.load=function(a){this.resetBorders();this.resetSelection();
|
|
188
|
+
this.tbody.innerText=_$_ac43[3];this.options.data=a;k.build.call(this);C.call(this)};k.refresh=function(a){if(typeof a!==_$_ac43[13])for(var c=0;c<this.options.columns.length;c++){var b=this.records[a]&&this.records[a][c].element?this.records[a][c].element:null,d=Z[_$_ac43[51]].call(this,c,a);typeof d[0].updateCell==_$_ac43[85]&&d[0].updateCell(b,K.call(this,c,a),c,a,this,d[1]);b&&I.applyOverflow.call(this,b,c,a)}else if(this.options.url){var e=this;1==this.parent.config.loadingSpin&&jSuites.loading.show();
|
|
189
|
+
jSuites.ajax({url:this.options.url,method:_$_ac43[59],dataType:_$_ac43[60],success:function(f){e.setData(f);jSuites.loading.hide()}})}};k.getRowData=function(a,c){if(typeof this.options.data[a]===_$_ac43[13])return!1;if(c){if(this.dataType){c={};for(var b=0;b<this.options.columns.length;b++){var d=_$_ac43[3]+V.call(this,b),e=_$_ac43[3]+aa.processed.call(this,b,a,!0);jSuites.path.call(c,d,e)}}else for(c=[],b=0;b<this.options.columns.length;b++)c.push(aa.processed.call(this,b,a,!0));return c}return JSON.parse(JSON.stringify(this.options.data[a]))};
|
|
190
|
+
k.setRowData=function(a,c,b){for(var d=[],e=0;e<this.options.columns.length;e++)typeof c[e]===_$_ac43[13]&&(c[e]=_$_ac43[3]),d.push({x:e,y:a,value:c[e]});d.length&&this.setValue(d,null,b)};k.getColumnData=function(a,c){if(typeof this.options.columns[a]===_$_ac43[13])return!1;for(var b=[],d=0;d<this.options.data.length;d++){var e=c?aa.processed.call(this,a,d,!0):K.call(this,a,d);b.push(e)}return b};k.setColumnData=function(a,c,b){for(var d=[],e=0;e<this.rows.length;e++)typeof c[e]===_$_ac43[13]&&(c[e]=
|
|
191
|
+
_$_ac43[3]),d.push({x:a,y:e,value:c[e]});d.length&&this.setValue(d,null,b)};k.copy=function(a){var c=this,b=this.getHighlighted(),d=function(){c.setBorder(b[0],b[1],b[2],b[3],_$_ac43[127]);c.borders.copying.clear=1==a?!0:!1},e=k[_$_ac43[51]].call(this,b,!0,_$_ac43[190]),f=B.call(this.parent,_$_ac43[191],this,b,e);if(f)e=f;else if(!1===f)return!1;navigator.clipboard?navigator.clipboard.writeText(e).then(d):(this.parent.textarea.value=e,this.parent.textarea.select(),document.execCommand(_$_ac43[192]),
|
|
192
|
+
d());return e};k.paste=function(a,c,b){if(!N.call(this.parent,this))return!1;var d=this,e=function(){d.borders.copying&&(d.resetBorders(_$_ac43[127],!0),d.borders.copying.clear=!1)},f=b,g=null,h=this.options.style,l=null,n=null,p=[];if(this.borders.copying){var q=[this.borders.copying.x1,this.borders.copying.y1,this.borders.copying.x2,this.borders.copying.y2];l=q[0];n=q[1];var r=jSuites.hash(b),w=jSuites.hash(k[_$_ac43[51]].call(this,q,!0,_$_ac43[190]));if(r!=w)e();else{var m=0,v=0;b=k[_$_ac43[51]].call(this,
|
|
193
|
+
q,!1,!1);for(r=q[1];r<=q[3];r++)if(!this.results||-1!=this.results.indexOf(r)){p[v]=[];m=0;for(w=q[0];w<=q[2];w++)g=A.getColumnNameFromCoords(w,r),p[v][m]=h&&h[g]?h[g]:_$_ac43[193],m++;v++}}}a=parseInt(a);c=parseInt(c);100<f.length&&!this.options.pagination&&!C.limited.call(this)&&console.log(_$_ac43[194]);if(r=B.call(this.parent,_$_ac43[195],this,b,a,c,p,f))b=r;else if(!1===r)return!1;if(b){Array.isArray(b)||(b=A.parseCSV(b,_$_ac43[190]));if(f=this.getHighlighted()){g=[];m=[];v=[];h=[];var u=0,x=
|
|
194
|
+
0;for(r=f[1];r<=f[3];r++)if(!this.results||-1!=this.results.indexOf(r)){g=[];m=[];for(w=f[0];w<=f[2];w++)g.push(b[x][u]),p&&p[x]&&p[x][u]?m.push(p[x][u]):m.push(_$_ac43[3]),u++,u>=b[0].length&&(u=0);v.push(g);h.push(m);x++;x>=b.length&&(x=0)}0==v.length%b.length&&0==v[0].length%b[0].length&&(b=v,p=h)}h=null;f=[];if(this.borders.copying&&!0===this.borders.copying.clear){for(r=q[1];r<=q[3];r++)for(w=q[0];w<=q[2];w++)(!this.results||this.results&&0<=this.results.indexOf(r))&&f.push({x:w,y:r,value:_$_ac43[3],
|
|
195
|
+
style:_$_ac43[3]});e()}r=a+b[0].length-this.options.columns.length;0<r&&this.insertColumn(r);r=c+b.length-this.rows.length;0<r&&this.insertRow(r);m=g=a;u=v=c;x=null;this.results&&(h=this.results.indexOf(c));for(r=0;r<b.length;r++)for(w=0;w<b[r].length;w++){null!==l&&null!==n&&b[r][w][0]==_$_ac43[12]&&(b[r][w]=S.shiftFormula(b[r][w],a-l,c-n));m=a+w;u=c+r;this.results&&(u=this.results[h+r]);var y={x:m,y:u,value:b[r][w]};p&&p[r]&&p[r][w]&&(y.style=p[r][w]);f.push(y);null===x&&ta.isSelected.call(this,
|
|
196
|
+
m,u,q)&&(x=!0)}x&&e();f.length&&(aa[_$_ac43[11]].call(this,f,null,this.parent.config.forceUpdateOnPaste?!0:!1),B.call(this.parent,_$_ac43[196],this,f),this.updateSelectionFromCoords(g,v,m,u))}};k.download=function(a,c){if(this.parent.config.allowExport){void 0===c&&(c=!0);var b=_$_ac43[3];if(1==a||1==this.parent.config.includeHeadersOnDownload)b+=this.getHeaders().replace(/\s+/gm,_$_ac43[132])+_$_ac43[10];b+=k[_$_ac43[51]].call(this,null,c,this.options.csvDelimiter);c=new Blob([_$_ac43[198]+b],{type:_$_ac43[199]});
|
|
197
|
+
window.navigator&&window.navigator.msSaveOrOpenBlob?window.navigator.msSaveOrOpenBlob(c,this.options.csvFileName+_$_ac43[200]):(a=document.createElement(_$_ac43[201]),c=URL.createObjectURL(c),a.href=c,a.setAttribute(_$_ac43[202],this.options.csvFileName+_$_ac43[200]),document.body.appendChild(a),a.click(),a.parentNode.removeChild(a))}else console.error(_$_ac43[197])};k.standardize=function(a){a||(a=[]);Array.isArray(a)||(a=[a]);void 0==a[0]||Array.isArray(a[0])||typeof a[0]==_$_ac43[84]||(a=[a]);
|
|
198
|
+
for(var c=0;c<a.length;c++){var b={};Array.isArray(a[c])||void 0==a[c].data?b.data=a[c]:b=a[c];b.row=void 0==a[c].row?c:a[c].row;a[c]=b}return a};return k}(),Qa=function(){var k=function(a){a.getLabel=k[_$_ac43[51]];a.getLabelFromCoords=k[_$_ac43[51]]};k[_$_ac43[51]]=function(a,c,b){if(typeof a==_$_ac43[17]){a=A.getCoordsFromColumnName(a);var d=a[0];c=a[1]}else d=a;return this.getProcessed(d,c,b)};return k}(),Ca=function(){var k=function(a){a.getDefinedNames=k[_$_ac43[51]];a.setDefinedNames=k[_$_ac43[11]]};
|
|
199
|
+
k[_$_ac43[11]]=function(a){var c=Object.keys(a);if(c.length){for(var b=0;b<c.length;b++)this.parent.config.definedNames[c[b]]=a[c[b]];G.call(this,_$_ac43[203],[a])}};k[_$_ac43[51]]=function(a){var c=this.parent.config.definedNames;return a?c[a]:c};k.updateAll=function(a,c){var b,d={};if(b=this.parent.config.definedNames){var e=Object.keys(b);if(e.length){for(var f=this.getWorksheetName(),g=0;g<e.length;g++){var h=S.update.call(this,b[e[g]],a,c,f);h!==b[e[g]]&&(d[e[g]]=h)}k[_$_ac43[11]].call(this,
|
|
200
|
+
d)}}};k.updateWorksheetName=function(a,c){var b,d={};if(b=this.parent.config.definedNames){var e=Object.keys(b);if(e.length){for(var f=0;f<e.length;f++){var g=S.updateWorksheetName(b[e[f]],a,c);g!==b[e[f]]&&(d[e[f]]=g)}k[_$_ac43[11]].call(this,d)}}};return k}(),fa=function(){var k=[_$_ac43[204],_$_ac43[205],_$_ac43[206],_$_ac43[207],_$_ac43[208]],a=[_$_ac43[185],_$_ac43[151],_$_ac43[209],_$_ac43[210],_$_ac43[211],_$_ac43[212],_$_ac43[1],_$_ac43[213],_$_ac43[25],_$_ac43[214],_$_ac43[12],_$_ac43[215],
|
|
201
|
+
_$_ac43[216]],c=[],b=function(){if(0<c.length){for(var f=0;f<c.length;f++)da.destroy.call(this,c[f]);c=[]}},d=function(f){b.call(this);for(var g=0,h=[],l,n=0;n<f.children.length;n++)if(l=f.children[n].getAttribute(_$_ac43[217])){h[l]||(h[l]=k[g++],4<g&&(g=0));f.children[n].style.color=h[l];if(-1===l.indexOf(_$_ac43[135])){if(0<=l.indexOf(_$_ac43[136])){var p=l.split(_$_ac43[136]),q=A.getCoordsFromColumnName(p[0]);p=A.getCoordsFromColumnName(p[1])}else p=q=A.getCoordsFromColumnName(l);ta[_$_ac43[11]].call(this,
|
|
202
|
+
q[0],q[1],p[0],p[1],null,l,h[l])}c.push(l)}},e=function(f,g){f.classList.add(_$_ac43[92]);f.classList.add(_$_ac43[218]);f.classList.add(_$_ac43[219]);f.classList.add(_$_ac43[220]);f.setAttribute(_$_ac43[221],!0);f.onclick=function(h){h=h.changedTouches&&h.changedTouches[0]?h.changedTouches[0].clientX:h.clientX;var l=this.getBoundingClientRect();24>l.width-(h-l.left)&&(e.current=f,f.classList.add(_$_ac43[222]))};f.onblur=function(){f.worksheet&&(b.call(f.worksheet),typeof f.onchange==_$_ac43[85]&&
|
|
203
|
+
f.onchange.call(f),f.worksheet=null)};f.onchange=g};e.current=null;e.parse=function(f){for(var g=_$_ac43[3],h=_$_ac43[3],l=window.getSelection(),n=document.createRange(),p=A.getCaretIndex.call(this.parent,f),q=S.tokenize(f.innerText.replace(/(\r\n|\n|\r)/gm,_$_ac43[3])),r=0;r<q.length;r++)q[r]&&S.tokenIdentifier.test(q[r].trim())?(r==q.length-1&&(h=_$_ac43[223]),g+=_$_ac43[224]+h+_$_ac43[225]+q[r].trim().replace(/\$/g,_$_ac43[3])+_$_ac43[226]+q[r]+_$_ac43[227]):g+=q[r];f.innerHTML=g;g=null;for(r=
|
|
204
|
+
0;r<f.childNodes.length&&!(g=f.childNodes[r],h=g.tagName?g.innerText.length:g.length,0>=p-h);r++)p-=h;g&&(g.tagName?n.setStart(g.firstChild,p):n.setStart(g,p),l.removeAllRanges(),l.addRange(n));d.call(this,f)};e.close=function(f){b.call(this);f?f.classList.remove(_$_ac43[92]):e.current&&(typeof e.current.onchange==_$_ac43[85]&&e.current.onchange.call(e.current),e.current.classList.remove(_$_ac43[222]),e.current.worksheet=null,e.current=null)};e.getName=function(f,g,h,l,n){f=A.getColumnNameFromCoords(f,
|
|
205
|
+
g);h=A.getColumnNameFromCoords(h,l);n.ctrlKey&&(f=h);return f!==h?(n=f+_$_ac43[136]+h,n=S.getTokensFromRange.call(this,n),S.getRangeFromTokens.call(this,n)):f};e.range=function(f,g,h,l,n){e.current.getAttribute(_$_ac43[228])==_$_ac43[229]&&(f=h,g=l);f=e.getName.call(this,f,g,h,l,n);g=document.createElement(_$_ac43[230]);g.innerText=f;g.setAttribute(_$_ac43[217],f);e.current.innerText=_$_ac43[3];e.current.appendChild(g);d.call(this,e.current);jSuites.focus(g);n.preventDefault()};e.update=function(f,
|
|
206
|
+
g,h,l,n){var p=this,q=jSuites.getNode();if(q){var r=e.getName.call(this,f,g,h,l,n);f=function(w){var m=document.createElement(_$_ac43[230]);m.innerText=r;m.setAttribute(_$_ac43[217],r);q.parentNode===p.parent.input&&!1===w?q.parentNode.insertBefore(m,q.nextSibling):p.parent.input.appendChild(m);q=m};if(q.getAttribute(_$_ac43[217]))n.ctrlKey?(p.parent.input.appendChild(document.createTextNode(_$_ac43[25])),f(!0)):(q.innerText=r,q.setAttribute(_$_ac43[217],r));else{if(q.innerText!==_$_ac43[3]&&-1==
|
|
207
|
+
a.indexOf(q.innerText.slice(-1))||q.nextElementSibling&&q.nextElementSibling.getAttribute(_$_ac43[217]))return!1;f(!1)}jSuites.focus(q);d.call(p,p.parent.input);n.preventDefault();return!0}return!1};e.onkeydown=function(f){f.target.worksheet=this;if(f.ctrlKey){if(67==f.which||88==f.which)f=window.getSelection().toString().replace(/(\r\n|\n|\r)/gm,_$_ac43[3]),navigator.clipboard?navigator.clipboard.writeText(f):(this.parent.textarea.value=f,this.parent.textarea.select(),document.execCommand(_$_ac43[192]))}else if(36==
|
|
208
|
+
f.which){var g=window.getSelection(),h=document.createRange();h.setStart(f.target,0);g.removeAllRanges();g.addRange(h)}else 35==f.which?jSuites.focus(f.target):187==f.which&&!f.target.innerText.replace(/(\r\n|\n|\r)/gm,_$_ac43[3])&&f.target.getAttribute(_$_ac43[94])&&f.target.removeAttribute(_$_ac43[94])};return e}(),S=function(){var k=new RegExp(/^(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]+)(:\$?[A-Z]+\$?[0-9]+)?$/i),a=function(h){h=c(h);for(var l=[_$_ac43[185],_$_ac43[151],_$_ac43[209],_$_ac43[210],_$_ac43[211],
|
|
209
|
+
_$_ac43[231]],n=[_$_ac43[212],_$_ac43[232],_$_ac43[1],_$_ac43[2],_$_ac43[213],_$_ac43[233],_$_ac43[25],_$_ac43[214],_$_ac43[12],_$_ac43[215],_$_ac43[216]],p=_$_ac43[3],q=[],r=0,w=0;w<h.length;w++){if(h[w]==_$_ac43[187]||h[w]==_$_ac43[133])r=0==r?1:0;0==r&&(-1<l.indexOf(h[w])||-1<n.indexOf(h[w]))?(p&&(q.push(p),p=_$_ac43[3]),q.push(h[w])):p+=h[w]}p&&q.push(p);for(w=0;w<q.length;w++)-1==q[w].indexOf(_$_ac43[187])&&-1==q[w].indexOf(_$_ac43[133])&&(q[w]=q[w].replace(/\s/g,_$_ac43[3]));return q},c=function(h,
|
|
210
|
+
l){for(var n=_$_ac43[3],p=0,q=[_$_ac43[12],_$_ac43[135],_$_ac43[216],_$_ac43[215]],r=0;r<h.length;r++)h[r]==_$_ac43[187]&&(p=0==p?1:0),1==p?n+=h[r]:(n+=h[r].toUpperCase(),1==l&&0<r&&h[r]==_$_ac43[12]&&-1==q.indexOf(h[r-1])&&-1==q.indexOf(h[r+1])&&(n+=_$_ac43[12]));return n},b=function(h){h.setFormula=b[_$_ac43[11]];h.executeFormula=b.execute;h.formula=[]};b.run=function(h,l){var n=_$_ac43[3],p=Object.keys(l);if(p.length){for(var q={},r=0;r<p.length;r++){var w=p[r].replace(/!/g,_$_ac43[27]);0<w.indexOf(_$_ac43[27])&&
|
|
211
|
+
(w=w.split(_$_ac43[27]),q[w[0]]=!0)}w=Object.keys(q);for(r=0;r<w.length;r++)n+=_$_ac43[234]+w[r]+_$_ac43[235];for(r=0;r<p.length;r++)w=p[r].replace(/!/g,_$_ac43[27]),jSuites.isNumeric(l[p[r]])||(q=l[p[r]].match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&q.length&&(l[p[r]]=e(q,l[p[r]])),n=0<w.indexOf(_$_ac43[27])?n+(w+_$_ac43[236]+l[p[r]]+_$_ac43[237]):n+(_$_ac43[234]+w+_$_ac43[236]+l[p[r]]+_$_ac43[237])}h=h.replace(/\$/g,_$_ac43[3]);(q=h.match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&
|
|
212
|
+
q.length&&(h=e(q,h));h=h.replace(/!/g,_$_ac43[27]);return(new Function(n+_$_ac43[238]+h))()};b[_$_ac43[11]]=function(){};var d=function(h){h=c(h,!0);return h.replace(/\$/g,_$_ac43[3])},e=function(h,l){for(var n=0;n<h.length;n++){var p=b.getTokensFromRange.call(this,h[n]);l=l.replace(h[n],_$_ac43[213]+p.join(_$_ac43[25])+_$_ac43[233])}return l},f=function(h,l,n){for(var p=this.config.definedNames,q=0;q<h.length;q++)h[q]&&p&&p[h[q]]&&(l=l.replace(h[q],p[h[q]]),n&&(n[h[q]]=p[h[q]]));return d(l)},g=function(h,
|
|
213
|
+
l){var n;if(n=this.records[l][h].a)for(var p=0;p<n.length;p++)for(var q=0;q<n[p].length;q++)n[p][q]&&(n[p][q].innerText=_$_ac43[3],this.records[l+p][h+q].v=_$_ac43[3]);this.records[l][h].a=[]};b.execute=function(h,l,n,p,q){if(1==this.parent.processing)return null!==l&&null!==n&&this.parent.queue.push([this,l,n]),_$_ac43[3];var r=[],w=function(H,L,E,ba){if(void 0!=L&&void 0!=E){var ra=A.getColumnNameFromCoords(L,E);E=ba.getWorksheetName()+_$_ac43[27]+ra;r[E]||(r[E]=0);r[E]++;if(3<r[E])throw{error:_$_ac43[239],
|
|
214
|
+
message:_$_ac43[240],reference:E};}else ra=null;q||(H=d(H));var J=H,U=J.match(/[A-Z_]+[A-Z0-9_\.]*/g);U&&U.length&&(J=f.call(ba.parent,U,J,m));(U=J.match(/(('.*?'!)|(\w*!))?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&U.length&&(J=e.call(ba,U,J));U=[];J=a(J);for(var R=0;R<J.length;R++)J[R]&&k.test(J[R])&&U.push(J[R]);if(U){if(-1<U.indexOf(ra))throw{error:_$_ac43[241],message:_$_ac43[242]};for(J=0;J<U.length;J++){R=U[J].split(_$_ac43[135]);R[1]?(L=R[1],R=D(R[0]),E=ba.getWorksheetName()+_$_ac43[27]+
|
|
215
|
+
ra):(L=R[0],R=ba,E=ra);if(typeof R==_$_ac43[13]||typeof R.formula==_$_ac43[13])throw{error:_$_ac43[243],message:_$_ac43[244]};E&&(R.formula[L]||(R.formula[L]=[]),0>R.formula[L].indexOf(E)&&R.formula[L].push(E));if(!m[U[J]]){E=A.getCoordsFromColumnName(L);L=E[0];E=E[1];var oa=void 0!==R.records[E][L].v?R.records[E][L].v:K.call(R,L,E);m[U[J]]||((_$_ac43[3]+oa).substr(0,1)==_$_ac43[12]?m[U[J]]=w(oa,L,E,R):(oa?oa!=Number(oa)&&(oa=_$_ac43[187]+oa+_$_ac43[187]):oa=0,m[U[J]]=oa))}}}return H.substr(1)},m=
|
|
216
|
+
{};try{if(h=w(h,l,n,this)){var v=q?b.run(h,m):t.formula(h,m,l,n,this);if(!1!==p&&void 0!=l&&void 0!=n)if(v instanceof Date)this.records[n][l].v=jSuites.calendar.dateToNum(v);else if(Array.isArray(v)){g.call(this,l,n);p=[];for(var u=null,x=0;x<v.length;x++)for(var y=0;y<v[x].length;y++)null===u&&(0<x&&x>y&&this.options.data[n+x][l+y]?u=_$_ac43[245]:(this.records[n+x][l+y].v=v[x][y],this.records[n+x][l+y].element&&(p[x]||(p[x]=[]),p[x][y]=this.records[n+x][l+y].element,this.records[n+x][l+y].element.innerText=
|
|
217
|
+
v[x][y])));null===u?(u=v[0][0],this.records[n][l].a=p):g.call(this,l,n);v=this.records[n][l].v=u}else this.records[n][l].v=v;return v}}catch(H){return 1==this.parent.config.debugFormulas&&console.log(h,m,H),H&&H.error?H.error:_$_ac43[243]}};b.update=function(h,l,n,p){var q=null,r=null,w=function(u){n&&n[u]&&(u=_$_ac43[246]);l[u]&&(u=l[u]);return u};h=c(h,!0);h=a(h);for(var m=0;m<h.length;m++)if(h[m]&&k.test(h[m])){if(-1==h[m].indexOf(_$_ac43[135])){if(r=h[m],q=_$_ac43[3],p)continue}else if(r=h[m].split(_$_ac43[135]),
|
|
218
|
+
q=r[0],r=r[1],p!=q)continue;if(0<=r.indexOf(_$_ac43[136])){r=b.getTokensFromRange.call(this,r);for(var v=0;v<r.length;v++)r[v]=w(r[v]);r=b.getRangeFromTokens.call(this,r)}else-1==r.indexOf(_$_ac43[247])?r=w(r):(r=w(r.replace(/\$/g,_$_ac43[3])),r=_$_ac43[247]+r.match(/[A-Z]+/g)+_$_ac43[247]+r.match(/[0-9]+/g));q&&(r=q+_$_ac43[135]+r);h[m]=r}return h.join(_$_ac43[3])};b.getChain=function(h){if(void 0===h)return[];var l=[],n=[],p=[],q=function(m){if(0<=m.indexOf(_$_ac43[27])){var v=m.split(_$_ac43[27]),
|
|
219
|
+
u=v[0],x=v[1];v=D(v[0])}else v=this,u=v.getWorksheetName(),x=m;if(v.formula[x]&&!p[m]){var y=!1;p[m]=!0;for(m=0;m<v.formula[x].length;m++){var H=v.formula[x][m];-1==H.indexOf(_$_ac43[27])&&(H=u+_$_ac43[27]+H);if(!n[H]){var L=v.getValue(H);M(L)?l.push([H,L,b.getTokens.call(v,L,u)]):(y=!0,v.formula[x][m]=null);q.call(v,H);n[H]=!0}}1==y&&(v.formula[x]=v.formula[x].filter(function(E){return null!=E}))}},r=Object.keys(h);for(h=0;h<r.length;h++)q.call(this,r[h]);r=0;for(h=l.length-1;0<=h;h--){for(var w=
|
|
220
|
+
0;w<h;w++)if(0<=l[w][2].indexOf(l[h][0])){l.splice(w,0,l.splice(h,1)[0]);h=l.length;break}r++;if(1E6<r){console.error(_$_ac43[248]);break}}n=[];for(h=0;h<l.length;h++)n[l[h][0]]=l[h][1];return n};b.updateAll=function(h,l){var n,p;Ca.updateAll.call(this,h,l);var q=Object.keys(this.formula);var r=[];var w=[];for(n=0;n<q.length;n++){var m=q[n];var v=this.formula[m];if(l&&l[m])for(var u=0;u<v.length;u++)h[v[u]]&&(v[u]=h[v[u]]),w[v[u]]=!0;else{var x=[];for(u=0;u<v.length;u++)l&&l[v[u]]||(h[v[u]]&&(v[u]=
|
|
221
|
+
h[v[u]]),w[v[u]]=!0,x.push(v[u]));x.length&&(h[m]&&(m=h[m]),r[m]=x)}}this.formula=r;x=this.getWorksheetName();for(var y=0;y<t.spreadsheet.length;y++)for(var H=t.spreadsheet[y].worksheets,L=0;L<H.length;L++)if(H[L].getWorksheetName()!==x)for(q=Object.keys(H[L].formula),n=0;n<q.length;n++){r=[];v=H[L].formula[q[n]];for(u=0;u<v.length;u++)m=v[u].split(_$_ac43[27]),m[0]==x&&m[1]?l&&l[m[1]]||(h[m[1]]&&(m[1]=h[m[1]]),r.push(m[0]+_$_ac43[27]+m[1])):r.push(v[u]);H[L].formula[q[n]]=r}q=[];m=Object.keys(w);
|
|
222
|
+
for(u=0;u<m.length;u++)0<=m[u].indexOf(_$_ac43[27])?(v=m[u].split(_$_ac43[27]),r=D(v[0]),n=v[1],x=this.getWorksheetName(),v=v[0]):(r=this,n=m[u],x=null,v=this.getWorksheetName()),(p=r.getValue(n))&&M(p)&&(r=b.update.call(r,p,h,l,x),r!=p&&(w[m[u]]=r,n=A.getCoordsFromColumnName(n),q[v]||(q[v]=[]),q[v].push({x:n[0],y:n[1],value:r,force:!0})));m=Object.keys(q);for(h=0;h<m.length;h++)r=D(m[h]),q[m[h]]=aa.applyValues.call(r,q[m[h]]),aa.setValueChained.call(r,q[m[h]]),G.call(r,_$_ac43[107],{data:q[m[h]]})};
|
|
223
|
+
b.updateWorksheetName=function(h,l,n){for(var p=a(h),q=0;q<p.length;q++)h=p[q].split(_$_ac43[135]),h[1]&&(h[0]=h[0].replace(new RegExp(_$_ac43[133],_$_ac43[188]),_$_ac43[3]),h[0].toUpperCase()==l.toUpperCase()&&(h[0]=n,0<=h[0].indexOf(_$_ac43[132])&&(h[0]=_$_ac43[133]+h[0]+_$_ac43[133]),p[q]=h.join(_$_ac43[135])));return p.join(_$_ac43[3])};b.updateWorksheetNames=function(h,l){for(var n,p,q=0;q<t.spreadsheet.length;q++)for(var r=[],w=t.spreadsheet[q].worksheets,m=0;m<w.length;m++){for(var v=0;v<w[m].options.data.length;v++)for(var u=
|
|
224
|
+
0;u<w[m].options.data[v].length;u++)(n=w[m].options.data[v][u])&&M(n)&&(p=b.updateWorksheetName(n,h,l),p!=n&&r.push({x:u,y:v,value:p,force:!0}));r=aa.applyValues.call(w[m],r);G.call(w[m],_$_ac43[107],{data:r})}};b.shiftFormula=function(h,l,n){var p=a(h,!0);h=function(m){if(-1==m.indexOf(_$_ac43[135])){m=A.getCoordsFromColumnName(m);var v=_$_ac43[3]}else v=p[q].split(_$_ac43[135]),m=A.getCoordsFromColumnName(v[1]),v=v[0]+_$_ac43[135];var u=m[0]+l;m=m[1]+n;return m=0>u||0>m?_$_ac43[246]:v+A.getColumnNameFromCoords(u,
|
|
225
|
+
m)};for(var q=0;q<p.length;q++)if(k.test(p[q])&&-1==p[q].indexOf(_$_ac43[247])){var r=-1==p[q].indexOf(_$_ac43[135])?[_$_ac43[3],p[q]]:p[q].split(_$_ac43[135]);if(-1==r[1].indexOf(_$_ac43[136]))r[1]=h(r[1]);else{var w=r[1].split(_$_ac43[136]);r[1]=h(w[0])+_$_ac43[136]+h(w[1])}p[q]=r[0]?r.join(_$_ac43[135]):r[1]}return p.join(_$_ac43[3])};b.getTokensFromRange=function(h){var l=this,n=_$_ac43[3],p=_$_ac43[3];0<=h.indexOf(_$_ac43[27])?p=_$_ac43[27]:0<=h.indexOf(_$_ac43[135])&&(p=_$_ac43[135]);h=h.replace(/\$/g,
|
|
226
|
+
_$_ac43[3]);p&&(n=h.split(p),l=D(n[0]),h=n[1],n=n[0]+p);p=[];h=h.split(_$_ac43[136]);var q=A.getCoordsFromColumnName(h[0]),r=A.getCoordsFromColumnName(h[1]);if(q[0]<=r[0]){h=q[0];var w=r[0]}else h=r[0],w=q[0];if(null===q[1]&&null==r[1]){var m=0;q=0;l.options&&l.options.data&&(q=l.options.data.length-1)}else q[1]<=r[1]?(m=q[1],q=r[1]):(m=r[1],q=q[1]);for(l=m;l<=q;l++)for(m=h;m<=w;m++)p.push(n+A.getColumnNameFromCoords(m,l));return p};b.getRangeFromTokens=function(h){h=h.filter(function(p){return p!=
|
|
227
|
+
_$_ac43[246]});for(var l=_$_ac43[3],n=0;n<h.length;n++)0<=h[n].indexOf(_$_ac43[27])&&(l=h[n].split(_$_ac43[27]),h[n]=l[1],l=l[0]);l&&(l+=_$_ac43[27]);h.sort(function(p,q){p=A.getCoordsFromColumnName(p);q=A.getCoordsFromColumnName(q);return p[1]>q[1]?1:p[1]<q[1]?-1:p[0]>q[0]?1:p[0]<q[0]?-1:0});return h.length?l+(h[0]+_$_ac43[136]+h[h.length-1]):_$_ac43[246]};b.getTokens=function(h,l){var n=d(h);h.replace(/!/g,_$_ac43[27]);(h=n.match(/[A-Z_]+[A-Z0-9_\.]*/g))&&h.length&&(n=f.call(this.parent,h,n));(h=
|
|
228
|
+
n.match(/('.*?'?|\w*\.)?(\$?[A-Z]+\$?[0-9]*):(\$?[A-Z]+\$?[0-9]*)?/g))&&h.length&&(n=e.call(this,h,n));h=n.match(/('.*?'?|\w*\.)?(\$?[A-Z]+\$?[0-9]+)(:\$?[A-Z]+\$?[0-9]+)?/g);for(n=0;n<h.length;n++)-1==h[n].indexOf(_$_ac43[27])&&l&&(h[n]=l+_$_ac43[27]+h[n]);return h};b.tokenIdentifier=k;b.tokenize=a;return b}(),aa=function(){var k=function(a){a.name=V;a.value=K;a.getValue=k[_$_ac43[51]];a.getValueFromCoords=k.getFromCoords;a.setValue=k[_$_ac43[11]];a.setValueFromCoords=k.setFromCoords;a.setCheckRadioValue=
|
|
229
|
+
k.setCheckRadio;a.getProcessed=k.processed};k[_$_ac43[51]]=function(a,c){var b=this;if(typeof a==_$_ac43[84]){var d=a.x;a=a.y}else 0<=a.indexOf(_$_ac43[27])&&(b=a.split(_$_ac43[27]),a=b[1],b=D(b[0])),a=A.getCoordsFromColumnName(a),d=a[0],a=a[1];return k.getFromCoords.call(b,d,a,c)};k.getFromCoords=function(a,c,b){var d=null;null!=a&&null!=c&&(d=b?k.processed.call(this,a,c):K.call(this,a,c));return d};k[_$_ac43[11]]=function(a,c,b){if(!N.call(this.parent,this))return!1;var d=null,e=null,f=null,g=[];
|
|
230
|
+
b=b?!0:!1;var h=function(p,q){var r=null;typeof p==_$_ac43[17]?(f=A.getCoordsFromColumnName(p),d=f[0],e=f[1]):p.tagName?(d=p.getAttribute(_$_ac43[42]),e=p.getAttribute(_$_ac43[43])):p.element&&p.element.tagName?(d=p.element.getAttribute(_$_ac43[42]),e=p.element.getAttribute(_$_ac43[43])):(d=p.x,e=p.y,void 0!==p.value&&(q=p.value),void 0!==p.style&&(r=p.style));p={x:d,y:e,value:q,force:b};null!==r&&(p.style=r);g.push(p)};if(a&&Array.isArray(a))for(var l=0;l<a.length;l++)h(a[l],c);else if(typeof a==
|
|
231
|
+
_$_ac43[84]&&void 0==a.x&&void 0==a.tagName)for(c=Object.keys(a),l=0;l<c.length;l++)h(c[l],a[c[l]]);else h(a,c);if(g.length){g=k.applyValues.call(this,g);this.parent.config.parseFormulas&&k.setValueChained.call(this,g);T.update.call(this,!0);this.refreshBorders();var n=this;setTimeout(function(){da.refresh.call(n)},250);if(g.length){Q.call(this.parent,{worksheet:n,action:_$_ac43[79],records:g,selection:this.selectedCell});a=this.getPrimaryKey();if(!1!==a)for(l=0;l<g.length;l++)g[l].x===a&&g[l].value&&
|
|
232
|
+
O.call(this,g[l]);G.call(this,_$_ac43[79],{data:g});B.call(this.parent,_$_ac43[249],this,g)}}};k.setFromCoords=function(a,c,b,d){var e=[];e.push({x:a,y:c,value:b});k[_$_ac43[11]].call(this,e,null,d)};k.setCheckRadio=function(){for(var a=[],c=this.getSelected(),b=0;b<c.length;b++){var d=c[b].x,e=c[b].y;if(!this.options.columns[d].readOnly&&this.options.columns[d].type==_$_ac43[250]){var f=K.call(this,d,e)?!1:!0;a.push({x:d,y:e,value:f})}}a.length&&k[_$_ac43[11]].call(this,a)};k.applyValues=function(a){for(var c,
|
|
233
|
+
b,d=this.options.style||{},e=[],f={},g=0;g<a.length;g++)if(c=a[g],b=this.updateCell(c.x,c.y,c.value,c.force),void 0!==b.value){if(void 0!==c.style){var h=A.getColumnNameFromCoords(c.x,c.y);b.style=f[h]=c.style;b.oldStyle=d&&d[h]?d[h]:_$_ac43[193]}e.push(b)}0<Object.keys(f).length&&La.update.call(this,f);return e};k.processed=function(a,c,b){var d=K.call(this,a,c);if(null===d)return null;var e=Z[_$_ac43[51]].call(this,a,c),f=e[1];f.type!=_$_ac43[49]&&f.type!=_$_ac43[251]&&f.type!=_$_ac43[252]&&f.type!=
|
|
234
|
+
_$_ac43[253]&&f.type!=_$_ac43[254]&&0!=f.process&&(!0===b||f.type!=_$_ac43[255]&&f.type!=_$_ac43[256]&&f.type!=_$_ac43[257])&&(f.type==_$_ac43[250]?d=e[0][_$_ac43[51]](f,d,b):this.records[c][a].element?d=1==this.parent.config.stripHTML?this.records[c][a].element.innerText:this.records[c][a].element.innerHTML:((_$_ac43[3]+d).substr(0,1)==_$_ac43[12]&&(d=this.executeFormula(d,a,c,!1)),e[0]&&typeof e[0][_$_ac43[51]]==_$_ac43[85]&&(d=e[0][_$_ac43[51]](f,d,b))));return d};k.setValueChained=function(a){for(var c,
|
|
235
|
+
b=[],d,e=0;e<a.length;e++)c=a[e],d=A.getColumnNameFromCoords(c.x,c.y),b[d]=c.value;b=S.getChain.call(this,b);a=Object.keys(b);for(e=0;e<a.length;e++)0<=a[e].indexOf(_$_ac43[27])?(c=a[e].split(_$_ac43[27]),d=c[1],c=D(c[0])):(d=a[e],c=this),d=A.getCoordsFromColumnName(d),I.update.call(c,d[0],d[1],b[a[e]],!0)};return k}(),I=function(){var k=function(a){a.getCell=k[_$_ac43[51]];a.getCellFromCoords=k[_$_ac43[51]];a.updateCell=k.update;a.updateCells=k.updateAll;a.getSelected=k.selected;a.getCells=k.getCells;
|
|
236
|
+
a.setCells=k.setCells;a.isAttached=k.attached};k.attached=function(a,c){return this.records[c]&&this.records[c][a]&&this.records[c][a].element&&this.records[c][a].element.parentNode&&this.records[c][a].element.parentNode.parentNode?!0:!1};k[_$_ac43[51]]=function(a,c,b){typeof a==_$_ac43[17]&&(c=A.getCoordsFromColumnName(a),a=c[0],c=c[1]);a=parseInt(a);c=parseInt(c);if(this.records[c]&&this.records[c][a]&&this.records[c][a].element)return this.records[c][a].element;var d=K.call(this,a,c);null===d&&
|
|
237
|
+
(d=_$_ac43[3]);return I.create.call(this,a,c,d,b)};k.getFromCoords=function(a,c,b){if(!a)return null;var d=[],e=a[0],f=a[1],g=a[2];a=a[3];for(b&&(b=this.results?A.invert(this.results):null);f<=a;f++)for(var h=e;h<=g;h++)if(!b||b[f])c?d.push(A.getColumnNameFromCoords(h,f)):d.push(this.records[f][h]);return d};k.selected=function(a,c){return k.getFromCoords.call(this,this.getHighlighted(),a,c)};k.getSelectedColumns=function(){var a=[],c=this.getHighlighted();if(c)for(var b=c[0];b<=c[2];b++)a.push(b);
|
|
238
|
+
return a};k.updateAll=function(a){for(var c=this.getPrimaryKey(),b=[],d=0;d<a.length;d++)void 0!==a[d].id?(O.call(this,a[d]),b.push({id:a[d].id,y:a[d].y}),!1!==c&&k.update.call(this,c,a[d].y,a[d].id,!0)):b.push(k.update.call(this,a[d].x,a[d].y,a[d].value,a[d].force));G.call(this,_$_ac43[106],[b])};k.update=function(a,c,b,d){var e=this.records[c];if(e=e&&e[a]?e[a]:null)if(e=e.element,!d&&e&&1==e.classList.contains(_$_ac43[18]))d={x:a,y:c};else{d=B.call(this.parent,_$_ac43[258],this,e,a,c,b);void 0!==
|
|
239
|
+
d&&(b=d);d=Z[_$_ac43[51]].call(this,a,c);typeof d[0].updateCell==_$_ac43[85]&&(d=d[0].updateCell(e,b,a,c,this,d[1]),void 0!==d&&(b=d));d={x:a,y:c};var f=K.call(this,a,c);f!==b&&(b=K.call(this,a,c,b),d.oldValue=f,d.value=b,e&&k.applyOverflow.call(this,e,a,c),B.call(this.parent,_$_ac43[259],this,e,a,c,d.value,d.oldValue))}else return!1;return d};k.create=function(a,c,b,d){var e=document.createElement(_$_ac43[147]);e.setAttribute(_$_ac43[42],a);e.setAttribute(_$_ac43[43],c);var f=Z[_$_ac43[51]].call(this,
|
|
240
|
+
a,c);f[0]&&typeof f[0].createCell==_$_ac43[85]&&(f=f[0].createCell(e,b,a,c,this,f[1]),void 0!==f&&(b=f));K.call(this,a,c,b);this.records[c][a]||ia.cell.call(this,a,c,b);this.records[c][a].element=e;!b&&this.records[c][a].v&&(e.innerText=this.records[c][a].v);k.applyProperties.call(this,e,a,c,d);k.applyOverflow.call(this,e,a,c);B.call(this.parent,_$_ac43[260],this,e,a,c,b);return e};k.getAttributes=function(a,c,b){b[a]||(b[a]={});a==_$_ac43[261]?b[a][c]=this.getValue(c):a==_$_ac43[262]?this.merged.cells&&
|
|
241
|
+
(c=this.merged.cells[c])&&(b[a][c]=this.options.mergeCells[c]):this.options[a]&&this.options[a][c]&&(b[a][c]=this.options[a][c])};k.setAttributes=function(a){a&&a.style&&this.setStyle(a.style);a&&a.comments&&this.setComments(a.comments);a&&a.meta&&this.setMeta(a.meta);a&&a.cells&&this.setCells(a.cells);a&&a.mergeCells&&this.setMerge(a.mergeCells);a&&a.values&&k.batch.call(this,a.values);a&&a.formulas&&k.batch.call(this,a.formulas,!0)};k.applyProperties=function(a,c,b,d){if(!d){d=A.getColumnNameFromCoords(c,
|
|
242
|
+
b);var e=this.options.style,f=this.options.comments,g=this.options.cells,h=this.options.rows;if(e&&e[d]){var l=(l=a.getAttribute(_$_ac43[98]))?l+(_$_ac43[263]+e[d]):e[d];a.setAttribute(_$_ac43[98],l)}f&&f[d]&&a.setAttribute(_$_ac43[264],f[d]);g&&g[d]&&(1==g[d].readOnly&&a.classList.add(_$_ac43[18]),!1===g[d].locked&&!0===this.options.selectUnLockedCells&&a.classList.add(_$_ac43[265]));h&&h[b]&&1==h[b].readOnly&&a.classList.add(_$_ac43[18])}f=this.options.columns[c];a.style.textAlign||(a.style.textAlign=
|
|
243
|
+
f.align?f.align:this.options.defaultColAlign);!1===this.records[b][c].readonly||1!=this.records[b][c].readonly&&1!=f.readOnly&&1!=f.readonly||a.classList.add(_$_ac43[18])};k.applyOverflow=function(a,c,b){1==this.options.textOverflow&&0<c&&(c==this.options.columns.length-1&&(a.style.overflow=_$_ac43[49]),this.records[b][c-1]&&this.records[b][c-1].element&&(this.records[b][c-1].element.style.overflow=!a.innerText&&this.headers[c-1]&&this.headers[c-1].offsetWidth?_$_ac43[3]:_$_ac43[49]))};k.batch=function(a,
|
|
244
|
+
c){var b=[],d=Object.keys(a);if(d.length)for(var e=0;e<d.length;e++){if(0<=d[e].indexOf(_$_ac43[27])){var f=d[e].split(_$_ac43[27]);var g=D(f[0]);var h=f[1];f=f[0]}else g=this,h=d[e],f=this.getWorksheetName();h=A.getCoordsFromColumnName(h);h=g.updateCell(h[0],h[1],a[d[e]],!0);b[f]||(b[f]=[]);b[f].push(h)}if(1==c&&(d=Object.keys(b),d.length))for(e=0;e<d.length;e++)g=D(d[e]),G.call(g,_$_ac43[107],b[d[e]])};k.getCells=function(a){return a?this.options.cells[a]:this.options.cells};k.setCells=function(a,
|
|
245
|
+
c){if(!N.call(this.parent,this))return!1;if(typeof a==_$_ac43[17])this.options.cells[a]=c;else{c=Object.keys(a);for(var b=0;b<c.length;b++)this.options.cells[c[b]]=a[c[b]]}};return k}(),ua=function(){var k=function(c,b){Array.isArray(b)||(b=[b]);for(var d,e=c?_$_ac43[3]:_$_ac43[40],f=Object.keys(b),g=0;g<f.length;g++)if(d=this.rows[b[f[g]]])d.element&&(d.element.style.display=e),d.visible=c;this.resetBorders();C.refresh.call(this)},a=function(c){c.getRow=a[_$_ac43[51]];c.moveRow=a.move;c.insertRow=
|
|
246
|
+
a.add;c.deleteRow=a.del;c.getSelectedRows=a.selected;c.showRow=k.bind(c,!0);c.hideRow=k.bind(c,!1)};a[_$_ac43[51]]=function(c){return this.rows[c]};a.attached=function(c){return this.rows[c]&&this.rows[c].element&&this.rows[c].element.parentNode?!0:!1};a.selected=function(c){var b=[],d=this.getHighlighted();if(d)for(var e=d[1];e<=d[3];e++)c?b.push(e):b.push(this.rows[e].element);return b};a.create=function(c,b){if(this.rows[c]&&this.rows[c].element)return this.rows[c].element;this.rows[c]||ia.row.call(this,
|
|
247
|
+
c);var d=document.createElement(_$_ac43[145]);d.setAttribute(_$_ac43[43],c);this.rows[c].element=d;var e=null;this.options.rows[c]&&!b&&(this.options.rows[c].style&&d.setAttribute(_$_ac43[98],this.options.rows[c].style),this.options.rows[c].height&&(d.style.height=parseInt(this.options.rows[c].height)+_$_ac43[44]),this.options.rows[c].title&&(e=this.options.rows[c].title),0==this.options.rows[c].visible&&(this.rows[c].visible=!1),this.options.rows[c].id&&(this.rows[c].id=this.options.rows[c].id));
|
|
248
|
+
B.call(this.parent,_$_ac43[266],this,c,d);0==this.rows[c].visible&&(d.style.display=_$_ac43[40]);e||(e=parseInt(c+1));b=document.createElement(_$_ac43[147]);b.innerHTML=e;b.setAttribute(_$_ac43[43],c);b.className=_$_ac43[267];d.appendChild(b);return d};a.move=function(c,b){if(!N.call(this.parent,this))return!1;c=parseInt(c);b=parseInt(b);if(!this.rows[b]||!this.rows[c])return console.error(_$_ac43[268]),!1;if(0<Object.keys(this.getMerge()).length){var d=null;this.merged.rows[c]?d=!0:this.merged.rows[b]&&
|
|
249
|
+
(c>b?this.merged.rows[b-1]&&(d=!0):this.merged.rows[b+1]&&(d=!0));d&&this.destroyMerged()}this.resetBorders();0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[b].element)?(d=C.renderRow.call(this,c),c>b?this.tbody.insertBefore(d,this.rows[b].element):this.tbody.insertBefore(d,this.rows[b].element.nextSibling)):this.rows[c].element&&(this.tbody.removeChild(this.rows[c].element),C.refresh.call(this));this.rows.splice(b,0,this.rows.splice(c,1)[0]);this.records.splice(b,0,this.records.splice(c,
|
|
250
|
+
1)[0]);this.options.data.splice(b,0,this.options.data.splice(c,1)[0]);0<this.options.pagination&&this.tbody.children.length!=this.options.pagination&&this.page(this.pageNumber);G.call(this,_$_ac43[67],{f:c,t:b});T.references.call(this);T.update.call(this);Q.call(this.parent,{worksheet:this,action:_$_ac43[67],oldValue:c,newValue:b});B.call(this.parent,_$_ac43[269],this,c,b)};a.add=function(c,b,d,e){if(!N.call(this.parent,this))return!1;if(!this.options.allowInsertRow)return console.error(_$_ac43[270]),
|
|
251
|
+
!1;var f=[];if(0<c)var g=parseInt(c);else g=1,Array.isArray(c)&&!e&&(Array.isArray(c[0])?e=c:(e=[],e.push(c)));e=za.standardize(e);d=d?!0:!1;var h=this.options.data?this.options.data.length-1:0;if(void 0==b||b>h||0>b)b=h,d=!1;g||(g=1);if(!1===B.call(this.parent,_$_ac43[271],this,b,g,d))return console.log(_$_ac43[272]),!1;this.resetBorders();c=d?b:b+1;for(var l,n,p=0,q=[],r=[],w=this.rows.splice(c),m=this.options.data?this.options.data.splice(c):[],v=this.records.splice(c),u=c;u<g+c;u++){var x=e[p]&&
|
|
252
|
+
e[p].id?e[p].id:pa.next.call(this);ia.row.call(this,u,x);n=this.dataType?{}:[];for(var y=0;y<this.options.columns.length;y++)l=V.call(this,y),n[l]=_$_ac43[3],e&&e[p]&&e[p].data&&(typeof e[p].data[l]!==_$_ac43[13]?n[l]=e[p].data[l]:typeof e[p].data[y]!==_$_ac43[13]&&(n[l]=e[p].data[y])),f.push({x:y,y:u,value:n[l],force:!0});r.push({id:x,data:n});p++}this.rows=this.rows.concat(w);this.records=this.records.concat(v);this.options.data=this.options.data.concat(m);this.results&&0<this.results.length&&(h=
|
|
253
|
+
this.results[this.results.length-1]);e=!1;w[0]?0<=Array.prototype.indexOf.call(this.tbody.children,w[0].element)&&(e=!0):this.rows[h]?this.rows[h].element&&0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[h].element)&&(e=!0):e=!0;for(u=c;u<g+c;u++)this.results&&this.results.push(u),1==e&&(h=w[0]?w[0].element:null,l=C.renderRow.call(this,u,null,null,!0),h?this.tbody.insertBefore(l,h):this.tbody.appendChild(l),0<this.options.pagination?Array.prototype.indexOf.call(this.tbody.children,l)>=
|
|
254
|
+
this.options.pagination&&(e=!1):C.limited.call(this)&&(C.isVisible.call(this,l.children[1])||(e=!1))),q.push(this.records[u]);0<this.options.pagination?qa[_$_ac43[11]].call(this,this.pageNumber):C.limited.call(this)&&(w=this.tbody.firstChild.getAttribute(_$_ac43[43]),this.tbody.innerText=_$_ac43[3],C[_$_ac43[46]].call(this,w));this.merged.rows[c]&&X.updateConfig.call(this,1,1,c-1,g);G.call(this,_$_ac43[63],{numOfRows:g,rowNumber:b,insertBefore:d?1:0,data:r});T.references.call(this);f.length&&aa.applyValues.call(this,
|
|
255
|
+
f);T.update.call(this);P.call(this);da.refresh.call(this);Q.call(this.parent,{worksheet:this,action:_$_ac43[63],rowNumber:b,numOfRows:g,insertBefore:d,data:r});B.call(this.parent,_$_ac43[273],this,b,g,q,d)};a.del=function(c,b){if(!N.call(this.parent,this))return!1;if(!this.options.allowDeleteRow)return console.error(_$_ac43[274]),!1;var d=null,e={},f=[],g=0;void 0==c&&(b=this.getSelectedRows(),b[0]?(c=parseInt(b[0].getAttribute(_$_ac43[43])),b=b.length):(c=this.options.data.length-1,b=1));d=this.options.data.length-
|
|
256
|
+
1;if(void 0==c||c>d||0>c)c=d;b||(b=1);c+b>=this.options.data.length&&(b=this.options.data.length-c,b>=this.options.data.length&&(b=this.options.data.length,this.resetSelection()));if(!1===B.call(this.parent,_$_ac43[275],this,c,b))return console.log(_$_ac43[276]),!1;if(-1<parseInt(c)&&0<parseInt(b)){this.resetBorders();for(var h=c;h<c+b;h++)for(var l=0;l<this.options.columns.length;l++)d=A.getColumnNameFromCoords(l,h),I.getAttributes.call(this,_$_ac43[277],d,e),I.getAttributes.call(this,_$_ac43[98],
|
|
257
|
+
d,e),I.getAttributes.call(this,_$_ac43[278],d,e),I.getAttributes.call(this,_$_ac43[279],d,e),I.getAttributes.call(this,_$_ac43[262],d,e),I.getAttributes.call(this,_$_ac43[261],d,e),f[d]=!0;if(d=S.getChain.call(this,e.values))e.formulas=d;for(h=c;h<c+b;h++)0<=Array.prototype.indexOf.call(this.tbody.children,this.rows[h].element)&&(this.rows[h].element.parentNode.removeChild(this.rows[h].element),g++);d=[];for(h=c;h<c+b;h++)d.push({id:this.getRowId(h),row:h,data:this.getRowData(h)});this.rows.splice(c,
|
|
258
|
+
b);h=this.records.splice(c,b);this.options.data.splice(c,b);X.updateConfig.call(this,1,0,c,b);G.call(this,_$_ac43[64],{rowNumber:c,numOfRows:b,data:d});T.references.call(this,f);if(0<this.options.pagination)this.page(this.pageNumber,function(){if(0==this.tbody.children.length){var n=this.whichPage(this.options.data.length-1);this.page(n)}});else if(C.limited.call(this)&&0<g)if(0==this.tbody.children.length)this[_$_ac43[46]](c);else C.refresh.call(this);T.update.call(this,!0);this.refreshBorders();
|
|
259
|
+
Q.call(this.parent,{worksheet:this,action:_$_ac43[64],rowNumber:c,numOfRows:b,insertBefore:1,data:d,attributes:e});B.call(this.parent,_$_ac43[280],this,c,b,h,d,e)}};return a}(),Ba=function(){var k=function(c,b){Array.isArray(b)||(b=[b]);for(var d,e,f=Object.keys(b),g=0;g<f.length;g++)if(d=b[f[g]],e=this.options.columns[d])this.colgroup[d]&&(this.colgroup[d].style.width=c?parseInt(e.width||this.options.defaultColWidth)+_$_ac43[44]:_$_ac43[144]),e.visible=c;this.resetBorders();C.refresh.call(this)},
|
|
260
|
+
a=function(c){c.getColumn=a[_$_ac43[51]];c.getColumnIdByName=a.getByName;c.getPrimaryKey=a.getPrimaryKey;c.getSelectedColumns=a.selected;c.getOptions=a.getOptions;c.getColumnOptions=a.getOptions;c.moveColumn=a.move;c.insertColumn=a.add;c.deleteColumn=a.del;c.getProperties=a.properties;c.setProperties=a.properties;c.getProperty=a.properties;c.setProperty=a.properties;c.showColumn=k.bind(c,!0);c.hideColumn=k.bind(c,!1)};a[_$_ac43[51]]=function(c){return this.options.columns[c]||!1};a.getByName=function(c){for(var b=
|
|
261
|
+
this.options.columns,d=0;d<b.length;d++)if(b[d].name==c)return d;return!1};a.getPrimaryKey=function(){for(var c=0;c<this.options.columns.length;c++)if(1==this.options.columns[c].primaryKey)return c;return!1};a.getOptions=function(c,b){var d=this.options.columns[c];Object.keys(this.options.cells).length&&void 0!==b&&(c=A.getColumnNameFromCoords(c,b),this.options.cells[c]&&(d=this.options.cells[c]));if(!d)d={type:_$_ac43[56]};else if(!d.type||typeof d.type==_$_ac43[17]&&!t.editors[d.type])d.type=_$_ac43[56];
|
|
262
|
+
return d};a.selected=function(c){c=[];var b=this.getHighlighted();if(b)for(var d=b[0];d<=b[2];d++)c.push(d);return c};a.move=function(c,b){if(!N.call(this.parent,this))return!1;c=parseInt(c);b=parseInt(b);if(!this.options.columns[c])return console.error(_$_ac43[281]),!1;if(!this.options.columns[b])return console.error(_$_ac43[282]),!1;if(0<Object.keys(this.getMerge()).length){var d=null;this.merged.cols[c]?d=!0:this.merged.cols[b]&&(c>b?this.merged.cols[b-1]&&(d=!0):this.merged.cols[b+1]&&(d=!0));
|
|
263
|
+
d&&this.destroyMerged()}this.resetBorders();d=this.options.freezeColumns;0<d&&(c<d||b<d)?ja.reset.call(this):d=null;if(this.headers[b]&&this.headers[b].parentNode){this.headers[c]||wa.create.call(this,c);var e=(c>b?this.headers[b]:this.headers[b].nextSibling)||null;this.headerContainer.insertBefore(this.headers[c],e);e=(c>b?this.colgroup[b]:this.colgroup[b].nextSibling)||null;this.colgroupContainer.insertBefore(this.colgroup[c],e);for(var f=0;f<this.tbody.children.length;f++){var g=this.tbody.children[f].getAttribute(_$_ac43[43]);
|
|
264
|
+
e=(c>b?this.records[g][b].element:this.records[g][b].element.nextSibling)||null;this.tbody.children[f].insertBefore(I[_$_ac43[51]].call(this,c,g),e)}if(this.options.footers)for(f=0;f<this.tfoot.children.length;f++)e=(c>b?this.footers.content[f][b].element:this.footers.content[f][b].element.nextSibling)||null,this.tfoot.children[f].insertBefore(W.create.call(this,c,f),e)}else if(this.headers[c]&&this.headers[c].parentNode){this.headerContainer.removeChild(this.headers[c]);this.colgroupContainer.removeChild(this.colgroup[c]);
|
|
265
|
+
for(f=0;f<this.tbody.children.length;f++)g=parseInt(this.tbody.children[f].getAttribute(_$_ac43[43])),this.tbody.children[f].removeChild(this.records[g][c].element);if(this.options.footers)for(f=0;f<this.tfoot.children.length;f++)this.tfoot.children[f].removeChild(this.footers.content[f][c].element)}this.options.columns.splice(b,0,this.options.columns.splice(c,1)[0]);this.headers.splice(b,0,this.headers.splice(c,1)[0]);this.colgroup.splice(b,0,this.colgroup.splice(c,1)[0]);for(f=0;f<this.rows.length;f++)this.dataType||
|
|
266
|
+
this.options.data[f].splice(b,0,this.options.data[f].splice(c,1)[0]),this.records[f].splice(b,0,this.records[f].splice(c,1)[0]);if(this.options.footers)for(f=0;f<this.options.footers.length;f++)this.options.footers[f].splice(b,0,this.options.footers[f].splice(c,1)[0]),this.footers.content[f].splice(b,0,this.footers.content[f].splice(c,1)[0]);G.call(this,_$_ac43[68],{f:c,t:b});T.references.call(this);T.update.call(this);0<d&&(c<=d||d<=d)&&ja[_$_ac43[11]].call(this,d);Q.call(this.parent,{worksheet:this,
|
|
267
|
+
action:_$_ac43[68],oldValue:c,newValue:b});B.call(this.parent,_$_ac43[283],this,c,b)};a.add=function(c,b,d,e,f,g){if(!N.call(this.parent,this))return!1;if(!this.options.allowInsertColumn)return console.error(_$_ac43[284]),!1;var h=[];if(0<c)var l=parseInt(c);else if(l=1,Array.isArray(c)&&!f)if(Array.isArray(c[0]))f=c;else{f=[];for(var n=0;n<c.length;n++)f[n]=[c[n]]}f||(f=[]);d=d?!0:!1;c=this.options.columns.length-1;if(void 0==b||b>c||0>b)b=c,d=!1;l||(l=1);if(!1===B.call(this.parent,_$_ac43[285],
|
|
268
|
+
this,b,l,d))return console.log(_$_ac43[286]),!1;da.reset.call(this);if(1==this.dataType)var p=parseInt((_$_ac43[3]+Date.now()).substr(-8));e||(e=[]);for(n=0;n<l;n++)e[n]||(e[n]={type:_$_ac43[56],source:[],options:[],width:this.options.defaultColWidth,align:this.options.defaultColAlign}),1==this.dataType&&typeof e[n].name==_$_ac43[13]&&(e[n].name=_$_ac43[287]+(p+n));var q=d?b:b+1;this.options.columns=A.injectArray(this.options.columns,q,e);p=function(u,x){for(var y=q;y<l+q;y++)wa.create.call(this,
|
|
269
|
+
y),u?(this.headerContainer.insertBefore(this.headers[y],u),this.colgroupContainer.insertBefore(this.colgroup[y],x)):(this.headerContainer.appendChild(this.headers[y]),this.colgroupContainer.appendChild(this.colgroup[y]))};n=function(u,x){if(x)for(var y=q;y<l+q;y++)this.rows[u].element.insertBefore(I[_$_ac43[51]].call(this,y,u),x);else for(y=q;y<l+q;y++)this.rows[u].element.appendChild(I[_$_ac43[51]].call(this,y,u))};var r=this.headers.splice(q),w=this.colgroup.splice(q);r[0]?0<=Array.prototype.indexOf.call(this.headerContainer.children,
|
|
270
|
+
r[0])&&p.call(this,r[0],w[0]):this.headers[c]&&0<=Array.prototype.indexOf.call(this.headerContainer.children,this.headers[c])&&p.call(this);this.headers=this.headers.concat(r);this.colgroup=this.colgroup.concat(w);W.adjust.call(this,q,l,1);ka.adjust.call(this,b,l,1,g);g=0;w=r=p=null;for(var m=0;m<this.options.data.length;m++){this.dataType||(r=this.options.data[m].splice(q));w=this.records[m].splice(q);g=0;for(var v=q;v<l+q;v++)p=f[m]&&f[m][g]?f[m][g]:_$_ac43[3],K.call(this,v,m,p),h.push({x:v,y:m,
|
|
271
|
+
value:p}),ia.cell.call(this,v,m),g++;this.rows[m].element&&this.rows[m].element.parentNode&&(w[0]?0<=Array.prototype.indexOf.call(this.rows[m].element.children,w[0].element)&&n.call(this,m,w[0].element):this.records[m][c].element&&0<=Array.prototype.indexOf.call(this.rows[m].element.children,this.records[m][c].element)&&n.call(this,m));this.dataType||(this.options.data[m]=this.options.data[m].concat(r));this.records[m]=this.records[m].concat(w)}this.merged.cols[q]&&X.updateConfig.call(this,0,1,q-
|
|
272
|
+
1,l);G.call(this,_$_ac43[65],{numOfColumns:l,columnNumber:b,insertBefore:d?1:0,properties:e,data:f});T.references.call(this);h.length&&aa.applyValues.call(this,h);T.update.call(this);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[65],columnNumber:b,numOfColumns:l,insertBefore:d,properties:e,data:f});B.call(this.parent,_$_ac43[288],this,b,l,[],d)};a.del=function(c,b){if(!N.call(this.parent,this))return!1;if(!this.options.allowDeleteColumn)return console.error(_$_ac43[289]),
|
|
273
|
+
!1;var d={},e=[],f=0;if(1<this.options.columns.length){void 0==c&&(b=this.getSelectedColumns(!0),b.length?(c=parseInt(b[0]),b=parseInt(b.length)):(c=this.options.columns.length-1,b=1));var g=this.options.columns.length-1;if(void 0==c||c>g||0>c)c=g;b||(b=1);c+b>=this.options.columns.length&&(b=this.options.columns.length-c,b>=this.options.columns.length&&(b--,console.error(_$_ac43[290])));if(!1===B.call(this.parent,_$_ac43[291],this,c,b))return console.log(_$_ac43[292]),!1;if(-1<parseInt(c)&&0<parseInt(b)){this.resetBorders();
|
|
274
|
+
g=null;var h=[],l=[],n=[];var p=0;for(var q=c;q<c+b;q++)0<=Array.prototype.indexOf.call(this.headerContainer.children,this.headers[q])&&(this.colgroup[q].parentNode.removeChild(this.colgroup[q]),this.headers[q].parentNode.removeChild(this.headers[q]),f++),n[p]=this.options.columns[q],p++;for(var r=0;r<this.options.data.length;r++)for(q=c;q<c+b;q++)p=A.getColumnNameFromCoords(q,r),I.getAttributes.call(this,_$_ac43[277],p,d),I.getAttributes.call(this,_$_ac43[98],p,d),I.getAttributes.call(this,_$_ac43[278],
|
|
275
|
+
p,d),I.getAttributes.call(this,_$_ac43[279],p,d),I.getAttributes.call(this,_$_ac43[262],p,d),I.getAttributes.call(this,_$_ac43[261],p,d),e[p]=!0,this.records[r][q].element&&0<=Array.prototype.indexOf.call(this.rows[r].element.children,this.records[r][q].element)&&this.records[r][q].element.parentNode.removeChild(this.records[r][q].element);if(q=S.getChain.call(this,d.values))d.formulas=q;this.options.columns.splice(c,b);this.headers.splice(c,b);this.colgroup.splice(c,b);for(r=0;r<this.options.data.length;r++)this.dataType||
|
|
276
|
+
(l[r]=this.options.data[r].splice(c,b)),h[r]=this.records[r].splice(c,b);W.adjust.call(this,c,b,0);(q=ka.adjust.call(this,c,b,0))&&(g={nested:q});X.updateConfig.call(this,0,0,c,b);G.call(this,_$_ac43[66],{columnNumber:c,numOfColumns:b});T.references.call(this,e);0<f&&(1==this.thead.children.length?C[_$_ac43[46]].call(this,null,c):C.refresh.call(this));T.update.call(this,!0);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[66],columnNumber:c,numOfColumns:b,insertBefore:1,data:l,
|
|
277
|
+
properties:n,attributes:d,extra:g});B.call(this.parent,_$_ac43[293],this,c,b,h,n,d)}}};a.properties=function(c,b){if(this.options.columns[c]){if(b){if(!N.call(this.parent,this))return!1;b=typeof b==_$_ac43[17]?{type:b}:b;b.type&&t.editors[b.type]||(b.type=_$_ac43[56]);parseInt(b.width)||(b.width=this.options.defaultColWidth||100);this.edition&&this.closeEditor(this.edition,!1);var d=this.options.columns[c],e=t.editors[d.type],f=t.editors[b.type];if(e&&typeof e.destroyCell==_$_ac43[85])for(var g=0;g<
|
|
278
|
+
this.records.length;g++)this.records[g][c].element&&e.destroyCell(this.records[g][c].element);this.options.columns[c]=b;if(f&&typeof f.createCell==_$_ac43[85])for(g=0;g<this.records.length;g++)this.records[g]&&this.records[g][c]&&this.records[g][c].element&&(I.applyProperties.call(this,this.records[g][c].element,c,g),f.createCell(this.records[g][c].element,K.call(this,c,g),c,g,this,b));b.width&&this.colgroup[c]&&this.colgroup[c].setAttribute(_$_ac43[152],parseInt(b.width));b.title&&(this.headers[c]&&
|
|
279
|
+
(this.headers[c].innerText=b.title,this.headers[c].setAttribute(_$_ac43[166],b.title)),this.options.columns[c].title=b.title);b.tooltip&&(this.headers[c]&&(this.headers[c].title=b.tooltip),this.options.columns[c].tooltip=b.tooltip);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[77],column:c,newValue:b,oldValue:d});G.call(this,_$_ac43[77],{column:c,options:b});return!0}return this.options.columns[c]}console.error(_$_ac43[294])};return a}(),La=function(){var k={},a={},c=function(d){if(typeof d==
|
|
280
|
+
_$_ac43[17]){var e=d;d=A.getCoordsFromColumnName(d);var f=d[0];d=d[1]}else f=d.x,d=d.y,e=A.getColumnNameFromCoords(f,d);if(this.records[d]&&this.records[d][f]&&this.records[d][f].element){a[e]=this.options.style[e];this.records[d][f].element.setAttribute(_$_ac43[98],_$_ac43[3]);var g=this.options.columns[f].align?this.options.columns[f].align:this.options.defaultColAlign;g&&(this.records[d][f].element.style.textAlign=g)}this.options.style&&this.options.style[e]&&delete this.options.style[e]},b=function(d){d.getStyle=
|
|
281
|
+
b[_$_ac43[51]];d.setStyle=b[_$_ac43[11]];d.resetStyle=b.reset};b[_$_ac43[51]]=function(d){var e=this.options.style;if(!e)return!1;if(d){if(typeof d==_$_ac43[17])return e[d];var f=[],g=Object.keys(d);if(0<g.length)for(var h=0;h<g.length;h++){if(typeof d[h]==_$_ac43[17])var l=e&&e[d[h]]?e[d[h]]:_$_ac43[3];else l=A.getColumnNameFromCoords(d[h].x,d[h].y),l=e&&e[l]?e[l]:_$_ac43[3];f.push(l)}return f}return this.options.style};b[_$_ac43[11]]=function(d,e,f,g){if(!N.call(this.parent,this))return!1;this.options.style||
|
|
282
|
+
(this.options.style={});var h=this.options.style,l=null,n=[],p=[],q={};p=function(m,v,u){if(!q[m]&&(h[m]?n=h[m].split(_$_ac43[263]):(h[m]=_$_ac43[3],n=[]),q[m]={},n.length))for(var x=0;x<n.length;x++)n[x]&&n[x].trim()&&(l=n[x].split(_$_ac43[136]),q[m][l[0].trim()]=l[1].trim());a[m]||(a[m]=[]);k[m]||(k[m]=[]);q[m][v]||(q[m][v]=_$_ac43[3]);a[m].push([v+_$_ac43[136]+q[m][v]]);q[m][v]=q[m][v]&&q[m][v]==u&&!g?_$_ac43[3]:u;k[m].push([v+_$_ac43[136]+q[m][v]]);u=A.getCoordsFromColumnName(m);this.records[u[1]]&&
|
|
283
|
+
this.records[u[1]][u[0]]&&this.records[u[1]][u[0]].element&&(this.records[u[1]][u[0]].element.style[v]=q[m][v]);q[m][v]||delete q[m][v]};k={};a={};if(e)if(typeof d==_$_ac43[17])p.call(this,d,e,f);else{if(d&&d.length)for(var r=0;r<d.length;r++){var w=A.getColumnNameFromCoords(d[r].x,d[r].y);p.call(this,w,e,f)}}else for(f=Object.keys(d),r=0;r<f.length;r++)if(w=d[f[r]])for(typeof w==_$_ac43[17]&&(w=w.split(_$_ac43[263])),e=0;e<w.length;e++)w[e]&&(typeof w[e]==_$_ac43[17]&&(w[e]=w[e].split(_$_ac43[136])),
|
|
284
|
+
w[e][0].trim()&&p.call(this,f[r],w[e][0].trim(),w[e][1].trim()));n={};p=Object.keys(q);if(p.length){for(r=0;r<p.length;r++){n[p[r]]||(n[p[r]]=[]);d=Object.keys(q[p[r]]);for(e=0;e<d.length;e++)n[p[r]].push(d[e]+_$_ac43[114]+q[p[r]][d[e]]);this.options.style[p[r]]=n[p[r]].join(_$_ac43[295])}p=Object.keys(k);for(r=0;r<p.length;r++)k[p[r]]=k[p[r]].join(_$_ac43[263]);p=Object.keys(a);for(r=0;r<p.length;r++)a[p[r]]=a[p[r]].join(_$_ac43[263]);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[71],
|
|
285
|
+
oldValue:a,newValue:k});G.call(this,_$_ac43[71],[k]);B.call(this.parent,_$_ac43[296],this,k,a)}};b.reset=function(d){if(!N.call(this.parent,this))return!1;if(d){a={};if(Array.isArray(d))for(var e=0;e<d.length;e++)c.call(this,d[e]);else c.call(this,d);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[72],cells:d,oldValue:a});G.call(this,_$_ac43[72],[d]);B.call(this.parent,_$_ac43[298],this,d)}else console.error(_$_ac43[297])};b.update=function(d){k={};a={};for(var e=Object.keys(d),
|
|
286
|
+
f=0;f<e.length;f++){a[e[f]]=this.options.style[e[f]]||_$_ac43[3];k[e[f]]=this.options.style[e[f]]=d[e[f]];var g=A.getCoordsFromColumnName(e[f]),h=g[0];g=g[1];this.records[g]&&this.records[g][h]&&this.records[g][h].element&&(this.records[g][h].element.setAttribute(_$_ac43[98],d[e[f]]),this.records[g][h].element.style.textAlign||(this.records[g][h].element.style.textAlign=this.options.columns[h].align||this.options.defaultColAlign||_$_ac43[53]))}G.call(this,_$_ac43[72],[e]);G.call(this,_$_ac43[71],
|
|
287
|
+
[k]);B.call(this.parent,_$_ac43[296],this,k,a)};return b}(),Ra=function(){var k=function(a){a.getComments=k[_$_ac43[51]];a.setComments=k[_$_ac43[11]]};k[_$_ac43[51]]=function(a){return a&&typeof a==_$_ac43[17]?this.options.comments&&this.options.comments[a]?this.options.comments[a]:!1:this.options.comments};k[_$_ac43[11]]=function(a,c){if(!N.call(this.parent,this))return!1;if(typeof a==_$_ac43[17]){var b={};b[a]=c}else b=a;if(c=B.call(this.parent,_$_ac43[299],this,b))b=c;else if(!1===c)return!1;this.options.comments||
|
|
288
|
+
(this.options.comments={});a={};var d=Object.keys(b);if(d.length){for(var e=0;e<d.length;e++){var f=A.getCoordsFromColumnName(d[e]);this.records[f[1]]&&this.records[f[1]][f[0]]&&(a[d[e]]=this.options.comments[d[e]]||_$_ac43[3],(c=b[d[e]])?this.options.comments[d[e]]=c:delete this.options.comments[d[e]],this.records[f[1]][f[0]].element&&(c?this.records[f[1]][f[0]].element.setAttribute(_$_ac43[264],c):this.records[f[1]][f[0]].element.removeAttribute(_$_ac43[264])))}Q.call(this.parent,{worksheet:this,
|
|
289
|
+
action:_$_ac43[76],newValue:b,oldValue:a});G.call(this,_$_ac43[76],[b]);B.call(this.parent,_$_ac43[300],this,b,a)}};return k}(),Sa=function(){var k=function(a){a.getMeta=k[_$_ac43[51]];a.setMeta=k[_$_ac43[11]];a.resetMeta=k.reset};k[_$_ac43[51]]=function(a,c){if(a){if(this.options.meta[a])return c?this.options.meta[a][c]:this.options.meta[a]}else return this.options.meta};k[_$_ac43[11]]=function(a,c,b){if(!N.call(this.parent,this))return!1;this.options.meta||(this.options.meta={});if(typeof a==_$_ac43[17]&&
|
|
290
|
+
c){b||(b=_$_ac43[3]);var d={};d[a]={};d[a][c]=b;a=d}c=Object.keys(a);if(c.length){b={};for(d=0;d<c.length;d++){this.options.meta[c[d]]||(this.options.meta[c[d]]={});b[c[d]]||(b[c[d]]={});for(var e=Object.keys(a[c[d]]),f=0;f<e.length;f++)this.options.meta[c[d]][e[f]]=a[c[d]][e[f]],b[c[d]][e[f]]=a[c[d]][e[f]]}Object.keys(b).length&&(G.call(this,_$_ac43[301],[b]),B.call(this.parent,_$_ac43[302],this,b))}};k.reset=function(){this.options.meta={};G.call(this,_$_ac43[303],{});B.call(this.parent,_$_ac43[304],
|
|
291
|
+
this,{})};return k}(),Ta=function(){var k=function(a){a.orderBy=k.execute};k.handler=function(a,c){return function(b,d){b=b[1];d=d[1];return a?b===_$_ac43[3]&&d!==_$_ac43[3]?1:b!==_$_ac43[3]&&d===_$_ac43[3]?-1:b>d?-1:b<d?1:0:b===_$_ac43[3]&&d!==_$_ac43[3]?1:b!==_$_ac43[3]&&d===_$_ac43[3]?-1:b>d?1:b<d?-1:0}};k.execute=function(a,c,b){if(0<=a){c=null==c?this.headers[a].classList.contains(_$_ac43[305])?1:0:c?1:0;for(var d,e,f=[],g=0;g<this.options.data.length;g++)d=Ba.getOptions.call(this,a,g),e=this.records[g][a].v,
|
|
292
|
+
e=d.type==_$_ac43[251]||d.type==_$_ac43[256]||d.type==_$_ac43[257]||d.type==_$_ac43[306]||d.type==_$_ac43[14]||d.type==_$_ac43[307]?Number(e):jSuites.isNumeric(e)?Number(e):e.toLowerCase(),f[g]=[g,e];g=typeof this.parent.config.sorting===_$_ac43[85]?this.parent.config.sorting(c,a):k.handler(c,a);f.sort(g);d=b?!0:!1;if(!b)for(b=[],g=0;g<f.length;g++)b[g]=f[g][0];if(g=B.call(this.parent,_$_ac43[308],this,a,c,b))b=g;else if(!1===g)return!1;if(d)this.destroyMerged();else if(0<Object.keys(this.getMerge()).length)if(confirm(z(_$_ac43[309])))this.destroyMerged();
|
|
293
|
+
else return!1;if(b.length<f.length)for(g=0;g<f.length;g++)-1==b.indexOf(f[g][0])&&b.push(f[g][0]);f=[];for(g=0;g<b.length;g++)f[b[g]]=g;ya.call(this,!1);da.reset.call(this);G.call(this,_$_ac43[78],{column:a,direction:c,order:b});k.update.call(this,b);k.arrow.call(this,a,c);da.refresh.call(this);Q.call(this.parent,{worksheet:this,action:_$_ac43[78],column:a,newValue:b,oldValue:f,direction:c});B.call(this.parent,_$_ac43[310],this,a,c,b);return!0}};k.update=function(a){for(var c=[],b=0;b<a.length;b++)c[b]=
|
|
294
|
+
this.options.data[a[b]];for(b=0;b<a.length;b++)this.options.data[b]=c[b];c=[];for(b=0;b<a.length;b++)c[b]=this.records[a[b]];this.records=c;c=[];for(b=0;b<a.length;b++)c[b]=this.rows[a[b]];this.rows=c;T.references.call(this);this.searchInput&&this.searchInput.value?ma.update.call(this,null):Y.update.call(this)};k.arrow=function(a,c){for(var b=0;b<this.headers.length;b++)this.headers[b].classList.remove(_$_ac43[311]),this.headers[b].classList.remove(_$_ac43[305]);c?this.headers[a].classList.add(_$_ac43[311]):
|
|
295
|
+
this.headers[a].classList.add(_$_ac43[305])};return k}(),qa=function(){var k=function(a){a.whichPage=k.whichPage;a.quantityOfPages=k.quantityOfPages;a.page=k[_$_ac43[11]];a.updatePagination=k.update};k.build=function(){this.pageNumber=0;var a=document.createElement(_$_ac43[20]),c=document.createElement(_$_ac43[20]);this.pagination=document.createElement(_$_ac43[20]);this.pagination.classList.add(_$_ac43[312]);this.pagination.appendChild(a);this.pagination.appendChild(c);this.options.pagination||(this.pagination.style.display=
|
|
296
|
+
_$_ac43[40]);this.element.appendChild(this.pagination)};k.pageUp=function(){0<this.pageNumber&&(this.pageNumber--,k[_$_ac43[11]].call(this,this.pageNumber))};k.pageDown=function(){this.pageNumber<k.quantityOfPages.call(this)-1&&(this.pageNumber++,k[_$_ac43[11]].call(this,this.pageNumber))};k.whichPage=function(a){if(0<this.options.pagination)return this.rows[a]?(this.results&&(a=this.results.indexOf(parseInt(a))),Math.ceil((parseInt(a)+1)/parseInt(this.options.pagination))-1):null;console.log(_$_ac43[313]);
|
|
297
|
+
return!1};k.quantityOfPages=function(){if(0<this.options.pagination)return Math.ceil((this.results?this.results.length:this.rows.length)/parseInt(this.options.pagination));console.log(_$_ac43[313]);return!1};k[_$_ac43[11]]=function(a,c){var b=this.pageNumber,d=parseInt(this.options.pagination);if(d){if(null==a||-1==a)a=Math.ceil((this.results?this.results:this.rows).length/d)-1;if(!1===B.call(this.parent,_$_ac43[315],this,a,b,d))return!1;this.pageNumber=a;C.resetY.call(this);W.refresh.call(this);
|
|
298
|
+
typeof c==_$_ac43[85]&&c.call(this);B.call(this.parent,_$_ac43[316],this,a,b,d)}else console.error(_$_ac43[314])};k.update=function(){this.pagination.children[0].innerHTML=_$_ac43[3];this.pagination.children[1].innerHTML=_$_ac43[3];if(this.options.pagination){var a=this.results?this.results.length:this.rows.length;if(a){a=Math.ceil(a/this.options.pagination);if(6>this.pageNumber)var c=1,b=10>a?a:10;else 5>a-this.pageNumber?(c=a-9,b=a,1>c&&(c=1)):(c=this.pageNumber-4,b=this.pageNumber+5);if(1<c){var d=
|
|
299
|
+
document.createElement(_$_ac43[20]);d.className=_$_ac43[318];d.innerHTML=_$_ac43[215];d.title=1;this.pagination.children[1].appendChild(d)}for(;c<=b;c++)d=document.createElement(_$_ac43[20]),d.className=_$_ac43[318],d.innerHTML=c,this.pagination.children[1].appendChild(d),this.pageNumber==c-1&&d.classList.add(_$_ac43[319]);b<a&&(d=document.createElement(_$_ac43[20]),d.className=_$_ac43[318],d.innerHTML=_$_ac43[216],d.title=a,this.pagination.children[1].appendChild(d));this.pagination.children[0].innerHTML=
|
|
300
|
+
z(_$_ac43[320],[this.pageNumber+1,a])}else this.pagination.children[0].innerHTML=z(_$_ac43[317])}};return k}(),ja=function(){var k=function(a){a.setFreezeColumns=k[_$_ac43[11]];a.resetFreezeColumns=k.reset};k.update=function(a){var c,b;if(b=this.options.freezeColumns){var d=50;if(this.rows[a].element)for(var e=0;e<b;e++){if(c=this.records[a][e].element)c.classList.add(_$_ac43[50]),c.style.left=d+1+_$_ac43[44];d+=this.options.columns[e].width}}};k.headers=function(){var a=50,c;if(c=this.options.freezeColumns)for(var b=
|
|
301
|
+
0;b<c;b++){this.headers[b].classList.add(_$_ac43[50]);this.headers[b].style.left=a+1+_$_ac43[44];if(this.options.footers)for(var d=0;d<this.options.footers.length;d++)this.footers.content[d][b].element.classList.add(_$_ac43[50]),this.footers.content[d][b].element.style.left=a+1+_$_ac43[44];a+=this.options.columns[b].width}else k.reset.call(this)};k[_$_ac43[11]]=function(a){a&&(this.options.freezeColumns=a,C.reset.call(this,!0),C[_$_ac43[46]].call(this,null,0));if(this.options.freezeColumns)for(k.headers.call(this),
|
|
302
|
+
a=0;a<this.rows.length;a++)this.rows[a].element&&k.update.call(this,a)};k.reset=function(){for(var a,c=1;c<=this.options.freezeColumns;c++){if(a=this.thead.lastChild)a.children[c].classList.remove(_$_ac43[50]),a.children[c].style.left=_$_ac43[3];for(var b=0;b<this.rows.length;b++)if(a=this.rows[b].element)a.children[c].classList.remove(_$_ac43[50]),a.children[c].style.left=_$_ac43[3];if(this.options.footers)for(b=0;b<this.options.footers.length;b++)this.tfoot.children[b].children[c].classList.remove(_$_ac43[50]),
|
|
303
|
+
this.tfoot.children[b].children[c].style.left=_$_ac43[3]}this.options.freezeColumns=0};k.getWidth=function(){var a=0;if(0<this.options.freezeColumns)for(var c=0;c<=this.options.freezeColumns;c++)a+=this.thead.lastChild.children[c].offsetWidth;return a};return k}(),T=function(){var k=function(b,d){if(this.options[b]){for(var e={},f=Object.keys(this.options[b]),g=0;g<f.length;g++)e[d&&void 0!=d[f[g]]?d[f[g]]:f[g]]=this.options[b][f[g]];this.options[b]=e}},a=function(){if(0<this.options.minSpareRows){for(var b=
|
|
304
|
+
0,d=this.rows.length-1;0<=d;d--){for(var e=!1,f=0;f<this.options.columns.length;f++)K.call(this,f,d)&&(e=!0);if(e)break;else b++}0<this.options.minSpareRows-b&&this.insertRow(this.options.minSpareRows-b)}if(0<this.options.minSpareCols){b=0;for(f=this.options.columns.length-1;0<=f;f--){e=!1;for(d=0;d<this.rows.length;d++)K.call(this,f,d)&&(e=!0);if(e)break;else b++}0<this.options.minSpareCols-b&&this.insertColumn(this.options.minSpareCols-b)}},c=function(){};c.build=function(){var b=this;this.content=
|
|
305
|
+
document.createElement(_$_ac43[20]);this.content.classList.add(_$_ac43[321]);this.content.addEventListener(_$_ac43[322],function(f){if(C.limited.call(b)&&!b.options.pagination){var g=Math.abs(f.deltaX),h=Math.abs(f.deltaY);f.shiftKey||g>h?0>f.deltaX||0>f.deltaY?C.pageLeft.call(b,1,null,f):C.pageRight.call(b,1,null,f):0>f.deltaY?C.pageUp.call(b,1,null,f):C.pageDown.call(b,1,null,f)}});this.content.addEventListener(_$_ac43[323],function(f){if(!b.edition)return f.preventDefault(),!1});this.table=document.createElement(_$_ac43[324]);
|
|
306
|
+
this.thead=document.createElement(_$_ac43[325]);this.tbody=document.createElement(_$_ac43[326]);this.tfoot=document.createElement(_$_ac43[327]);this.headers=[];this.colgroup=[];this.colgroupContainer=document.createElement(_$_ac43[328]);var d=document.createElement(_$_ac43[169]);d.setAttribute(_$_ac43[152],_$_ac43[329]);this.colgroupContainer.appendChild(d);this.headerContainer=document.createElement(_$_ac43[145]);d=document.createElement(_$_ac43[147]);d.classList.add(_$_ac43[330]);this.headerContainer.appendChild(d);
|
|
307
|
+
this.thead.appendChild(this.headerContainer);this.table.classList.add(_$_ac43[331]);this.table.setAttribute(_$_ac43[332],_$_ac43[97]);this.table.setAttribute(_$_ac43[333],_$_ac43[97]);this.table.setAttribute(_$_ac43[334],_$_ac43[335]);this.table.appendChild(this.colgroupContainer);this.table.appendChild(this.thead);this.table.appendChild(this.tbody);this.table.appendChild(this.tfoot);this.parent.config.wordWrap&&this.table.classList.add(_$_ac43[336]);this.options.textOverflow||this.table.classList.add(_$_ac43[337]);
|
|
308
|
+
!1===this.options.selectLockedCells&&this.table.classList.add(_$_ac43[338]);this.corner=document.createElement(_$_ac43[20]);this.corner.className=_$_ac43[339];this.corner.setAttribute(_$_ac43[334],_$_ac43[340]);this.corner.setAttribute(_$_ac43[341],_$_ac43[342]);0==this.options.selectionCopy&&(this.corner.style.display=_$_ac43[40]);this.scrollX=P.build.call(b,_$_ac43[45]);this.scrollY=P.build.call(b,_$_ac43[343]);d=document.createElement(_$_ac43[20]);d.appendChild(this.content);d.appendChild(this.scrollY);
|
|
309
|
+
d.classList.add(_$_ac43[344]);var e=document.createElement(_$_ac43[20]);e.appendChild(d);e.appendChild(this.scrollX);e.classList.add(_$_ac43[345]);this.content.appendChild(this.table);this.content.appendChild(this.corner);this.element.appendChild(e);1==this.options.tableOverflow&&(this.options.tableHeight||(this.options.tableHeight=300),this.options.tableWidth||(this.options.tableWidth=document.body.offsetWidth-8),this.content.style.maxHeight=parseInt(this.options.tableHeight)+_$_ac43[44],this.content.style.maxWidth=
|
|
310
|
+
parseInt(this.options.tableWidth)+_$_ac43[44],1==this.options.tableOverflowResizable&&(this.content.style.resize=_$_ac43[346]));ma.build.call(this);ka.build.call(this);qa.build.call(this);za.build.call(this);X.build.call(this);W.build.call(this);C.call(this);Y.onload.call(this);a.call(this)};c.references=function(b){var d=[],e=[],f=null,g=null,h=null,l=null;for(f=0;f<this.options.columns.length;f++)if(g=this.headers[f])h=g.getAttribute(_$_ac43[42]),h!=f&&(g.setAttribute(_$_ac43[42],f),g.getAttribute(_$_ac43[166])||
|
|
311
|
+
(g.innerHTML=A.getColumnName(f)));for(var n=0;n<this.rows.length;n++)g=this.rows[n],l=g.y,l!=n&&(g.y=n,d[l]=n,g.element&&(g.element.setAttribute(_$_ac43[43],n),g.element.children[0].setAttribute(_$_ac43[43],n),f=this.options.rows&&this.options.rows[l]&&this.options.rows[l].title?this.options.rows[l].title:n+1,g.element.children[0].innerHTML=f));var p=function(r,w){g=this.records[w][r];h=g.x;l=g.y;h!=r&&(g.x=r,g.element&&g.element.setAttribute(_$_ac43[42],r));l!=w&&(g.y=w,g.element&&g.element.setAttribute(_$_ac43[43],
|
|
312
|
+
w));if(h!=r||l!=w){var m=A.getColumnNameFromCoords(h,l);r=A.getColumnNameFromCoords(r,w);e[m]=r}};if(b){n=function(r,w){r&&r[w]&&delete r[w]};var q=Object.keys(b);for(f=0;f<q.length;f++)n(this,q[f]),n(this.options.meta,q[f]),n(this.options.cells,q[f]),n(this.options.style,q[f]),n(this.options.comments,q[f])}for(n=0;n<this.rows.length;n++)for(f=0;f<this.options.columns.length;f++)p.call(this,f,n);k.call(this,_$_ac43[347],d);k.call(this,_$_ac43[277],e);k.call(this,_$_ac43[278],e);k.call(this,_$_ac43[98],
|
|
313
|
+
e);k.call(this,_$_ac43[279],e);k.call(this,_$_ac43[262],e);this.options.mergeCells&&X.build.call(this);S.updateAll.call(this,e,b);return e};c.update=function(b){b&&a.call(this);if(typeof this.parent.config.updateTable==_$_ac43[85])for(var d=0;d<this.rows.length;d++)for(var e=0;e<this.options.columns.length;e++)b=this.records[d][e],this.parent.config.updateTable.call(this,this,b.element,e,d,K.call(this,e,d),b.r?b.r:b.v);P.call(this);W.refresh.call(this)};return c}(),ia=function(){var k={spreadsheet:function(a,
|
|
314
|
+
c){var b={name:null,config:{},el:a,element:a,plugins:[],worksheets:[],history:[],historyIndex:-1,queue:[],ignoreEvents:!1,ignoreHistory:!1,ignorePersistence:!1};xa.spreadsheet.call(b,c);b.config.license&&(t.license=b.config.license);a.spreadsheet=b;a.jspreadsheet=a.jexcel=b.worksheets;t.spreadsheet.push(b);b.name||(b.name=jSuites.guid());k.bind(b.config.root?b.config.root:document);var d=b.config.tabs;typeof d!==_$_ac43[84]&&(d={allowCreate:d?!0:!1,hideHeaders:d?!1:!0,allowChangePosition:b.config.allowMoveWorksheet?
|
|
315
|
+
!0:!1});d.maxWidth||(d.maxWidth=a.offsetWidth-50+_$_ac43[44]);d.animation=void 0==d.animation?!0:d.animation;d.onbeforecreate=function(){b.createWorksheet();return!1};d.onclick=function(f,g,h,l,n){0<=h&&b.openWorksheet(h)};d.onchangeposition=function(f,g,h){b.updateWorksheet(g,h)};jSuites.tabs(a,d);a.classList.add(_$_ac43[348]);1==c.fullscreen&&a.classList.add(_$_ac43[15]);var e=document.createElement(_$_ac43[20]);b.toolbar=document.createElement(_$_ac43[20]);b.toolbar.className=_$_ac43[349];e.appendChild(b.toolbar);
|
|
316
|
+
b.filter=Y.build.call(b);e.appendChild(b.filter);b.helper=document.createElement(_$_ac43[20]);b.helper.className=_$_ac43[350];e.appendChild(b.helper);b.loading=document.createElement(_$_ac43[20]);b.loading.classList.add(_$_ac43[351]);e.appendChild(b.loading);e.appendChild(Z.build(b));e.appendChild(Ma(b));b.textarea=document.createElement(_$_ac43[352]);b.textarea.className=_$_ac43[353];b.textarea.tabIndex=_$_ac43[354];e.appendChild(b.textarea);d.position===_$_ac43[355]?a.insertBefore(e,a.children[0]):
|
|
317
|
+
a.insertBefore(e,a.children[1]);a.appendChild(Da.call(b,t.license));b.createWorksheet=ea.createWorksheet;b.deleteWorksheet=ea.deleteWorksheet;b.renameWorksheet=ea.renameWorksheet;b.updateWorksheet=ea.updateWorksheet;b.openWorksheet=ea.openWorksheet;b.moveWorksheet=ea.moveWorksheet;b.getWorksheet=ea.getWorksheet;b.getWorksheetActive=ea.getWorksheetActive;b.getWorksheetInstance=ea.getWorksheetInstance;b.getConfig=function(){var f=b.config;f.worksheets=[];for(var g=0;g<b.worksheets.length;g++)f.worksheets.push(b.worksheets[g].getConfig());
|
|
318
|
+
return f};b.fullscreen=Ea;b.progress=Fa;b.undo=Q.undo;b.redo=Q.redo;b.setToolbar=ca[_$_ac43[11]];b.getToolbar=ca[_$_ac43[51]];b.showToolbar=ca.show;b.hideToolbar=ca.hide;b.tools=e;1!==b.edition&&(a=Object.keys(b.config.definedNames))&&a.length&&(b.config.definedNames={},console.log(_$_ac43[356]));c.plugins&&la.call(b,c.plugins);b.setPlugins=function(f){la.call(b,f)};a=Object.keys(t.extensions);if(a.length)for(d=0;d<a.length;d++)if(typeof t.extensions[a[d]].oninit==_$_ac43[85])t.extensions[a[d]].oninit(b,
|
|
319
|
+
c);return b},worksheet:function(a,c){var b={};a.worksheets.push(b);b.parent=a;xa(b);Na(b);ta(b);da(b);Z(b);za(b);Pa(b);X(b);La(b);Qa(b);aa(b);S(b);I(b);ua(b);Ba(b);Sa(b);Ra(b);wa(b);W(b);ka(b);ma(b);Y(b);ca(b);pa(b);Ua(b);Va(b);qa(b);ea(b);ja(b);Oa(b);Ta(b);Ca(b);xa.worksheet.call(b,c);!t.license&&b.options.license&&(t.license=b.options.license);a.element.jexcel=a.worksheets?a.worksheets:b;b.onload=function(){this.options.worksheetName||(this.options.worksheetName=_$_ac43[357]+ea.nextName());var d=
|
|
320
|
+
this.options.worksheetName;D(d)&&console.log(_$_ac43[358]+d+_$_ac43[359]);D(d,b);this.element=a.element.tabs.appendElement(this.options.worksheetName,function(e,f){b.options.worksheetState===_$_ac43[49]&&(f.style.display=_$_ac43[40])});this.element.classList.add(_$_ac43[360]);this.element.jexcel=this;T.build.call(this);la.execute.call(this.parent,_$_ac43[361],[this]);this.options.data&&500<this.options.data.length&&!C.limited.call(this)&&!this.options.pagination&&console.error(_$_ac43[362])};return b},
|
|
321
|
+
row:function(a,c){this.rows[a]||(this.rows[a]={element:null,y:a});c&&(this.rows[a].id=c,pa[_$_ac43[11]].call(this,c));this.options.rows&&this.options.rows[a]&&this.options.rows[a].height&&(this.rows[a].height=this.options.rows[a].height);this.records[a]||(this.records[a]=[]);this.options.data[a]||(this.options.data[a]=this.dataType?{}:[]);for(c=0;c<this.options.columns.length;c++)k.cell.call(this,c,a)},cell:function(a,c,b){typeof b==_$_ac43[13]&&(b=K.call(this,a,c),null===b||void 0===b)&&(b=_$_ac43[3],
|
|
322
|
+
K.call(this,a,c,b));this.records[c][a]||(this.records[c][a]={element:null,x:a,y:c,v:b})},bind:function(a){for(var c=Object.keys(va),b=0;b<c.length;b++)(c[b]==_$_ac43[363]?window:a).addEventListener(c[b],va[c[b]],c[b]==_$_ac43[364]||c[b]==_$_ac43[365]||c[b]==_$_ac43[366]?{passive:!1}:{})},unbind:function(a){for(var c=Object.keys(va),b=0;b<c.length;b++)(c[b]==_$_ac43[363]?window:a).removeEventListener(c[b],va[c[b]])}};return k}(),Ua=function(){var k=function(a){a.getWidth=k[_$_ac43[51]];a.setWidth=
|
|
323
|
+
k[_$_ac43[11]]};k[_$_ac43[51]]=function(a){var c=this.options.columns;if(typeof a===_$_ac43[13]){a=[];for(var b=0;b<c.length;b++)a.push(c[b].width)}else a=c[a].width;return a};k[_$_ac43[11]]=function(a,c,b){if(!N.call(this.parent,this))return!1;if(c){if(Array.isArray(a)){b||(b=[]);for(var d=0;d<a.length;d++){b[d]||(b[d]=this.colgroup[a[d]].getAttribute(_$_ac43[152]));var e=Array.isArray(c)&&c[d]?c[d]:c;this.colgroup[a[d]].setAttribute(_$_ac43[152],e);this.options.columns[a[d]].width=e}}else b||(b=
|
|
324
|
+
this.colgroup[a].getAttribute(_$_ac43[152])),this.colgroup[a].setAttribute(_$_ac43[152],c),this.options.columns[a].width=c;this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[73],column:a,oldValue:b,newValue:c});G.call(this,_$_ac43[73],{column:a,width:c,oldWidth:b});B.call(this.parent,_$_ac43[367],this,a,c,b)}C.refresh.call(this)};return k}(),Va=function(){var k=function(c){c.getHeight=k[_$_ac43[51]];c.setHeight=k[_$_ac43[11]]};k[_$_ac43[51]]=function(c){if(c)c=this.rows[c].element.style.height;
|
|
325
|
+
else{c=[];for(var b=0;b<this.rows.length;b++){var d=this.rows[b].element.style.height;d&&(c[b]=d)}}return c};var a=function(c,b){b=parseInt(b);var d=this.rows[c].height?this.rows[c].height:this.rows[c].element.offsetHeight||this.options.defaultRowHeight;this.rows[c].element.style.height=b+_$_ac43[44];this.options.rows[c]||(this.options.rows[c]={});this.options.rows[c].height=b+_$_ac43[44];this.rows[c].height=b;return d};k[_$_ac43[11]]=function(c,b,d){if(!N.call(this.parent,this))return!1;var e,f=
|
|
326
|
+
typeof d==_$_ac43[13]?!0:!1;if(b){if(Array.isArray(c))for(!0===f&&(d=[]),e=0;e<c.length;e++){var g=Array.isArray(b)&&b[e]?b[e]:b;a.call(this,c[e],g);1==f&&d.push(f)}else e=a.call(this,c,b),1==f&&(d=e);this.refreshBorders();Q.call(this.parent,{worksheet:this,action:_$_ac43[74],row:c,oldValue:d,newValue:b});G.call(this,_$_ac43[74],{row:c,height:b,oldHeight:d});B.call(this.parent,_$_ac43[368],this,c,b,d)}C.refresh.call(this)};return k}(),Y=function(){var k=function(g){var h=e[g];g=b[e[g]];if(!g.element){g.element=
|
|
327
|
+
document.createElement(_$_ac43[369]);g.element.innerHTML=g.value;var l=document.createElement(_$_ac43[220]);l.type=_$_ac43[250];l.value=h;l.o=g;g.element.insertBefore(l,g.element.firstChild)}g.element.firstChild.checked=g.selected;return g.element},a=null,c=null,b=[],d=0,e=null,f=function(g){g.setFilter=f[_$_ac43[11]];g.getFilter=f[_$_ac43[51]];g.openFilter=f.open;g.closeFilter=f.close;g.resetFilters=f.reset;g.showFilter=f.show;g.hideFilter=f.hide};f.isVisible=function(){return c};f[_$_ac43[11]]=
|
|
328
|
+
function(g,h){var l=this.headers[g];g=this.options.columns[g];Array.isArray(h)&&0<h.length?(l&&l.classList.add(_$_ac43[370]),g.filters=h):(l&&l.classList.remove(_$_ac43[370]),g.filters=null);f.update.call(this)};f[_$_ac43[51]]=function(g){if(g)return this.options.columns[g].filters||null;g={};for(var h=0;h<this.options.columns.length;h++)g[h]=this.options.columns[h].filters||null;return g};f.open=function(g){a=parseInt(g);if(this.headers[a].classList.contains(_$_ac43[168])){c=!0;var h=this.parent.element.getBoundingClientRect(),
|
|
329
|
+
l=this.headers[a].getBoundingClientRect();g=l.left-h.left;l=l.top-h.top+l.height;h=this.parent.filter;h.style.display=_$_ac43[16];h.style.top=l+_$_ac43[44];h.style.left=g+_$_ac43[44];h.children[0].focus();g=h.children[1].selectAll;h.children[1].textContent=_$_ac43[3];h.children[1].appendChild(g);this.options.columns[a].filters||(g.children[0].checked=!0);g=ma.execute.call(this,null,a);g=A.invert(g);h=[];for(l=0;l<this.rows.length;l++)if(g[l]){var n=_$_ac43[3]+K.call(this,a,l),p=_$_ac43[3]+aa.processed.call(this,
|
|
330
|
+
a,l,!0);n.substr(0,1)==_$_ac43[12]&&(n=p);h.push([n,p])}h.sort(function(q,r){return q[0]>r[0]?1:q[0]<r[0]?-1:0});b=[];for(l=0;l<h.length;l++)b[h[l][0]]={value:h[l][1],element:null};void 0!==b[_$_ac43[3]]&&(delete b[_$_ac43[3]],b[_$_ac43[3]]={value:_$_ac43[212]+z(_$_ac43[372])+_$_ac43[232],element:null});f.search.call(this,_$_ac43[3])}else console.log(_$_ac43[371])};f.close=function(g){if(g){g=this.parent.filter.children[1];if(1==g.selectAll.firstChild.checked&&e.length==Object.keys(b).length)g=null;
|
|
331
|
+
else{g=1==g.currentSelection.firstChild.checked?this.options.columns[a].filters||[]:[];for(var h=0;h<e.length;h++)b[e[h]].selected&&g.push(e[h])}f[_$_ac43[11]].call(this,a,g)}this.parent.filter.style.display=_$_ac43[3];this.parent.filter.children[0].value=_$_ac43[3];a=null;c=!1;b=null;d=0;e=null};f.reset=function(g){f.updateDOM.call(this,g,!1);this.results=null;f.update.call(this)};f.execute=function(g){for(var h=this.options.columns,l=[],n=0;n<this.options.data.length;n++){for(var p=!0,q=0;q<h.length;q++)if(h[q].filters&&
|
|
332
|
+
g!==q){var r=_$_ac43[3]+K.call(this,q,n),w=_$_ac43[3]+this.getLabelFromCoords(q,n,!0);-1==h[q].filters.indexOf(r)&&-1==h[q].filters.indexOf(w)&&(p=!1)}p&&l.push(n)}return l};f.update=function(){this.resetSelection();this.resetBorders();var g=ma.execute.call(this,null);if(typeof this.parent.config.onbeforefilter==_$_ac43[85]){var h=f[_$_ac43[51]].call(this),l=B.call(this.parent,_$_ac43[373],this,h,g);if(l)g=l;else if(!1===l)return!1}this.pageNumber=0;this.results=g&&g.length<this.rows.length?g:null;
|
|
333
|
+
C.resetY.call(this);W.refresh.call(this);B.call(this.parent,_$_ac43[374],this,h,g)};f.show=function(g){f.updateDOM.call(this,g,!0)};f.hide=function(g){f.updateDOM.call(this,g,!1,!0);f.update.call(this)};f.search=function(g){for(var h=this.parent.filter.children[1];h.children[1];)h.removeChild(h.lastChild);h.currentSelection.firstChild.checked=!1;if(g){e=[];g=new RegExp(g,_$_ac43[375]);for(var l=Object.keys(b),n=0;n<l.length;n++)(_$_ac43[3]+l[n]).match(g)||(_$_ac43[3]+b[l[n]]).match(g)?(e.push(l[n]),
|
|
334
|
+
b[l[n]].selected=!0):b[l[n]].selected=!1;h.firstChild.checked=!0;this.options.columns[a].filters&&h.appendChild(h.currentSelection)}else{e=Object.keys(b);if(g=this.options.columns[a].filters)for(n=0;n<e.length;n++)b[e[n]].selected=!1,0<=g.indexOf(e[n])&&(b[e[n]].selected=!0);else for(n=0;n<e.length;n++)b[e[n]].selected=!0;h.firstChild.checked=g?!1:!0}for(n=d=0;n<e.length;n++)200>n&&(g=d++,h.appendChild(k(g)))};f.build=function(){var g=document.createElement(_$_ac43[20]);g.className=_$_ac43[376];g.onclick=
|
|
335
|
+
function(p){p.target.tagName==_$_ac43[377]&&p.target.o&&(p.target.o.selected=p.target.checked);p=!0;for(var q=1;q<this.children.length;q++)this.children[q].children[0].checked||(p=!1);this.children[0].children[0].checked=p};var h=document.createElement(_$_ac43[220]);h.type=_$_ac43[56];h.placeholder=z(_$_ac43[378]);h.className=_$_ac43[379];var l=document.createElement(_$_ac43[220]);l.type=_$_ac43[380];l.value=_$_ac43[381];l.className=_$_ac43[382];var n=document.createElement(_$_ac43[20]);n.className=
|
|
336
|
+
_$_ac43[383];n.appendChild(h);n.appendChild(g);n.appendChild(l);g.currentSelection=document.createElement(_$_ac43[369]);g.currentSelection.innerHTML=_$_ac43[384]+z(_$_ac43[385]);g.selectAll=document.createElement(_$_ac43[369]);g.selectAll.innerHTML=_$_ac43[386]+z(_$_ac43[387])+_$_ac43[232];g.selectAll.onclick=function(){for(var p=this.children[0].checked,q=1;q<this.parentNode.children.length;q++)this.parentNode.children[q].children[0].checked=p;if(1==p)for(q=0;q<e.length;q++)b[e[q]].selected=!0;else for(p=
|
|
337
|
+
Object.keys(b),q=0;q<p.length;q++)b[p[q]].selected=!1};jSuites.lazyLoading(g,{loadDown:function(p){for(p=0;d<e.length-1&&10>p;){var q=d++;g.appendChild(k(q));p++}}});return n};f.updateDOM=function(g,h,l){var n=this.headers,p=function(q){1==h?n[q].classList.add(_$_ac43[168]):(this.options.columns[q].filters=null,n[q].classList.remove(_$_ac43[370]),1==l&&n[q].classList.remove(_$_ac43[168]))};if(g)p.call(this,g);else for(g=0;g<n.length;g++)p.call(this,g)};f.onload=function(){var g,h=!1;if(g=this.options.columns)for(var l=
|
|
338
|
+
0;l<g.length;l++)Array.isArray(g[l].filters)&&0<g[l].filters.length&&this.headers[l]&&(this.headers[l].classList.add(_$_ac43[370]),h=!0);1==h&&f.update.call(this)};return f}(),ma=function(){var k=function(c){var b=document.createElement(_$_ac43[20]);if(0<c.options.pagination&&c.options.paginationOptions&&0<c.options.paginationOptions.length){c.paginationDropdown=document.createElement(_$_ac43[388]);c.paginationDropdown.classList.add(_$_ac43[389]);c.paginationDropdown.onchange=function(){c.options.pagination=
|
|
339
|
+
parseInt(this.value);c.page(0)};for(var d=0;d<c.options.paginationOptions.length;d++){var e=document.createElement(_$_ac43[390]);e.value=c.options.paginationOptions[d];e.innerHTML=c.options.paginationOptions[d];c.paginationDropdown.appendChild(e)}c.paginationDropdown.value=c.options.pagination;b.appendChild(document.createTextNode(z(_$_ac43[391])));b.appendChild(c.paginationDropdown);b.appendChild(document.createTextNode(z(_$_ac43[392])))}return b},a=function(c){c.search=a.update;c.resetSearch=a.reset;
|
|
340
|
+
c.updateSearch=a.refresh;c.showSearch=a.show;c.hideSearch=a.hide};a.execute=function(c,b){null===c?c=this.searchInput.value||_$_ac43[3]:c!==this.searchInput.value&&(this.searchInput.value=c);this.pageNumber=0;var d=[],e=null;b=Y.execute.call(this,b);if(c)try{c=new RegExp(c,_$_ac43[375]);for(var f=0;f<this.rows.length;f++){e=!1;if(!b||0<=b.indexOf(f))for(var g=0;g<this.options.columns.length;g++){var h=_$_ac43[3]+K.call(this,g,f),l=_$_ac43[3]+this.getLabelFromCoords(g,f);if(h.match(c)||l.match(c))e=
|
|
341
|
+
!0}if(1==e){g=d;var n=f,p=this.merged.rows;if(p[n]){for(;0<n&&p[n-1];)n--;for(;p[n];)g.push(n++)}else g.push(n)}}}catch(q){}else d=b;return d};a.update=function(c){this.resetSelection();this.resetBorders();var b=a.execute.call(this,c);if(typeof this.parent.config.onbeforesearch==_$_ac43[85]){var d=B.call(this.parent,_$_ac43[394],this,c,b);if(d)b=d;else if(!1===d)return!1}this.pageNumber=0;this.results=b&&b.length<this.rows.length?b:null;C.resetY.call(this);W.refresh.call(this);B.call(this.parent,
|
|
342
|
+
_$_ac43[395],this,c,b)};a.refresh=function(){C.resetY.call(this);W.refresh.call(this)};a.reset=function(){this.searchInput.value=_$_ac43[3];this.results=null;C.resetY.call(this);W.refresh.call(this)};a.show=function(){this.options.search=!0;this.searchContainer.style.display=_$_ac43[3]};a.hide=function(){this.options.search=!1;this.searchContainer.style.display=_$_ac43[40]};a.build=function(){this.searchContainer=document.createElement(_$_ac43[20]);this.searchContainer.classList.add(_$_ac43[396]);
|
|
343
|
+
this.searchContainer.appendChild(k(this));var c=this.searchContainer,b=c.appendChild,d=document.createElement(_$_ac43[20]);d.innerHTML=z(_$_ac43[378])+_$_ac43[114];this.searchInput=document.createElement(_$_ac43[220]);this.searchInput.classList.add(_$_ac43[393]);d.appendChild(this.searchInput);b.call(c,d);0==this.options.search&&(this.searchContainer.style.display=_$_ac43[40]);this.element.insertBefore(this.searchContainer,this.element.firstChild)};return a}(),Ma=function(){var k=function(a){a.contextmenu=
|
|
344
|
+
document.createElement(_$_ac43[20]);a.contextmenu.className=_$_ac43[397];jSuites.contextmenu(a.contextmenu,{onclick:function(c,b,d){c.close()}});return a.contextmenu};k.open=function(a,c){var b=a.target.getAttribute(_$_ac43[42]),d=a.target.getAttribute(_$_ac43[43]),e=k[_$_ac43[51]](this,b,d,a,c[0],c[1],c[2]);if(typeof this.parent.config.contextMenu==_$_ac43[85]){var f=this.parent.config.contextMenu(this,b,d,a,e,c[0],c[1],c[2]);if(f)e=f;else if(!1===f)return!1}a.preventDefault();f=la.execute.call(this.parent,
|
|
345
|
+
_$_ac43[86],[this,b,d,a,e,c[0],c[1],c[2]]);e=f[4];this.parent.contextmenu.contextmenu.open(a,e)};k[_$_ac43[51]]=function(a,c,b,d,e,f,g){var h=[],l=a.parent.config,n=-1!=navigator.userAgent.indexOf(_$_ac43[398])?_$_ac43[399]:_$_ac43[400];e==_$_ac43[401]&&(1==l.allowRenameWorksheet&&h.push({title:z(_$_ac43[402]),onclick:function(){var q=prompt(z(_$_ac43[402]),d.target.innerText);q&&a.parent.renameWorksheet(f,q)}}),1==l.allowDeleteWorksheet&&h.push({title:z(_$_ac43[403]),onclick:function(){confirm(z(_$_ac43[404]),
|
|
346
|
+
d.target.innerText)&&a.parent.deleteWorksheet(f)}}),h.push({type:_$_ac43[405]}));e==_$_ac43[406]&&(h.push({title:z(_$_ac43[407]),onclick:function(){var q=prompt(z(_$_ac43[407]),d.target.innerText);a.setNestedCell(f,g,{title:q})}}),h.push({type:_$_ac43[405]}));if(e==_$_ac43[408]||e==_$_ac43[409]||e==_$_ac43[410]||e==_$_ac43[406])h.push({title:z(_$_ac43[411]),icon:_$_ac43[412],shortcut:n+_$_ac43[413],onclick:function(){a.cut()}}),h.push({title:z(_$_ac43[414]),icon:_$_ac43[415],shortcut:n+_$_ac43[416],
|
|
347
|
+
onclick:function(){a.copy()}}),navigator&&navigator.clipboard&&navigator.clipboard.readText&&h.push({title:z(_$_ac43[417]),icon:_$_ac43[418],shortcut:n+_$_ac43[419],onclick:function(){a.selectedCell&&navigator.clipboard.readText().then(function(q){q&&a.paste(a.selectedCell[0],a.selectedCell[1],q)})}}),h.push({type:_$_ac43[405]});e==_$_ac43[408]&&(1==a.options.allowInsertColumn&&h.push({title:z(_$_ac43[420]),onclick:function(){a.insertColumn(1,parseInt(f),1)}}),1==a.options.allowInsertColumn&&h.push({title:z(_$_ac43[421]),
|
|
348
|
+
onclick:function(){a.insertColumn(1,parseInt(f),0)}}),1==a.options.allowDeleteColumn&&h.push({title:z(_$_ac43[422]),onclick:function(){a.deleteColumn(a.getSelectedColumns().length?void 0:parseInt(c))}}),1==a.options.allowRenameColumn&&h.push({title:z(_$_ac43[423]),onclick:function(){a.setHeader(f)}}),a.options.data.length||(h.push({type:_$_ac43[405]}),h.push({title:z(_$_ac43[424]),onclick:function(){a.insertRow(0)}})),1==a.options.columnSorting&&(h.push({type:_$_ac43[405]}),h.push({title:z(_$_ac43[425]),
|
|
349
|
+
onclick:function(){a.orderBy(f,0)}}),h.push({title:z(_$_ac43[426]),onclick:function(){a.orderBy(f,1)}}),h.push({type:_$_ac43[405]})));if(e==_$_ac43[410]||e==_$_ac43[409])1==a.options.allowInsertRow&&(h.push({title:z(_$_ac43[427]),onclick:function(){a.insertRow(1,parseInt(b),1)}}),h.push({title:z(_$_ac43[428]),onclick:function(){a.insertRow(1,parseInt(b))}})),1==a.options.allowDeleteRow&&h.push({title:z(_$_ac43[429]),onclick:function(){a.deleteRow(a.getSelectedRows().length?void 0:parseInt(b))}}),
|
|
350
|
+
h.push({type:_$_ac43[405]});if(e==_$_ac43[410]&&1==a.options.allowComments){var p=a.records[g][f].element.getAttribute(_$_ac43[264])||_$_ac43[3];h.push({title:p?z(_$_ac43[430]):z(_$_ac43[431]),icon:_$_ac43[432],onclick:function(){var q=A.getColumnNameFromCoords(f,g),r=prompt(z(_$_ac43[433]),p);r&&a.setComments(q,r)}});p&&h.push({title:z(_$_ac43[434]),onclick:function(){var q=A.getColumnNameFromCoords(f,g);a.setComments(q,_$_ac43[3])}});h.push({type:_$_ac43[405]})}l.allowExport&&h.push({title:z(_$_ac43[435]),
|
|
351
|
+
icon:_$_ac43[436],shortcut:n+_$_ac43[437],onclick:function(){a.download()}});l.about&&h.push({title:z(_$_ac43[438]),icon:_$_ac43[439],onclick:function(){!0===l.about?alert(F().print()):alert(l.about)}});return h};return k}(),ca=function(){var k=function(a){a.showToolbar=function(){k.show.call(a.parent)};a.hideToolbar=function(){k.hide.call(a.parent)};a.refreshToolbar=function(){k.update.call(a.parent,a)}};k[_$_ac43[11]]=function(a){this.toolbar.innerHTML=_$_ac43[3];this.config.toolbar=k[_$_ac43[51]].call(this,
|
|
352
|
+
a);k.show.call(this)};k[_$_ac43[51]]=function(a){a||(a=this.config.toolbar);a?Array.isArray(a)?a={items:a}:typeof a===_$_ac43[85]&&(a=a({items:k.getDefault()})):a={};typeof a!==_$_ac43[84]&&(a={});a.items||(a.items=k.getDefault());typeof a.responsive==_$_ac43[13]&&(a.responsive=!0,a.bottom=!1,a.maxWidth=this.element.offsetWidth);return a};k.show=function(){this.toolbar.innerHTML||k.build.call(this);this.toolbar.style.display=_$_ac43[3];this.element.classList.add(_$_ac43[440])};k.hide=function(){this.toolbar.style.display=
|
|
353
|
+
_$_ac43[40];this.element.classList.remove(_$_ac43[440])};k.update=function(a,c){if(c=this.toolbarInstance)if(c.update(a),c.options.responsive){var b=parseInt(a.content.style.maxWidth);if(!b||this.config.fullscreen)b=a.element.offsetWidth;c.options.maxWidth=b;c.refresh()}};k.build=function(){for(var a=k[_$_ac43[51]].call(this),c=0;c<a.items.length;c++)if(a.items[c].type==_$_ac43[388]){if(!a.items[c].options&&a.items[c].v){a.items[c].options=[];for(var b=0;b<a.items[c].v.length;b++)a.items[c].options.push(a.items[c].v[b]);
|
|
354
|
+
a.items[c].k&&(a.items[c].onchange=function(d,e,f,g){t.current.setStyle(t.current.getSelected(),f.k,g)})}}else a.items[c].type==_$_ac43[255]?(a.items[c].type=_$_ac43[441],a.items[c].onclick=function(d,e,f){f.color||jSuites.color(f,{onchange:function(g,h){t.current.setStyle(t.current.getSelected(),f.k,h)}}).open()}):!a.items[c].onclick&&a.items[c].k&&(a.items[c].onclick=function(){t.current.setStyle(t.current.getSelected(),this.k,this.v)});(c=la.execute.call(this,_$_ac43[87],[a]))&&(a=c[0]);this.toolbarInstance=
|
|
355
|
+
jSuites.toolbar(this.toolbar,a);this.toolbarInstance.application=this;a=this.element.tabs.getActive();this.toolbarInstance.update(this.worksheets[a])};k.getDefault=function(){return[{content:_$_ac43[442],onclick:function(){t.current&&t.current.undo()}},{content:_$_ac43[443],onclick:function(){t.current&&t.current.redo()}},{content:_$_ac43[436],onclick:function(){t.current&&t.current.download()}},{type:_$_ac43[444]},{type:_$_ac43[388],width:_$_ac43[445],options:[_$_ac43[446],_$_ac43[447],_$_ac43[448]],
|
|
356
|
+
render:function(a){return _$_ac43[449]+a+_$_ac43[226]+a+_$_ac43[450]},onchange:function(a,c,b,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_ac43[451],d)}},{type:_$_ac43[388],width:_$_ac43[452],content:_$_ac43[453],options:[_$_ac43[454],_$_ac43[455],_$_ac43[456],_$_ac43[457],_$_ac43[458]],render:function(a){return _$_ac43[459]+a+_$_ac43[226]+a+_$_ac43[450]},onchange:function(a,c,b,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_ac43[460],d)}},{type:_$_ac43[388],columns:4,
|
|
357
|
+
options:[_$_ac43[461],_$_ac43[462],_$_ac43[463],_$_ac43[464]],render:function(a){return _$_ac43[465]+a+_$_ac43[466]},onchange:function(a,c,b,d){t.current&&t.current.setStyle(t.current.getSelected(),_$_ac43[467],d.split(_$_ac43[468])[2])}},{type:_$_ac43[441],content:_$_ac43[469],k:_$_ac43[470],v:_$_ac43[471]},{type:_$_ac43[255],content:_$_ac43[472],k:_$_ac43[255]},{type:_$_ac43[255],content:_$_ac43[473],k:_$_ac43[474]},{type:_$_ac43[388],content:_$_ac43[475],width:_$_ac43[476],options:[_$_ac43[477],
|
|
358
|
+
_$_ac43[478],_$_ac43[479],_$_ac43[480]],onchange:function(a,c,b,d,e){a=t.current.table;a.classList.remove(_$_ac43[481]);a.classList.remove(_$_ac43[482]);a.classList.remove(_$_ac43[483]);1==e?a.classList.add(_$_ac43[481]):2==e?a.classList.add(_$_ac43[482]):3==e&&a.classList.add(_$_ac43[483]);t.current.refreshBorders()}},{content:_$_ac43[15],onclick:function(a,c,b){b.children[0].innerText==_$_ac43[15]?(t.current.fullscreen(!0),b.children[0].innerText=_$_ac43[484]):(t.current.fullscreen(!1),b.children[0].innerText=
|
|
359
|
+
_$_ac43[15])},tooltip:_$_ac43[485],updateState:function(a,c,b,d){b.children[0].innerText=1==d.parent.config.fullscreen?_$_ac43[484]:_$_ac43[15]}},{type:_$_ac43[388],data:[_$_ac43[486],_$_ac43[487],_$_ac43[488],_$_ac43[489],_$_ac43[490],_$_ac43[491],_$_ac43[492],_$_ac43[493],_$_ac43[494],_$_ac43[495]],columns:5,render:function(a){return _$_ac43[465]+a+_$_ac43[466]},right:!0,onchange:function(a,c,b,d,e){if(a=t.current.getHighlighted()){b=c.thickness||1;c=c.color||_$_ac43[496];e={};for(var f=a[0],g=
|
|
360
|
+
a[1],h=a[2],l=a[3],n=a[1];n<=a[3];n++)for(var p=a[0];p<=a[2];p++){var q=A.getColumnNameFromCoords(p,n);e[q]||(e[q]=_$_ac43[3]);e[q]=d!=_$_ac43[491]&&d!=_$_ac43[487]||p!=f?(d==_$_ac43[488]||d==_$_ac43[490])&&p>f?e[q]+(_$_ac43[497]+b+_$_ac43[498]+c+_$_ac43[295]):d==_$_ac43[486]?e[q]+(_$_ac43[497]+b+_$_ac43[498]+c+_$_ac43[295]):e[q]+_$_ac43[499]:e[q]+(_$_ac43[497]+b+_$_ac43[498]+c+_$_ac43[295]);e[q]=d!=_$_ac43[486]&&d!=_$_ac43[493]&&d!=_$_ac43[487]||p!=h?e[q]+_$_ac43[501]:e[q]+(_$_ac43[500]+b+_$_ac43[498]+
|
|
361
|
+
c+_$_ac43[295]);e[q]=d!=_$_ac43[492]&&d!=_$_ac43[487]||n!=g?(d==_$_ac43[488]||d==_$_ac43[489])&&n>g?e[q]+(_$_ac43[502]+b+_$_ac43[498]+c+_$_ac43[295]):d==_$_ac43[486]?e[q]+(_$_ac43[502]+b+_$_ac43[498]+c+_$_ac43[295]):e[q]+_$_ac43[503]:e[q]+(_$_ac43[502]+b+_$_ac43[498]+c+_$_ac43[295]);e[q]=d!=_$_ac43[486]&&d!=_$_ac43[494]&&d!=_$_ac43[487]||n!=l?e[q]+_$_ac43[505]:e[q]+(_$_ac43[504]+b+_$_ac43[498]+c+_$_ac43[295])}Object.keys(e)&&t.current.setStyle(e,null,null,!0)}},onload:function(a,c){var b=document.createElement(_$_ac43[20]),
|
|
362
|
+
d=document.createElement(_$_ac43[20]);b.appendChild(d);var e=jSuites.color(d,{closeOnChange:!1,onchange:function(f,g){f.parentNode.children[1].style.color=g;c.color=g}});d=document.createElement(_$_ac43[441]);d.classList.add(_$_ac43[506]);d.innerHTML=_$_ac43[507];d.onclick=function(){e.open()};b.appendChild(d);a.children[1].appendChild(b);d=document.createElement(_$_ac43[20]);jSuites.picker(d,{type:_$_ac43[388],data:[1,2,3,4,5],render:function(f){return _$_ac43[508]+f+_$_ac43[509]},onchange:function(f,
|
|
363
|
+
g,h,l){c.thickness=l},width:_$_ac43[510]});a.children[1].appendChild(d);d=document.createElement(_$_ac43[20]);d.style.flex=_$_ac43[511];a.children[1].appendChild(d)}},{content:_$_ac43[512],onclick:function(a,c,b){b.children[0].innerText==_$_ac43[512]?(ma.show.call(t.current),b.children[0].innerText=_$_ac43[513]):(ma.hide.call(t.current),b.children[0].innerText=_$_ac43[512])},tooltip:_$_ac43[514],updateState:function(a,c,b,d){b.children[0].innerText=1==d.options.search?_$_ac43[513]:_$_ac43[512]}}]};
|
|
364
|
+
return k}(),ea=function(){var k=function(a){a.createWorksheet=function(c){return a.parent.createWorksheet(c)};a.deleteWorksheet=function(c){return a.parent.deleteWorksheet(c)};a.renameWorksheet=function(c,b){return a.parent.renameWorksheet(c,b)};a.moveWorksheet=function(c,b){return a.parent.moveWorksheet(c,b)};a.openWorksheet=function(){return a.parent.openWorksheet(a.parent.getWorksheet(a))};a.getWorksheet=function(c){return a.parent.getWorksheet(c)};a.getWorksheetActive=function(){return a.parent.getWorksheetActive()};
|
|
365
|
+
a.getWorksheetName=function(){return a.options.worksheetName.toUpperCase()}};k.nextName=function(){var a=1,c,b=t.spreadsheet;if(b.length)for(var d=0;d<b.length;d++){var e=b[d].worksheets;if(e.length)for(var f=0;f<e.length;f++)e[f].options.worksheetName&&(c=e[f].options.worksheetName.match(/(\d+)/))&&(c=parseInt(c[0])+1,c>a&&(a=c))}return a};k.createWorksheet=function(a){if(!N.call(this))return!1;a||(a={});var c=this.worksheets.length,b=B.call(this,_$_ac43[515],a,c);if(typeof b===_$_ac43[84])a=b;else if(!1===
|
|
366
|
+
b)return!1;a.data||a.minDimensions||(a.minDimensions=[8,8]);a.worksheetId||(a.worksheetId=jSuites.guid().substring(0,8));a.worksheetName||(a.worksheetName=_$_ac43[357]+k.nextName());D(a.worksheetName)?jSuites.notification({error:_$_ac43[511],message:_$_ac43[516]}):(b=ia.worksheet(this,a),b.onload(),G.call(b,_$_ac43[517],[a]),B.call(this,_$_ac43[518],b,a,c))};k.deleteWorksheet=function(a){var c=this.worksheets[a];if(!N.call(this,c))return!1;D(c.options.worksheetName,null);this.element.tabs.deleteElement(a);
|
|
367
|
+
this.worksheets.splice(a,1);G.call(c,_$_ac43[519],[a]);B.call(this,_$_ac43[520],c,a)};k.renameWorksheet=function(a,c){var b=this.worksheets[a];if(!N.call(this,b))return!1;var d=b.options.worksheetName;if(d.toLowerCase()==c.toLowerCase())return!1;c=c.replace(/[^0-9A-Za-z_\s^]+/gi,_$_ac43[3]);Number(c)==c&&(c=_$_ac43[357]+Number(c));D(c)?alert(_$_ac43[521]):(D(d,null),this.element.tabs.rename(a,c),b.options.worksheetName=c,D(c,b),Q.call(this,{worksheet:b,action:_$_ac43[80],index:a,oldValue:d,newValue:c}),
|
|
368
|
+
G.call(b,_$_ac43[80],{worksheet:a,newValue:c}),Ca.updateWorksheetName.call(b,d,c),S.updateWorksheetNames.call(b,d,c),B.call(this,_$_ac43[522],b,a,c,d))};k.updateWorksheet=function(a,c){var b=this.worksheets;if(!N.call(this))return!1;this.worksheets.splice(c,0,b.splice(a,1)[0]);Q.call(this,{worksheet:b[c],action:_$_ac43[81],f:a,t:c});G.call(b[c],_$_ac43[81],{f:a,t:c});B.call(this,_$_ac43[523],b[c],a,c)};k.moveWorksheet=function(a,c){this.element.tabs.move(a,c)};k.openWorksheet=function(a){var c=this.worksheets[a];
|
|
369
|
+
!c||t.current&&t.current==c||(this.element.tabs.getActive()!=a?this.element.tabs.open(a):this.element.tabs.setBorder(a),t.current&&t.current.resetSelection(),t.current=c,t.current.refreshBorders(),P.call(t.current),k.state.call(this,a),ca.update.call(this,t.current),B.call(this,_$_ac43[524],c,a))};k.getWorksheet=function(a){if(a&&typeof a==_$_ac43[84]){if(a=this.worksheets.indexOf(a),0<=a)return a}else for(var c=0;c<this.worksheets.length;c++)if(a===this.worksheets[c].options.worksheetId)return c;
|
|
370
|
+
return!1};k.getWorksheetActive=function(){return this.element.tabs.getActive()};k.getWorksheetInstance=function(a){return a===_$_ac43[3]||typeof a==_$_ac43[17]?(a=k.getWorksheet.call(this,a),!1===a?!1:this.worksheets[a]):this.worksheets[a]};k.state=function(a){try{if(typeof localStorage!==_$_ac43[13]){var c=this.config.cloud?this.config.cloud:this.element.id;if(c)if(typeof a!==_$_ac43[13])localStorage.setItem(_$_ac43[525]+c,a);else{var b=parseInt(localStorage.getItem(_$_ac43[525]+c));k.openWorksheet.call(this,
|
|
371
|
+
b)}}}catch(d){}};return k}(),A=function(){var k={getCaretIndex:function(a){var c=0,b=(this.config.root?this.config.root:window).getSelection();b&&0!==b.rangeCount&&(c=b.getRangeAt(0),b=c.cloneRange(),b.selectNodeContents(a),b.setEnd(c.endContainer,c.endOffset),c=b.toString().length);return c},invert:function(a){for(var c=[],b=Object.keys(a),d=0;d<b.length;d++)c[a[b[d]]]=b[d];return c},getColumnName:function(a){var c=_$_ac43[3];701<a?(c+=String.fromCharCode(64+parseInt(a/676)),c+=String.fromCharCode(64+
|
|
372
|
+
parseInt(a%676/26))):25<a&&(c+=String.fromCharCode(64+parseInt(a/26)));return c+=String.fromCharCode(65+a%26)},getColumnNameFromCoords:function(a,c){return k.getColumnName(parseInt(a))+(parseInt(c)+1)},getCoordsFromColumnName:function(a){var c=/^[a-zA-Z]+/.exec(a);if(c){for(var b=0,d=0;d<c[0].length;d++)b+=parseInt(c[0].charCodeAt(d)-64)*Math.pow(26,c[0].length-1-d);b--;0>b&&(b=0);a=parseInt(/[0-9]+$/.exec(a))||null;0<a&&a--;return[b,a]}}};k.shiftFormula=S.shiftFormula;k.createFromTable=function(a,
|
|
373
|
+
c){if(a.tagName!=_$_ac43[526])console.log(_$_ac43[527]);else{c||(c={});c.columns=[];c.data=[];var b=a.querySelectorAll(_$_ac43[528]);if(b.length)for(var d=0;d<b.length;d++){var e=b[d].style.width;e||(e=b[d].getAttribute(_$_ac43[152]));e&&(c.columns[d]||(c.columns[d]={}),c.columns[d].width=e)}e=function(u){var x=u.getBoundingClientRect();x=50<x.width?x.width:50;c.columns[d]||(c.columns[d]={});u.getAttribute(_$_ac43[529])?c.columns[d].type=u.getAttribute(_$_ac43[529]):c.columns[d].type=_$_ac43[56];
|
|
374
|
+
c.columns[d].width=x+_$_ac43[44];c.columns[d].title=u.innerHTML;c.columns[d].align=u.style.textAlign||(c.defaultColAlign?c.defaultColAlign:_$_ac43[53]);u.classList.contains(_$_ac43[530])&&(c.columns[d].readOnly=!0);if(x=u.getAttribute(_$_ac43[531]))c.columns[d].name=x;if(x=u.getAttribute(_$_ac43[532]))c.columns[d].id=x};var f=[],g=a.querySelectorAll(_$_ac43[533]);if(g.length){for(b=0;b<g.length-1;b++){var h=[];for(d=0;d<g[b].children.length;d++){var l={title:g[b].children[d].innerText,colspan:g[b].children[d].getAttribute(_$_ac43[52])||
|
|
375
|
+
1};h.push(l)}f.push(h)}g=g[g.length-1].children;for(d=0;d<g.length;d++)e(g[d])}l=0;var n={},p={},q={},r={},w=null;h=a.querySelectorAll(_$_ac43[534]);for(b=0;b<h.length;b++)if(c.data[l]=[],1!=c.parseTableFirstRowAsHeader||g.length||0!=b){for(d=0;d<h[b].children.length;d++){var m=h[b].children[d].getAttribute(_$_ac43[535]);m?m.substr(0,1)!=_$_ac43[12]&&(m=_$_ac43[12]+m):m=h[b].children[d].innerHTML;c.data[l].push(m);m=A.getColumnNameFromCoords(d,b);(w=h[b].children[d].getAttribute(_$_ac43[536]))&&(r[m]=
|
|
376
|
+
w);w=parseInt(h[b].children[d].getAttribute(_$_ac43[52]))||0;var v=parseInt(h[b].children[d].getAttribute(_$_ac43[164]))||0;if(w||v)n[m]=[w||1,v||1];if(w=h[b].children[d].style&&h[b].children[d].style.display==_$_ac43[40])h[b].children[d].style.display=_$_ac43[3];(w=h[b].children[d].getAttribute(_$_ac43[98]))&&(q[m]=w);h[b].children[d].classList.contains(_$_ac43[537])&&(q[m]=q[m]?q[m]+_$_ac43[538]:_$_ac43[539])}h[b].style&&h[b].style.height&&(p[b]={height:h[b].style.height});l++}else for(d=0;d<h[b].children.length;d++)e(h[b].children[d]);
|
|
377
|
+
0<Object.keys(f).length&&(c.nestedHeaders=f);0<Object.keys(q).length&&(c.style=q);0<Object.keys(n).length&&(c.mergeCells=n);0<Object.keys(p).length&&(c.rows=p);0<Object.keys(r).length&&(c.classes=r);h=a.querySelectorAll(_$_ac43[540]);if(h.length){a=[];for(b=0;b<h.length;b++){e=[];for(d=0;d<h[b].children.length;d++)e.push(h[b].children[d].innerText);a.push(e)}0<Object.keys(a).length&&(c.footers=a)}if(1==c.parseTableAutoCellType)for(a=[],d=0;d<c.columns.length;d++){f=e=!0;a[d]=[];for(b=0;b<c.data.length;b++)if(m=
|
|
378
|
+
c.data[b][d],a[d][m]||(a[d][m]=0),a[d][m]++,25<m.length&&(e=!1),10==m.length){if(m.substr(4,1)!=_$_ac43[185]||m.substr(7,1)!=_$_ac43[185])f=!1}else f=!1;b=Object.keys(a[d]).length;f?c.columns[d].type=_$_ac43[184]:1==e&&1<b&&b<=parseInt(.1*c.data.length)&&(c.columns[d].type=_$_ac43[58],c.columns[d].source=Object.keys(a[d]))}return c}};k.injectArray=function(a,c,b){return a.slice(0,c).concat(b).concat(a.slice(c))};k.parseCSV=function(a,c){c=c||_$_ac43[25];for(var b=0,d=0,e=[[]],f=0,g=null,h=!1,l=!1,
|
|
379
|
+
n=0;n<a.length;n++)if(e[d]||(e[d]=[]),e[d][b]||(e[d][b]=_$_ac43[3]),a[n]!=_$_ac43[541])if(a[n]!=_$_ac43[542]&&a[n]!=c||0!=h&&1!=l&&g){a[n]==_$_ac43[187]&&(h=!h);if(null===g){if(g=h,1==g)continue}else if(!0===g&&!l&&a[n]==_$_ac43[187]){a[n+1]==_$_ac43[187]?(h=!0,e[d][b]+=a[n],n++):l=!0;continue}e[d][b]+=a[n]}else{g=null;l=h=!1;if(e[d][b][0]==_$_ac43[187]){var p=e[d][b].trim();p[p.length-1]==_$_ac43[187]&&(e[d][b]=p.substr(1,p.length-2))}a[n]==_$_ac43[542]?(b=0,d++):(b++,b>f&&(f=b))}for(a=0;a<e.length;a++)for(n=
|
|
380
|
+
0;n<=f;n++)void 0===e[a][n]&&(e[a][n]=_$_ac43[3]);return e};k.getTokensFromRange=S.getTokensFromRange;k.getRangeFromTokens=S.getRangeFromTokens;return k}(),va=function(){var k={},a=null,c=null,b=null,d=!1,e=null,f=null,g=null,h=function(m){function v(J){J.className&&(J.classList.contains(_$_ac43[348])&&(y=J),J.classList.contains(_$_ac43[360])&&(H=J),J.classList.contains(_$_ac43[543])&&(L=J));J.tagName==_$_ac43[544]?u=1:J.tagName==_$_ac43[545]?u=2:J.tagName==_$_ac43[546]&&(u=3);J.parentNode&&!y&&v(J.parentNode)}
|
|
381
|
+
var u=null,x=null,y=null,H=null,L=null,E=null,ba=null,ra=null;v(m.target);if(null!==L)return!1;if(y)if(m.target.classList.contains(_$_ac43[330]))x=_$_ac43[547];else if(m.target.classList.contains(_$_ac43[339]))x=_$_ac43[138];else if(m.target.classList.contains(_$_ac43[267]))x=_$_ac43[409],E=parseInt(m.target.getAttribute(_$_ac43[43]));else if(m.target.parentNode&&m.target.parentNode.classList.contains(_$_ac43[177]))E=m.target.getAttribute(_$_ac43[181]),ba=m.target.getAttribute(_$_ac43[182]),null===
|
|
382
|
+
E?x=_$_ac43[547]:(x=_$_ac43[406],E=parseInt(E),ba=parseInt(ba));else if(m.target.parentNode&&m.target.parentNode.classList.contains(_$_ac43[146]))x=_$_ac43[548];else if(m.target.classList.contains(_$_ac43[150]))x=_$_ac43[548];else if(m.target.parentNode&&m.target.parentNode.classList.contains(_$_ac43[549]))x=_$_ac43[401],E=Array.prototype.indexOf.call(m.target.parentNode.children,m.target);else if(1==u)x=_$_ac43[408],E=m.target.clientWidth-m.offsetX,m.target.classList.contains(_$_ac43[168])&&3<E&&
|
|
383
|
+
20>E&&(x=_$_ac43[550]),E=m.target.getAttribute(_$_ac43[42]);else if(2==u){if(m=l(m,y))x=_$_ac43[410],E=m[0],ba=m[1],ra=m[2]}else if(3==u){if(E=m.target.getAttribute(_$_ac43[42]),ba=m.target.getAttribute(_$_ac43[43]),E||ba)x=_$_ac43[551]}else u||jSuites.findElement(m.target,_$_ac43[552])&&(x=_$_ac43[87]);return[y,H,u,x,E,ba,ra]},l=function(m,v){if(m.changedTouches&&m.changedTouches[0]){var u=m.changedTouches[0].clientX;m=m.changedTouches[0].clientY}else u=m.clientX,m=m.clientY;v=(v.spreadsheet.config.root?
|
|
384
|
+
v.spreadsheet.config.root:document).elementsFromPoint(u,m);for(var x=0;x<v.length;x++)if(u=v[x].getAttribute(_$_ac43[42]),m=v[x].getAttribute(_$_ac43[43]),null!=u&&null!=m)return u=parseInt(u),m=parseInt(m),[u,m,v[x]];return!1},n=function(m){var v=h(m);if(!1===v)return!1;v[0]?v[1]?t.current!=v[1].jexcel&&(t.current&&t.current.resetSelection(),t.current=v[1].jexcel):(m=v[0].tabs.getActive(),0<=m&&(t.current=v[0].spreadsheet.worksheets[m])):t.current&&!jSuites.findElement(m.target,_$_ac43[219])&&(t.current.resetSelection(!0),
|
|
385
|
+
t.current=null);return v};k.input=function(m){if(m.target.tagName==_$_ac43[553]&&m.target.classList.contains(_$_ac43[92])){var v=null;t.current?v=t.current:m.target.getAttribute(_$_ac43[554])&&(v=D(m.target.getAttribute(_$_ac43[554])));v&&fa.parse.call(v,m.target)}};k.keydown=function(m){if(t.current){m.target.tagName==_$_ac43[553]&&m.target.classList.contains(_$_ac43[92])&&fa.onkeydown.call(t.current,m);if(27==m.which){if(t.current.edition)return t.current.closeEditor(t.current.edition,!1),m.preventDefault(),
|
|
386
|
+
!1;if(na.event)return na.cancel.call(t.current,m),m.preventDefault(),!1;if(ha.event)return ha.cancel.call(t.current,m),!1;if(1==Y.isVisible())return Y.close.call(t.current,!1),m.preventDefault(),!1}if(!m.target.classList.contains(_$_ac43[219]))if(m.target.classList.contains(_$_ac43[379])){var v=m.target;e&&clearTimeout(e);e=setTimeout(function(){Y.search.call(t.current,v.value);e=null},500)}else if(m.target.classList.contains(_$_ac43[393]))v=m.target,e&&clearTimeout(e),e=setTimeout(function(){t.current.search(v.value);
|
|
387
|
+
e=null},400);else if(t.current.edition){var u=t.current.edition.getAttribute(_$_ac43[42]);13==m.which?t.current.options.columns[u].type==_$_ac43[184]?t.current.closeEditor(t.current.edition,!0):t.current.options.columns[u].type!=_$_ac43[58]&&t.current.options.columns[u].type!=_$_ac43[555]&&t.current.options.columns[u].type!=_$_ac43[432]&&(m.altKey?t.current.parent.input.classList.contains(_$_ac43[556])||document.execCommand(_$_ac43[557],!1,_$_ac43[558]):(t.current.closeEditor(t.current.edition,!0),
|
|
388
|
+
t.current.down(),m.preventDefault())):9==m.which&&(t.current.closeEditor(t.current.edition,!0),t.current.right(),m.preventDefault())}else if(t.current.selectedCell)if(33==m.which)0<t.current.options.pagination?qa.pageUp.call(t.current):C.pageUp.call(t.current);else if(34==m.which)0<t.current.options.pagination?qa.pageDown.call(t.current):C.pageDown.call(t.current);else if(37==m.which)t.current.left(m.shiftKey,m.ctrlKey),m.preventDefault();else if(39==m.which)t.current.right(m.shiftKey,m.ctrlKey),
|
|
389
|
+
m.preventDefault();else if(38==m.which)t.current.up(m.shiftKey,m.ctrlKey),m.preventDefault();else if(40==m.which)t.current.down(m.shiftKey,m.ctrlKey),m.preventDefault();else if(36==m.which)t.current.first(m.shiftKey,m.ctrlKey),m.preventDefault();else if(35==m.which)t.current.last(m.shiftKey,m.ctrlKey),m.preventDefault();else if(32==m.which)t.current.setCheckRadioValue(),m.preventDefault();else if(46==m.which||8==m.which)t.current.isEditable()&&t.current.setValue(t.current.getSelected(!1,!0),_$_ac43[3]);
|
|
390
|
+
else if(13==m.which)m.shiftKey?t.current.up():(1==t.current.options.allowManualInsertRow&&t.current.selectedCell[1]==(t.current.results?t.current.results[t.current.results.length-1]:t.current.rows.length-1)&&t.current.insertRow(),t.current.selectedCell&&t.current.down()),m.preventDefault();else if(9==m.which)m.shiftKey?t.current.left():(u=t.current.selectedCell[0],t.current.right(),1==t.current.options.allowInsertColumn&&1==t.current.options.allowManualInsertColumn&&t.current.selectedCell[0]==u&&
|
|
391
|
+
(t.current.insertColumn(),t.current.right())),m.preventDefault();else if((m.ctrlKey||m.metaKey)&&!m.shiftKey)65==m.which?(t.current.selectAll(),m.preventDefault()):83==m.which?(t.current.download(),m.preventDefault()):89==m.which?(t.current.parent.redo(),m.preventDefault()):90==m.which?(t.current.parent.undo(),m.preventDefault()):67==m.which?(t.current.copy(),m.preventDefault()):88==m.which?(t.current.cut(),m.preventDefault()):86==m.which?k.paste(m):189==m.which&&(1==t.current.options.allowDeleteRow&&
|
|
392
|
+
b==_$_ac43[409]?(t.current.deleteRow(),m.preventDefault()):1==t.current.options.allowDeleteColumn&&b==_$_ac43[408]&&(t.current.deleteColumn(),m.preventDefault()));else if(t.current.selectedCell&&t.current.isEditable()){u=t.current.selectedCell[1];var x=t.current.selectedCell[0];t.current.options.columns[x].type!=_$_ac43[18]&&(32==m.keyCode?t.current.options.columns[x].type==_$_ac43[250]||t.current.options.columns[x].type==_$_ac43[252]?m.preventDefault():t.current.openEditor(t.current.records[u][x].element,
|
|
393
|
+
!0,m):113==m.keyCode?t.current.openEditor(t.current.records[u][x].element,!1,m):1!=m.key.length&&m.key!=_$_ac43[559]||m.altKey||m.ctrlKey||t.current.records[u]&&t.current.openEditor(t.current.records[u][x].element,!0,m))}}};var p=function(m,v,u,x,y,H){if(1==t.current.parent.input.classList.contains(_$_ac43[92])&&fa.update.call(t.current,m,v,u,x,y))return!1;if(t.current.edition)t.current.closeEditor(t.current.edition,!0);else if(b&&b!==H)return!1;fa.current?fa.range.call(t.current,m,v,u,x,y):ta[_$_ac43[11]].call(t.current,
|
|
394
|
+
m,v,u,x,y)};k.mousedown=function(m){m=m||window.event;var v=m.buttons?m.buttons:m.button?m.button:m.which;if(t.current)if(1==Y.isVisible()&&(jSuites.findElement(m.target,_$_ac43[383])||Y.close.call(t.current,!1)),t.current.edition){if(jSuites.findElement(m.target,_$_ac43[99]))return!1}else if(jSuites.findElement(m.target,_$_ac43[219]))return!1;var u=n(m);if(!1===u)return!1;g=u;if(1<v)if(u[3]==_$_ac43[408]){if(t.current.isSelected(u[4],null))return!1}else if(u[3]==_$_ac43[409]){if(t.current.isSelected(null,
|
|
395
|
+
u[4]))return!1}else if(u[3]==_$_ac43[410]&&t.current.isSelected(u[4],u[5]))return!1;if(t.current){if(u[3]==_$_ac43[138])t.current.isEditable()&&(ha.event=!0);else if(u[3]==_$_ac43[550])Y.open.call(t.current,u[4]);else{if(1==u[2])if(1==t.current.options.columnDrag&&6>m.target.offsetHeight-m.offsetY)na.start.call(t.current,m);else if(1==t.current.options.columnResize&&6>m.target.offsetWidth-m.offsetX)sa.start.call(t.current,m);else{v=t.current.options.columns.length-1;var x=t.current.options.data.length-
|
|
396
|
+
1;if(u[3]==_$_ac43[547])p(0,0,v,x,m,u[3]),c=a=0;else if(u[3]==_$_ac43[406]){var y=ka.range.call(t.current,u[5])[u[4]];y[1]>v&&(y[1]=v);p(y[0],0,y[1],x,m,u[3]);a=y[0];c=0}else(m.shiftKey||m.ctrlKey)&&null!=a&&null!=c?p(a,0,u[4],x,m,u[3]):(u[3]==_$_ac43[408]&&a==u[4]&&1==t.current.options.allowRenameColumn&&(f=setTimeout(function(){t.current.setHeader(u[4])},800)),p(u[4],0,u[4],x,m,u[3]),a=u[4],c=0)}if(2==u[2])if(u[3]==_$_ac43[409])1==t.current.options.rowDrag&&6>m.target.offsetWidth-m.offsetX?na.start.call(t.current,
|
|
397
|
+
m):1==t.current.options.rowResize&&6>m.target.offsetHeight-m.offsetY?sa.start.call(t.current,m):(v=t.current.options.columns.length-1,x=parseInt(u[4]),(m.shiftKey||m.ctrlKey)&&null!=a&&null!=c?p(0,c,v,x,m,u[3]):(p(0,x,v,x,m,u[3]),a=0,c=x));else if(u[3]==_$_ac43[410]){v=parseInt(u[4]);x=parseInt(u[5]);if(!t.current.edition&&(y=t.current.options.columns[u[4]].type,m.target.tagName==_$_ac43[560]&&(y==_$_ac43[253]||y==_$_ac43[254])&&m.target.parentNode.classList.contains(_$_ac43[124]))){var H=m.target.innerText;
|
|
398
|
+
y==_$_ac43[253]&&(H=_$_ac43[561]+H);window.open(H,_$_ac43[562])}(m.shiftKey||m.ctrlKey)&&null!=a&&null!=c?p(a,c,v,x,m,u[3]):(p(v,x,v,x,m,u[3]),a=v,c=x)}}b=u[3];typeof u[3]!==_$_ac43[13]&&B.call(t.current.parent,_$_ac43[563],t.current,u[3],u[4],u[5]);d=!0}else d=!1};k.mouseup=function(m){t.current&&(na.event?na.end.call(t.current,m):sa.event?sa.end.call(t.current,m):ha.event?ha.end.call(t.current,m):m.target.classList.contains(_$_ac43[382])?Y.close.call(t.current,!0):t.current.edition&&m.target.classList.contains(_$_ac43[564])&&
|
|
399
|
+
50>m.target.clientWidth-m.offsetX&&50>m.offsetY?Z.close.call(t.current,null,!0):m.target.classList.contains(_$_ac43[318])&&(m=m.target.innerText==_$_ac43[215]?0:m.target.innerText==_$_ac43[216]?m.target.getAttribute(_$_ac43[264])-1:m.target.innerText-1,qa[_$_ac43[11]].call(t.current,parseInt(m))));f&&(clearTimeout(f),f=null);d=b=!1;fa.current&&fa.close.call(t.current)};k.mousemove=function(m){m=m||window.event;if(t.current){var v=m.target.getAttribute(_$_ac43[42]),u=m.target.getAttribute(_$_ac43[43]);
|
|
400
|
+
if(1==d)na.event?na.update.call(t.current,m):sa.event?sa.update.call(t.current,m):Ka.event&&Ka.update.call(t.current,m);else{var x=m.target.getBoundingClientRect();t.current.cursor&&(t.current.cursor.style.cursor=_$_ac43[3],t.current.cursor=null);1==t.current.options.editable&&(v||u)&&(1==t.current.options.rowResize&&m.target&&v&&!u&&5>x.width-(m.clientX-x.left)?(t.current.cursor=m.target,t.current.cursor.style.cursor=_$_ac43[565]):1==t.current.options.columnResize&&m.target&&!v&&u&&5>x.height-(m.clientY-
|
|
401
|
+
x.top)?(t.current.cursor=m.target,t.current.cursor.style.cursor=_$_ac43[566]):1==t.current.options.rowDrag&&m.target&&!v&&u&&5>x.width-(m.clientX-x.left)?(t.current.cursor=m.target,t.current.cursor.style.cursor=_$_ac43[567]):1==t.current.options.columnDrag&&m.target&&v&&!u&&5>x.height-(m.clientY-x.top)&&(t.current.cursor=m.target,t.current.cursor.style.cursor=_$_ac43[567]))}}};k.mouseover=function(m){m=m||window.event;var v=!1;if(t.current&&1==d){var u=h(m);if(u[0]){if(u[1]&&t.current!=u[1].jexcel&&
|
|
402
|
+
t.current)return!1;if(!na.event&&!sa.event)if(ha.event){var x=m.target.getAttribute(_$_ac43[42]),y=m.target.getAttribute(_$_ac43[43]);t.current.isSelected(x,y)||null===x||null===y||(ha.call(t.current,x,y),v=!0)}else null!==a&&null!==c&&(1==u[2]&&(x=a,u[3]==_$_ac43[408]&&(x=m.target.getAttribute(_$_ac43[42])),y=t.current.options.data.length-1,p(a,0,x,y,m,u[3])),2==u[2]&&(u[3]==_$_ac43[409]?(x=t.current.options.columns.length-1,y=parseInt(m.target.getAttribute(_$_ac43[43])),p(0,c,x,y,m,u[3])):u[3]==
|
|
403
|
+
_$_ac43[410]&&(x=m.target.getAttribute(_$_ac43[42]),y=m.target.getAttribute(_$_ac43[43]),x&&y&&(p(a,c,x,y,m,u[3]),v=!0))))}}1==v&&!f&&C.limited.call(t.current)?f=setTimeout(function(){var H=t.current.content.getBoundingClientRect();if(m.changedTouches&&m.changedTouches[0])var L=m.changedTouches[0].clientX,E=m.changedTouches[0].clientY;else L=m.clientX,E=m.clientY;50>H.height-(E-H.top)?C.pageDown.call(t.current,1,null,m):80>E-H.top&&C.pageUp.call(t.current,1,null,m);50>H.width-(L-H.left)?C.pageRight.call(t.current,
|
|
404
|
+
1,null,m):80>L-H.left&&C.pageLeft.call(t.current,1,null,m);f=null},100):f&&(clearTimeout(f),f=null)};k.dblclick=function(m){if(t.current)if(m.target.classList.contains(_$_ac43[339]))ha.execute.call(t.current,!1);else{var v=h(m);1==v[2]?1==t.current.options.columnSorting&&(m=m.target.getAttribute(_$_ac43[42]))&&t.current.orderBy(m):2==v[2]&&t.current.isEditable()&&!t.current.edition&&v[6]&&t.current.openEditor(v[6])}};k.paste=function(m){if(t.current&&t.current.selectedCell&&!t.current.edition){var v=
|
|
405
|
+
m.clipboardData||window.clipboardData;v&&(t.current.paste(t.current.selectedCell[0],t.current.selectedCell[1],v.getData(_$_ac43[56])),m&&m.preventDefault())}};k.contextmenu=function(m){var v=n(m);!1!==v&&(v[1]||(v=g),t.current&&!t.current.edition&&(v=Array.prototype.slice.call(v,3),Ma.open.call(t.current,m,v)))};var q=null,r=null,w=null;k.touchstart=function(m){var v=h(m);v[0]?v[1]&&t.current!=v[1].jexcel&&(t.current&&t.current.resetSelection(),t.current=v[1].jexcel):t.current&&(t.current.resetSelection(),
|
|
406
|
+
t.current=null);if(t.current&&!t.current.edition){var u=v[4];v=v[5];r=m.touches[0];q=m.touches.length;w=[u,v];if(null!==u&&null!==v){t.current.updateSelectionFromCoords(u,v,u,v);var x=m.target;f=setTimeout(function(){t.current.openEditor(x,!1,m);f=null},250)}}};k.touchmove=function(m){f&&(clearTimeout(f),f=null);if(t.current){m=m.changedTouches[0];if(r)if(1<q){var v=document.elementFromPoint(m.pageX,m.pageY),u=v.getAttribute(_$_ac43[42]);v=v.getAttribute(_$_ac43[43]);null!==u&&null!==v&&t.current.updateSelectionFromCoords(w[0],
|
|
407
|
+
w[1],u,v)}else t.current.scrollY.scrollTop+=-1*(m.clientY-r.clientY),t.current.scrollX.scrollLeft+=-1*(m.clientX-r.clientX);r=m}};k.touchend=function(m){f&&(clearTimeout(f),f=null);w=r=q=null};k.resize=function(){t.current&&1==t.current.parent.config.fullscreen&&C.refresh.call(t.current)};return k}(),t=function(k,a,c){a||(a={});if(a.cloud&&!c)typeof a.plugins.cloud==_$_ac43[85]?a.plugins.cloud.load(a,function(f){t(k,f,!0)}):console.error(_$_ac43[568]);else{if(k.spreadsheet)b=k.spreadsheet,xa[_$_ac43[11]].call(b,
|
|
408
|
+
a);else var b=ia.spreadsheet(k,a);b.processing=!0;1==b.config.loadingSpin&&jSuites.loading.show();jSuites.ajax.oncomplete[b.name]=function(){for(var f=0;f<b.worksheets.length;f++)b.worksheets[f].onload();b.processing=!1;if(Array.isArray(b.queue)&&0<b.queue.length)for(;f=b.queue.shift();)f[0].updateCell(f[1],f[2],K.call(f[0],f[1],f[2]),!0);b.config.toolbar&&ca.show.call(b);for(f=0;f<b.worksheets.length;f++)W.refresh.call(b.worksheets[f]);if(typeof b.config.onload==_$_ac43[85])b.config.onload(b);ea.state.call(b);
|
|
409
|
+
jSuites.loading.hide()};Array.isArray(a.worksheets)&&(a=a.worksheets);if(Array.isArray(a)){c=null;for(var d=[],e=0;e<a.length;e++)c=ia.worksheet(b,a[e]),d.push(c)}else d=ia.worksheet(b,a);jSuites.ajax.pending(b.name)||(jSuites.ajax.oncomplete[b.name](),jSuites.ajax.oncomplete[b.name]=null);return d}};t.license=null;t.setLicense=function(k){t.license=k};t.spreadsheet=[];t.picker=fa;t.setDictionary=function(k){jSuites.setDictionary(k)};t.extensions={};t.setExtensions=function(k){for(var a=Object.keys(k),
|
|
410
|
+
c=0;c<a.length;c++)typeof k[a[c]]===_$_ac43[85]&&(t[a[c]]=k[a[c]],t.extensions[a[c]]=k[a[c]],t.license&&typeof t[a[c]].license==_$_ac43[85]&&t[a[c]].license.call(t,t.license))};t.destroy=function(k,a){k.spreadsheet&&(a&&ia.unbind(k),a=t.spreadsheet.indexOf(k.spreadsheet),t.spreadsheet.splice(a,1),k.spreadsheet=null,k.jexcel=null,k.innerHTML=_$_ac43[3],k.classList.remove(_$_ac43[569]),k.classList.remove(_$_ac43[348]))};t.version=F;t.helpers=A;t.events=va;typeof formula!==_$_ac43[13]&&(t.formula=formula);
|
|
411
|
+
t.editors=function(){var k={},a=function(c,b){return 1==c[b]||c.options&&1==c.options[b]?!0:c[b]==_$_ac43[229]||c.options&&c.options[b]==_$_ac43[229]?!0:!1};k.createEditor=function(c,b,d,e){e.parent.input.setAttribute(_$_ac43[100],!1);c==_$_ac43[220]?(c=document.createElement(_$_ac43[220]),c.type=_$_ac43[56],c.value=d):c=document.createElement(_$_ac43[20]);c.style.width=b.offsetWidth-2+_$_ac43[44];c.style.height=b.offsetHeight-1+_$_ac43[44];e.parent.input.appendChild(c);return c};k.createDialog=function(c,
|
|
412
|
+
b,d,e,f,g){c=k.createEditor(_$_ac43[20],c,b,f);c.classList.add(_$_ac43[570]);c.classList.add(_$_ac43[564]);800>window.innerWidth?(f.parent.input.style.top=_$_ac43[144],f.parent.input.style.left=_$_ac43[144]):(b=f.parent.input.getBoundingClientRect(),window.innerHeight<b.bottom&&(f.parent.input.style.marginTop=-f.parent.input.offsetHeight));return c};k.general=function(){var c={},b=function(e){e=(_$_ac43[3]+e)[0];return e==_$_ac43[12]||e==_$_ac43[571]?!0:!1},d=function(e){if(e.format||e.mask||e.locale){var f=
|
|
413
|
+
{};e.mask?f.mask=e.mask:e.format?f.mask=e.format:(f.locale=e.locale,f.options=e.options);e.decimal&&(f.options||(f.options={}),f.options={decimal:e.decimal});return f}return null};c.updateCell=function(e,f,g,h,l,n){g=parseInt(g);h=parseInt(h);if(e){var p=d(n),q=null;f===_$_ac43[3]||b(f)||typeof f===_$_ac43[14]||(p?(p=jSuites.mask.extract(f,p,!0))&&p.value!==_$_ac43[3]&&(q=p.value):1==(!1===l.options.autoCasting||!1===n.autoCasting?!1:!0)&&(n.type==_$_ac43[14]||n.type==_$_ac43[307]||n.type==_$_ac43[306]?
|
|
414
|
+
(p=jSuites.mask.extract(f,n,!0))&&p.value!==_$_ac43[3]&&(q=p.value):jSuites.isNumeric(Number(f))&&(q=Number(f))));null!==q&&(f=q);f=c.parseValue(g,h,f,l,n,e);f instanceof Element||f instanceof HTMLDocument?(e.innerHTML=_$_ac43[3],e.appendChild(f)):1==l.parent.config.stripHTML?e.innerText=f:e.innerHTML=f;if(null!==q)return q}};c.createCell=c.updateCell;c.openEditor=function(e,f,g,h,l,n){var p=l.parent.input;p.onblur=function(){p.classList.contains(_$_ac43[92])||l.closeEditor(e,!0)};if(n.type==_$_ac43[14]||
|
|
415
|
+
n.type==_$_ac43[307]||n.type==_$_ac43[306])p.classList.add(_$_ac43[556]),b(f)||n.inputmode||(n.inputmode=_$_ac43[572]);g=null;b(f)||(n.inputmode&&p.setAttribute(_$_ac43[96],n.inputmode),(g=d(n))?(n.disabledMaskOnEdition||(n.mask?(n=n.mask.split(_$_ac43[263]),p.setAttribute(_$_ac43[94],n[0])):n.locale&&p.setAttribute(_$_ac43[573],n.locale)),g.input=l.parent.input,l.parent.input.mask=g,jSuites.mask.render(f,g,!1)):f&&n.type==_$_ac43[306]&&(f*=100));g||(p.innerText=f,jSuites.focus(l.parent.input))};
|
|
416
|
+
c.closeEditor=function(e,f,g,h,l,n){e=l.parent.input;f=f?e.innerText:_$_ac43[3];b(f)?f=f.replace(/(\r\n|\n|\r)/gm,_$_ac43[3]):n.type==_$_ac43[306]&&(f+=_$_ac43[574],e.classList.remove(_$_ac43[575]));return f};c.parseValue=function(e,f,g,h,l,n){b(g)&&1==h.parent.config.parseFormulas&&(g=h.executeFormula(g,e,f));g instanceof Element||g instanceof HTMLDocument||!l||b(g)||!(f=d(l))||(e=jSuites.mask.render(g,f,!0),n&&f.mask&&(f=f.mask.split(_$_ac43[263]),f[1]&&(f[1].match(new RegExp(_$_ac43[576],_$_ac43[375]))&&
|
|
417
|
+
(0>g?n.classList.add(_$_ac43[577]):n.classList.remove(_$_ac43[577])),f[1].match(new RegExp(_$_ac43[578],_$_ac43[375]))&&0>g&&(e=_$_ac43[212]+e+_$_ac43[232]))),e&&(g=e));return g};c[_$_ac43[51]]=function(e,f){var g;return(g=d(e))?jSuites.mask.render(f,g,!0):e.type==_$_ac43[306]?100*parseFloat(f):f};return c}();k.text=k.general;k.number=k.general;k.numeric=k.general;k.percent=k.general;k.notes=function(){var c={},b=null;c.updateCell=function(d,e,f,g,h,l){d&&(f=document.createElement(_$_ac43[20]),f.classList.add(_$_ac43[579]),
|
|
418
|
+
1==h.parent.config.stripHTML?f.innerText=e:f.innerHTML=e,d.innerHTML=_$_ac43[3],d.appendChild(f))};c.createCell=c.updateCell;c.openEditor=function(d,e,f,g,h,l){var n=l&&l.options?l.options:{};n.focus=!0;n.value=e;n.border=!1;n.height=_$_ac43[580];n.toolbar=!1;b=k.createDialog(d,e,f,g,h,l);b=jSuites.editor(b,n)};c.closeEditor=function(d,e,f,g,h,l){return e?b.getData():_$_ac43[3]};return c}();k.dropdown=function(){var c={createCell:function(b,d,e,f,g,h){h.render==_$_ac43[581]?b.classList.add(_$_ac43[582]):
|
|
419
|
+
b.classList.add(_$_ac43[583]);if(b=c.updateCell(b,d,e,f,g,h))return b},destroyCell:function(b){b.classList.remove(_$_ac43[583])},updateCell:function(b,d,e,f,g,h){if(b){var l=c.getItem(b,d,e,f,g,h);l?b.innerHTML=l:d?(d=c.fromLabel(b,d,e,f,g,h),d.length?(l=c.getItem(b,d,e,f,g,h),b.innerHTML=l):b.innerHTML=_$_ac43[3]):b.innerHTML=_$_ac43[3];return d}},openEditor:function(b,d,e,f,g,h){var l=k.createEditor(_$_ac43[20],b,d,g),n=h.delimiter||_$_ac43[263];h=Object.create(h);h.options||(h.options={});typeof h.filter==
|
|
420
|
+
_$_ac43[85]&&(h.source=h.filter(g.el,b,e,f,h.source));typeof h.filterOptions==_$_ac43[85]&&(h=h.filterOptions(g,b,e,f,d,h));e=h.options;h.source&&(e.data=JSON.parse(JSON.stringify(h.source)));a(h,_$_ac43[584])&&(e.multiple=!0);a(h,_$_ac43[57])&&(e.autocomplete=!0);e.format=!0;e.opened=!0;e.width=b.offsetWidth-2;e.onclose=function(){g.closeEditor(b,!0)};a(h,_$_ac43[584])?d&&(e.value=(_$_ac43[3]+d).split(n)):e.value=d;jSuites.dropdown(l,e)},closeEditor:function(b,d,e,f,g,h){for(var l=g.parent.input.children[0],
|
|
421
|
+
n=h.delimiter||_$_ac43[263],p=l.dropdown.getText(!0),q=l.dropdown.getValue(!0),r=0;r<q.length;r++)!1===c.getItem(b,q[r],e,f,g,h)&&h.source.push({id:q[r],name:p[r]});l.dropdown.close(!0);if(d)return q.join(n)},fromLabel:function(b,d,e,f,g,h){b=h.delimiter||_$_ac43[263];e=[];f=[];Array.isArray(d)||(d=(_$_ac43[3]+d).split(b));for(g=0;g<d.length;g++)f[d[g].trim()]=!0;d=Object.keys(f);!a(h,_$_ac43[584])&&1<Object.keys(d).length&&(f=[],f[d[0]]=!0);for(d=0;d<h.source.length;d++)f[h.source[d].name]&&e.push(h.source[d].id);
|
|
422
|
+
return e.join(b)},getItem:function(b,d,e,f,g,h){f=h.delimiter||_$_ac43[263];b=[];e=[];Array.isArray(d)||(d=(_$_ac43[3]+d).split(f));for(f=0;f<d.length;f++)e[d[f].trim()]=!0;f=Object.keys(e);!a(h,_$_ac43[584])&&1<Object.keys(f).length&&(d=[],d[f[0]]=!0,e=d);if(h.source&&typeof h.source[0]!==_$_ac43[84])for(d=0;d<h.source.length;d++)f=h.source[d],h.source[d]={id:f,name:f};for(d=0;d<h.source.length;d++)typeof e[h.source[d].id]!==_$_ac43[13]&&b.push(h.render==_$_ac43[255]?h.source[d].color:h.render==
|
|
423
|
+
_$_ac43[585]?h.source[d].image:h.source[d].name);if(b.length){if(typeof h.render!==_$_ac43[13]){for(d=0;d<b.length;d++)e=d,f=b[d],f=h.render==_$_ac43[255]?_$_ac43[586]+f+_$_ac43[587]:h.render==_$_ac43[585]?_$_ac43[586]+f+_$_ac43[587]:h.render==_$_ac43[581]?_$_ac43[589]+(h.source[d].color||_$_ac43[588])+_$_ac43[590]+f+_$_ac43[591]:void 0,b[e]=f;return b.join(_$_ac43[3])}for(d=0;d<b.length;d++)b[d]=(_$_ac43[3]+b[d]).replace(_$_ac43[215],_$_ac43[592]);return b.join(_$_ac43[295])}return!1}};c[_$_ac43[51]]=
|
|
424
|
+
function(b,d){for(var e=0;e<b.source.length;e++)if(b.source[e].id==d)return b.render==_$_ac43[255]?b.source[e].color:b.render==_$_ac43[585]?b.source[e].image:b.source[e].name};return c}();k.autocomplete=k.dropdown;k.calendar=function(){var c={},b=null;c.updateCell=function(d,e,f,g,h,l){if(d){f=e;l=c.getFormat(l);0<e&&Number(e)==e&&(f=jSuites.calendar.numToDate(e));g=_$_ac43[3]+e;g.substr(4,1)==_$_ac43[185]&&g.substr(7,1)==_$_ac43[185]?g=!0:(g=g.split(_$_ac43[185]),g=4==g[0].length&&g[0]==Number(g[0])&&
|
|
425
|
+
2==g[1].length&&g[1]==Number(g[1])?!0:!1);g||(g=jSuites.calendar.extractDateFromString(e,l))&&(f=g);if(f=jSuites.calendar.getDateString(f,l))return d.innerText=f,e;d.innerText=_$_ac43[3];return _$_ac43[3]}};c.createCell=c.updateCell;c.openEditor=function(d,e,f,g,h,l){l=Object.create(l);typeof l.filterOptions==_$_ac43[85]&&(l=l.filterOptions(h,d,f,g,e,l));f=l.options||{};f.opened=!0;f.onclose=function(n,p){h.closeEditor(d,!0)};typeof l.timepicker!==_$_ac43[13]&&(f.time=a(l,_$_ac43[593])?!0:!1);typeof f.readonly!==
|
|
426
|
+
_$_ac43[13]&&(f.readonly=f.readonly);f.value=e||null;f.placeholder=f.format;b=k.createEditor(_$_ac43[220],d,e,h);jSuites.calendar(b,f);!1===b.calendar.options.readonly&&b.focus()};c.closeEditor=function(d,e,f,g,h){d=b.calendar.close(!0,b.value?!0:!1);d=b.value?d:_$_ac43[3];if(e)return d};c.getFormat=function(d){return d&&d.format?d.format:d&&d.options&&d.options.format?d.options.format:_$_ac43[594]};c[_$_ac43[51]]=function(d,e){d=c.getFormat(d);return jSuites.calendar.getDateString(e,d)};return c}();
|
|
427
|
+
k.color=function(){var c={},b=null;c.updateCell=function(d,e,f,g,h,l){d&&(l.render==_$_ac43[595]?(f=document.createElement(_$_ac43[20]),f.className=_$_ac43[255],f.style.backgroundColor=e,d.innerText=_$_ac43[3],d.appendChild(f)):(d.style.color=e,d.innerText=e))};c.createCell=c.updateCell;c.openEditor=function(d,e,f,g,h,l){l=Object.create(l);typeof l.filterOptions==_$_ac43[85]&&(l=l.filterOptions(h,d,f,g,e,l));l.value=e;l.onclose=function(n,p){h.closeEditor(d,!0)};b=k.createEditor(_$_ac43[220],d,e,
|
|
428
|
+
h);b=jSuites.color(b,l);b.open()};c.closeEditor=function(d,e,f,g,h,l){d=b.close(!0);if(e)return d};c[_$_ac43[51]]=function(d,e){d=document.createElement(_$_ac43[20]);d.style.width=_$_ac43[596];d.style.height=_$_ac43[22];d.style.backgroundColor=e;return d.outerHTML};return c}();k.checkbox=function(){var c={createCell:function(b,d,e,f,g,h){d=d&&d!=_$_ac43[597]&&d!=_$_ac43[598]?!0:!1;e=document.createElement(_$_ac43[220]);e.type=_$_ac43[250];e.checked=d;e.onclick=function(){g.setValue(b,this.checked)};
|
|
429
|
+
(h&&1==h.readOnly||!g.isEditable())&&e.setAttribute(_$_ac43[599],_$_ac43[599]);b.innerHTML=_$_ac43[3];b.appendChild(e);return d},updateCell:function(b,d){d=d&&d!=_$_ac43[597]&&d!=_$_ac43[598]?!0:!1;b&&(b.children[0].checked=d);return d},openEditor:function(b,d,e,f,g){d=b.children[0].checked?!1:!0;g.setValue(b,d);return!1},closeEditor:function(b,d){return!1}};c[_$_ac43[51]]=function(b,d){return 1==d||1==d||d==_$_ac43[229]?jSuites.translate(_$_ac43[229]):jSuites.translate(_$_ac43[597])};return c}();
|
|
430
|
+
k.radio=function(){var c={createCell:function(b,d,e,f,g,h){b.getAttribute(_$_ac43[42]);e=document.createElement(_$_ac43[220]);e.type=_$_ac43[252];e.checked=1==d||1==d||d==_$_ac43[229]?!0:!1;e.onclick=function(){g.setValue(b,!0)};(h&&1==h.readOnly||!g.isEditable())&&e.setAttribute(_$_ac43[599],_$_ac43[599]);b.innerHTML=_$_ac43[3];b.appendChild(e)},updateCell:function(b,d,e,f,g){d=1==d||1==d||d==_$_ac43[229]||d==_$_ac43[600]?!0:!1;b&&(b.children[0].checked=d);if(1==d){b=[];for(var h=0;h<g.options.data.length;h++)f!=
|
|
431
|
+
h&&g.options.data[h][e]&&b.push({x:e,y:h,value:0});b.length&&g.setValue(b)}return d},openEditor:function(b,d,e,f,g){return!1},closeEditor:function(b,d){return!1}};c[_$_ac43[51]]=function(b,d){return 1==d||1==d||d==_$_ac43[229]?_$_ac43[229]:_$_ac43[597]};return c}();k.autonumber=function(){var c={},b=null;c.createCell=function(d,e,f,g,h,l){(e=parseInt(e))||0<parseInt(d.innerText)&&(e=parseInt(d.innerText));l.sequence||(l.sequence=0);e?c.isValid(e,f,g,h)||(e=_$_ac43[243]):e=l.sequence+1;e>l.sequence&&
|
|
432
|
+
(l.sequence=e);return d.innerText=e};c.updateCell=c.createCell;c.openEditor=function(d,e,f,g,h,l){b=k.createEditor(_$_ac43[220],d,e,h);b.onblur=function(){h.closeEditor(d,!0)};b.focus();b.value=e};c.closeEditor=function(d,e,f,g,h){return e?b.value:_$_ac43[3]};c.isValid=function(d,e,f,g){for(var h,l=0;l<g.options.data.length;l++)if(h=g.value(e,l),h==d&&l!=f)return!1;return!0};return c}();k.progressbar=function(){var c={},b=null;c.createCell=function(d,e){e=parseInt(e);if(100<e)e=100;else if(!e||0>
|
|
433
|
+
e)e=0;if(d.children[0]&&d.children[0].tagName==_$_ac43[553])var f=d.children[0];else f=document.createElement(_$_ac43[20]),f.classList.add(_$_ac43[256]),d.innerText=_$_ac43[3],d.classList.add(_$_ac43[601]),d.appendChild(f);f.style.width=parseInt(e)+_$_ac43[574];f.setAttribute(_$_ac43[264],parseInt(e)+_$_ac43[574])};c.destroyCell=function(d){d.classList.remove(_$_ac43[601])};c.updateCell=c.createCell;c.openEditor=function(d,e,f,g,h,l){b=k.createEditor(_$_ac43[220],d,e,h);b.type=_$_ac43[14];b.setAttribute(_$_ac43[602],
|
|
434
|
+
0);b.setAttribute(_$_ac43[603],100);b.onblur=function(){h.closeEditor(d,!0)};b.focus();b.value=e};c.closeEditor=function(d,e,f,g,h){return e?b.value:_$_ac43[3]};return c}();k.rating=function(){var c={},b=null;c.createCell=function(d,e,f,g,h,l){return c.setCell(d,e,l)};c.destroyCell=function(d){d.classList.remove(_$_ac43[604])};c.updateCell=c.createCell;c.openEditor=function(d,e,f,g,h,l){b=k.createEditor(_$_ac43[220],d,e,h);b.type=_$_ac43[14];b.setAttribute(_$_ac43[602],0);b.setAttribute(_$_ac43[603],
|
|
435
|
+
5);b.onblur=function(){h.closeEditor(d,!0)};b.focus();b.value=e};c.closeEditor=function(d,e,f,g,h,l){return e?b.value:_$_ac43[3]};c.setCell=function(d,e,f){e=parseInt(e);if(5<e)e=5;else if(!e||0>e)e=0;if(d){f=f&&f.color?f.color:_$_ac43[577];var g=document.createElement(_$_ac43[20]);g.setAttribute(_$_ac43[264],parseInt(e)+_$_ac43[605]);g.classList.add(_$_ac43[257]);for(var h=0;h<e;h++){var l=document.createElement(_$_ac43[441]);l.className=_$_ac43[506];l.style.color=f;l.innerHTML=_$_ac43[606];g.appendChild(l)}d.innerHTML=
|
|
436
|
+
_$_ac43[3];d.className=_$_ac43[604];d.appendChild(g)}return e};return c}();k.email=function(){var c={createCell:function(b,d,e,f,g,h){b&&(b.children&&b.children[0]&&b.children[0].tagName==_$_ac43[560]?e=b.children[0]:(e=document.createElement(_$_ac43[201]),b.innerText=_$_ac43[3],b.appendChild(e),h.options&&h.options.url&&e.setAttribute(_$_ac43[607],h.options.url)),e.innerText=d)}};c.updateCell=c.createCell;c.openEditor=function(b,d,e,f,g,h){g.parent.input.classList.add(_$_ac43[556]);g.parent.input.onblur=
|
|
437
|
+
function(){g.closeEditor(b,!0)};g.parent.input.innerText=d;jSuites.focus(g.parent.input)};c.closeEditor=function(b,d,e,f,g){g.parent.input.classList.remove(_$_ac43[556]);return d?g.parent.input.innerText.replace(new RegExp(/\n/,_$_ac43[188]),_$_ac43[3]):_$_ac43[3]};return c}();k.url=k.email;k.image=function(){var c={},b=null;c.createCell=function(d,e,f,g,h,l){d&&(e?d.children&&d.children[0]&&d.children[0].tagName==_$_ac43[608]?d.children[0].src=e:(f=document.createElement(_$_ac43[37]),l.render==_$_ac43[609]&&
|
|
438
|
+
f.classList.add(_$_ac43[609]),l.options&&(f.style.maxWidth=_$_ac43[610],l.options.absolute&&(f.style.position=_$_ac43[611]),l.options.width&&(f.style.maxWidth=parseInt(l.options.width)+_$_ac43[44]),l.options.height&&(f.style.maxHeight=parseInt(l.options.height)+_$_ac43[44],f.style.marginTop=-1*parseInt(l.options.height)/2+_$_ac43[44])),f.src=e,d.innerHTML=_$_ac43[3],d.appendChild(f)):d.innerHTML=_$_ac43[3])};c.updateCell=c.createCell;c.openEditor=function(d,e,f,g,h,l){(l&&l.options?l.options:{}).value=
|
|
439
|
+
e;b=k.createDialog(d,e,f,g,h,l);e&&(d=document.createElement(_$_ac43[37]),d.src=e,d.classList.add(_$_ac43[612]),d.style.width=_$_ac43[610],b.appendChild(d));jSuites.image(b,l)};c.closeEditor=function(d,e,f,g,h,l){if(e&&(d=b.children[0]))return d.tagName==_$_ac43[608]?d.src:_$_ac43[3]};c[_$_ac43[51]]=function(d,e){return _$_ac43[613]+e+_$_ac43[614]};return c}();k.html=function(){var c={},b=null;c.createCell=function(d,e){d.classList.add(_$_ac43[615]);var f=document.createElement(_$_ac43[20]);f.innerHTML=
|
|
440
|
+
e;d.appendChild(f)};c.updateCell=function(d,e){d&&(d.firstChild.innerHTML=e)};c.destroyCell=function(d){d.classList.remove(_$_ac43[615])};c.openEditor=function(d,e,f,g,h,l){var n=l&&l.options?l.options:{};n.focus=!0;n.value=e;n.border=!1;n.height=_$_ac43[580];e=k.createDialog(d,e,f,g,h,l);b=jSuites.editor(e,n);b.close=function(){h.closeEditor(d,!0)};jSuites.tracking(b,!0)};c.closeEditor=function(d,e,f,g,h,l){jSuites.tracking(b,!1);d=b.getData();if(e)return d};return c}();k.hidden=function(){return{createCell:function(c,
|
|
441
|
+
b,d,e,f){c.style.display=_$_ac43[40];c.innerText=b},updateCell:function(c,b,d,e,f){c&&(c.innerText=b)},openEditor:function(c,b,d,e,f){return!1},closeEditor:function(c,b){return!1}}}();k.tags=function(){var c={},b=null;c.createCell=function(d,e){d.classList.add(_$_ac43[616]);c.updateCell(d,e)};c.updateCell=function(d,e){d&&(d.innerHTML=e)};c.destroyCell=function(d){d.classList.remove(_$_ac43[616])};c.openEditor=function(d,e,f,g,h,l){var n=l&&l.options?l.options:{};n.value=e;b=k.createDialog(d,e,f,
|
|
442
|
+
g,h,l);d=document.createElement(_$_ac43[20]);d.style.margin=_$_ac43[22];d.style.marginRight=_$_ac43[617];b.appendChild(d);b=jSuites.tags(d,n);d.focus();jSuites.focus(d)};c.closeEditor=function(d,e,f,g,h,l){d=b.getValue();if(e)return d};return c}();k.record=function(){var c={},b=null;c.createCell=function(d,e,f,g,h,l){d.classList.add(_$_ac43[583]);var n;(n=h.parent.getWorksheetInstance(l.worksheetId))?n.rows?c.updateCell(d,e,f,g,h,l):(d.innerText=_$_ac43[243],h.parent.queue.push([h,f,g])):(d.innerText=
|
|
443
|
+
_$_ac43[243],h.parent.queue.push([h,f,g]))};c.destroyCell=function(d){d.classList.remove(_$_ac43[583])};c.updateCell=function(d,e,f,g,h,l){d&&(typeof l.worksheetId==_$_ac43[13]?d.innerText=_$_ac43[243]:d.innerHTML=c.getValue(d,e,f,g,h,l))};c.openEditor=function(d,e,f,g,h,l){var n=l.delimiter||_$_ac43[263];l=Object.create(l);l.options||(l.options={});typeof l.filter==_$_ac43[85]&&(l.source=l.filter(h.el,d,f,g,l.source));typeof l.filterOptions==_$_ac43[85]&&(l=l.filterOptions(h,d,f,g,e,l));f=l.options;
|
|
444
|
+
f.data=c.getSource(h,l);a(l,_$_ac43[584])&&(f.multiple=!0);a(l,_$_ac43[57])&&(f.autocomplete=!0);f.opened=!0;f.width=d.offsetWidth-2;f.onclose=function(){h.closeEditor(d,!0)};a(l,_$_ac43[584])?e&&(f.value=(_$_ac43[3]+e).split(n)):f.value=e;b=k.createEditor(_$_ac43[20],d,e,h);b=jSuites.dropdown(b,f)};c.closeEditor=function(d,e,f,g,h,l){d=l.delimiter||_$_ac43[263];f=b.getValue(!0);b.close(!0);if(e)return f.join(d)};c.getValue=function(d,e,f,g,h,l){d=[];if(typeof l.worksheetId==_$_ac43[17]&&(h=h.parent.getWorksheetInstance(l.worksheetId))){f=
|
|
445
|
+
l.worksheetColumn?l.worksheetColumn:0;0<=l.worksheetImage&&(f=l.worksheetImage);if(e==_$_ac43[3]||0==e||null==e||void 0==e)return _$_ac43[3];e=(_$_ac43[3]+e).split(_$_ac43[263]);for(g=0;g<e.length;g++){var n=e[g].trim();var p=h.name(f);n=h.getRowById(n);p=!1===n?_$_ac43[618]:n[p];0<=l.worksheetImage&&(p=_$_ac43[619]+p+_$_ac43[620]);d.push(p)}return 0<=l.worksheetImage?d.join(_$_ac43[3]):d.join(_$_ac43[295])}return _$_ac43[243]};c.getSource=function(d,e){var f=e.worksheetColumn?e.worksheetColumn:0,
|
|
446
|
+
g=null;typeof e.worksheetId==_$_ac43[17]&&(g=d.parent.getWorksheetInstance(e.worksheetId));if(g){var h,l=[];for(d=0;d<g.rows.length;d++)if(h=g.value(f,d))h={id:g.getRowId(d),name:h},void 0!=e.worksheetImage&&(h.image=g.value(e.worksheetImage,d)),l.push(h)}else console.error(_$_ac43[621]+e.worksheetId);return l};c[_$_ac43[51]]=function(d,e){for(var f=0;f<d.source.length;f++)if(d.source[f].id==e)return d.render==_$_ac43[255]?d.source[f].color:d.render==_$_ac43[585]?d.source[f].image:d.source[f].name};
|
|
447
|
+
return c}();return k}();typeof jQuery!==_$_ac43[13]&&function(k){k.fn.jspreadsheet=k.fn.jexcel=function(a){var c=k(this)[_$_ac43[51]](0);if(c.jspreadsheet){if(typeof arguments[0]==_$_ac43[14])var b=arguments[0],d=2;else b=0,d=1;return c.jspreadsheet[b][a].apply(c.jspreadsheet[b],Array.prototype.slice.call(arguments,d))}return t(k(this)[_$_ac43[51]](0),arguments[0])}}(jQuery);return t});
|