rapid-spreadjs 1.0.26 → 1.0.27

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.
@@ -1,2 +1,2 @@
1
- "use strict";var rapidUtils=require("rapid-utils"),echarts=require("echarts"),math=require("mathjs"),fileSaver=require("file-saver");function _interopNamespaceDefault(e){var t=Object.create(null);return e&&Object.keys(e).forEach(function(l){if("default"!==l){var o=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(t,l,o.get?o:{enumerable:!0,get:function(){return e[l]}})}}),t.default=e,Object.freeze(t)}var echarts__namespace=_interopNamespaceDefault(echarts),math__namespace=_interopNamespaceDefault(math);const SheetUtils={getActiveSheetSelectCells:e=>e.getActiveSheet().getSelections(),setActiveSheetSelectCells:(e,t)=>{e.getActiveSheet().setSelection(t.row,t.col,t.rowCount,t.colCount)},getAllCellObjsByRange:(e,t,l=!1)=>SheetUtils.getAllCellObjsByRanges(e,[t],l),getAllCellObjsByRanges:(e,t,l=!1)=>{let o=[];return t.forEach((t,l)=>{if(e.getSpans(t).forEach(e=>{o.push({row:e.row,col:e.col,rowCount:e.rowCount,colCount:e.colCount})}),void 0===t.row||void 0===t.col||void 0===t.rowCount||void 0===t.colCount)throw new Error("row、col、rowCount、colCount is required.");for(let l=t.row;l<+t.row+t.rowCount;l++)for(let n=t.col;n<t.col+t.colCount;n++){null==e.getSpan(l,n)&&o.push({row:l,col:n,rowCount:1,colCount:1})}}),o=rapidUtils.orderByJson(o,l?["col","row"]:["row","col"],["asc","asc"]),o},getSheetAllCellObjs:e=>{const t=[{row:0,col:0,rowCount:e.getRowCount(),colCount:e.getColumnCount()}];return SheetUtils.getAllCellObjsByRanges(e,t)},getSheetSelectCellObjs:(e,t=!1)=>{const l=e.getSelections();return SheetUtils.getAllCellObjsByRanges(e,l,t)},getActiveSheetSelectCellObjs:(e,t=!1)=>{const l=e.getActiveSheet();return SheetUtils.getSheetSelectCellObjs(l,t)},getSheetCellObjsByGroup:(e,t,l="row")=>{e.suspendPaint();const o=SheetUtils.getAllCellObjsByRange(e,t),n=rapidUtils.groupByJson(o,l),a=[];return rapidUtils.forEachJson(n,(e,t,l)=>{a.push(e)}),e.resumePaint(),a},getSheetSelectVals:(e,t=!1,l)=>{const o=SheetUtils.getSheetSelectCellObjs(e,t);let n=[];return o.forEach(t=>{let o=e.getValue(t.row,t.col);null!=l&&null!=l&&null==o&&(o=l),n.push(o)}),n},getActiveSheetSelectVals:(e,t=!1,l)=>{const o=e.getActiveSheet();return SheetUtils.getSheetSelectVals(o,t,l)},getSheetRangeValsByGroup:(e,t,l="row",o)=>{e.suspendPaint();const n=SheetUtils.getAllCellObjsByRange(e,t),a=rapidUtils.groupByJson(n,l),s=[];return rapidUtils.forEachJson(a,(t,l,n)=>{const a=[];rapidUtils.forEachJson(t,(t,l,n)=>{let s=e.getValue(t.row,t.col);null!=o&&null!=o&&null==s&&(s=o),a.push(s)}),s.push(a)}),e.resumePaint(),s},getCellType:(e,t,l,o)=>{let n;const a=t.getCellType(l,o);if(a instanceof e.Spread.Sheets.CellTypes.Button?n="button":a instanceof e.Spread.Sheets.CellTypes.RadioButtonList?n="radio":a instanceof e.Spread.Sheets.CellTypes.CheckBox?n="checkbox":a instanceof e.Spread.Sheets.CellTypes.CheckBoxList?n="checkboxList":a instanceof e.Spread.Sheets.CellTypes.HyperLink?n="hyperLink":a instanceof e.Spread.Sheets.CellTypes.ComboBox&&(n="comboBox"),null==n||null==n){const e=t.getStyle(l,o);e&&e.cellButtons&&e.cellButtons.length>0&&("openDateTimePicker"==e.cellButtons[0].command?e.dropDowns&&e.dropDowns.length>0&&(n=e.dropDowns[0].option.showDateRange?"dateRange":"date"):"openCalculator"==e.cellButtons[0].command&&(n="calc"))}return n},setSheetZoom:(e,t)=>{e.suspendPaint();const l=e.getSheetCount();for(let o=0;o<l;o++){e.getSheet(o).zoom(t)}e.resumePaint()},setActiveSheetSelectBgColor:(e,t)=>{const l=e.getActiveSheet();l.suspendPaint();SheetUtils.getActiveSheetSelectCells(e).forEach(e=>{l.getRange(e.row,e.col,e.rowCount,e.colCount).backColor(t)}),l.resumePaint()},setSheetBgColor:(e,t,l)=>{e.suspendPaint(),t.forEach(t=>{e.getRange(t.row,t.col,t.rowCount,t.colCount).backColor(l)}),e.resumePaint()},setSheetShowPrintPageLine:(e,t)=>{e.suspendPaint();const l=e.getSheetCount();for(let o=0;o<l;o++){e.getSheet(o).isPrintLineVisible(t)}e.resumePaint()},ignoreSheetShowStrs:e=>{const t=["#DIV/0!","#VALUE!","#NAME?","#N/A","#NULL!","#NUM!","#REF!"],l=e.Spread.Sheets.CellTypes.Text.prototype.paint;e.Spread.Sheets.CellTypes.Text.prototype.paint=function(e,o,n,a,s,r,i,h){t.some(e=>e==o)?l.call(this,e,"/",n,a,s,r,i,h):l.apply(this,arguments)}},setSheetAuxiliaryLine:(e,t,l,o,n=1,a="#409eff",s=!1)=>{let r=new e.Spread.Sheets.FloatingObjects.FloatingObject("floatLineBottom"+(s?"Hb":""),0,o,l,n),i=new e.Spread.Sheets.FloatingObjects.FloatingObject("floatLineRight"+(s?"Hb":""),l,0,n,o),h=document.createElement("div"),c=document.createElement("div");h.style.width=`${l}px`,h.style.height="1px",h.style.borderBottom=`${n}px dashed ${a}`,c.style.width="1px",c.style.height=`${o}px`,c.style.borderLeft=`${n}px dashed ${a}`,r.allowResize(!1),r.allowMove(!1),r.content(h),i.allowResize(!1),i.allowMove(!1),i.content(c),t.floatingObjects.add(r),t.floatingObjects.add(i)},setActiveSheetWatermark:(e,t,l)=>{if(null==t||null==t)return;const o=e.getActiveSheet();o.suspendPaint(),t.forEach(e=>{o.getCell(e.row,e.col).watermark(l?`{${e.title}}`:void 0),o.setBindingPath(e.row,e.col,l?`${e.pathPrev}.${e.pathField}`:void 0)}),o.resumePaint()},setSheetCellDate:(e,t,l,o=!0)=>{l.forEach((l,n)=>{let a=t.getStyle(l.row,l.col);a||(a=new e.Spread.Sheets.Style),a.cellButtons=[{imageType:e.Spread.Sheets.ButtonImageType.dropdown,command:"openDateTimePicker"}],a.dropDowns=[{type:e.Spread.Sheets.DropDownType.dateTimePicker,option:{showTime:!1,showDateRange:!1}}],a.formatter=l.dateFormat,a.shrinkToFit=o,t.setStyle(l.row,l.col,a)})}},BusinessUtils={createTestObjectAttrsCells:(e,t,l,o=!0,n=1,a=77,s=24)=>{if(!l||0===l.length)return;const r=o?12:10,i=o?26:15,h=o?2:3,c=rapidUtils.chunkJson(l,h);t.suspendPaint(),t.setRowCount(0);for(let l=0;l<c.length;l++){const h=c[l],u=t.getRowCount();t.addRows(u,1),t.setRowHeight(u,s,e.Spread.Sheets.SheetArea.viewport);const m=t.getRange(u,1,n,a,e.Spread.Sheets.SheetArea.viewport);if(m.setBorder(new e.Spread.Sheets.LineBorder("#000",e.Spread.Sheets.LineStyle.thin),{all:!0}),m.setBorder(new e.Spread.Sheets.LineBorder("#000",e.Spread.Sheets.LineStyle.medium),{left:!0}),m.setBorder(new e.Spread.Sheets.LineBorder("#000",e.Spread.Sheets.LineStyle.medium),{right:!0}),m.hAlign(e.Spread.Sheets.HorizontalAlign.center),m.vAlign(e.Spread.Sheets.HorizontalAlign.center),t.addSpan(u,n,1,r,e.Spread.Sheets.SheetArea.viewport),t.addSpan(u,n+r,1,h.length>1?i:a-r,e.Spread.Sheets.SheetArea.viewport),t.setValue(u,n,h[0].title),t.setValue(u,n+r,h[0].value),h.length>1){const l=n+r+i,a=l+r;t.addSpan(u,l,1,r,e.Spread.Sheets.SheetArea.viewport),t.addSpan(u,a,1,i+1+(o||2!=h.length?0:r+i+1),e.Spread.Sheets.SheetArea.viewport),t.setValue(u,l,h[1].title),t.setValue(u,a,h[1].value)}if(h.length>2){const l=n+r+i+r+i+1,o=l+r;t.addSpan(u,l,1,r,e.Spread.Sheets.SheetArea.viewport),t.addSpan(u,o,1,i+1,e.Spread.Sheets.SheetArea.viewport),t.setValue(u,l,h[2].title),t.setValue(u,o,h[2].value)}}t.resumePaint()},getTestObjectAttrsVals:(e,t,l=!0,o=1,n=77)=>{const a=l?2:3,s=rapidUtils.chunkJson(t,a);e.suspendPaint();const r=SheetUtils.getAllCellObjsByRange(e,{row:0,col:o,rowCount:e.getRowCount(),colCount:n}),i=rapidUtils.chunkJson(r,2*a),h=[];for(let e=0;e<i.length;e++)h.push(rapidUtils.chunkJson(i[e],2));let c=[];for(let t=0;t<s.length;t++){const l=s[t];for(let o=0;o<l.length;o++){const n=l[o];c.push({title:e.getValue(h[t][o][0].row,h[t][o][0].col),fieldName:n.fieldName,value:e.getValue(h[t][o][1].row,h[t][o][1].col)})}}return e.resumePaint(),c}};function __awaiter(e,t,l,o){return new(l||(l=Promise))(function(n,a){function s(e){try{i(o.next(e))}catch(e){a(e)}}function r(e){try{i(o.throw(e))}catch(e){a(e)}}function i(e){var t;e.done?n(e.value):(t=e.value,t instanceof l?t:new l(function(e){e(t)})).then(s,r)}i((o=o.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const CommonUtils={getFileBlob:e=>__awaiter(void 0,void 0,void 0,function*(){const t=yield fetch(e,{method:"GET"});if(t.ok){return yield t.blob()}return null}),getColLetterName:e=>{e+=1;let t="";for(;e>0;){const l=(e-1)%26;t=String.fromCharCode(l+65)+t,e=Math.floor((e-1)/26)}return t.toUpperCase()}},EChartsUtilsComm={getRound:(e,t)=>{const l=e<0;if(l&&(e=Math.abs(e)),0==t){let t=e.toString();if(-1==t.indexOf("."))return l?-e:e;let o=parseInt(t.split(".")[0]),n=t.split(".")[1];return parseFloat(`0.${n}`)>=.5?l?-(o+1):o+1:l?-o:o}let o=1/t;const n=(e=>{let t=e.toString();if(-1==t.indexOf("."))return e;let l=parseInt(t.split(".")[0]),o=t.split(".")[1],n=parseInt(o.substring(0,1));return n>=6?l+1:n<=4?l:5==n&&1==o.length?l%2!=0?l+1:l:5==n&&o.length>1?l+1:e})(Number((e*o).toFixed(8)))/o;let a=t+"";if(-1==a.indexOf("."))return l?-n:n;{const e=n+"";let t="";if(-1==e.indexOf(".")){let e="";for(let t=0;t<a.split(".")[1].length;t++)e+="0";return(l?"-":"")+`${n}.${e}`}{const o=e.split(".")[1];if(a.split(".")[1].length>o.length)for(let e=0;e<a.split(".")[1].length-o.length;e++)t+="0";return(l?"-":"")+`${n}${t}`}}},calcTrend:(e,t,l)=>{let o=e.length,n=0,a=0,s=0,r=0;for(let l=0;l<o;l++)n+=e[l],a+=t[l],s+=e[l]*t[l],r+=e[l]*e[l];let i=(o*s-n*a)/(o*r-n*n),h=(a-i*n)/o;return i+""=="NaN"?{y:"",gs:"",xl:"",jj:""}:{y:i*l+h,gs:`${i}*x+${h}`,xl:i,jj:h}},filterNullEmptyErrArray:e=>e.filter(e=>null!=e&&null!=e&&(null==e._error||null==e._error)&&"/"!=e)},EChartsUtilsAll={chart10:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,x=Number(EChartsUtilsComm.getRound(p+.05,.01)),g=Number(EChartsUtilsComm.getRound(d-.05,.01)),S=[],b=[];h.forEach((e,t)=>{b.push([e,c[t]])});const w=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),C=math__namespace.transpose(w),E=math__namespace.multiply(C,w),A=math__namespace.multiply(C,math__namespace.matrix(c));let N=null,v=[];try{N=math__namespace.lusolve(E,A),v=N.valueOf()}catch(e){for(let e=0;e<h.length;e++)v.push([0])}function L(e){let t=0;return v.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let J=[],j=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));j.push(L(t)),J.push(t)}let M=Math.max(...j),z=j.findIndex(e=>e===M),_=e.chartXName,q=e.chartYName;J.forEach((e,t)=>{h.includes(e)?S.push({value:[e,j[t]]}):S.push({value:[e,j[t]],symbol:"none"})});const O=[J[z],Number(EChartsUtilsComm.getRound(M,.001))],U=[O[0],g];null!=a&&(null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,u),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,m)),null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,J[z]));let T=[],R=[];T=[[{coord:U,lineStyle:{color:"#333",type:"dashed"}},{coord:O}]],R=[{xAxis:O[0],yAxis:O[1],symbolOffset:[0,15],label:{show:!0,color:"#000",formatter:function(e){return 0==Number(e.data.xAxis)&&0==Number(e.data.yAxis)?"":"( "+e.data.xAxis+","+e.data.yAxis+")"}},itemStyle:{color:"transparent"}},{xAxis:O[0],yAxis:g,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a1"}},itemStyle:{color:"transparent"}}];let V=!1;return S.forEach(e=>{V=e.value.every(e=>0==e)}),V&&(y=null,f=null,g=null,x=null,S=[]),{grid:{top:10,left:V?25:30,right:10,bottom:V?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:_,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:x,min:g,name:q,nameGap:V?5:40,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:R},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:T}}]}},chart11:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,x=Math.ceil(p+2),g=Math.floor(d-2),S=[],b=null,w=7.5;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}}null!=b&&b>x&&(x=b+2),null!=w&&w>x&&(g=w-2);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],z=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));z.push(j(t)),M.push(t)}let _=Math.max(...z),q=z.findIndex(e=>e===_),O=e.chartXName,U=e.chartYName;function T(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function R(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}M.forEach((e,t)=>{h.includes(e)?S.push({value:[e,z[t]]}):S.push({value:[e,z[t]],symbol:"none"})});let V=[],W=[],D=[],k=[];M.forEach((e,t)=>{if(t>0){if(null!=b&&T(z[t-1],z[t],b,b)){let e=R(z[t-1],z[t],b);V.push([M[t+e],z[t+e]]),z[t-1]>z[t]?D.push(0):D.push(1)}if(null!=w&&T(z[t-1],z[t],w,w)){let e=R(z[t-1],z[t],w);W.push([M[t+e],z[t+e]]),z[t-1]>z[t]?k.push(0):k.push(1)}}});let P=u,B=m;0==V.length&&W.length>0?0==k[0]?(P=u,B=W[0][0]):(P=W[0][0],B=1==W.length?m:W[1][0]):V.length>0&&0==W.length?0==D[0]?(P=V[0][0],B=1==V.length?m:V[1][0]):(P=u,B=V[0][0]):V.length>0&&W.length>0&&(0==D[0]?(P=V[0][0],B=W[0][0]):(P=W[0][0],B=V[0][0])),null!=a&&(null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,P),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,B)),null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,M[q]));const H=[M[q],Number(EChartsUtilsComm.getRound(_,.001))];let $=[],X=[];$=[[{coord:[H[0],g],lineStyle:{color:"#333",type:"dashed"}},{coord:H}]],X=[{xAxis:H[0],yAxis:H[1],symbolOffset:[0,15],label:{show:!0,color:"#000",formatter:function(e){return 0==Number(e.data.xAxis)&&0==Number(e.data.yAxis)?"":"( "+e.data.xAxis+","+e.data.yAxis+")"}},itemStyle:{color:"transparent"}},{xAxis:H[0],yAxis:g,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a2"}},itemStyle:{color:"transparent"}}],null!=b&&$.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]),null!=w&&$.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]);let Y=!1;return S.forEach(e=>{Y=e.value.every(e=>0==e)}),Y&&(y=null,f=null,g=null,x=null,S=[]),{grid:{top:10,left:Y?25:30,right:10,bottom:Y?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:O,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:x,min:g,name:U,nameGap:Y?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:X},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:$}}]}},chart12:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,x=Math.ceil(p+2),g=Math.floor(d-2),S=[],b=5,w=3;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}}null!=b&&b>x&&(x=b+2),null!=w&&w>x&&(g=w-2);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],z=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));z.push(j(t)),M.push(t)}let _=e.chartXName,q=e.chartYName;function O(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}let T=[],R=[],V=[],W=[];M.forEach((e,t)=>{if(h.includes(e)?S.push({value:[e,z[t]]}):S.push({value:[e,z[t]],symbol:"none"}),t>0){if(null!=b&&O(z[t-1],z[t],b,b)){let e=U(z[t-1],z[t],b);T.push([M[t+e],z[t+e]]),z[t-1]>z[t]?V.push(0):V.push(1)}if(null!=w&&O(z[t-1],z[t],w,w)){let e=U(z[t-1],z[t],w);R.push([M[t+e],z[t+e]]),z[t-1]>z[t]?W.push(0):W.push(1)}}});let D=u,k=m;0==T.length&&R.length>0?0==W[0]?(D=u,k=R[0][0]):(D=R[0][0],k=1==R.length?m:R[1][0]):T.length>0&&0==R.length?0==V[0]?(D=T[0][0],k=1==T.length?m:T[1][0]):(D=u,k=T[0][0]):T.length>0&&R.length>0&&(0==V[0]?(D=T[0][0],k=R[0][0]):(D=R[0][0],k=T[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,D),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,k));let P=[],B=[];if(T.length>0&&T.forEach((e,t)=>{P.push([{coord:[e[0],g],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],b]}])}),R.length>0&&R.forEach((e,t)=>{P.push([{coord:[e[0],g],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],w]}])}),1==T.length&&1==R.length){const e=((T[0][0]+R[0][0])/2).toFixed(2),t=M.findIndex(t=>t==e);null!=a&&null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,e),P.push([{coord:[e,g],lineStyle:{color:"#333",type:"dashed"}},{coord:[e,z[t]]}]),B.push({xAxis:e,yAxis:g,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a3"}},itemStyle:{color:"transparent"}})}null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]),null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]);let H=!1;return S.forEach(e=>{H=e.value.every(e=>0==e)}),H&&(y=null,f=null,g=null,x=null,S=[]),{grid:{top:10,left:H?25:30,right:10,bottom:H?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:_,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:x,min:g,name:q,nameGap:H?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:B},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart13:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,x=Math.ceil(p+1),g=Math.floor(d-1),S=[],b=null,w=2;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}}null!=b&&b>x&&(x=b+1),null!=w&&w>x&&(g=w-1);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],z=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));z.push(j(t)),M.push(t)}let _=e.chartXName,q=e.chartYName;function O(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}M.forEach((e,t)=>{h.includes(e)?S.push({value:[e,z[t]]}):S.push({value:[e,z[t]],symbol:"none"})});let T=[],R=[],V=[],W=[];M.forEach((e,t)=>{if(t>0){if(null!=b&&O(z[t-1],z[t],b,b)){let e=U(z[t-1],z[t],b);T.push([M[t+e],z[t+e]]),z[t-1]>z[t]?V.push(0):V.push(1)}if(null!=w&&O(z[t-1],z[t],w,w)){let e=U(z[t-1],z[t],w);R.push([M[t+e],z[t+e]]),z[t-1]>z[t]?W.push(0):W.push(1)}}});let D=u,k=m;0==T.length&&R.length>0?0==W[0]?(D=u,k=R[0][0]):(D=R[0][0],k=1==R.length?m:R[1][0]):T.length>0&&0==R.length?0==V[0]?(D=T[0][0],k=1==T.length?m:T[1][0]):(D=u,k=T[0][0]):T.length>0&&R.length>0&&(0==V[0]?(D=T[0][0],k=R[0][0]):(D=R[0][0],k=T[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,D),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,k));let P=[],B=[];P=[],B=[],null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]),null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]);let H=!1;return S.forEach(e=>{H=e.value.every(e=>0==e)}),H&&(y=null,f=null,g=null,x=null,S=[]),{grid:{top:10,left:H?25:30,right:10,bottom:H?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:_,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:x,min:g,name:q,nameGap:H?5:25,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:B},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart14:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,x=Math.ceil(p+1),g=Math.floor(d-1),S=[],b=null,w=13.5;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}}null!=b&&b>x&&(x=b+1),null!=w&&w>x&&(g=w-1);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],z=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));z.push(j(t)),M.push(t)}let _=e.chartXName,q=e.chartYName;function O(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}M.forEach((e,t)=>{h.includes(e)?S.push({value:[e,z[t]]}):S.push({value:[e,z[t]],symbol:"none"})});let T=[],R=[],V=[],W=[];M.forEach((e,t)=>{if(t>0){if(null!=b&&O(z[t-1],z[t],b,b)){let e=U(z[t-1],z[t],b);T.push([M[t+e],z[t+e]]),z[t-1]>z[t]?V.push(0):V.push(1)}if(null!=w&&O(z[t-1],z[t],w,w)){let e=U(z[t-1],z[t],w);R.push([M[t+e],z[t+e]]),z[t-1]>z[t]?W.push(0):W.push(1)}}});let D=u,k=m;0==T.length&&R.length>0?0==W[0]?(D=u,k=R[0][0]):(D=R[0][0],k=1==R.length?m:R[1][0]):T.length>0&&0==R.length?0==V[0]?(D=T[0][0],k=1==T.length?m:T[1][0]):(D=u,k=T[0][0]):T.length>0&&R.length>0&&(0==V[0]?(D=T[0][0],k=R[0][0]):(D=R[0][0],k=T[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,D),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,k));let P=[],B=[];P=[],B=[],null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]),null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]);let H=!1;return S.forEach(e=>{H=e.value.every(e=>0==e)}),H&&(y=null,f=null,g=null,x=null,S=[]),{grid:{top:10,left:H?25:30,right:10,bottom:H?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:_,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:x,min:g,name:q,nameGap:H?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:B},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart15:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,x=Math.ceil(p+10),g=Math.floor(d-10),S=[],b=75,w=60;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}}null!=b&&b>x&&(x=b+10),null!=w&&w>x&&(g=w-10);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],z=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));z.push(j(t)),M.push(t)}let _=e.chartXName,q=e.chartYName;function O(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}let T=[],R=[],V=[],W=[];M.forEach((e,t)=>{if(h.includes(e)?S.push({value:[e,z[t]]}):S.push({value:[e,z[t]],symbol:"none"}),t>0){if(null!=b&&O(z[t-1],z[t],b,b)){let e=U(z[t-1],z[t],b);T.push([M[t+e],z[t+e]]),z[t-1]>z[t]?V.push(0):V.push(1)}if(null!=b&&O(z[t-1],z[t],w,w)){let e=U(z[t-1],z[t],w);R.push([M[t+e],z[t+e]]),z[t-1]>z[t]?W.push(0):W.push(1)}}});let D=u,k=m;0==T.length&&R.length>0?0==W[0]?(D=u,k=R[0][0]):(D=R[0][0],k=1==R.length?m:R[1][0]):T.length>0&&0==R.length?0==V[0]?(D=T[0][0],k=1==T.length?m:T[1][0]):(D=u,k=T[0][0]):T.length>0&&R.length>0&&(0==V[0]?(D=T[0][0],k=R[0][0]):(D=R[0][0],k=T[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,D),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,k));let P=[],B=[];if(T.length>0&&T.forEach((e,t)=>{P.push([{coord:[e[0],g],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],b]}])}),R.length>0&&R.forEach((e,t)=>{P.push([{coord:[e[0],g],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],w]}])}),1==T.length&&1==R.length){const e=((T[0][0]+R[0][0])/2).toFixed(2),t=M.findIndex(t=>t==e);null!=a&&null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,e),P.push([{coord:[e,g],lineStyle:{color:"#333",type:"dashed"}},{coord:[e,z[t]]}]),B.push({xAxis:e,yAxis:g,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a4"}},itemStyle:{color:"transparent"}})}null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]),null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]);let H=!1;return S.forEach(e=>{H=e.value.every(e=>0==e)}),H&&(y=null,f=null,g=null,x=null,S=[]),{grid:{top:10,left:H?25:30,right:10,bottom:H?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:_,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:x,min:g,name:q,nameGap:H?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:B},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart16:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=[[o.getValue(a.lqhhlHz[0].row,a.lqhhlHz[0].col),o.getValue(a.lqhhlHz[1].row,a.lqhhlHz[1].col)],[o.getValue(a.lqhhlHz[2].row,a.lqhhlHz[2].col),o.getValue(a.lqhhlHz[3].row,a.lqhhlHz[3].col)],[o.getValue(a.lqhhlHz[4].row,a.lqhhlHz[4].col),o.getValue(a.lqhhlHz[5].row,a.lqhhlHz[5].col)],[o.getValue(a.lqhhlHz[6].row,a.lqhhlHz[6].col),o.getValue(a.lqhhlHz[7].row,a.lqhhlHz[7].col)],[o.getValue(a.lqhhlHz[8].row,a.lqhhlHz[8].col),o.getValue(a.lqhhlHz[9].row,a.lqhhlHz[9].col)],[o.getValue(a.lqhhlHz[10].row,a.lqhhlHz[10].col),o.getValue(a.lqhhlHz[11].row,a.lqhhlHz[11].col)]],r=t[0],i=5.5,h=3.5,c=0,u=6,m=["VFA","VMA","流值","稳定度","空隙率","密度"];let d=[],p=[],f=Math.max(...s.map(e=>e[0])),y=Math.min(...s.map(e=>e[1]));if(s.forEach((e,t)=>{d.push([{coord:[e[0],s.length-t],lineStyle:{color:n[0].lineColor,type:"solid",width:2}},{coord:[e[1],s.length-t]}])}),f<=y&&(d.push([{coord:[f,0],lineStyle:{color:"#333",type:"dashed",width:2}},{coord:[f,6]}]),d.push([{coord:[y,0],lineStyle:{color:"#333",type:"dashed",width:2}},{coord:[y,6]}]),p=[{xAxis:f,yAxis:0,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"OACmin"}},itemStyle:{color:"transparent"}},{xAxis:y,yAxis:0,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"OACmax"}},itemStyle:{color:"transparent"}}]),f<=y){const e=(f+y)/2;d.push([{coord:[e,0],lineStyle:{color:"#333",type:"dashed",width:2}},{coord:[e,6]}]),p.push({xAxis:e,yAxis:0,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"OAC2"}},itemStyle:{color:"transparent"}})}isNaN(f)&&(f=0),isNaN(y)&&(y=0),null!=a&&(null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,f),null!=a.lqhhlSc2&&null!=a.lqhhlSc2&&o.setValue(a.lqhhlSc2.row,a.lqhhlSc2.col,y));let x=!1;return s.forEach(e=>{x=e.every(e=>"/"==e)}),x&&(h=null,i=null,c=null,u=null),{grid:{top:25,left:10,right:10,bottom:x?20:16,containLabel:!0},title:[{show:!0,text:"OAC",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:"油石比(%)",left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:i,min:h,data:r,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:u,min:c,axisLabel:{formatter:function(e){return 0==e?"":m[e-1]}}}],series:[{name:"图例1",type:"line",markPoint:{data:p},markLine:{symbol:["none","none"],data:d}}]}},chart30:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);null==a||null!=a.jsIsJz&&null!=a.jsIsJz||(a.jsIsJz=!0);let s=2==t.length,r=t[0],i=s?t[1]:[],h=l[0],c=s?l[1]:[],u=e.chartTitle,m=e.chartXName,d=e.chartYName;const p=(e,t,l,s,r)=>{let i=null!=a?a.dxsJs:5,h=[],c=[],u=[];if(e.forEach((e,l)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&0!=e&&/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(t[l])&&0!=t[l]&&(h.push(e),c.push(t[l]))}),0==c.length)return;i>=c.length&&(i=c.length-1);let m,d,p=Math.min(...h),f=Math.max(...h),y=Math.min(...c),x=Math.max(...c),g=Math.ceil(f+.1),S=Math.trunc(p-.1),b=Number(EChartsUtilsComm.getRound(x+.02,.01)),w=Number(EChartsUtilsComm.getRound(y-.02,.01));null!=a&&a.jsIsJz&&(null!=a.jsZjhslJz&&null!=a.jsZjhslJz&&(m=o.getValue(a.jsZjhslJz.row,a.jsZjhslJz.col)),null!=a.jsZdgmdJz&&null!=a.jsZdgmdJz&&(d=o.getValue(a.jsZdgmdJz.row,a.jsZdgmdJz.col)),/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(d)&&d>b&&(b=Number(EChartsUtilsComm.getRound(d+.02,.01))));let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],z=[];for(let e=p;e<=f;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));e=Number(t),z.push(j(t)),M.push(t)}let _=Math.max(...z),q=z.findIndex(e=>e===_),O=.01,U=.001,T=0,R=0;null!=a&&(null!=a.jsZjhslJd&&null!=a.jsZjhslJd&&(O=a.jsZjhslJd),null!=a.jsZdgmdJd&&null!=a.jsZdgmdJd&&(U=a.jsZdgmdJd),0==M[q]&&0==_?(o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,"/"),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,"/")):(T=EChartsUtilsComm.getRound(M[q],O),R=EChartsUtilsComm.getRound(_,U),o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,T),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,R))),M.forEach((e,t)=>{h.includes(e)?u.push({value:[e,z[t]]}):u.push({value:[e,z[t]],symbol:"none"})});const V=[M[q],Number(EChartsUtilsComm.getRound(_,U))],W=[V[0],w],D=[S,V[1]];let k={data:[{xAxis:EChartsUtilsComm.getRound(V[0],O),yAxis:EChartsUtilsComm.getRound(V[1],U),symbolOffset:[0,15],symbol:"circle",symbolSize:6,label:{show:!0,color:"#000",formatter:function(e){return 0==Number(e.data.xAxis)&&0==Number(e.data.yAxis)?"":"( "+e.data.xAxis+","+e.data.yAxis+")"}},itemStyle:{color:"transparent"}}]},P={symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:[[{coord:W,lineStyle:{color:"#333",type:"dashed"}},{coord:V}],[{coord:D,lineStyle:{color:"#333",type:"dashed"}},{coord:V}]]};a.jsIsJz&&/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(m)&&/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(d)&&(P=null,k.data[0].label=null,k.data[0].symbolOffset=null,k.data[0].itemStyle.color="#F56C6C",k.data[0].xAxis=m,k.data[0].yAxis=d,P=null);let B={name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[r?1:0].lineColor,type:r?"dotted":"solid"},itemStyle:{color:n[r?1:0].lineColor},data:u,markPoint:l?k:null,markLine:s?P:null};return{xAxisMin:S,xAxisMax:g,yAxisMin:w,yAxisMax:b,xData:h,seriesDataObj:B,maxPointData:[M[q],_]}};let f,y=0,x=0,g=0,S=0,b=[],w=[],C=0,E=0,A=p(r,h,!s,!s,!1);if(s&&(f=p(i,c,!1,!1,!0)),null==A||null==A)return;if(s){if(null==f||null==f)return;x=A.xAxisMax,f.xAxisMax>x&&(x=f.xAxisMax),y=A.xAxisMin,f.xAxisMin<y&&(y=f.xAxisMin),S=A.yAxisMax,f.yAxisMax>S&&(S=f.yAxisMax),g=A.yAxisMin,f.yAxisMin<g&&(g=f.yAxisMin),A.xData.forEach(e=>{b.push(e)}),f.xData.forEach(e=>{b.push(e)}),w.push(A.seriesDataObj),w.push(f.seriesDataObj),C=(A.maxPointData[0]+f.maxPointData[0])/2,E=(A.maxPointData[1]+f.maxPointData[1])/2;let e=.01,t=.001,l=0,n=0;null!=a&&(null!=a.jsZjhslJd&&null!=a.jsZjhslJd&&(e=a.jsZjhslJd),null!=a.jsZdgmdJd&&null!=a.jsZdgmdJd&&(t=a.jsZdgmdJd),0==C&&0==E?(o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,"/"),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,"/")):(l=EChartsUtilsComm.getRound(C,e),n=EChartsUtilsComm.getRound(E,t),o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,l),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,n)))}else y=A.xAxisMin,x=A.xAxisMax,g=A.yAxisMin,S=A.yAxisMax,b=A.xData,w.push(A.seriesDataObj);let N=!1;return w.forEach(e=>{N=e.data[0].value.every(e=>0==e)}),N&&(y=null,x=null,g=null,S=null,w=[]),{grid:{top:25,left:N?25:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:u,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:m,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:x,min:y,data:b,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:S,min:g,name:d,nameGap:N?5:40,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:w}},chart50:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartXName,a=e.chartYName;const s=t[0],r=l[0],i=l[1],h=l[2],c=[];s.forEach((e,t)=>{c.push({x:e,y:r[t],ySx:i[t],yXx:h[t]})}),c.sort(function(e,t){return e.x-t.x});const u=[],m=[],d=[],p=[];let f=0;i.forEach((e,t)=>{null!=e&&"/"!=e||f++}),f==i.length?c.forEach((e,t)=>{u.push(e.x),m.push(e.y),d.push(e.ySx),p.push(e.yXx)}):c.forEach((e,t)=>{null!=e.ySx&&"/"!=e.ySx&&null!=e.yXx&&"/"!=e.yXx&&(u.push(e.x),m.push(e.y),d.push(e.ySx),p.push(e.yXx))});let y=[],x=[],g=[],S=[];u.forEach((e,t)=>{const l=Number(EChartsUtilsComm.getRound(Math.pow(e,.45),.001));y.push([l,m[t]]),S.push({name:e+"",xAxis:l,label:{show:!(u.length>=6&&t%2!=0&&t<6),fontSize:10}}),x.push([l,d[t]]),g.push([l,p[t]])});const b=(e,t)=>{const l=1==e?"筛分曲线":2==e?"上限":"下限",n=1==e?"rect":2==e?"triangle":"circle",a=1==e?"solid":2==e?"dotted":[10,5],s=1==e?o[0].lineColor:2==e?o[1].lineColor:o[2].lineColor;let r={name:l,type:"line",smooth:!0,symbol:n,symbolSize:5,z:10,lineStyle:{color:s,type:a},itemStyle:{color:s},data:t,connectNulls:!0,markLine:{symbol:"",silent:!0,label:{position:"start",formatter:e=>e.name},lineStyle:{color:"#e0e6f1",type:"solid"},data:S}};return r};let w=!1;0==y.length&&(w=!0);let C=0;return y.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||C++}),C==y.length&&(w=!0),(i.some(e=>null!=e&&null!=e&&"/"!=e)||h.some(e=>null!=e&&null!=e&&"/"!=e))&&(w=!1),{grid:{top:20,left:w?25:30,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){if(e&&e[0].data.length>1){let t=S.filter(t=>t.xAxis==e[0].data[0]);return e[0].seriesName+"("+t[0].name+"):"+e[0].data[1]}return e[0].data}},title:[{show:!0,text:"",left:"center",top:5,textStyle:{fontSize:18,fontWeight:"normal"}},{show:!0,text:n,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{left:"center",data:["筛分曲线","上限","下限"],selected:{"筛分曲线":!0,"上限":!0,"下限":!0},selectedMode:"multiple"},xAxis:{type:"value",axisTick:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},min:y.length>0?y[0][0]>.2?y[0][0]-.2:0:null,max:y.length>0?y[y.length-1][0]+.1:null},yAxis:[{type:"value",name:a,nameGap:w?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},splitNumber:10,axisLabel:{fontSize:10}}],series:[b(1,y),b(2,x),b(3,g)]}},chart70:(e,t,l,o)=>{JSON.parse(e.chartLinesJson);const n=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);if(t[0].some(e=>null==e||""==e||null==e)||l[0].some(e=>null==e||""==e||null==e))return{};let a=e.chartTitle,s=e.chartXName,r=e.chartYName,i=t[0],h=l[0],c=100,u="砂类土",m=[],d=[];if(null!=n){let e=o.getValue(n.jxhslZtzl.row,n.jxhslZtzl.col),t=o.getValue(n.jxhslCllx.row,n.jxhslCllx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(e=Number(e),100!=e&&76!=e||(c=e)),"砂类土"!=t&&"细粒土"!=t||(u=t)}for(const e of i)m.push(Math.log(e));for(const e of h)d.push(Math.log(e));let p=(d[2]-d[1])/(m[2]-m[1]),f=(d[2]-d[0])/(m[2]-m[0]);const y=Math.max.apply(Math,i)+1,x=Math.min.apply(Math,i)-.3,g=Math.max.apply(Math,h)+1,S=Math.min.apply(Math,h)-2,b=["C","B","A"],w=[];function C(e,t,l){const o=Math.log(e[0]),n=Math.log(e[1]),a=Math.log(t[0]),s=n+(Math.log(t[1])-n)/(a-o)*(Math.log(l)-o);return Math.exp(s)}i.forEach((e,t)=>{w.push([e,h[t],b[t]])});let E=[20,C([i[2],h[2]],[i[1],h[1]],20)],A=[20,C([i[2],h[2]],[i[0],h[0]],20)];function N(e){let t;return t="砂类土"==u?29.6-1.22*e+.017*e*e-744e-7*e*e*e:e/(.524*e-7.606),t}let v,L,J,j=[],M=[],z=[],_=N(i[2]),q=Math.log(_),O=(p*m[2]-(d[2]-q))/p,U=(f*m[2]-(d[2]-q))/f,T=Math.exp((O+U)/2),R=Math.log(T),V=(d[2]-q)/(m[2]-R);if(76==c){let e=Math.log(17),t=(V*m[2]-(d[2]-e))/V,l=Math.exp(t),o=Math.log(2),n=(V*m[2]-(d[2]-o))/V,a=Math.exp(n);z=[T,_],j=[T,S],M=[x,_],w.push([T,_,"Hp"]),v=_,L=l,J=a}else if(100==c){let e=Math.log(20),t=(V*m[2]-(d[2]-e))/V,l=Math.exp(t),o=N(l),n=Math.log(o),a=(p*m[2]-(d[2]-n))/p,s=(f*m[2]-(d[2]-n))/f,r=Math.exp((a+s)/2),i=r;z=[r,o],j=[r,S],M=[x,o],w.push([r,o,"Hp"]),v=o,L=l,J=i}if((isNaN(v)||isNaN(L)||isNaN(J))&&(v=0,L=0,J=0),null!=n){let e=.01,t=.01,l=.01;null!=n.jxhslScHpJd&&null!=n.jxhslScHpJd&&(e=n.jxhslScHpJd),null!=n.jxhslScWlJd&&null!=n.jxhslScWlJd&&(t=n.jxhslScWlJd),null!=n.jxhslScWpJd&&null!=n.jxhslScWpJd&&(l=n.jxhslScWpJd),null!=n.jxhslScHp&&null!=n.jxhslScHp&&(0==v?o.setValue(n.jxhslScHp.row,n.jxhslScHp.col,"/"):o.setValue(n.jxhslScHp.row,n.jxhslScHp.col,EChartsUtilsComm.getRound(v,e))),null!=n.jxhslScWl&&null!=n.jxhslScWl&&(0==L?o.setValue(n.jxhslScWl.row,n.jxhslScWl.col,"/"):o.setValue(n.jxhslScWl.row,n.jxhslScWl.col,EChartsUtilsComm.getRound(L,t))),null!=n.jxhslScWp&&null!=n.jxhslScWp&&(0==J?o.setValue(n.jxhslScWp.row,n.jxhslScWp.col,"/"):o.setValue(n.jxhslScWp.row,n.jxhslScWp.col,EChartsUtilsComm.getRound(J,l)))}let W=!1;0==i.length&&(W=!0);let D=0;return i.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||D++}),D==i.length&&(W=!0),(h.some(e=>null!=e&&null!=e&&"/"!=e)||h.some(e=>null!=e&&null!=e&&"/"!=e))&&(W=!1),{grid:{top:20,left:W?25:50,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+e[0].value[1]:e[0].data}},title:[{show:!0,text:a,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:s,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"log",min:x,max:y,interval:0,axisTick:{show:!1,alignWithLabel:!0},splitLine:{show:!1},axisLabel:{show:!1}},yAxis:{type:"log",name:r,nameGap:W?5:30,nameRotate:90,nameLocation:"middle",min:S,max:g,interval:0,axisTick:{show:!1,alignWithLabel:!0},splitLine:{show:!1},axisLabel:{show:!1}},series:[{name:"图例1",data:w,type:"scatter",symbol:"circle",smooth:!1,symbolSize:6,label:{show:!0,formatter:function(e){return e.data[2]},position:"right",minMargin:2},markLine:{symbol:["none","none"],silent:!0,label:{show:!0,position:"start",color:"#000000"},lineStyle:{type:"solid",color:"#333"},data:[{xAxis:w[0][0]},{xAxis:w[1][0]},{xAxis:w[2][0]},{yAxis:w[0][1]},{yAxis:w[1][1]},{yAxis:w[2][1]},[{coord:j,lineStyle:{color:"#333",type:"dashed"}},{coord:z}],[{coord:M,lineStyle:{color:"#333",type:"dashed"}},{coord:z}]]}},{type:"line",data:[[i[2],h[2]],[i[1],h[1]]],lineStyle:{color:"#0000FF",type:"solid",width:1},symbol:"none"},{type:"line",data:[[i[1],h[1]],[E[0],E[1]]],lineStyle:{color:"#000000",type:"dashed",width:1},symbol:"none"},{type:"line",data:[[i[2],h[2]],[i[0],h[0]]],lineStyle:{color:"#0000FF",type:"solid",width:1},symbol:"none"},{type:"line",data:[[i[0],h[0]],[A[0],A[1]]],lineStyle:{color:"#000000",type:"dashed",width:1},symbol:"none"},{type:"line",data:[[i[2],h[2]],z],lineStyle:{color:"#0000FF",type:"solid",width:1},symbol:"none"}]}},chart90:(config,xDataArr,yDataArr,sheet)=>{let lineData=JSON.parse(config.chartLinesJson);const chartExtJson=null==config.chartExtJson||null==config.chartExtJson?null:JSON.parse(config.chartExtJson);let yDataSource=yDataArr[0],title=config.chartTitle,xName=config.chartXName,yName=config.chartYName,legendName="图例1",xData=xDataArr[0],xDataCl=[],yDataSourceCl=[];for(let e=0;e<xData.length;e++)if("/"!=xData[e]&&(0==e||e>0&&0!=xData[e]))xDataCl.push(xData[e]),yDataSourceCl.push(yDataSource[e]);else if(e>0&&0==xData[e])break;xData=xDataCl,yDataSource=yDataSourceCl;let seriesData=[],markPointData=[],markLineData=[...xData];const gsS=EChartsUtilsComm.calcTrend(xData,yDataSource,xData[0]);null!=chartExtJson&&null!=chartExtJson.jxhslSnShScfc&&null!=chartExtJson.jxhslSnShScfc&&(""==gsS.xl||""==gsS.jj?sheet.setValue(chartExtJson.jxhslSnShScfc.row,chartExtJson.jxhslSnShScfc.col,"/"):sheet.setValue(chartExtJson.jxhslSnShScfc.row,chartExtJson.jxhslSnShScfc.col,`Y=${EChartsUtilsComm.getRound(gsS.xl,1e-4)}X+${EChartsUtilsComm.getRound(gsS.jj,1e-4)}`));let yDataCopy=[];xData.forEach((item,index)=>{let curYData=Number(EChartsUtilsComm.getRound(eval(gsS.gs.replace("x",item+"")),.01));isNaN(curYData)&&(curYData=0),seriesData.push([item,curYData]),yDataCopy.push(curYData),markPointData.push({xAxis:item,yAxis:yDataSource[index],symbol:"circle",symbolSize:6})});let yValIsAllNull=!1;0==xData.length&&(yValIsAllNull=!0);let nullCount=0;xData.forEach(e=>{0!=e[1]&&null!=e[1]&&null!=e[1]||nullCount++}),nullCount==xData.length&&(yValIsAllNull=!0),yDataCopy.some(e=>0!=e||null==e[1]||null==e[1])&&(yValIsAllNull=!1);let option={grid:{top:22,left:yValIsAllNull?25:30,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].value[0]+":"+e[0].value[1]:e[0].data}},title:[{show:!0,text:title,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:xName,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:[legendName],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1}},yAxis:[{type:"value",name:yName,nameGap:yValIsAllNull?5:30,nameRotate:90,nameLocation:"middle"}],series:[{name:legendName,type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:lineData[0].lineColor,type:"dotted"},itemStyle:{color:lineData[0].lineColor,opacity:0},data:seriesData,markPoint:{data:markPointData},markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value},lineStyle:{color:"#ddd",type:"solid"},data:markLineData.map(e=>({xAxis:e}))}}]};return option},chart110:(e,t,l,o,n)=>{let a=JSON.parse(e.chartLinesJson),s=e.chartTitle,r=e.chartXName,i=e.chartYName;const h=o[0];let c=[];h.forEach((e,t)=>{"/"==e?c.push(e):c.push(Number(e))});let u=l[0],m=[];c.forEach((e,t)=>{"/"!=e&&null!=e&&null!=e&&m.push([e,u[t]])});let d=!1;return 0==m.length&&(d=!0),{grid:{top:25,left:25,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:s,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:r,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",axisTick:{alignWithLabel:!0},axisLabel:{formatter:function(e){let t="";for(let l=0;l<c.length;l++)if(c[l]==e){t=h[l],"/"==t&&(t="");break}return t}}},yAxis:[{type:"value",name:i,nameGap:d?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:a[0].lineColor},itemStyle:{color:a[0].lineColor},data:m}]}},chart130:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=.01,c=200,u=[];r.forEach((e,t)=>{u.push(["筛底"==e?0:e,i[t]])});let m=!1;0==r.length&&(m=!0);let d=0;return r.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||d++}),d==r.length&&(m=!0),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(m=!1),m&&(h=null,c=null),{grid:{top:25,left:20,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"log",logBase:10,inverse:!0,min:h,max:c},yAxis:[{type:"value",name:s,nameGap:m?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:u}]}},chart150:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=[];r.forEach((e,t)=>{h.push([e,i[t]])});let c=!1;0==r.length&&(c=!0);let u=0;return r.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||u++}),u==r.length&&(c=!0),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(c=!1),{grid:{top:55,left:c?25:30,right:10,bottom:10,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:18,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1},position:"top"},yAxis:[{type:"value",name:s,nameGap:c?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h,markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value},lineStyle:{color:"#ddd",type:"solid"},data:r.map(e=>({xAxis:e}))}}]}},chart170:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=[];r.forEach((e,t)=>{h.push([e,i[t]])});let c=!1;0==r.length&&(c=!0);let u=0;return r.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||u++}),u==r.length&&(c=!0),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(c=!1),{grid:{top:55,left:c?25:30,right:10,bottom:10,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:18,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1},position:"top"},yAxis:[{type:"value",name:s,nameGap:c?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h,markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value},lineStyle:{color:"#ddd",type:"solid"},data:r.map(e=>({xAxis:e}))}}]}},chart190:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartXName,a=e.chartYName,s=t[0],r=l[0];s=s.filter(e=>null!=e&&null!=e&&"/"!=e&&(null==e._code||null==e._code)),r=r.filter(e=>null!=e&&null!=e&&"/"!=e&&(null==e._code||null==e._code));let i=!1;0==s.length&&(i=!0);let h=0;return s.forEach(e=>{null!=e&&null!=e&&"/"!=e||h++}),h==s.length&&(i=!0,s=[]),r.some(e=>null!=e&&null!=e&&"/"!=e)&&(i=!1),{grid:{top:10,left:i?25:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:18,fontWeight:"normal"}},{show:!0,text:n,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:s,axisTick:{alignWithLabel:!0},axisLabel:{formatter:function(e){return"/"==e?"":e}}},yAxis:[{type:"value",name:a,nameGap:i?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:r}]}},chart210:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=t[0],a=l[0],s=e.chartTitle,r=e.chartXName,i=e.chartYName;const h=[];for(let e=n.length-1;e>=0;e--){const t=n[e];null==t||null==t||"/"==t||null!=t._error&&null!=t._error||h.push([t,a[e]])}let c=!1;0==n.length&&(c=!0);let u=0;n.forEach(e=>{(null==e||null==e||"/"==e||null!=e._error&&null!=e._error)&&u++}),u==n.length&&(c=!0),a.some(e=>null!=e&&null!=e&&"/"!=e)&&(c=!1);return{grid:{top:25,left:!c&&h.length>0?30:25,right:10,bottom:40,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].value[0]+":"+e[0].value[1]:e[0].data}},title:[{show:!0,text:s,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:r,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1}},yAxis:[{type:"value",name:i,nameGap:!c&&h.length>0?30:5,nameRotate:90,nameLocation:"middle",axisLabel:{fontSize:10}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h,markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value,fontSize:10},lineStyle:{color:"#ddd",type:"solid"},data:(()=>{let e=[];[0,.02,.04,.06,.08,.1].forEach(t=>{n.forEach(l=>{let o={xAxis:""};"/"==l?(o.xAxis="",e.push(o)):(o.xAxis=t,e.push(o))})});let t=e.filter((e,t,l)=>t===l.findIndex(t=>t.xAxis==e.xAxis));return u==n.length?[]:t})()}}]}},chart230:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=t.length,a=[],s=[],r=[],i=[],h=[],c=[];a=EChartsUtilsComm.filterNullEmptyErrArray(t[0]),i=EChartsUtilsComm.filterNullEmptyErrArray(l[0]),2==n&&(s=EChartsUtilsComm.filterNullEmptyErrArray(t[1]),h=EChartsUtilsComm.filterNullEmptyErrArray(l[1])),3==n&&(s=EChartsUtilsComm.filterNullEmptyErrArray(t[1]),h=EChartsUtilsComm.filterNullEmptyErrArray(l[1]),r=EChartsUtilsComm.filterNullEmptyErrArray(t[2]),c=EChartsUtilsComm.filterNullEmptyErrArray(l[2]));let u=[],m=[],d=[];a.forEach((e,t)=>{if("object"==typeof e)u.push(60*e.getHours()+e.getMinutes());else if("number"==typeof e)u.push(e);else{const t=e.split(":"),l=60*Number(t[0])+Number(t[1]);u.push(l)}}),s.forEach((e,t)=>{if("object"==typeof e)m.push(60*e.getHours()+e.getMinutes());else if("number"==typeof e)m.push(e);else{const t=e.split(":"),l=60*Number(t[0])+Number(t[1]);m.push(l)}}),r.forEach((e,t)=>{if("object"==typeof e)d.push(60*e.getHours()+e.getMinutes());else if("number"==typeof e)d.push(e);else{const t=e.split(":"),l=60*Number(t[0])+Number(t[1]);d.push(l)}}),a.length>0&&(u.push(u[u.length-1]+20),u.unshift(u[0]-20),i.push(null),i.unshift(null)),2==n&&s.length>0&&(m.push(m[m.length-1]+20),m.unshift(m[0]-20),h.push(null),h.unshift(null)),3==n&&0==r.length&&(m.push(m[m.length-1]+20),m.unshift(m[0]-20),h.push(null),h.unshift(null),d.push(d[d.length-1]+20),d.unshift(d[0]-20),c.push(null),c.unshift(null));let p=e.chartTitle,f=e.chartXName,y=e.chartYName;const x=(e,t)=>({type:"category",data:t,axisTick:{alignWithLabel:!0},show:1==e,splitLine:{show:!0}});let g=[x(1,u)];2==n&&g.push(x(2,m)),3==n&&(g.push(x(2,m)),g.push(x(3,d)));const S=(e,t)=>{const l=1==e?"第一组":2==e?"第二组":"第三组",n=1==e?"rect":2==e?"triangle":"circle",a=1==e?"solid":2==e?"dotted":[10,5],s=1==e&&o.length>=1?o[0].lineColor:2==e&&o.length>=2?o[1].lineColor:3==e&&o.length>=3?o[2].lineColor:"#000";return{name:l,type:"line",smooth:!0,symbol:n,symbolSize:6,lineStyle:{color:s,type:a},itemStyle:{color:s},data:t}};let b=[S(1,i)];2==n&&h.length>0&&b.push(S(2,h)),3==n&&(h.length>0&&b.push(S(2,h)),c.length>0&&b.push(S(3,c)));let w=1==n?["第一组"]:2==n?["第一组","第二组"]:["第一组","第二组","第三组"],C=1==n?{"第一组":!0}:2==n?{"第一组":!0,"第二组":!0}:{"第一组":!0,"第二组":!0,"第三组":!0},E=!1,A=!1,N=0;return 0==a.length?(A=!0,N=15,w=["第二组","第三组"],C={"第一组":!1,"第二组":!0,"第三组":!0},g=[],b=[],g.push(x(1,m)),g.push(x(3,d)),b.push(S(2,h)),b.push(S(3,c)),0==s.length&&(N=35,w=["第三组"],C={"第一组":!1,"第二组":!1,"第三组":!0},g=[],b=[],g.push(x(1,d)),b.push(S(3,c)),0==r.length&&(N=0,E=!0,w=[],C={"第一组":!1,"第二组":!1,"第三组":!1},g=[],b=[],g.push(x(1,[])),b.push(S(3,[]))))):0==s.length?(N=15,A=!0,w=["第一组","第三组"],C={"第一组":!0,"第二组":!1,"第三组":!0},g=[],b=[],g.push(x(1,u)),g.push(x(3,d)),b.push(S(1,i)),b.push(S(3,c)),0==a.length&&(N=35,w=["第三组"],C={"第一组":!1,"第二组":!1,"第三组":!0},g=[],b=[],g.push(x(1,u)),b.push(S(3,i)),0==r.length&&(N=0,E=!0,w=[],C={"第一组":!1,"第二组":!1,"第三组":!1},g=[],b=[],g.push(x(1,[])),b.push(S(3,[]))))):0==r.length&&(N=15,A=!0,w=["第一组","第二组"],C={"第一组":!0,"第二组":!0,"第三组":!1},g=[],b=[],g.push(x(1,u)),g.push(x(2,m)),b.push(S(1,i)),b.push(S(2,h)),0==a.length&&(N=35,w=["第二组"],C={"第一组":!1,"第二组":!0,"第三组":!1},g=[],b=[],g.push(x(1,m)),b.push(S(2,h)),0==s.length&&(N=0,E=!0,w=[],C={"第一组":!1,"第二组":!1,"第三组":!1},g=[],b=[],g.push(x(1,[])),b.push(S(2,[]))))),{grid:{top:A?N:-5,left:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:p,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:f,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{left:"center",top:16,data:w,selected:C,selectedMode:"multiple"},xAxis:g,yAxis:[{type:"value",name:y,nameGap:E?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:b}},chart250:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=[];r.forEach((e,t)=>{h.push([e,i[t]])});let c=.001,u=100,m=!1;0==r.length&&(m=!0);let d=0;return r.forEach(e=>{null!=e&&null!=e&&"/"!=e||d++}),d==r.length&&(m=!0,c=null,u=null),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(m=!1),{grid:{top:25,left:20,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"log",logBase:10,inverse:!0,min:c,max:u},yAxis:[{type:"value",name:s,nameGap:m?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h}]}},chart270:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=[],i=[],h=[],c=[],u=[],m=[];t[0].forEach((e,t)=>{0!=e&&0!=l[0][t]&&(r.push(e),c.push(l[0][t]))}),t[1].forEach((e,t)=>{0!=e&&0!=l[1][t]&&(i.push(e),u.push(l[1][t]))}),t[2].forEach((e,t)=>{0!=e&&0!=l[2][t]&&(h.push(e),m.push(l[2][t]))});const d=(e,t,l)=>{const n=`曲线${e}`,a=1==e?"rect":2==e?"triangle":"circle",s=1==e?"solid":2==e?"dotted":[10,5],r=1==e?o[0].lineColor:2==e?o[1].lineColor:o[2].lineColor,i=[];return t.forEach((e,t)=>{i.push([e,l[t]])}),{name:n,type:"line",smooth:!0,symbol:a,symbolSize:5,lineStyle:{color:r,type:s},itemStyle:{color:r},data:i}};let p=!1;return r.every(e=>"/"==e)&&i.every(e=>"/"==e)&&h.every(e=>"/"==e)&&c.every(e=>"/"==e)&&u.every(e=>"/"==e)&&m.every(e=>"/"==e)&&(p=!0),{grid:{top:35,left:p?25:30,right:20,bottom:5,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+e[0].value[1]:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:16,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",axisTick:{alignWithLabel:!0},splitLine:{show:!0},position:"top",nameGap:5,nameLocation:"end"},yAxis:[{type:"value",name:s,nameGap:p?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[d(1,r,c),d(2,i,u),d(3,h,m)]}},chart279_280_281:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=279==e.chartType?5:280==e.chartType?.1:.15,i=t[0],h=l[0],c=Math.min(...i),u=Number(EChartsUtilsComm.getRound(Math.min(...h)-r,.001)),m=Number(EChartsUtilsComm.getRound(Math.max(...h)+r,.001));c=Number(EChartsUtilsComm.getRound(c-.01*c,.001));let d=[];i.forEach((e,t)=>{d.push([e,h[t]])});let p=!1;return h.every(e=>"/"==e)&&(p=!0),{grid:{top:25,left:20,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",min:c,max:100},yAxis:[{type:"value",name:s,nameGap:p?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0},min:u,max:m}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:d}]}},chart290:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=t[0],i=t[0],h=t[0],c=l[0],u=l[1],m=l[2];const d=(e,t)=>{const l=`曲线${e}`,n=1==e?"rect":2==e?"triangle":"circle",a=1==e?"solid":2==e?"dotted":[10,5],s=1==e?o[0].lineColor:2==e?o[1].lineColor:o[2].lineColor;return{name:l,type:"line",smooth:!0,symbol:n,symbolSize:5,lineStyle:{color:s,type:a},itemStyle:{color:s},data:t}};let p=!1;return r.every(e=>"/"==e)&&i.every(e=>"/"==e)&&h.every(e=>"/"==e)&&c.every(e=>"/"==e)&&u.every(e=>"/"==e)&&m.every(e=>"/"==e)&&(p=!0,r=[]),{grid:{top:35,left:p?25:30,right:10,bottom:5,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:16,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:r,axisTick:{alignWithLabel:!0},splitLine:{show:!0},position:"top",nameGap:5,nameLocation:"end",axisLabel:{formatter:function(e){return"/"==e?"":e}}},yAxis:[{type:"value",name:s,nameGap:p?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[d(1,c),d(2,u),d(3,m)]}},chart310:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=t[0],i=l[0],h=[],c=[];r.forEach((e,t)=>{null==e||null==e||"/"==e||null!=e._code&&null!=e._code||(h.push(e),c.push(i[t]))}),r=h,i=c;let u=!1;return r.every(e=>"/"==e||null!=e._code&&null!=e._code)&&i.every(e=>"/"==e||null!=e._code&&null!=e._code)&&(u=!0,r=[]),{grid:{top:35,left:u?25:30,right:20,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:16,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:r,axisLabel:{formatter:function(e){return"/"==e?"":e}},axisTick:{alignWithLabel:!0},axisLine:{symbol:["none","arrow"],symbolSize:10},splitLine:{show:!0},position:"top",name:"p",nameGap:5,nameLocation:"end"},yAxis:[{type:"value",name:s,nameGap:u?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0,symbol:["arrow","none"],symbolSize:10}},{name:"L",nameRotate:0,nameLocation:"end",nameGap:5,position:"left",inverse:!0}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:i}]}},chart330:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=e.chartXName,r=e.chartYName,i=t[0],h=l[0];const c=EChartsUtilsComm.calcTrend(i,h,i[0]);let u=EChartsUtilsComm.getRound((.15-c.jj)/c.xl,0),m=EChartsUtilsComm.getRound((.19-c.jj)/c.xl,0),d=EChartsUtilsComm.getRound((.25-c.jj)/c.xl,0),p=EChartsUtilsComm.getRound((.31-c.jj)/c.xl,0);u==1/0&&(u=0),m==1/0&&(m=0),d==1/0&&(d=0),p==1/0&&(p=0);let f=`${u}~${m}`,y=`${d}~${p}`;null!=a&&(0==u&&0==m?o.setValue(a.bszdjBh.row,a.bszdjBh.col,"/"):o.setValue(a.bszdjBh.row,a.bszdjBh.col,f),0==d&&0==p?o.setValue(a.bszdjYs.row,a.bszdjYs.col,"/"):o.setValue(a.bszdjYs.row,a.bszdjYs.col,y));let x=!1;return i.every(e=>"/"==e)&&h.every(e=>"/"==e)&&(x=!0,i=[]),{grid:{top:10,left:x?25:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:18,fontWeight:"normal"}},{show:!0,text:s,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:i,axisTick:{alignWithLabel:!0},axisLabel:{formatter:function(e){return"/"==e?"":e}}},yAxis:[{type:"value",name:r,nameGap:x?5:25,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:h}]}},chart350:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson)[0].lineColor;const n=[t[0][0],t[0][1]],a=[l[0][0],l[0][1]],s=Number(EChartsUtilsComm.getRound(EChartsUtilsComm.calcTrend(n,a,n[0]).y,.1)),r=Number(EChartsUtilsComm.getRound(EChartsUtilsComm.calcTrend(n,a,n[1]).y,.1)),i=Number(EChartsUtilsComm.getRound(EChartsUtilsComm.calcTrend(n,a,25).y,.1)),h=Math.floor(Number(r))-2,c=Math.floor(Number(s))+2;let u=e.chartTitle,m=e.chartXName,d=e.chartYName,p=!0;p=0==t[0].filter(e=>null!=e&&null!=e&&"/"!=e).length,p&&(p=0==l[0].filter(e=>null!=e&&null!=e&&"/"!=e).length);let f=[{name:"图例1",type:"line",symbol:"circle",z:10,lineStyle:{color:o},itemStyle:{color:o},connectNulls:!0,data:[[0,null],[2,null],[3.5,null],[4.9,null],[5.9,null],[6.9,null],{value:[10.4,i-2.7*(i-s)/2.1],symbol:"none"},[11,s],[11.8,null],[13.1,i],[14.6,r],{value:[15.2,2.1/1.5*(r-i)+i],symbol:"none"},[16.4,null],[17.4,null],[18.9,null],[19.8,null],[20.7,null],[21.6,null],[22.6,null]],markPoint:{data:[{xAxis:13.1,yAxis:i,symbolOffset:[40,25],label:{show:!0,color:"#000",formatter:function(e){return p?"":"( 25 , "+e.data.yAxis+")"}},itemStyle:{color:"transparent"}}]},markLine:{symbol:"",silent:!0,label:{position:"start",formatter:e=>e.name},lineStyle:{color:"#e0e6f1",type:"solid"},data:[{name:"5",xAxis:0,label:{fontSize:8}},{name:"6",xAxis:2,label:{fontSize:8}},{name:"7",xAxis:3.5,label:{fontSize:8}},{name:"8",xAxis:4.9,label:{fontSize:8}},{name:"9",xAxis:5.9,label:{fontSize:8}},{name:"10",xAxis:6.9,label:{fontSize:8}},{name:"",xAxis:10.4,lineStyle:{opacity:0}},{name:"",xAxis:11},{name:"20",xAxis:11.8,label:{fontSize:8}},{name:"25",xAxis:13.1,label:{fontSize:8}},{name:"30",xAxis:14.6,label:{fontSize:8}},{name:"",xAxis:15.2,lineStyle:{opacity:0}},{name:"40",xAxis:16.4,label:{fontSize:8}},{name:"50",xAxis:17.4,label:{fontSize:8}},{name:"",xAxis:18.9},{name:"",xAxis:19.8},{name:"",xAxis:20.7},{name:"",xAxis:21.6},{name:"100",xAxis:22.6,label:{fontSize:8}},[{coord:[0,i],lineStyle:{color:"#529b2e",type:"solid"}},{coord:[13.1,i]}],[{coord:[13.1,h],lineStyle:{color:"#000",type:"silid"}},{coord:[13.1,i]}]]}}];return p&&(f=[]),{grid:{top:25,left:30,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e[0].data.length>1?null==e[0].data[1]?"":e[0].seriesName+"("+e[0].data[0]+"):"+e[0].data[1]:e[0].data}},title:[{show:!0,text:u,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:m,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",axisTick:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},min:0,max:23.5},yAxis:[{type:"value",name:d,nameGap:p?10:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},splitNumber:4,min:p?null:h,max:c,axisLabel:{show:!p,fontSize:8},axisTick:{show:!p}}],series:f}}},EChartsUtils={create:(e,t,l,o,...n)=>__awaiter(void 0,[e,t,l,o,...n],void 0,function*(e,t,l,o,n=!1){const a=null==o.chartExtJson||null==o.chartExtJson?null:JSON.parse(o.chartExtJson);if(null!=a&&null!=a.isShowCon&&null!=a.isShowCon){if(l.getValue(a.isShowCon.row,a.isShowCon.col)!=a.isShowVal)return void l.floatingObjects.remove(o.chartId)}let s=0,r=0,i=0,h=0;for(let e=0;e<o.row;e++)s+=l.getRowHeight(e);s+=l.getRowHeight(0,e.Spread.Sheets.SheetArea.colHeader);for(let e=o.col;e<o.col+o.colCount;e++)r+=l.getColumnWidth(e);for(let e=0;e<o.col;e++)i+=l.getColumnWidth(e);i+=l.getColumnWidth(0,e.Spread.Sheets.SheetArea.rowHeader);for(let e=o.row;e<o.row+o.rowCount;e++)h+=l.getRowHeight(e);const c={x:i-40+2,y:s-20+2,w:r-6,h:h-6};let u=l.floatingObjects.get(o.chartId);if(null==u||null==u?(u=new e.Spread.Sheets.FloatingObjects.FloatingObject(o.chartId,c.x,c.y,c.w,c.h),u.allowResize(!1),u.allowMove(!1),l.floatingObjects.add(u)):(u.x(c.x),u.y(c.y),u.width(c.w),u.height(c.h)),null==document.getElementById(o.chartId+"_ec")){const e=document.createElement("div");e.setAttribute("style","background-color:#fff;width:100%;height:100%;"),e.innerHTML=`<div id="${o.chartId}_ec" style="width:100%;height:100%;"></div>`,u.content(e)}let m=null;return m=(yield new Promise((e,a)=>{setTimeout(()=>{e({ecObj:EChartsUtils.initChart(t,l,o,n)})},10)})).ecObj,{fObj:u,fObjPosition:c,ecObj:m}}),initChart:(e,t,l,o=!1)=>{if(null==document.getElementById(l.chartId+"_ec"))return null;let n=[],a=[],s=[],r=[];const i=(e,t,l,o)=>{let n={dataOneArr:[],dataOneSourceArr:[]},a=null;return null!=l&&null!=l&&l.length>0&&(a=e.getSheetFromName(l)),null==o||o.forEach((e,l)=>{const o=null!=a?a.getValue(e.row,e.col):t.getValue(e.row,e.col);n.dataOneSourceArr.push(o),/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(o)?n.dataOneArr.push(Number(o)):n.dataOneArr.push(null==o?0:o)}),n};JSON.parse(l.chartLinesJson).forEach((l,o)=>{let h=[],c=[],u=[],m=[];const d=i(e,t,l.sheetNameX,l.xCells);h=d.dataOneArr,u=d.dataOneSourceArr;const p=i(e,t,l.sheetNameY,l.yCells);c=p.dataOneArr,m=p.dataOneSourceArr,n.push(h),a.push(c),s.push(u),r.push(m)});const h=document.getElementById(l.chartId+"_ec");let c,u=echarts__namespace.getInstanceByDom(h);return null!=u&&null!=u||(u=echarts__namespace.init(h,null,{renderer:"canvas",useDirtyRect:!1})),10==l.chartType?c=EChartsUtilsAll.chart10(l,n,a,t):11==l.chartType?c=EChartsUtilsAll.chart11(l,n,a,t):12==l.chartType?c=EChartsUtilsAll.chart12(l,n,a,t):13==l.chartType?c=EChartsUtilsAll.chart13(l,n,a,t):14==l.chartType?c=EChartsUtilsAll.chart14(l,n,a,t):15==l.chartType?c=EChartsUtilsAll.chart15(l,n,a,t):16==l.chartType?c=EChartsUtilsAll.chart16(l,n,a,t):30==l.chartType?c=EChartsUtilsAll.chart30(l,n,a,t):50==l.chartType?c=EChartsUtilsAll.chart50(l,n,a):70==l.chartType?c=EChartsUtilsAll.chart70(l,n,a,t):90==l.chartType?c=EChartsUtilsAll.chart90(l,n,a,t):110==l.chartType?c=EChartsUtilsAll.chart110(l,n,a,s,r):130==l.chartType?c=EChartsUtilsAll.chart130(l,n,a):150==l.chartType?c=EChartsUtilsAll.chart150(l,n,a):170==l.chartType?c=EChartsUtilsAll.chart170(l,n,a):190==l.chartType?c=EChartsUtilsAll.chart190(l,n,a):210==l.chartType?c=EChartsUtilsAll.chart210(l,n,a):230==l.chartType?c=EChartsUtilsAll.chart230(l,n,a):250==l.chartType?c=EChartsUtilsAll.chart250(l,n,a):270==l.chartType?c=EChartsUtilsAll.chart270(l,n,a):279==l.chartType||280==l.chartType||281==l.chartType?c=EChartsUtilsAll.chart279_280_281(l,n,a):290==l.chartType?c=EChartsUtilsAll.chart290(l,n,a):310==l.chartType?c=EChartsUtilsAll.chart310(l,n,a):330==l.chartType?c=EChartsUtilsAll.chart330(l,n,a,t):350==l.chartType&&(c=EChartsUtilsAll.chart350(l,n,a)),c&&"object"==typeof c&&(o&&(c.animation=!1),u.setOption(c)),u.setOption(c),u},getEChartsObj:e=>{const t=document.getElementById(e+"_ec");let l=echarts__namespace.getInstanceByDom(t);return null==l||null==l?null:l}},WorkbookUtils={loadSjsFile:(e,t,l,o)=>__awaiter(void 0,void 0,void 0,function*(){const n=yield fetch(t,{method:"GET"});if(n.ok){const t=yield n.blob(),a=new Blob([t],{type:"application/zip"});e.open(a,()=>__awaiter(void 0,void 0,void 0,function*(){"function"==typeof l&&(yield l(e))}),e=>__awaiter(void 0,void 0,void 0,function*(){"function"==typeof o&&(yield o(e))}))}}),print:(e,t)=>{const l=t.getSheetCount();for(let o=0;o<l;o++){const l=t.getSheet(o);let n=l.printInfo();n.showRowHeader(e.Spread.Sheets.Print.PrintVisibilityType.hide),n.showColumnHeader(e.Spread.Sheets.Print.PrintVisibilityType.hide),n.rowStart(0),n.rowEnd(l.getRowCount()),n.columnStart(0),n.columnEnd(76),n.margin({top:59.055119999999995,bottom:59.055119999999995,left:98.42520000000002,right:59.055119999999995,header:0,footer:0}),n.paperSize(new e.Spread.Sheets.Print.PaperSize(e.Spread.Sheets.Print.PaperKind.a4)),l.printInfo(n)}t.print()},exportToExcel:(e,t,l="")=>{const o=t.toJSON({includeBindingSource:!0}),n=["YJMAX","YJMIN","YJMID","YJGETNUM","YJGETS","YJGETCV","YJINTERPOLATIONMETHOD","YJINTERPOLATIONMETHOD_Y"],a=new e.Spread.Sheets.Workbook;a.fromJSON(o),a.suspendPaint();const s=a.getSheetCount();for(let e=0;e<s;e++){const t=a.getSheet(e);t.suspendCalcService();for(var r=0;r<t.getRowCount();r++)for(var i=0;i<t.getColumnCount();i++){const e=t.getFormula(r,i);if(null!=e&&null!=e&&n.some(t=>e.indexOf(t)>-1)){const e=t.getValue(r,i);t.getCell(r,i).formula(void 0),t.setValue(r,i,e)}}t.resumeCalcService(!1)}a.resumePaint(),""==l&&(l=a.getSheet(0).name());let h={fileType:e.Spread.Sheets.FileType.excel,includeBindingSource:!0,includeStyles:!0,includeFormulas:!0,saveAsView:!1,rowHeadersAsFrozenColumns:!1,columnHeadersAsFrozenRows:!1,includeAutoMergedCells:!1,includeCalcModelCache:!1,includeUnusedNames:!0,includeEmptyRegionCells:!0};a.export(e=>{fileSaver.saveAs(e,`${l}.xlsx`)},()=>{},h),a.destroy()}};exports.BusinessUtils=BusinessUtils,exports.CommonUtils=CommonUtils,exports.EChartsUtils=EChartsUtils,exports.SheetUtils=SheetUtils,exports.WorkbookUtils=WorkbookUtils;
1
+ "use strict";var rapidUtils=require("rapid-utils"),echarts=require("echarts"),math=require("mathjs"),fileSaver=require("file-saver");function _interopNamespaceDefault(e){var t=Object.create(null);return e&&Object.keys(e).forEach(function(l){if("default"!==l){var o=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(t,l,o.get?o:{enumerable:!0,get:function(){return e[l]}})}}),t.default=e,Object.freeze(t)}var echarts__namespace=_interopNamespaceDefault(echarts),math__namespace=_interopNamespaceDefault(math);const SheetUtils={getActiveSheetSelectCells:e=>e.getActiveSheet().getSelections(),setActiveSheetSelectCells:(e,t)=>{e.getActiveSheet().setSelection(t.row,t.col,t.rowCount,t.colCount)},getAllCellObjsByRange:(e,t,l=!1)=>SheetUtils.getAllCellObjsByRanges(e,[t],l),getAllCellObjsByRanges:(e,t,l=!1)=>{let o=[];return t.forEach((t,l)=>{if(e.getSpans(t).forEach(e=>{o.push({row:e.row,col:e.col,rowCount:e.rowCount,colCount:e.colCount})}),void 0===t.row||void 0===t.col||void 0===t.rowCount||void 0===t.colCount)throw new Error("row、col、rowCount、colCount is required.");for(let l=t.row;l<+t.row+t.rowCount;l++)for(let n=t.col;n<t.col+t.colCount;n++){null==e.getSpan(l,n)&&o.push({row:l,col:n,rowCount:1,colCount:1})}}),o=rapidUtils.orderByJson(o,l?["col","row"]:["row","col"],["asc","asc"]),o},getSheetAllCellObjs:e=>{const t=[{row:0,col:0,rowCount:e.getRowCount(),colCount:e.getColumnCount()}];return SheetUtils.getAllCellObjsByRanges(e,t)},getSheetSelectCellObjs:(e,t=!1)=>{const l=e.getSelections();return SheetUtils.getAllCellObjsByRanges(e,l,t)},getActiveSheetSelectCellObjs:(e,t=!1)=>{const l=e.getActiveSheet();return SheetUtils.getSheetSelectCellObjs(l,t)},getSheetCellObjsByGroup:(e,t,l="row")=>{e.suspendPaint();const o=SheetUtils.getAllCellObjsByRange(e,t),n=rapidUtils.groupByJson(o,l),a=[];return rapidUtils.forEachJson(n,(e,t,l)=>{a.push(e)}),e.resumePaint(),a},getSheetSelectVals:(e,t=!1,l)=>{const o=SheetUtils.getSheetSelectCellObjs(e,t);let n=[];return o.forEach(t=>{let o=e.getValue(t.row,t.col);null!=l&&null!=l&&null==o&&(o=l),n.push(o)}),n},getActiveSheetSelectVals:(e,t=!1,l)=>{const o=e.getActiveSheet();return SheetUtils.getSheetSelectVals(o,t,l)},getSheetRangeValsByGroup:(e,t,l="row",o)=>{e.suspendPaint();const n=SheetUtils.getAllCellObjsByRange(e,t),a=rapidUtils.groupByJson(n,l),s=[];return rapidUtils.forEachJson(a,(t,l,n)=>{const a=[];rapidUtils.forEachJson(t,(t,l,n)=>{let s=e.getValue(t.row,t.col);null!=o&&null!=o&&null==s&&(s=o),a.push(s)}),s.push(a)}),e.resumePaint(),s},getCellType:(e,t,l,o)=>{let n;const a=t.getCellType(l,o);if(a instanceof e.Spread.Sheets.CellTypes.Button?n="button":a instanceof e.Spread.Sheets.CellTypes.RadioButtonList?n="radio":a instanceof e.Spread.Sheets.CellTypes.CheckBox?n="checkbox":a instanceof e.Spread.Sheets.CellTypes.CheckBoxList?n="checkboxList":a instanceof e.Spread.Sheets.CellTypes.HyperLink?n="hyperLink":a instanceof e.Spread.Sheets.CellTypes.ComboBox&&(n="comboBox"),null==n||null==n){const e=t.getStyle(l,o);e&&e.cellButtons&&e.cellButtons.length>0&&("openDateTimePicker"==e.cellButtons[0].command?e.dropDowns&&e.dropDowns.length>0&&(n=e.dropDowns[0].option.showDateRange?"dateRange":"date"):"openCalculator"==e.cellButtons[0].command&&(n="calc"))}return n},setSheetZoom:(e,t)=>{e.suspendPaint();const l=e.getSheetCount();for(let o=0;o<l;o++){e.getSheet(o).zoom(t)}e.resumePaint()},setActiveSheetSelectBgColor:(e,t)=>{const l=e.getActiveSheet();l.suspendPaint();SheetUtils.getActiveSheetSelectCells(e).forEach(e=>{l.getRange(e.row,e.col,e.rowCount,e.colCount).backColor(t)}),l.resumePaint()},setSheetBgColor:(e,t,l)=>{e.suspendPaint(),t.forEach(t=>{e.getRange(t.row,t.col,t.rowCount,t.colCount).backColor(l)}),e.resumePaint()},setSheetShowPrintPageLine:(e,t)=>{e.suspendPaint();const l=e.getSheetCount();for(let o=0;o<l;o++){e.getSheet(o).isPrintLineVisible(t)}e.resumePaint()},ignoreSheetShowStrs:e=>{const t=["#DIV/0!","#VALUE!","#NAME?","#N/A","#NULL!","#NUM!","#REF!"],l=e.Spread.Sheets.CellTypes.Text.prototype.paint;e.Spread.Sheets.CellTypes.Text.prototype.paint=function(e,o,n,a,s,r,i,h){t.some(e=>e==o)?l.call(this,e,"/",n,a,s,r,i,h):l.apply(this,arguments)}},setSheetAuxiliaryLine:(e,t,l,o,n=1,a="#409eff",s=!1)=>{let r=new e.Spread.Sheets.FloatingObjects.FloatingObject("floatLineBottom"+(s?"Hb":""),0,o,l,n),i=new e.Spread.Sheets.FloatingObjects.FloatingObject("floatLineRight"+(s?"Hb":""),l,0,n,o),h=document.createElement("div"),c=document.createElement("div");h.style.width=`${l}px`,h.style.height="1px",h.style.borderBottom=`${n}px dashed ${a}`,c.style.width="1px",c.style.height=`${o}px`,c.style.borderLeft=`${n}px dashed ${a}`,r.allowResize(!1),r.allowMove(!1),r.content(h),i.allowResize(!1),i.allowMove(!1),i.content(c),t.floatingObjects.add(r),t.floatingObjects.add(i)},setActiveSheetWatermark:(e,t,l)=>{if(null==t||null==t)return;const o=e.getActiveSheet();o.suspendPaint(),t.forEach(e=>{o.getCell(e.row,e.col).watermark(l?`{${e.title}}`:void 0),o.setBindingPath(e.row,e.col,l?`${e.pathPrev}.${e.pathField}`:void 0)}),o.resumePaint()},setSheetCellDate:(e,t,l,o=!0)=>{l.forEach((l,n)=>{let a=t.getStyle(l.row,l.col);a||(a=new e.Spread.Sheets.Style),a.cellButtons=[{imageType:e.Spread.Sheets.ButtonImageType.dropdown,command:"openDateTimePicker"}],a.dropDowns=[{type:e.Spread.Sheets.DropDownType.dateTimePicker,option:{showTime:!1,showDateRange:!1}}],a.formatter=l.dateFormat,a.shrinkToFit=o,t.setStyle(l.row,l.col,a)})}},BusinessUtils={createTestObjectAttrsCells:(e,t,l,o=!0,n=1,a=77,s=24)=>{if(!l||0===l.length)return;const r=o?12:10,i=o?26:15,h=o?2:3,c=rapidUtils.chunkJson(l,h);t.suspendPaint(),t.setRowCount(0);for(let l=0;l<c.length;l++){const h=c[l],u=t.getRowCount();t.addRows(u,1),t.setRowHeight(u,s,e.Spread.Sheets.SheetArea.viewport);const m=t.getRange(u,1,n,a,e.Spread.Sheets.SheetArea.viewport);if(m.setBorder(new e.Spread.Sheets.LineBorder("#000",e.Spread.Sheets.LineStyle.thin),{all:!0}),m.setBorder(new e.Spread.Sheets.LineBorder("#000",e.Spread.Sheets.LineStyle.medium),{left:!0}),m.setBorder(new e.Spread.Sheets.LineBorder("#000",e.Spread.Sheets.LineStyle.medium),{right:!0}),m.hAlign(e.Spread.Sheets.HorizontalAlign.center),m.vAlign(e.Spread.Sheets.HorizontalAlign.center),t.addSpan(u,n,1,r,e.Spread.Sheets.SheetArea.viewport),t.addSpan(u,n+r,1,h.length>1?i:a-r,e.Spread.Sheets.SheetArea.viewport),t.setValue(u,n,h[0].title),t.setValue(u,n+r,h[0].value),h.length>1){const l=n+r+i,a=l+r;t.addSpan(u,l,1,r,e.Spread.Sheets.SheetArea.viewport),t.addSpan(u,a,1,i+1+(o||2!=h.length?0:r+i+1),e.Spread.Sheets.SheetArea.viewport),t.setValue(u,l,h[1].title),t.setValue(u,a,h[1].value)}if(h.length>2){const l=n+r+i+r+i+1,o=l+r;t.addSpan(u,l,1,r,e.Spread.Sheets.SheetArea.viewport),t.addSpan(u,o,1,i+1,e.Spread.Sheets.SheetArea.viewport),t.setValue(u,l,h[2].title),t.setValue(u,o,h[2].value)}}t.resumePaint()},getTestObjectAttrsVals:(e,t,l=!0,o=1,n=77)=>{const a=l?2:3,s=rapidUtils.chunkJson(t,a);e.suspendPaint();const r=SheetUtils.getAllCellObjsByRange(e,{row:0,col:o,rowCount:e.getRowCount(),colCount:n}),i=rapidUtils.chunkJson(r,2*a),h=[];for(let e=0;e<i.length;e++)h.push(rapidUtils.chunkJson(i[e],2));let c=[];for(let t=0;t<s.length;t++){const l=s[t];for(let o=0;o<l.length;o++){const n=l[o];c.push({title:e.getValue(h[t][o][0].row,h[t][o][0].col),fieldName:n.fieldName,value:e.getValue(h[t][o][1].row,h[t][o][1].col)})}}return e.resumePaint(),c}};function __awaiter(e,t,l,o){return new(l||(l=Promise))(function(n,a){function s(e){try{i(o.next(e))}catch(e){a(e)}}function r(e){try{i(o.throw(e))}catch(e){a(e)}}function i(e){var t;e.done?n(e.value):(t=e.value,t instanceof l?t:new l(function(e){e(t)})).then(s,r)}i((o=o.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;const CommonUtils={getFileBlob:e=>__awaiter(void 0,void 0,void 0,function*(){const t=yield fetch(e,{method:"GET"});if(t.ok){return yield t.blob()}return null}),getColLetterName:e=>{e+=1;let t="";for(;e>0;){const l=(e-1)%26;t=String.fromCharCode(l+65)+t,e=Math.floor((e-1)/26)}return t.toUpperCase()}},EChartsUtilsComm={getRound:(e,t)=>{const l=e<0;if(l&&(e=Math.abs(e)),0==t){let t=e.toString();if(-1==t.indexOf("."))return l?-e:e;let o=parseInt(t.split(".")[0]),n=t.split(".")[1];return parseFloat(`0.${n}`)>=.5?l?-(o+1):o+1:l?-o:o}let o=1/t;const n=(e=>{let t=e.toString();if(-1==t.indexOf("."))return e;let l=parseInt(t.split(".")[0]),o=t.split(".")[1],n=parseInt(o.substring(0,1));return n>=6?l+1:n<=4?l:5==n&&1==o.length?l%2!=0?l+1:l:5==n&&o.length>1?l+1:e})(Number((e*o).toFixed(8)))/o;let a=t+"";if(-1==a.indexOf("."))return l?-n:n;{const e=n+"";let t="";if(-1==e.indexOf(".")){let e="";for(let t=0;t<a.split(".")[1].length;t++)e+="0";return(l?"-":"")+`${n}.${e}`}{const o=e.split(".")[1];if(a.split(".")[1].length>o.length)for(let e=0;e<a.split(".")[1].length-o.length;e++)t+="0";return(l?"-":"")+`${n}${t}`}}},calcTrend:(e,t,l)=>{let o=e.length,n=0,a=0,s=0,r=0;for(let l=0;l<o;l++)n+=e[l],a+=t[l],s+=e[l]*t[l],r+=e[l]*e[l];let i=(o*s-n*a)/(o*r-n*n),h=(a-i*n)/o;return i+""=="NaN"?{y:"",gs:"",xl:"",jj:""}:{y:i*l+h,gs:`${i}*x+${h}`,xl:i,jj:h}},filterNullEmptyErrArray:e=>e.filter(e=>null!=e&&null!=e&&(null==e._error||null==e._error)&&"/"!=e)},EChartsUtilsAll={chart10:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,g=Number(EChartsUtilsComm.getRound(p+.05,.01)),x=Number(EChartsUtilsComm.getRound(d-.05,.01)),S=[],w=[];h.forEach((e,t)=>{w.push([e,c[t]])});const b=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),C=math__namespace.transpose(b),E=math__namespace.multiply(C,b),A=math__namespace.multiply(C,math__namespace.matrix(c));let N=null,v=[];try{N=math__namespace.lusolve(E,A),v=N.valueOf()}catch(e){for(let e=0;e<h.length;e++)v.push([0])}function L(e){let t=0;return v.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let J=[],j=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));j.push(L(t)),J.push(t)}let M=Math.max(...j),_=j.findIndex(e=>e===M),z=e.chartXName,O=e.chartYName;J.forEach((e,t)=>{h.includes(e)?S.push({value:[e,j[t]]}):S.push({value:[e,j[t]],symbol:"none"})});const q=[J[_],Number(EChartsUtilsComm.getRound(M,.001))],U=[q[0],x];null!=a&&(null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,u),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,m)),null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,J[_]));let R=[],T=[];R=[[{coord:U,lineStyle:{color:"#333",type:"dashed"}},{coord:q}]],T=[{xAxis:q[0],yAxis:q[1],symbolOffset:[0,15],label:{show:!0,color:"#000",formatter:function(e){return 0==Number(e.data.xAxis)&&0==Number(e.data.yAxis)?"":"( "+e.data.xAxis+","+e.data.yAxis+")"}},itemStyle:{color:"transparent"}},{xAxis:q[0],yAxis:x,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a1"}},itemStyle:{color:"transparent"}}];let V=!1;return S.forEach(e=>{V=e.value.every(e=>0==e)}),V&&(y=null,f=null,x=null,g=null,S=[]),{grid:{top:10,left:V?25:30,right:10,bottom:V?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:z,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:g,min:x,name:O,nameGap:V?5:40,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:T},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:R}}]}},chart11:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,g=Math.ceil(p+2),x=Math.floor(d-2),S=[],w=null,b=7.5;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}}null!=w&&w>g&&(g=w+2),null!=b&&b>g&&(x=b-2);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],_=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));_.push(j(t)),M.push(t)}let z=Math.max(..._),O=_.findIndex(e=>e===z),q=e.chartXName,U=e.chartYName;function R(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function T(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}M.forEach((e,t)=>{h.includes(e)?S.push({value:[e,_[t]]}):S.push({value:[e,_[t]],symbol:"none"})});let V=[],W=[],k=[],D=[];M.forEach((e,t)=>{if(t>0){if(null!=w&&R(_[t-1],_[t],w,w)){let e=T(_[t-1],_[t],w);V.push([M[t+e],_[t+e]]),_[t-1]>_[t]?k.push(0):k.push(1)}if(null!=b&&R(_[t-1],_[t],b,b)){let e=T(_[t-1],_[t],b);W.push([M[t+e],_[t+e]]),_[t-1]>_[t]?D.push(0):D.push(1)}}});let P=u,H=m;0==V.length&&W.length>0?0==D[0]?(P=u,H=W[0][0]):(P=W[0][0],H=1==W.length?m:W[1][0]):V.length>0&&0==W.length?0==k[0]?(P=V[0][0],H=1==V.length?m:V[1][0]):(P=u,H=V[0][0]):V.length>0&&W.length>0&&(0==k[0]?(P=V[0][0],H=W[0][0]):(P=W[0][0],H=V[0][0])),null!=a&&(null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,P),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,H)),null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,M[O]));const $=[M[O],Number(EChartsUtilsComm.getRound(z,.001))];let B=[],X=[];B=[[{coord:[$[0],x],lineStyle:{color:"#333",type:"dashed"}},{coord:$}]],X=[{xAxis:$[0],yAxis:$[1],symbolOffset:[0,15],label:{show:!0,color:"#000",formatter:function(e){return 0==Number(e.data.xAxis)&&0==Number(e.data.yAxis)?"":"( "+e.data.xAxis+","+e.data.yAxis+")"}},itemStyle:{color:"transparent"}},{xAxis:$[0],yAxis:x,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a2"}},itemStyle:{color:"transparent"}}],null!=w&&B.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]),null!=b&&B.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]);let Y=!1;return S.forEach(e=>{Y=e.value.every(e=>0==e)}),Y&&(y=null,f=null,x=null,g=null,S=[]),{grid:{top:10,left:Y?25:30,right:10,bottom:Y?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:q,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:g,min:x,name:U,nameGap:Y?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:X},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:B}}]}},chart12:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,g=Math.ceil(p+2),x=Math.floor(d-2),S=[],w=5,b=3;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}}null!=w&&w>g&&(g=w+2),null!=b&&b>g&&(x=b-2);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],_=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));_.push(j(t)),M.push(t)}let z=e.chartXName,O=e.chartYName;function q(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}let R=[],T=[],V=[],W=[];M.forEach((e,t)=>{if(h.includes(e)?S.push({value:[e,_[t]]}):S.push({value:[e,_[t]],symbol:"none"}),t>0){if(null!=w&&q(_[t-1],_[t],w,w)){let e=U(_[t-1],_[t],w);R.push([M[t+e],_[t+e]]),_[t-1]>_[t]?V.push(0):V.push(1)}if(null!=b&&q(_[t-1],_[t],b,b)){let e=U(_[t-1],_[t],b);T.push([M[t+e],_[t+e]]),_[t-1]>_[t]?W.push(0):W.push(1)}}});let k=u,D=m;0==R.length&&T.length>0?0==W[0]?(k=u,D=T[0][0]):(k=T[0][0],D=1==T.length?m:T[1][0]):R.length>0&&0==T.length?0==V[0]?(k=R[0][0],D=1==R.length?m:R[1][0]):(k=u,D=R[0][0]):R.length>0&&T.length>0&&(0==V[0]?(k=R[0][0],D=T[0][0]):(k=T[0][0],D=R[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,k),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,D));let P=[],H=[];if(R.length>0&&R.forEach((e,t)=>{P.push([{coord:[e[0],x],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],w]}])}),T.length>0&&T.forEach((e,t)=>{P.push([{coord:[e[0],x],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],b]}])}),1==R.length&&1==T.length){const e=((R[0][0]+T[0][0])/2).toFixed(2),t=M.findIndex(t=>t==e);null!=a&&null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,e),P.push([{coord:[e,x],lineStyle:{color:"#333",type:"dashed"}},{coord:[e,_[t]]}]),H.push({xAxis:e,yAxis:x,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a3"}},itemStyle:{color:"transparent"}})}null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]),null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]);let $=!1;return S.forEach(e=>{$=e.value.every(e=>0==e)}),$&&(y=null,f=null,x=null,g=null,S=[]),{grid:{top:10,left:$?25:30,right:10,bottom:$?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:z,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:g,min:x,name:O,nameGap:$?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:H},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart13:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,g=Math.ceil(p+1),x=Math.floor(d-1),S=[],w=null,b=2;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}}null!=w&&w>g&&(g=w+1),null!=b&&b>g&&(x=b-1);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],_=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));_.push(j(t)),M.push(t)}let z=e.chartXName,O=e.chartYName;function q(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}M.forEach((e,t)=>{h.includes(e)?S.push({value:[e,_[t]]}):S.push({value:[e,_[t]],symbol:"none"})});let R=[],T=[],V=[],W=[];M.forEach((e,t)=>{if(t>0){if(null!=w&&q(_[t-1],_[t],w,w)){let e=U(_[t-1],_[t],w);R.push([M[t+e],_[t+e]]),_[t-1]>_[t]?V.push(0):V.push(1)}if(null!=b&&q(_[t-1],_[t],b,b)){let e=U(_[t-1],_[t],b);T.push([M[t+e],_[t+e]]),_[t-1]>_[t]?W.push(0):W.push(1)}}});let k=u,D=m;0==R.length&&T.length>0?0==W[0]?(k=u,D=T[0][0]):(k=T[0][0],D=1==T.length?m:T[1][0]):R.length>0&&0==T.length?0==V[0]?(k=R[0][0],D=1==R.length?m:R[1][0]):(k=u,D=R[0][0]):R.length>0&&T.length>0&&(0==V[0]?(k=R[0][0],D=T[0][0]):(k=T[0][0],D=R[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,k),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,D));let P=[],H=[];P=[],H=[],null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]),null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]);let $=!1;return S.forEach(e=>{$=e.value.every(e=>0==e)}),$&&(y=null,f=null,x=null,g=null,S=[]),{grid:{top:10,left:$?25:30,right:10,bottom:$?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:z,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:g,min:x,name:O,nameGap:$?5:25,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:H},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart14:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,g=Math.ceil(p+1),x=Math.floor(d-1),S=[],w=null,b=13.5;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}}null!=w&&w>g&&(g=w+1),null!=b&&b>g&&(x=b-1);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],_=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));_.push(j(t)),M.push(t)}let z=e.chartXName,O=e.chartYName;function q(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}M.forEach((e,t)=>{h.includes(e)?S.push({value:[e,_[t]]}):S.push({value:[e,_[t]],symbol:"none"})});let R=[],T=[],V=[],W=[];M.forEach((e,t)=>{if(t>0){if(null!=w&&q(_[t-1],_[t],w,w)){let e=U(_[t-1],_[t],w);R.push([M[t+e],_[t+e]]),_[t-1]>_[t]?V.push(0):V.push(1)}if(null!=b&&q(_[t-1],_[t],b,b)){let e=U(_[t-1],_[t],b);T.push([M[t+e],_[t+e]]),_[t-1]>_[t]?W.push(0):W.push(1)}}});let k=u,D=m;0==R.length&&T.length>0?0==W[0]?(k=u,D=T[0][0]):(k=T[0][0],D=1==T.length?m:T[1][0]):R.length>0&&0==T.length?0==V[0]?(k=R[0][0],D=1==R.length?m:R[1][0]):(k=u,D=R[0][0]):R.length>0&&T.length>0&&(0==V[0]?(k=R[0][0],D=T[0][0]):(k=T[0][0],D=R[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,k),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,D));let P=[],H=[];P=[],H=[],null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]),null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]);let $=!1;return S.forEach(e=>{$=e.value.every(e=>0==e)}),$&&(y=null,f=null,x=null,g=null,S=[]),{grid:{top:10,left:$?25:30,right:10,bottom:$?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:z,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:g,min:x,name:O,nameGap:$?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:H},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart15:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=t[0],r=l[0],i=null!=a?a.dxsJs:5,h=[],c=[];if(s.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?h.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,h.push(e))}),r.forEach((e,t)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)?c.push(e):"/"!=e&&null!=e&&null!=e&&""!=e||(e=0,c.push(e))}),0==c.length)return;h.forEach(e=>{}),i>=c.length&&(i=c.length-1);let u=Math.min(...h),m=Math.max(...h),d=Math.min(...c),p=Math.max(...c),f=m,y=u,g=Math.ceil(p+10),x=Math.floor(d-10),S=[],w=75,b=60;if(null!=a){if(null!=a.lqhhlSx&&null!=a.lqhhlSx){const e=o.getValue(a.lqhhlSx.row,a.lqhhlSx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(w=e)}if(null!=a.lqhhlXx&&null!=a.lqhhlXx){const e=o.getValue(a.lqhhlXx.row,a.lqhhlXx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(b=e)}}null!=w&&w>g&&(g=w+10),null!=b&&b>g&&(x=b-10);let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],_=[];for(let e=u;e<=m;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));_.push(j(t)),M.push(t)}let z=e.chartXName,O=e.chartYName;function q(e,t,l,o){return e>=l&&t<=o||e<=l&&t>=o}function U(e,t,l){return Math.abs(e-l)>Math.abs(t-l)?0:-1}let R=[],T=[],V=[],W=[];M.forEach((e,t)=>{if(h.includes(e)?S.push({value:[e,_[t]]}):S.push({value:[e,_[t]],symbol:"none"}),t>0){if(null!=w&&q(_[t-1],_[t],w,w)){let e=U(_[t-1],_[t],w);R.push([M[t+e],_[t+e]]),_[t-1]>_[t]?V.push(0):V.push(1)}if(null!=w&&q(_[t-1],_[t],b,b)){let e=U(_[t-1],_[t],b);T.push([M[t+e],_[t+e]]),_[t-1]>_[t]?W.push(0):W.push(1)}}});let k=u,D=m;0==R.length&&T.length>0?0==W[0]?(k=u,D=T[0][0]):(k=T[0][0],D=1==T.length?m:T[1][0]):R.length>0&&0==T.length?0==V[0]?(k=R[0][0],D=1==R.length?m:R[1][0]):(k=u,D=R[0][0]):R.length>0&&T.length>0&&(0==V[0]?(k=R[0][0],D=T[0][0]):(k=T[0][0],D=R[0][0])),null!=a&&null!=a.lqhhlKs&&null!=a.lqhhlKs&&(o.setValue(a.lqhhlKs.row,a.lqhhlKs.col,k),o.setValue(a.lqhhlJs.row,a.lqhhlJs.col,D));let P=[],H=[];if(R.length>0&&R.forEach((e,t)=>{P.push([{coord:[e[0],x],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],w]}])}),T.length>0&&T.forEach((e,t)=>{P.push([{coord:[e[0],x],lineStyle:{color:"#333",type:"dashed"}},{coord:[e[0],b]}])}),1==R.length&&1==T.length){const e=((R[0][0]+T[0][0])/2).toFixed(2),t=M.findIndex(t=>t==e);null!=a&&null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,e),P.push([{coord:[e,x],lineStyle:{color:"#333",type:"dashed"}},{coord:[e,_[t]]}]),H.push({xAxis:e,yAxis:x,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"a4"}},itemStyle:{color:"transparent"}})}null!=w&&P.push([{coord:[y,w],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,w]}]),null!=b&&P.push([{coord:[y,b],lineStyle:{color:"#333",type:"dashed"}},{coord:[f,b]}]);let $=!1;return S.forEach(e=>{$=e.value.every(e=>0==e)}),$&&(y=null,f=null,x=null,g=null,S=[]),{grid:{top:10,left:$?25:30,right:10,bottom:$?20:16,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:z,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:f,min:y,data:h,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:g,min:x,name:O,nameGap:$?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:S,markPoint:{data:H},markLine:{symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:P}}]}},chart16:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=[[o.getValue(a.lqhhlHz[0].row,a.lqhhlHz[0].col),o.getValue(a.lqhhlHz[1].row,a.lqhhlHz[1].col)],[o.getValue(a.lqhhlHz[2].row,a.lqhhlHz[2].col),o.getValue(a.lqhhlHz[3].row,a.lqhhlHz[3].col)],[o.getValue(a.lqhhlHz[4].row,a.lqhhlHz[4].col),o.getValue(a.lqhhlHz[5].row,a.lqhhlHz[5].col)],[o.getValue(a.lqhhlHz[6].row,a.lqhhlHz[6].col),o.getValue(a.lqhhlHz[7].row,a.lqhhlHz[7].col)],[o.getValue(a.lqhhlHz[8].row,a.lqhhlHz[8].col),o.getValue(a.lqhhlHz[9].row,a.lqhhlHz[9].col)],[o.getValue(a.lqhhlHz[10].row,a.lqhhlHz[10].col),o.getValue(a.lqhhlHz[11].row,a.lqhhlHz[11].col)]],r=t[0],i=5.5,h=3.5,c=0,u=6,m=["VFA","VMA","流值","稳定度","空隙率","密度"];let d=[],p=[],f=Math.max(...s.map(e=>e[0])),y=Math.min(...s.map(e=>e[1]));if(s.forEach((e,t)=>{d.push([{coord:[e[0],s.length-t],lineStyle:{color:n[0].lineColor,type:"solid",width:2}},{coord:[e[1],s.length-t]}])}),f<=y&&(d.push([{coord:[f,0],lineStyle:{color:"#333",type:"dashed",width:2}},{coord:[f,6]}]),d.push([{coord:[y,0],lineStyle:{color:"#333",type:"dashed",width:2}},{coord:[y,6]}]),p=[{xAxis:f,yAxis:0,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"OACmin"}},itemStyle:{color:"transparent"}},{xAxis:y,yAxis:0,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"OACmax"}},itemStyle:{color:"transparent"}}]),f<=y){const e=(f+y)/2;d.push([{coord:[e,0],lineStyle:{color:"#333",type:"dashed",width:2}},{coord:[e,6]}]),p.push({xAxis:e,yAxis:0,symbolOffset:[0,40],label:{show:!0,color:"#000",formatter:function(e){return"OAC2"}},itemStyle:{color:"transparent"}})}isNaN(f)&&(f=0),isNaN(y)&&(y=0),null!=a&&(null!=a.lqhhlSc1&&null!=a.lqhhlSc1&&o.setValue(a.lqhhlSc1.row,a.lqhhlSc1.col,f),null!=a.lqhhlSc2&&null!=a.lqhhlSc2&&o.setValue(a.lqhhlSc2.row,a.lqhhlSc2.col,y));let g=!1;return s.forEach(e=>{g=e.every(e=>"/"==e)}),g&&(h=null,i=null,c=null,u=null),{grid:{top:25,left:10,right:10,bottom:g?20:16,containLabel:!0},title:[{show:!0,text:"OAC",left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:"油石比(%)",left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:i,min:h,data:r,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:u,min:c,axisLabel:{formatter:function(e){return 0==e?"":m[e-1]}}}],series:[{name:"图例1",type:"line",markPoint:{data:p},markLine:{symbol:["none","none"],data:d}}]}},chart30:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);null==a||null!=a.jsIsJz&&null!=a.jsIsJz||(a.jsIsJz=!0);let s=2==t.length,r=t[0],i=s?t[1]:[],h=l[0],c=s?l[1]:[],u=e.chartTitle,m=e.chartXName,d=e.chartYName;const p=(e,t,l,s,r)=>{let i=null!=a?a.dxsJs:5,h=[],c=[],u=[];if(e.forEach((e,l)=>{/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&0!=e&&/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(t[l])&&0!=t[l]&&(h.push(e),c.push(t[l]))}),0==c.length)return;i>=c.length&&(i=c.length-1);let m,d,p=Math.min(...h),f=Math.max(...h),y=Math.min(...c),g=Math.max(...c),x=Math.ceil(f+.1),S=Math.trunc(p-.1),w=Number(EChartsUtilsComm.getRound(g+.02,.01)),b=Number(EChartsUtilsComm.getRound(y-.02,.01));null!=a&&a.jsIsJz&&(null!=a.jsZjhslJz&&null!=a.jsZjhslJz&&(m=o.getValue(a.jsZjhslJz.row,a.jsZjhslJz.col)),null!=a.jsZdgmdJz&&null!=a.jsZdgmdJz&&(d=o.getValue(a.jsZdgmdJz.row,a.jsZdgmdJz.col)),/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(d)&&d>w&&(w=Number(EChartsUtilsComm.getRound(d+.02,.01))));let C=[];h.forEach((e,t)=>{C.push([e,c[t]])});const E=function(e,t){const l=[];for(let o=0;o<e.length;o++){const n=[];for(let l=0;l<=t;l++)n.push(math__namespace.pow(e[o],l));l.push(n)}return math__namespace.matrix(l)}(h,i),A=math__namespace.transpose(E),N=math__namespace.multiply(A,E),v=math__namespace.multiply(A,math__namespace.matrix(c));let L=null,J=[];try{L=math__namespace.lusolve(N,v),J=L.valueOf()}catch(e){for(let e=0;e<h.length;e++)J.push([0])}function j(e){let t=0;return J.forEach((l,o)=>{t+=l*Math.pow(e,o)}),t}let M=[],_=[];for(let e=p;e<=f;e+=.01){let t=Number(EChartsUtilsComm.getRound(e,.01));e=Number(t),_.push(j(t)),M.push(t)}let z=Math.max(..._),O=_.findIndex(e=>e===z),q=.01,U=.001,R=0,T=0;null!=a&&(null!=a.jsZjhslJd&&null!=a.jsZjhslJd&&(q=a.jsZjhslJd),null!=a.jsZdgmdJd&&null!=a.jsZdgmdJd&&(U=a.jsZdgmdJd),0==M[O]&&0==z?(o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,"/"),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,"/")):(R=EChartsUtilsComm.getRound(M[O],q),T=EChartsUtilsComm.getRound(z,U),o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,R),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,T))),M.forEach((e,t)=>{h.includes(e)?u.push({value:[e,_[t]]}):u.push({value:[e,_[t]],symbol:"none"})});const V=[M[O],Number(EChartsUtilsComm.getRound(z,U))],W=[V[0],b],k=[S,V[1]];let D={data:[{xAxis:EChartsUtilsComm.getRound(V[0],q),yAxis:EChartsUtilsComm.getRound(V[1],U),symbolOffset:[0,15],symbol:"circle",symbolSize:6,label:{show:!0,color:"#000",formatter:function(e){return 0==Number(e.data.xAxis)&&0==Number(e.data.yAxis)?"":"( "+e.data.xAxis+","+e.data.yAxis+")"}},itemStyle:{color:"transparent"}}]},P={symbol:["none","none"],itemStyle:{lineStyle:{type:"solid",color:"#333",width:2}},data:[[{coord:W,lineStyle:{color:"#333",type:"dashed"}},{coord:V}],[{coord:k,lineStyle:{color:"#333",type:"dashed"}},{coord:V}]]};a.jsIsJz&&/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(m)&&/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(d)&&(P=null,D.data[0].label=null,D.data[0].symbolOffset=null,D.data[0].itemStyle.color="#F56C6C",D.data[0].xAxis=m,D.data[0].yAxis=d,P=null);let H={name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[r?1:0].lineColor,type:r?"dotted":"solid"},itemStyle:{color:n[r?1:0].lineColor},data:u,markPoint:l?D:null,markLine:s?P:null};return{xAxisMin:S,xAxisMax:x,yAxisMin:b,yAxisMax:w,xData:h,seriesDataObj:H,maxPointData:[M[O],z]}};let f,y=0,g=0,x=0,S=0,w=[],b=[],C=0,E=0,A=p(r,h,!s,!s,!1);if(s&&(f=p(i,c,!1,!1,!0)),null==A||null==A)return;if(s){if(null==f||null==f)return;g=A.xAxisMax,f.xAxisMax>g&&(g=f.xAxisMax),y=A.xAxisMin,f.xAxisMin<y&&(y=f.xAxisMin),S=A.yAxisMax,f.yAxisMax>S&&(S=f.yAxisMax),x=A.yAxisMin,f.yAxisMin<x&&(x=f.yAxisMin),A.xData.forEach(e=>{w.push(e)}),f.xData.forEach(e=>{w.push(e)}),b.push(A.seriesDataObj),b.push(f.seriesDataObj),C=(A.maxPointData[0]+f.maxPointData[0])/2,E=(A.maxPointData[1]+f.maxPointData[1])/2;let e=.01,t=.001,l=0,n=0;null!=a&&(null!=a.jsZjhslJd&&null!=a.jsZjhslJd&&(e=a.jsZjhslJd),null!=a.jsZdgmdJd&&null!=a.jsZdgmdJd&&(t=a.jsZdgmdJd),0==C&&0==E?(o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,"/"),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,"/")):(l=EChartsUtilsComm.getRound(C,e),n=EChartsUtilsComm.getRound(E,t),o.setValue(a.jsZjhsl.row,a.jsZjhsl.col,l),o.setValue(a.jsZdgmd.row,a.jsZdgmd.col,n)))}else y=A.xAxisMin,g=A.xAxisMax,x=A.yAxisMin,S=A.yAxisMax,w=A.xData,b.push(A.seriesDataObj);let N=!1;return b.forEach(e=>{N=e.data[0].value.every(e=>0==e)}),N&&(y=null,g=null,x=null,S=null,b=[]),{grid:{top:25,left:N?25:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+Number(EChartsUtilsComm.getRound(e[0].value[1],.001)):e[0].data}},title:[{show:!0,text:u,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:m,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",max:g,min:y,data:w,axisTick:{alignWithLabel:!0},splitLine:{show:!0}},yAxis:[{type:"value",max:S,min:x,name:d,nameGap:N?5:40,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:b}},chart50:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartXName,a=e.chartYName;const s=t[0],r=l[0],i=l[1],h=l[2],c=[];s.forEach((e,t)=>{c.push({x:e,y:r[t],ySx:i[t],yXx:h[t]})}),c.sort(function(e,t){return e.x-t.x});const u=[],m=[],d=[],p=[];let f=0;i.forEach((e,t)=>{null!=e&&"/"!=e||f++}),f==i.length?c.forEach((e,t)=>{u.push(e.x),m.push(e.y),d.push(e.ySx),p.push(e.yXx)}):c.forEach((e,t)=>{null!=e.ySx&&"/"!=e.ySx&&null!=e.yXx&&"/"!=e.yXx&&(u.push(e.x),m.push(e.y),d.push(e.ySx),p.push(e.yXx))});let y=[],g=[],x=[],S=[];u.forEach((e,t)=>{const l=Number(EChartsUtilsComm.getRound(Math.pow(e,.45),.001));y.push([l,m[t]]),S.push({name:e+"",xAxis:l,label:{show:!(u.length>=6&&t%2!=0&&t<6),fontSize:10}}),g.push([l,d[t]]),x.push([l,p[t]])});const w=(e,t)=>{const l=1==e?"筛分曲线":2==e?"上限":"下限",n=1==e?"rect":2==e?"triangle":"circle",a=1==e?"solid":2==e?"dotted":[10,5],s=1==e?o[0].lineColor:2==e?o[1].lineColor:o[2].lineColor;let r={name:l,type:"line",smooth:!0,symbol:n,symbolSize:5,z:10,lineStyle:{color:s,type:a},itemStyle:{color:s},data:t,connectNulls:!0,markLine:{symbol:"",silent:!0,label:{position:"start",formatter:e=>e.name},lineStyle:{color:"#e0e6f1",type:"solid"},data:S}};return r};let b=!1;0==y.length&&(b=!0);let C=0;return y.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||C++}),C==y.length&&(b=!0),(i.some(e=>null!=e&&null!=e&&"/"!=e)||h.some(e=>null!=e&&null!=e&&"/"!=e))&&(b=!1),{grid:{top:20,left:b?25:30,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){if(e&&e[0].data.length>1){let t=S.filter(t=>t.xAxis==e[0].data[0]);return e[0].seriesName+"("+t[0].name+"):"+e[0].data[1]}return e[0].data}},title:[{show:!0,text:"",left:"center",top:5,textStyle:{fontSize:18,fontWeight:"normal"}},{show:!0,text:n,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{left:"center",data:["筛分曲线","上限","下限"],selected:{"筛分曲线":!0,"上限":!0,"下限":!0},selectedMode:"multiple"},xAxis:{type:"value",axisTick:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},min:y.length>0?y[0][0]>.2?y[0][0]-.2:0:null,max:y.length>0?y[y.length-1][0]+.1:null},yAxis:[{type:"value",name:a,nameGap:b?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},splitNumber:10,axisLabel:{fontSize:10}}],series:[w(1,y),w(2,g),w(3,x)]}},chart70:(e,t,l,o)=>{JSON.parse(e.chartLinesJson);const n=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);if(t[0].some(e=>null==e||""==e||null==e)||l[0].some(e=>null==e||""==e||null==e))return{};let a=e.chartTitle,s=e.chartXName,r=e.chartYName,i=t[0],h=l[0],c=100,u="砂类土",m=[],d=[];if(null!=n){let e=o.getValue(n.jxhslZtzl.row,n.jxhslZtzl.col),t=o.getValue(n.jxhslCllx.row,n.jxhslCllx.col);/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(e)&&(e=Number(e),100!=e&&76!=e||(c=e)),"砂类土"!=t&&"细粒土"!=t||(u=t)}for(const e of i)m.push(Math.log(e));for(const e of h)d.push(Math.log(e));let p=(d[2]-d[1])/(m[2]-m[1]),f=(d[2]-d[0])/(m[2]-m[0]);const y=Math.max.apply(Math,i)+1,g=Math.min.apply(Math,i)-.3,x=Math.max.apply(Math,h)+1,S=Math.min.apply(Math,h)-2,w=["C","B","A"],b=[];function C(e,t,l){const o=Math.log(e[0]),n=Math.log(e[1]),a=Math.log(t[0]),s=n+(Math.log(t[1])-n)/(a-o)*(Math.log(l)-o);return Math.exp(s)}i.forEach((e,t)=>{b.push([e,h[t],w[t]])});let E=[20,C([i[2],h[2]],[i[1],h[1]],20)],A=[20,C([i[2],h[2]],[i[0],h[0]],20)];function N(e){let t;return t="砂类土"==u?29.6-1.22*e+.017*e*e-744e-7*e*e*e:e/(.524*e-7.606),t}let v,L,J,j=[],M=[],_=[],z=N(i[2]),O=Math.log(z),q=(p*m[2]-(d[2]-O))/p,U=(f*m[2]-(d[2]-O))/f,R=Math.exp((q+U)/2),T=Math.log(R),V=(d[2]-O)/(m[2]-T);if(76==c){let e=Math.log(17),t=(V*m[2]-(d[2]-e))/V,l=Math.exp(t),o=Math.log(2),n=(V*m[2]-(d[2]-o))/V,a=Math.exp(n);_=[R,z],j=[R,S],M=[g,z],b.push([R,z,"Hp"]),v=z,L=l,J=a}else if(100==c){let e=Math.log(20),t=(V*m[2]-(d[2]-e))/V,l=Math.exp(t),o=N(l),n=Math.log(o),a=(p*m[2]-(d[2]-n))/p,s=(f*m[2]-(d[2]-n))/f,r=Math.exp((a+s)/2),i=r;_=[r,o],j=[r,S],M=[g,o],b.push([r,o,"Hp"]),v=o,L=l,J=i}if((isNaN(v)||isNaN(L)||isNaN(J))&&(v=0,L=0,J=0),null!=n){let e=.01,t=.01,l=.01;null!=n.jxhslScHpJd&&null!=n.jxhslScHpJd&&(e=n.jxhslScHpJd),null!=n.jxhslScWlJd&&null!=n.jxhslScWlJd&&(t=n.jxhslScWlJd),null!=n.jxhslScWpJd&&null!=n.jxhslScWpJd&&(l=n.jxhslScWpJd),null!=n.jxhslScHp&&null!=n.jxhslScHp&&(0==v?o.setValue(n.jxhslScHp.row,n.jxhslScHp.col,"/"):o.setValue(n.jxhslScHp.row,n.jxhslScHp.col,EChartsUtilsComm.getRound(v,e))),null!=n.jxhslScWl&&null!=n.jxhslScWl&&(0==L?o.setValue(n.jxhslScWl.row,n.jxhslScWl.col,"/"):o.setValue(n.jxhslScWl.row,n.jxhslScWl.col,EChartsUtilsComm.getRound(L,t))),null!=n.jxhslScWp&&null!=n.jxhslScWp&&(0==J?o.setValue(n.jxhslScWp.row,n.jxhslScWp.col,"/"):o.setValue(n.jxhslScWp.row,n.jxhslScWp.col,EChartsUtilsComm.getRound(J,l)))}let W=!1;0==i.length&&(W=!0);let k=0;return i.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||k++}),k==i.length&&(W=!0),(h.some(e=>null!=e&&null!=e&&"/"!=e)||h.some(e=>null!=e&&null!=e&&"/"!=e))&&(W=!1),{grid:{top:20,left:W?25:50,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+e[0].value[1]:e[0].data}},title:[{show:!0,text:a,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:s,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"log",min:g,max:y,interval:0,axisTick:{show:!1,alignWithLabel:!0},splitLine:{show:!1},axisLabel:{show:!1}},yAxis:{type:"log",name:r,nameGap:W?5:30,nameRotate:90,nameLocation:"middle",min:S,max:x,interval:0,axisTick:{show:!1,alignWithLabel:!0},splitLine:{show:!1},axisLabel:{show:!1}},series:[{name:"图例1",data:b,type:"scatter",symbol:"circle",smooth:!1,symbolSize:6,label:{show:!0,formatter:function(e){return e.data[2]},position:"right",minMargin:2},markLine:{symbol:["none","none"],silent:!0,label:{show:!0,position:"start",color:"#000000"},lineStyle:{type:"solid",color:"#333"},data:[{xAxis:b[0][0]},{xAxis:b[1][0]},{xAxis:b[2][0]},{yAxis:b[0][1]},{yAxis:b[1][1]},{yAxis:b[2][1]},[{coord:j,lineStyle:{color:"#333",type:"dashed"}},{coord:_}],[{coord:M,lineStyle:{color:"#333",type:"dashed"}},{coord:_}]]}},{type:"line",data:[[i[2],h[2]],[i[1],h[1]]],lineStyle:{color:"#0000FF",type:"solid",width:1},symbol:"none"},{type:"line",data:[[i[1],h[1]],[E[0],E[1]]],lineStyle:{color:"#000000",type:"dashed",width:1},symbol:"none"},{type:"line",data:[[i[2],h[2]],[i[0],h[0]]],lineStyle:{color:"#0000FF",type:"solid",width:1},symbol:"none"},{type:"line",data:[[i[0],h[0]],[A[0],A[1]]],lineStyle:{color:"#000000",type:"dashed",width:1},symbol:"none"},{type:"line",data:[[i[2],h[2]],_],lineStyle:{color:"#0000FF",type:"solid",width:1},symbol:"none"}]}},chart90:(config,xDataArr,yDataArr,sheet)=>{let lineData=JSON.parse(config.chartLinesJson);const chartExtJson=null==config.chartExtJson||null==config.chartExtJson?null:JSON.parse(config.chartExtJson);let yDataSource=yDataArr[0],title=config.chartTitle,xName=config.chartXName,yName=config.chartYName,legendName="图例1",xData=xDataArr[0],xDataCl=[],yDataSourceCl=[];for(let e=0;e<xData.length;e++)if("/"!=xData[e]&&(0==e||e>0&&0!=xData[e]))xDataCl.push(xData[e]),yDataSourceCl.push(yDataSource[e]);else if(e>0&&0==xData[e])break;xData=xDataCl,yDataSource=yDataSourceCl;let seriesData=[],markPointData=[],markLineData=[...xData];const gsS=EChartsUtilsComm.calcTrend(xData,yDataSource,xData[0]);null!=chartExtJson&&null!=chartExtJson.jxhslSnShScfc&&null!=chartExtJson.jxhslSnShScfc&&(""==gsS.xl||""==gsS.jj?sheet.setValue(chartExtJson.jxhslSnShScfc.row,chartExtJson.jxhslSnShScfc.col,"/"):sheet.setValue(chartExtJson.jxhslSnShScfc.row,chartExtJson.jxhslSnShScfc.col,`Y=${EChartsUtilsComm.getRound(gsS.xl,1e-4)}X+${EChartsUtilsComm.getRound(gsS.jj,1e-4)}`));let yDataCopy=[];xData.forEach((item,index)=>{let curYData=Number(EChartsUtilsComm.getRound(eval(gsS.gs.replace("x",item+"")),.01));isNaN(curYData)&&(curYData=0),seriesData.push([item,curYData]),yDataCopy.push(curYData),markPointData.push({xAxis:item,yAxis:yDataSource[index],symbol:"circle",symbolSize:6})});let yValIsAllNull=!1;0==xData.length&&(yValIsAllNull=!0);let nullCount=0;xData.forEach(e=>{0!=e[1]&&null!=e[1]&&null!=e[1]||nullCount++}),nullCount==xData.length&&(yValIsAllNull=!0),yDataCopy.some(e=>0!=e||null==e[1]||null==e[1])&&(yValIsAllNull=!1);let option={grid:{top:22,left:yValIsAllNull?25:30,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].value[0]+":"+e[0].value[1]:e[0].data}},title:[{show:!0,text:title,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:xName,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:[legendName],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1}},yAxis:[{type:"value",name:yName,nameGap:yValIsAllNull?5:30,nameRotate:90,nameLocation:"middle"}],series:[{name:legendName,type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:lineData[0].lineColor,type:"dotted"},itemStyle:{color:lineData[0].lineColor,opacity:0},data:seriesData,markPoint:{data:markPointData},markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value},lineStyle:{color:"#ddd",type:"solid"},data:markLineData.map(e=>({xAxis:e}))}}]};return option},chart110:(e,t,l,o,n)=>{let a=JSON.parse(e.chartLinesJson),s=e.chartTitle,r=e.chartXName,i=e.chartYName;const h=o[0];let c=[];h.forEach((e,t)=>{"/"==e?c.push(e):c.push(Number(e))});let u=l[0],m=[];c.forEach((e,t)=>{"/"!=e&&null!=e&&null!=e&&m.push([e,u[t]])});let d=!1;return 0==m.length&&(d=!0),{grid:{top:25,left:25,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:s,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:r,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",axisTick:{alignWithLabel:!0},axisLabel:{formatter:function(e){let t="";for(let l=0;l<c.length;l++)if(c[l]==e){t=h[l],"/"==t&&(t="");break}return t}}},yAxis:[{type:"value",name:i,nameGap:d?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:a[0].lineColor},itemStyle:{color:a[0].lineColor},data:m}]}},chart130:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=.01,c=200,u=[];r.forEach((e,t)=>{u.push(["筛底"==e?0:e,i[t]])});let m=!1;0==r.length&&(m=!0);let d=0;return r.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||d++}),d==r.length&&(m=!0),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(m=!1),m&&(h=null,c=null),{grid:{top:25,left:20,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"log",logBase:10,inverse:!0,min:h,max:c},yAxis:[{type:"value",name:s,nameGap:m?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:u}]}},chart150:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=[];r.forEach((e,t)=>{h.push([e,i[t]])});let c=!1;0==r.length&&(c=!0);let u=0;return r.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||u++}),u==r.length&&(c=!0),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(c=!1),{grid:{top:55,left:c?25:30,right:10,bottom:10,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:18,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1},position:"top"},yAxis:[{type:"value",name:s,nameGap:c?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h,markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value},lineStyle:{color:"#ddd",type:"solid"},data:r.map(e=>({xAxis:e}))}}]}},chart170:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=[];r.forEach((e,t)=>{h.push([e,i[t]])});let c=!1;0==r.length&&(c=!0);let u=0;return r.forEach(e=>{null!=e[1]&&null!=e[1]&&"/"!=e[1]||u++}),u==r.length&&(c=!0),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(c=!1),{grid:{top:55,left:c?25:30,right:10,bottom:10,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:18,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1},position:"top"},yAxis:[{type:"value",name:s,nameGap:c?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h,markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value},lineStyle:{color:"#ddd",type:"solid"},data:r.map(e=>({xAxis:e}))}}]}},chart190:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartXName,a=e.chartYName,s=t[0],r=l[0];s=s.filter(e=>null!=e&&null!=e&&"/"!=e&&(null==e._code||null==e._code)),r=r.filter(e=>null!=e&&null!=e&&"/"!=e&&(null==e._code||null==e._code));let i=!1;0==s.length&&(i=!0);let h=0;return s.forEach(e=>{null!=e&&null!=e&&"/"!=e||h++}),h==s.length&&(i=!0,s=[]),r.some(e=>null!=e&&null!=e&&"/"!=e)&&(i=!1),{grid:{top:10,left:i?25:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:18,fontWeight:"normal"}},{show:!0,text:n,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:s,axisTick:{alignWithLabel:!0},axisLabel:{formatter:function(e){return"/"==e?"":e}}},yAxis:[{type:"value",name:a,nameGap:i?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:r}]}},chart210:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=t[0],a=l[0],s=e.chartTitle,r=e.chartXName,i=e.chartYName;const h=[];for(let e=n.length-1;e>=0;e--){const t=n[e];null==t||null==t||"/"==t||null!=t._error&&null!=t._error||h.push([t,a[e]])}let c=!1;0==n.length&&(c=!0);let u=0;n.forEach(e=>{(null==e||null==e||"/"==e||null!=e._error&&null!=e._error)&&u++}),u==n.length&&(c=!0),a.some(e=>null!=e&&null!=e&&"/"!=e)&&(c=!1);return{grid:{top:25,left:!c&&h.length>0?30:25,right:10,bottom:40,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].value[0]+":"+e[0].value[1]:e[0].data}},title:[{show:!0,text:s,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:r,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",splitLine:{show:!1},axisLabel:{show:!1}},yAxis:[{type:"value",name:i,nameGap:!c&&h.length>0?30:5,nameRotate:90,nameLocation:"middle",axisLabel:{fontSize:10}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h,markLine:{symbol:!1,silent:!0,label:{position:"start",formatter:e=>e.value,fontSize:10},lineStyle:{color:"#ddd",type:"solid"},data:(()=>{let e=[];[0,.02,.04,.06,.08,.1].forEach(t=>{n.forEach(l=>{let o={xAxis:""};"/"==l?(o.xAxis="",e.push(o)):(o.xAxis=t,e.push(o))})});let t=e.filter((e,t,l)=>t===l.findIndex(t=>t.xAxis==e.xAxis));return u==n.length?[]:t})()}}]}},chart230:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=t.length,a=[],s=[],r=[],i=[],h=[],c=[];a=EChartsUtilsComm.filterNullEmptyErrArray(t[0]),i=EChartsUtilsComm.filterNullEmptyErrArray(l[0]),2==n&&(s=EChartsUtilsComm.filterNullEmptyErrArray(t[1]),h=EChartsUtilsComm.filterNullEmptyErrArray(l[1])),3==n&&(s=EChartsUtilsComm.filterNullEmptyErrArray(t[1]),h=EChartsUtilsComm.filterNullEmptyErrArray(l[1]),r=EChartsUtilsComm.filterNullEmptyErrArray(t[2]),c=EChartsUtilsComm.filterNullEmptyErrArray(l[2]));let u=[],m=[],d=[];a.forEach((e,t)=>{if("object"==typeof e)u.push(60*e.getHours()+e.getMinutes());else if("number"==typeof e)u.push(e);else{const t=e.split(":"),l=60*Number(t[0])+Number(t[1]);u.push(l)}}),s.forEach((e,t)=>{if("object"==typeof e)m.push(60*e.getHours()+e.getMinutes());else if("number"==typeof e)m.push(e);else{const t=e.split(":"),l=60*Number(t[0])+Number(t[1]);m.push(l)}}),r.forEach((e,t)=>{if("object"==typeof e)d.push(60*e.getHours()+e.getMinutes());else if("number"==typeof e)d.push(e);else{const t=e.split(":"),l=60*Number(t[0])+Number(t[1]);d.push(l)}}),a.length>0&&(u.push(u[u.length-1]+20),u.unshift(u[0]-20),i.push(null),i.unshift(null)),2==n&&s.length>0&&(m.push(m[m.length-1]+20),m.unshift(m[0]-20),h.push(null),h.unshift(null)),3==n&&0==r.length&&(m.push(m[m.length-1]+20),m.unshift(m[0]-20),h.push(null),h.unshift(null),d.push(d[d.length-1]+20),d.unshift(d[0]-20),c.push(null),c.unshift(null));let p=e.chartTitle,f=e.chartXName,y=e.chartYName;const g=(e,t)=>({type:"category",data:t,axisTick:{alignWithLabel:!0},show:1==e,splitLine:{show:!0}});let x=[g(1,u)];2==n&&x.push(g(2,m)),3==n&&(x.push(g(2,m)),x.push(g(3,d)));const S=(e,t)=>{const l=1==e?"第一组":2==e?"第二组":"第三组",n=1==e?"rect":2==e?"triangle":"circle",a=1==e?"solid":2==e?"dotted":[10,5],s=1==e&&o.length>=1?o[0].lineColor:2==e&&o.length>=2?o[1].lineColor:3==e&&o.length>=3?o[2].lineColor:"#000";return{name:l,type:"line",smooth:!0,symbol:n,symbolSize:6,lineStyle:{color:s,type:a},itemStyle:{color:s},data:t}};let w=[S(1,i)];2==n&&h.length>0&&w.push(S(2,h)),3==n&&(h.length>0&&w.push(S(2,h)),c.length>0&&w.push(S(3,c)));let b=1==n?["第一组"]:2==n?["第一组","第二组"]:["第一组","第二组","第三组"],C=1==n?{"第一组":!0}:2==n?{"第一组":!0,"第二组":!0}:{"第一组":!0,"第二组":!0,"第三组":!0},E=!1,A=!1,N=0;return 0==a.length?(A=!0,N=15,b=["第二组","第三组"],C={"第一组":!1,"第二组":!0,"第三组":!0},x=[],w=[],x.push(g(1,m)),x.push(g(3,d)),w.push(S(2,h)),w.push(S(3,c)),0==s.length&&(N=35,b=["第三组"],C={"第一组":!1,"第二组":!1,"第三组":!0},x=[],w=[],x.push(g(1,d)),w.push(S(3,c)),0==r.length&&(N=0,E=!0,b=[],C={"第一组":!1,"第二组":!1,"第三组":!1},x=[],w=[],x.push(g(1,[])),w.push(S(3,[]))))):0==s.length?(N=15,A=!0,b=["第一组","第三组"],C={"第一组":!0,"第二组":!1,"第三组":!0},x=[],w=[],x.push(g(1,u)),x.push(g(3,d)),w.push(S(1,i)),w.push(S(3,c)),0==a.length&&(N=35,b=["第三组"],C={"第一组":!1,"第二组":!1,"第三组":!0},x=[],w=[],x.push(g(1,u)),w.push(S(3,i)),0==r.length&&(N=0,E=!0,b=[],C={"第一组":!1,"第二组":!1,"第三组":!1},x=[],w=[],x.push(g(1,[])),w.push(S(3,[]))))):0==r.length&&(N=15,A=!0,b=["第一组","第二组"],C={"第一组":!0,"第二组":!0,"第三组":!1},x=[],w=[],x.push(g(1,u)),x.push(g(2,m)),w.push(S(1,i)),w.push(S(2,h)),0==a.length&&(N=35,b=["第二组"],C={"第一组":!1,"第二组":!0,"第三组":!1},x=[],w=[],x.push(g(1,m)),w.push(S(2,h)),0==s.length&&(N=0,E=!0,b=[],C={"第一组":!1,"第二组":!1,"第三组":!1},x=[],w=[],x.push(g(1,[])),w.push(S(2,[]))))),{grid:{top:A?N:-5,left:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:p,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:f,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{left:"center",top:16,data:b,selected:C,selectedMode:"multiple"},xAxis:x,yAxis:[{type:"value",name:y,nameGap:E?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:w}},chart250:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName;const r=t[0],i=l[0];let h=[];r.forEach((e,t)=>{h.push([e,i[t]])});let c=.001,u=100,m=!1;0==r.length&&(m=!0);let d=0;return r.forEach(e=>{null!=e&&null!=e&&"/"!=e||d++}),d==r.length&&(m=!0,c=null,u=null),i.some(e=>null!=e&&null!=e&&"/"!=e)&&(m=!1),{grid:{top:25,left:20,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"log",logBase:10,inverse:!0,min:c,max:u},yAxis:[{type:"value",name:s,nameGap:m?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:h}]}},chart270:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=[],i=[],h=[],c=[],u=[],m=[];t[0].forEach((e,t)=>{0!=e&&0!=l[0][t]&&(r.push(e),c.push(l[0][t]))}),t[1].forEach((e,t)=>{0!=e&&0!=l[1][t]&&(i.push(e),u.push(l[1][t]))}),t[2].forEach((e,t)=>{0!=e&&0!=l[2][t]&&(h.push(e),m.push(l[2][t]))});const d=(e,t,l)=>{const n=`曲线${e}`,a=1==e?"rect":2==e?"triangle":"circle",s=1==e?"solid":2==e?"dotted":[10,5],r=1==e?o[0].lineColor:2==e?o[1].lineColor:o[2].lineColor,i=[];return t.forEach((e,t)=>{i.push([e,l[t]])}),{name:n,type:"line",smooth:!0,symbol:a,symbolSize:5,lineStyle:{color:r,type:s},itemStyle:{color:r},data:i}};let p=!1;return r.every(e=>"/"==e)&&i.every(e=>"/"==e)&&h.every(e=>"/"==e)&&c.every(e=>"/"==e)&&u.every(e=>"/"==e)&&m.every(e=>"/"==e)&&(p=!0),{grid:{top:35,left:p?25:30,right:20,bottom:5,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].value[0]+"):"+e[0].value[1]:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:16,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",axisTick:{alignWithLabel:!0},splitLine:{show:!0},position:"top",nameGap:5,nameLocation:"end"},yAxis:[{type:"value",name:s,nameGap:p?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[d(1,r,c),d(2,i,u),d(3,h,m)]}},chart279_280_281:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=279==e.chartType?5:280==e.chartType?.1:.15,i=t[0],h=l[0],c=Math.min(...i),u=Number(EChartsUtilsComm.getRound(Math.min(...h)-r,.001)),m=Number(EChartsUtilsComm.getRound(Math.max(...h)+r,.001));c=Number(EChartsUtilsComm.getRound(c-.01*c,.001));let d=[];i.forEach((e,t)=>{d.push([e,h[t]])});let p=!1;return h.every(e=>"/"==e)&&(p=!0),{grid:{top:25,left:20,right:15,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",min:c,max:100},yAxis:[{type:"value",name:s,nameGap:p?5:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0},min:u,max:m}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:d}]}},chart290:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=t[0],i=t[0],h=t[0],c=l[0],u=l[1],m=l[2];const d=(e,t)=>{const l=`曲线${e}`,n=1==e?"rect":2==e?"triangle":"circle",a=1==e?"solid":2==e?"dotted":[10,5],s=1==e?o[0].lineColor:2==e?o[1].lineColor:o[2].lineColor;return{name:l,type:"line",smooth:!0,symbol:n,symbolSize:5,lineStyle:{color:s,type:a},itemStyle:{color:s},data:t}};let p=!1;return r.every(e=>"/"==e)&&i.every(e=>"/"==e)&&h.every(e=>"/"==e)&&c.every(e=>"/"==e)&&u.every(e=>"/"==e)&&m.every(e=>"/"==e)&&(p=!0,r=[]),{grid:{top:35,left:p?25:30,right:10,bottom:5,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:16,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:r,axisTick:{alignWithLabel:!0},splitLine:{show:!0},position:"top",nameGap:5,nameLocation:"end",axisLabel:{formatter:function(e){return"/"==e?"":e}}},yAxis:[{type:"value",name:s,nameGap:p?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[d(1,c),d(2,u),d(3,m)]}},chart310:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson),n=e.chartTitle,a=e.chartXName,s=e.chartYName,r=t[0],i=l[0],h=[],c=[];r.forEach((e,t)=>{null==e||null==e||"/"==e||null!=e._code&&null!=e._code||(h.push(e),c.push(i[t]))}),r=h,i=c;let u=!1;return r.every(e=>"/"==e||null!=e._code&&null!=e._code)&&i.every(e=>"/"==e||null!=e._code&&null!=e._code)&&(u=!0,r=[]),{grid:{top:35,left:u?25:30,right:20,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:n,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:a,left:"center",top:16,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:r,axisLabel:{formatter:function(e){return"/"==e?"":e}},axisTick:{alignWithLabel:!0},axisLine:{symbol:["none","arrow"],symbolSize:10},splitLine:{show:!0},position:"top",name:"p",nameGap:5,nameLocation:"end"},yAxis:[{type:"value",name:s,nameGap:u?5:30,nameRotate:90,nameLocation:"middle",inverse:!0,splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0,symbol:["arrow","none"],symbolSize:10}},{name:"L",nameRotate:0,nameLocation:"end",nameGap:5,position:"left",inverse:!0}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:o[0].lineColor},itemStyle:{color:o[0].lineColor},data:i}]}},chart330:(e,t,l,o)=>{let n=JSON.parse(e.chartLinesJson);const a=null==e.chartExtJson||null==e.chartExtJson?null:JSON.parse(e.chartExtJson);let s=e.chartXName,r=e.chartYName,i=t[0],h=l[0];const c=EChartsUtilsComm.calcTrend(i,h,i[0]);let u=EChartsUtilsComm.getRound((.15-c.jj)/c.xl,0),m=EChartsUtilsComm.getRound((.19-c.jj)/c.xl,0),d=EChartsUtilsComm.getRound((.25-c.jj)/c.xl,0),p=EChartsUtilsComm.getRound((.31-c.jj)/c.xl,0);u==1/0&&(u=0),m==1/0&&(m=0),d==1/0&&(d=0),p==1/0&&(p=0);let f=`${u}~${m}`,y=`${d}~${p}`;null!=a&&(0==u&&0==m?o.setValue(a.bszdjBh.row,a.bszdjBh.col,"/"):o.setValue(a.bszdjBh.row,a.bszdjBh.col,f),0==d&&0==p?o.setValue(a.bszdjYs.row,a.bszdjYs.col,"/"):o.setValue(a.bszdjYs.row,a.bszdjYs.col,y));let g=!1;return i.every(e=>"/"==e)&&h.every(e=>"/"==e)&&(g=!0,i=[]),{grid:{top:10,left:g?25:30,right:10,bottom:20,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e.length>0?e[0].seriesName+"("+e[0].name+"):"+e[0].value:e[0].data}},title:[{show:!0,text:"",left:"center",top:0,textStyle:{fontSize:18,fontWeight:"normal"}},{show:!0,text:s,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"category",data:i,axisTick:{alignWithLabel:!0},axisLabel:{formatter:function(e){return"/"==e?"":e}}},yAxis:[{type:"value",name:r,nameGap:g?5:25,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},axisLine:{show:!0}}],series:[{name:"图例1",type:"line",smooth:!0,symbol:"circle",symbolSize:6,lineStyle:{color:n[0].lineColor},itemStyle:{color:n[0].lineColor},data:h}]}},chart350:(e,t,l)=>{let o=JSON.parse(e.chartLinesJson)[0].lineColor;const n=[t[0][0],t[0][1]],a=[l[0][0],l[0][1]],s=Number(EChartsUtilsComm.getRound(EChartsUtilsComm.calcTrend(n,a,n[0]).y,.1)),r=Number(EChartsUtilsComm.getRound(EChartsUtilsComm.calcTrend(n,a,n[1]).y,.1)),i=Number(EChartsUtilsComm.getRound(EChartsUtilsComm.calcTrend(n,a,25).y,.1)),h=Math.floor(Number(r))-2,c=Math.floor(Number(s))+2;let u=e.chartTitle,m=e.chartXName,d=e.chartYName,p=!0;p=0==t[0].filter(e=>null!=e&&null!=e&&"/"!=e).length,p&&(p=0==l[0].filter(e=>null!=e&&null!=e&&"/"!=e).length);let f=[{name:"图例1",type:"line",symbol:"circle",z:10,lineStyle:{color:o},itemStyle:{color:o},connectNulls:!0,data:[[0,null],[2,null],[3.5,null],[4.9,null],[5.9,null],[6.9,null],{value:[10.4,i-2.7*(i-s)/2.1],symbol:"none"},[11,s],[11.8,null],[13.1,i],[14.6,r],{value:[15.2,2.1/1.5*(r-i)+i],symbol:"none"},[16.4,null],[17.4,null],[18.9,null],[19.8,null],[20.7,null],[21.6,null],[22.6,null]],markPoint:{data:[{xAxis:13.1,yAxis:i,symbolOffset:[40,25],label:{show:!0,color:"#000",formatter:function(e){return p?"":"( 25 , "+e.data.yAxis+")"}},itemStyle:{color:"transparent"}}]},markLine:{symbol:"",silent:!0,label:{position:"start",formatter:e=>e.name},lineStyle:{color:"#e0e6f1",type:"solid"},data:[{name:"5",xAxis:0,label:{fontSize:8}},{name:"6",xAxis:2,label:{fontSize:8}},{name:"7",xAxis:3.5,label:{fontSize:8}},{name:"8",xAxis:4.9,label:{fontSize:8}},{name:"9",xAxis:5.9,label:{fontSize:8}},{name:"10",xAxis:6.9,label:{fontSize:8}},{name:"",xAxis:10.4,lineStyle:{opacity:0}},{name:"",xAxis:11},{name:"20",xAxis:11.8,label:{fontSize:8}},{name:"25",xAxis:13.1,label:{fontSize:8}},{name:"30",xAxis:14.6,label:{fontSize:8}},{name:"",xAxis:15.2,lineStyle:{opacity:0}},{name:"40",xAxis:16.4,label:{fontSize:8}},{name:"50",xAxis:17.4,label:{fontSize:8}},{name:"",xAxis:18.9},{name:"",xAxis:19.8},{name:"",xAxis:20.7},{name:"",xAxis:21.6},{name:"100",xAxis:22.6,label:{fontSize:8}},[{coord:[0,i],lineStyle:{color:"#529b2e",type:"solid"}},{coord:[13.1,i]}],[{coord:[13.1,h],lineStyle:{color:"#000",type:"silid"}},{coord:[13.1,i]}]]}}];return p&&(f=[]),{grid:{top:25,left:30,right:10,bottom:35,containLabel:!0},tooltip:{trigger:"axis",formatter:function(e,t){return e&&e[0].data.length>1?null==e[0].data[1]?"":e[0].seriesName+"("+e[0].data[0]+"):"+e[0].data[1]:e[0].data}},title:[{show:!0,text:u,left:"center",top:0,textStyle:{fontSize:14,fontWeight:"normal"}},{show:!0,text:m,left:"center",bottom:0,textStyle:{fontSize:12,fontWeight:"normal"}}],legend:{show:!1,left:"right",data:["图例1"],selected:{legendName:!0},selectedMode:"multiple"},xAxis:{type:"value",axisTick:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},min:0,max:23.5},yAxis:[{type:"value",name:d,nameGap:p?10:30,nameRotate:90,nameLocation:"middle",splitLine:{show:!0,lineStyle:{color:"#e0e6f1",type:"solid"}},splitNumber:4,min:p?null:h,max:c,axisLabel:{show:!p,fontSize:8},axisTick:{show:!p}}],series:f}}},EChartsUtils={create:(e,t,l,o,...n)=>__awaiter(void 0,[e,t,l,o,...n],void 0,function*(e,t,l,o,n=!1){const a=null==o.chartExtJson||null==o.chartExtJson?null:JSON.parse(o.chartExtJson);if(null!=a&&null!=a.isShowCon&&null!=a.isShowCon){if(l.getValue(a.isShowCon.row,a.isShowCon.col)!=a.isShowVal)return void l.floatingObjects.remove(o.chartId)}let s=0,r=0,i=0,h=0;for(let e=0;e<o.row;e++)s+=l.getRowHeight(e);s+=l.getRowHeight(0,e.Spread.Sheets.SheetArea.colHeader);for(let e=o.col;e<o.col+o.colCount;e++)r+=l.getColumnWidth(e);for(let e=0;e<o.col;e++)i+=l.getColumnWidth(e);i+=l.getColumnWidth(0,e.Spread.Sheets.SheetArea.rowHeader);for(let e=o.row;e<o.row+o.rowCount;e++)h+=l.getRowHeight(e);const c={x:i-40+2,y:s-20+2,w:r-6,h:h-6};let u=l.floatingObjects.get(o.chartId);if(null==u||null==u?(u=new e.Spread.Sheets.FloatingObjects.FloatingObject(o.chartId,c.x,c.y,c.w,c.h),u.allowResize(!1),u.allowMove(!1),l.floatingObjects.add(u)):(u.x(c.x),u.y(c.y),u.width(c.w),u.height(c.h)),null==document.getElementById(o.chartId+"_ec")){const e=document.createElement("div");e.setAttribute("style","background-color:#fff;width:100%;height:100%;"),e.innerHTML=`<div id="${o.chartId}_ec" style="width:100%;height:100%;"></div>`,u.content(e)}let m=null;return m=(yield new Promise((e,a)=>{setTimeout(()=>{e({ecObj:EChartsUtils.initChart(t,l,o,n)})},10)})).ecObj,{fObj:u,fObjPosition:c,ecObj:m}}),initChart:(e,t,l,o=!1)=>{if(null==document.getElementById(l.chartId+"_ec"))return null;let n=[],a=[],s=[],r=[];const i=(e,t,l,o)=>{let n={dataOneArr:[],dataOneSourceArr:[]},a=null;return null!=l&&null!=l&&l.length>0&&(a=e.getSheetFromName(l)),null==o||o.forEach((e,l)=>{const o=null!=a?a.getValue(e.row,e.col):t.getValue(e.row,e.col);n.dataOneSourceArr.push(o),/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/.test(o)?n.dataOneArr.push(Number(o)):n.dataOneArr.push(null==o?0:o)}),n};JSON.parse(l.chartLinesJson).forEach((l,o)=>{let h=[],c=[],u=[],m=[];const d=i(e,t,l.sheetNameX,l.xCells);h=d.dataOneArr,u=d.dataOneSourceArr;const p=i(e,t,l.sheetNameY,l.yCells);c=p.dataOneArr,m=p.dataOneSourceArr,n.push(h),a.push(c),s.push(u),r.push(m)});const h=document.getElementById(l.chartId+"_ec");let c,u=echarts__namespace.getInstanceByDom(h);return null!=u&&null!=u||(u=echarts__namespace.init(h,null,{renderer:"canvas",useDirtyRect:!1})),10==l.chartType?c=EChartsUtilsAll.chart10(l,n,a,t):11==l.chartType?c=EChartsUtilsAll.chart11(l,n,a,t):12==l.chartType?c=EChartsUtilsAll.chart12(l,n,a,t):13==l.chartType?c=EChartsUtilsAll.chart13(l,n,a,t):14==l.chartType?c=EChartsUtilsAll.chart14(l,n,a,t):15==l.chartType?c=EChartsUtilsAll.chart15(l,n,a,t):16==l.chartType?c=EChartsUtilsAll.chart16(l,n,a,t):30==l.chartType?c=EChartsUtilsAll.chart30(l,n,a,t):50==l.chartType?c=EChartsUtilsAll.chart50(l,n,a):70==l.chartType?c=EChartsUtilsAll.chart70(l,n,a,t):90==l.chartType?c=EChartsUtilsAll.chart90(l,n,a,t):110==l.chartType?c=EChartsUtilsAll.chart110(l,n,a,s,r):130==l.chartType?c=EChartsUtilsAll.chart130(l,n,a):150==l.chartType?c=EChartsUtilsAll.chart150(l,n,a):170==l.chartType?c=EChartsUtilsAll.chart170(l,n,a):190==l.chartType?c=EChartsUtilsAll.chart190(l,n,a):210==l.chartType?c=EChartsUtilsAll.chart210(l,n,a):230==l.chartType?c=EChartsUtilsAll.chart230(l,n,a):250==l.chartType?c=EChartsUtilsAll.chart250(l,n,a):270==l.chartType?c=EChartsUtilsAll.chart270(l,n,a):279==l.chartType||280==l.chartType||281==l.chartType?c=EChartsUtilsAll.chart279_280_281(l,n,a):290==l.chartType?c=EChartsUtilsAll.chart290(l,n,a):310==l.chartType?c=EChartsUtilsAll.chart310(l,n,a):330==l.chartType?c=EChartsUtilsAll.chart330(l,n,a,t):350==l.chartType&&(c=EChartsUtilsAll.chart350(l,n,a)),c&&"object"==typeof c&&(o&&(c.animation=!1),u.setOption(c)),u.setOption(c),u},getEChartsObj:e=>{const t=document.getElementById(e+"_ec");let l=echarts__namespace.getInstanceByDom(t);return null==l||null==l?null:l}},WorkbookUtils={loadSjsFile:(e,t,l,o)=>__awaiter(void 0,void 0,void 0,function*(){const n=yield fetch(t,{method:"GET"});if(n.ok){const t=yield n.blob(),a=new Blob([t],{type:"application/zip"});e.open(a,()=>__awaiter(void 0,void 0,void 0,function*(){"function"==typeof l&&(yield l(e))}),e=>__awaiter(void 0,void 0,void 0,function*(){"function"==typeof o&&(yield o(e))}))}}),getWookbookBlob:e=>__awaiter(void 0,void 0,void 0,function*(){return new Promise((t,l)=>{e.save(e=>t(e),e=>l(e))})}),print:(e,t)=>{const l=t.getSheetCount();for(let o=0;o<l;o++){const l=t.getSheet(o);let n=l.printInfo();n.showRowHeader(e.Spread.Sheets.Print.PrintVisibilityType.hide),n.showColumnHeader(e.Spread.Sheets.Print.PrintVisibilityType.hide),n.rowStart(0),n.rowEnd(l.getRowCount()),n.columnStart(0),n.columnEnd(76),n.margin({top:59.055119999999995,bottom:59.055119999999995,left:98.42520000000002,right:59.055119999999995,header:0,footer:0}),n.paperSize(new e.Spread.Sheets.Print.PaperSize(e.Spread.Sheets.Print.PaperKind.a4)),l.printInfo(n)}t.print()},exportToExcel:(e,t,l="")=>{const o=t.toJSON({includeBindingSource:!0}),n=["YJMAX","YJMIN","YJMID","YJGETNUM","YJGETS","YJGETCV","YJINTERPOLATIONMETHOD","YJINTERPOLATIONMETHOD_Y"],a=new e.Spread.Sheets.Workbook;a.fromJSON(o),a.suspendPaint();const s=a.getSheetCount();for(let e=0;e<s;e++){const t=a.getSheet(e);t.suspendCalcService();for(var r=0;r<t.getRowCount();r++)for(var i=0;i<t.getColumnCount();i++){const e=t.getFormula(r,i);if(null!=e&&null!=e&&n.some(t=>e.indexOf(t)>-1)){const e=t.getValue(r,i);t.getCell(r,i).formula(void 0),t.setValue(r,i,e)}}t.resumeCalcService(!1)}a.resumePaint(),""==l&&(l=a.getSheet(0).name());let h={fileType:e.Spread.Sheets.FileType.excel,includeBindingSource:!0,includeStyles:!0,includeFormulas:!0,saveAsView:!1,rowHeadersAsFrozenColumns:!1,columnHeadersAsFrozenRows:!1,includeAutoMergedCells:!1,includeCalcModelCache:!1,includeUnusedNames:!0,includeEmptyRegionCells:!0};a.export(e=>{fileSaver.saveAs(e,`${l}.xlsx`)},()=>{},h),a.destroy()},mergeWorkbooksToExcel:(e,t,l)=>__awaiter(void 0,void 0,void 0,function*(){if(!t||0==t.length)return;const o=new e.Spread.Sheets.Workbook;o.suspendPaint(),o.fromJSON(t[0].toJSON());for(let l=1;l<t.length;l++){const n=new e.Spread.Sheets.Workbook;n.suspendPaint(),n.fromJSON(t[l].toJSON());const a=l+"";n.getNamedStyles().forEach(function(e){e.name=`new_${a}_${e.name}`,o.addNamedStyle(e)});let s=n.getSheet(0),r=JSON.stringify(s.toJSON());r=r.replace(/"style":"/g,'"style":"new_'+a+"_"),r=r.replace(/"parentName":"/g,'"parentName":"new_'+a+"_");let i=new e.Spread.Sheets.Worksheet(`newSheet${a}_`);o.addSheet(o.getSheetCount(),i),i.fromJSON(JSON.parse(r));const h=i.getRowCount(),c=o.getSheet(0);c.addRows(c.getRowCount(),h);let u=c.getRowCount()-h;const m=[new e.Spread.Sheets.Range(-1,-1,-1,-1)],d=[new e.Spread.Sheets.Range(u,0,h,i.getColumnCount())];o.commandManager().execute({cmd:"clipboardPaste",sheetName:c.name(),fromSheet:i,fromRanges:m,pastedRanges:d,isCutting:!1,clipboardText:"",pasteOption:e.Spread.Sheets.ClipboardPasteOptions.all}),o.removeSheet(o.getSheetCount()-1),c.clearSelection(),n.resumePaint(),n.destroy()}const n=o.getActiveSheet();return n.zoom(1),n.options.rowHeaderVisible=!0,n.options.colHeaderVisible=!0,o.options.tabStripVisible=!0,o.options.showHorizontalScrollbar=!0,o.options.showVerticalScrollbar=!0,o.options.scrollbarMaxAlign=!1,o.resumePaint(),WorkbookUtils.exportToExcel(e,o,l),o})};exports.BusinessUtils=BusinessUtils,exports.CommonUtils=CommonUtils,exports.EChartsUtils=EChartsUtils,exports.SheetUtils=SheetUtils,exports.WorkbookUtils=WorkbookUtils;
2
2
  //# sourceMappingURL=index.cjs.min.js.map