rapid-spreadjs 1.0.138 → 1.0.139
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 +23 -2
- 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 +23 -2
- 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/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -1436,7 +1436,12 @@ const BusinessUtils = {
|
|
|
1436
1436
|
});
|
|
1437
1437
|
// 有值和没有值的行索引集合
|
|
1438
1438
|
let hasValueRows = [], noValueRows = [];
|
|
1439
|
+
// 有值的行索引(序号列使用)
|
|
1440
|
+
let hasValueRowsSer = [];
|
|
1439
1441
|
rowCells.forEach((rowObj, index) => {
|
|
1442
|
+
if (rowObj.rows.some((x) => x.hasValue) && !hasValueRowsSer.some((x) => x == rowObj.rowSpan)) {
|
|
1443
|
+
hasValueRowsSer.push(rowObj.rowSpan);
|
|
1444
|
+
}
|
|
1440
1445
|
if (rowObj.rows.some((x) => x.hasValue)) {
|
|
1441
1446
|
rowObj.rows.forEach((x) => {
|
|
1442
1447
|
x.rows.forEach((rowIndex) => {
|
|
@@ -1456,11 +1461,13 @@ const BusinessUtils = {
|
|
|
1456
1461
|
});
|
|
1457
1462
|
}
|
|
1458
1463
|
});
|
|
1464
|
+
hasValueRowsSer.forEach((rowIndex, index) => {
|
|
1465
|
+
// 设置序号列单元格的值(1、2、3...的格式)
|
|
1466
|
+
sheet.setValue(rowIndex, 1, index + 1);
|
|
1467
|
+
});
|
|
1459
1468
|
hasValueRows.forEach((rowIndex, index) => {
|
|
1460
1469
|
// 设置行可见
|
|
1461
1470
|
sheet.setRowVisible(rowIndex, true);
|
|
1462
|
-
// 设置序号列单元格的值(1、2、3...的格式)
|
|
1463
|
-
sheet.setValue(rowIndex, 1, index + 1);
|
|
1464
1471
|
});
|
|
1465
1472
|
noValueRows.forEach((rowIndex) => {
|
|
1466
1473
|
// 设置行不可见
|
|
@@ -19320,6 +19327,20 @@ const FormulaUtils = {
|
|
|
19320
19327
|
getddn.y1 = array_x[_index - 1];
|
|
19321
19328
|
getddn.y2 = array_x[_index];
|
|
19322
19329
|
getddn.x = dn;
|
|
19330
|
+
if (_index == array_y.length) {
|
|
19331
|
+
getddn.x1 = array_y[_index - 2];
|
|
19332
|
+
getddn.x2 = array_y[_index - 1];
|
|
19333
|
+
getddn.y1 = array_x[_index - 2];
|
|
19334
|
+
getddn.y2 = array_x[_index - 1];
|
|
19335
|
+
getddn.x = dn;
|
|
19336
|
+
}
|
|
19337
|
+
else if (_index == 0) {
|
|
19338
|
+
getddn.x1 = array_y[_index];
|
|
19339
|
+
getddn.x2 = array_y[_index + 1];
|
|
19340
|
+
getddn.y1 = array_x[_index];
|
|
19341
|
+
getddn.y2 = array_x[_index + 1];
|
|
19342
|
+
getddn.x = dn;
|
|
19343
|
+
}
|
|
19323
19344
|
if (getddn.y1 == dn) {
|
|
19324
19345
|
dnn = getddn.x1;
|
|
19325
19346
|
}
|