rapid-spreadjs 1.0.88 → 1.0.90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +35 -12
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.cjs.min.js +1 -1
- package/dist/index.cjs.min.js.map +1 -1
- package/dist/index.esm.js +35 -12
- package/dist/index.esm.js.map +1 -1
- package/dist/index.esm.min.js +1 -1
- package/dist/index.esm.min.js.map +1 -1
- package/dist/utils/echarts-all.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -872,10 +872,29 @@ const BusinessUtils = {
|
|
|
872
872
|
cellRange.colCount, // 源列数
|
|
873
873
|
GC.Spread.Sheets.CopyToOptions.all // 复制内容类型(值、样式、公式等)
|
|
874
874
|
);
|
|
875
|
+
// 使用命令的方式
|
|
876
|
+
// // 定义源区域
|
|
877
|
+
// var fromRange = [new GC.Spread.Sheets.Range(cellRange.row, cellRange.col, cellRange.rowCount, cellRange.colCount)];
|
|
878
|
+
// // 定义目标区域
|
|
879
|
+
// var toRange = [new GC.Spread.Sheets.Range(targetRow, cellRange.col, cellRange.rowCount, cellRange.colCount)];
|
|
880
|
+
// // 执行复制命令
|
|
881
|
+
// spread.commandManager().execute({
|
|
882
|
+
// cmd: "clipboardPaste",
|
|
883
|
+
// sheetName: sheet.name(), // 目标工作表名称
|
|
884
|
+
// fromSheet: sheet, // 源工作表对象
|
|
885
|
+
// fromRanges: fromRange, // 源区域数组
|
|
886
|
+
// pastedRanges: toRange, // 目标区域数组
|
|
887
|
+
// isCutting: false, // false 表示复制
|
|
888
|
+
// clipboardText: "", // 留空
|
|
889
|
+
// pasteOption: GC.Spread.Sheets.ClipboardPasteOptions.all // 粘贴全部内容(数据、样式、公式等)
|
|
890
|
+
// });
|
|
875
891
|
}
|
|
876
892
|
};
|
|
877
|
-
//
|
|
893
|
+
// 暂停绘制、计算、事件
|
|
878
894
|
sheet.suspendPaint();
|
|
895
|
+
sheet.suspendCalcService();
|
|
896
|
+
sheet.suspendDirty();
|
|
897
|
+
sheet.suspendEvent();
|
|
879
898
|
// 当前默认点数<=1并且上一次默认点数>0的时候,则删除所有循环的行
|
|
880
899
|
if (curDefaultPointCount <= 1 && lastDefaultPointCount > 0) {
|
|
881
900
|
sheet.deleteRows(cellRange.row + cellRange.rowCount, (curDefaultPointCount - 1) * cellRange.rowCount);
|
|
@@ -896,7 +915,7 @@ const BusinessUtils = {
|
|
|
896
915
|
addRowsFun(cellRange.row + cellRange.rowCount, (curDefaultPointCount - 1) * cellRange.rowCount, curDefaultPointCount - 1);
|
|
897
916
|
}
|
|
898
917
|
// 循环后的所有单元格范围
|
|
899
|
-
const cyclicCellsRangeObj = sheet.getRange(cellRange.row, cellRange.col, curDefaultPointCount * cellRange.rowCount, cellRange.colCount);
|
|
918
|
+
const cyclicCellsRangeObj = sheet.getRange(cellRange.row, cellRange.col, curDefaultPointCount * cellRange.rowCount, cellRange.colCount > 77 ? 77 : cellRange.colCount);
|
|
900
919
|
// 判断要循环的单元格最后一行是否为表格的末尾行,如果是,则在循环创建单元行的最后一行的时候,下边框线位细线样式
|
|
901
920
|
if (isCyclicLastRowIsSheetLastRow) {
|
|
902
921
|
// 设置所有内边框线为细线样式
|
|
@@ -927,12 +946,15 @@ const BusinessUtils = {
|
|
|
927
946
|
});
|
|
928
947
|
});
|
|
929
948
|
}
|
|
949
|
+
// 恢复事件、计算、绘制
|
|
950
|
+
sheet.resumeDirty();
|
|
951
|
+
sheet.resumeEvent();
|
|
952
|
+
sheet.resumeCalcService();
|
|
953
|
+
sheet.resumePaint();
|
|
930
954
|
// 创建完成后的回调函数
|
|
931
955
|
if (created != null && created != undefined && typeof created === 'function') {
|
|
932
956
|
created(cyclicCellsRange, allCellsByRow);
|
|
933
957
|
}
|
|
934
|
-
// 恢复绘制
|
|
935
|
-
sheet.resumePaint();
|
|
936
958
|
},
|
|
937
959
|
};
|
|
938
960
|
|
|
@@ -8499,9 +8521,10 @@ const EChartsUtilsAll = {
|
|
|
8499
8521
|
{
|
|
8500
8522
|
show: true,
|
|
8501
8523
|
text: title,
|
|
8524
|
+
left: 'center',
|
|
8502
8525
|
top: 2,
|
|
8503
8526
|
textStyle: {
|
|
8504
|
-
fontSize:
|
|
8527
|
+
fontSize: 14,
|
|
8505
8528
|
fontWeight: 'normal',
|
|
8506
8529
|
},
|
|
8507
8530
|
},
|
|
@@ -20003,7 +20026,7 @@ const FormulaUtils = {
|
|
|
20003
20026
|
isAcceptArea: true,
|
|
20004
20027
|
funParams: [
|
|
20005
20028
|
{
|
|
20006
|
-
name: '
|
|
20029
|
+
name: '需要用作判断的数字数组、字符串数组或单值',
|
|
20007
20030
|
repeatable: false,
|
|
20008
20031
|
optional: false,
|
|
20009
20032
|
},
|
|
@@ -20039,7 +20062,7 @@ const FormulaUtils = {
|
|
|
20039
20062
|
if (retData.allCellValsEw.length < 5) {
|
|
20040
20063
|
return '/';
|
|
20041
20064
|
}
|
|
20042
|
-
let array1 = retData.allCellValsEw[0], array2 = retData.allCellValsEw[1], operator = retData.allCellValsEw[2], value = retData.allCellValsEw[3], delimiter = retData.allCellValsEw[4], isOpposite = retData.allCellValsEw.length
|
|
20065
|
+
let array1 = retData.allCellValsEw[0], array2 = retData.allCellValsEw[1], operator = retData.allCellValsEw[2], value = retData.allCellValsEw[3], delimiter = retData.allCellValsEw[4], isOpposite = retData.allCellValsEw.length < 6 ? 0 : retData.allCellValsEw[5];
|
|
20043
20066
|
try {
|
|
20044
20067
|
// 处理array1和array2的默认值
|
|
20045
20068
|
if (array1 == null || array1 == undefined || (typeof array1 == 'string' && array1.trim().length == 0)) {
|
|
@@ -20108,7 +20131,7 @@ const FormulaUtils = {
|
|
|
20108
20131
|
case '>':
|
|
20109
20132
|
case '>':
|
|
20110
20133
|
if (isSingleValue1) {
|
|
20111
|
-
conditionMet =
|
|
20134
|
+
conditionMet = num2 > num1;
|
|
20112
20135
|
}
|
|
20113
20136
|
else {
|
|
20114
20137
|
conditionMet = num1 > numValue;
|
|
@@ -20117,7 +20140,7 @@ const FormulaUtils = {
|
|
|
20117
20140
|
case '<':
|
|
20118
20141
|
case '<':
|
|
20119
20142
|
if (isSingleValue1) {
|
|
20120
|
-
conditionMet =
|
|
20143
|
+
conditionMet = num2 < num1;
|
|
20121
20144
|
}
|
|
20122
20145
|
else {
|
|
20123
20146
|
conditionMet = num1 < numValue;
|
|
@@ -20127,7 +20150,7 @@ const FormulaUtils = {
|
|
|
20127
20150
|
case '≥':
|
|
20128
20151
|
case '≧':
|
|
20129
20152
|
if (isSingleValue1) {
|
|
20130
|
-
conditionMet =
|
|
20153
|
+
conditionMet = num2 >= num1;
|
|
20131
20154
|
}
|
|
20132
20155
|
else {
|
|
20133
20156
|
conditionMet = num1 >= numValue;
|
|
@@ -20137,7 +20160,7 @@ const FormulaUtils = {
|
|
|
20137
20160
|
case '≤':
|
|
20138
20161
|
case '≦':
|
|
20139
20162
|
if (isSingleValue1) {
|
|
20140
|
-
conditionMet =
|
|
20163
|
+
conditionMet = num2 <= num1;
|
|
20141
20164
|
}
|
|
20142
20165
|
else {
|
|
20143
20166
|
conditionMet = num1 <= numValue;
|
|
@@ -20146,7 +20169,7 @@ const FormulaUtils = {
|
|
|
20146
20169
|
case '=':
|
|
20147
20170
|
case '=':
|
|
20148
20171
|
if (isSingleValue1) {
|
|
20149
|
-
conditionMet =
|
|
20172
|
+
conditionMet = num2 === num1;
|
|
20150
20173
|
}
|
|
20151
20174
|
else {
|
|
20152
20175
|
conditionMet = num1 === numValue;
|