@indfnd/common 1.1.0 → 1.1.2
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/CHANGELOG.md +9 -0
- package/dist/ind-common.es.js +30 -7
- package/dist/ind-common.umd.cjs +50 -50
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [1.1.2](http://git.inspur.com/imp-ec/ind-front/ind-common-front/compare/v1.1.1...v1.1.2) (2025-09-02)
|
|
6
|
+
|
|
7
|
+
### [1.1.1](http://git.inspur.com/imp-ec/ind-front/ind-common-front/compare/v1.1.0...v1.1.1) (2025-08-30)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Features
|
|
11
|
+
|
|
12
|
+
* 初始化加载exceljs ([f51a422](http://git.inspur.com/imp-ec/ind-front/ind-common-front/commit/f51a422eb3a708c7cca36ce130a16106d77837db))
|
|
13
|
+
|
|
5
14
|
## [1.1.0](http://git.inspur.com/imp-ec/ind-front/ind-common-front/compare/v1.0.128...v1.1.0) (2025-08-29)
|
|
6
15
|
|
|
7
16
|
### [1.0.128](http://git.inspur.com/imp-ec/ind-front/ind-common-front/compare/v1.0.127...v1.0.128) (2025-08-27)
|
package/dist/ind-common.es.js
CHANGED
|
@@ -5460,7 +5460,7 @@ var lodash = { exports: {} };
|
|
|
5460
5460
|
})(lodash, lodash.exports);
|
|
5461
5461
|
var _ = lodash.exports;
|
|
5462
5462
|
const name$1 = "@indfnd/common";
|
|
5463
|
-
const version = "1.
|
|
5463
|
+
const version = "1.1.1";
|
|
5464
5464
|
const author = "huxuetong";
|
|
5465
5465
|
const publishConfig = {
|
|
5466
5466
|
registry: "https://registry.npmjs.org/"
|
|
@@ -5504,7 +5504,7 @@ const scripts = {
|
|
|
5504
5504
|
build: "yarn build:prod && yarn build:style",
|
|
5505
5505
|
"type-check": "vue-tsc --noEmit -p tsconfig.check.json --composite false",
|
|
5506
5506
|
dts: "vue-tsc -p tsconfig.types.json",
|
|
5507
|
-
release: "node build/auto-build.js && yarn release-
|
|
5507
|
+
release: "node build/auto-build.js && yarn release-patch && git push --follow-tags && yarn re-publish",
|
|
5508
5508
|
"release-major": "standard-version --release-as major",
|
|
5509
5509
|
"release-minor": "standard-version --release-as minor",
|
|
5510
5510
|
"release-patch": "standard-version --release-as patch",
|
|
@@ -43553,10 +43553,25 @@ function getAgColumnTitleAndData({ columns, datas }) {
|
|
|
43553
43553
|
});
|
|
43554
43554
|
var exportData = datasClo.map((d) => {
|
|
43555
43555
|
return columnsCalc.map((dd, idx) => {
|
|
43556
|
-
if (
|
|
43557
|
-
columnWidth[idx] =
|
|
43556
|
+
if (dd.columnWidth !== void 0) {
|
|
43557
|
+
columnWidth[idx] = dd.columnWidth;
|
|
43558
|
+
} else {
|
|
43559
|
+
if (d[dd.field] && columnWidth[idx] < ("" + d[dd.field]).length * 2) {
|
|
43560
|
+
columnWidth[idx] = ("" + d[dd.field]).length * 2;
|
|
43561
|
+
}
|
|
43562
|
+
}
|
|
43563
|
+
let formula = null;
|
|
43564
|
+
if (dd.formula) {
|
|
43565
|
+
if (dd.formula instanceof Function) {
|
|
43566
|
+
formula = dd.formula(d[dd.field], d, datasClo);
|
|
43567
|
+
} else {
|
|
43568
|
+
formula = dd.formula;
|
|
43569
|
+
}
|
|
43558
43570
|
}
|
|
43559
|
-
return
|
|
43571
|
+
return {
|
|
43572
|
+
formula,
|
|
43573
|
+
value: d[dd.field]
|
|
43574
|
+
};
|
|
43560
43575
|
});
|
|
43561
43576
|
});
|
|
43562
43577
|
return {
|
|
@@ -43818,7 +43833,11 @@ function exportJsonToExcel(excelData) {
|
|
|
43818
43833
|
const mergeEndCol = j + 1 + colSpan - 1;
|
|
43819
43834
|
if (mergeEndRow < rowsNow + jsonData.length && mergeEndCol <= columnCount) {
|
|
43820
43835
|
worksheet.mergeCells(rowsNow + i, j + 1, mergeEndRow, mergeEndCol);
|
|
43821
|
-
if (columnType[j] === "
|
|
43836
|
+
if (columnType[j] === "p" && lineData[j]) {
|
|
43837
|
+
const numericValue = typeof lineData[j].value === "string" ? parseFloat(lineData[j].value.replace(/,/g, "")) : lineData[j].value;
|
|
43838
|
+
worksheet.getCell(rowsNow + i, j + 1).value = isNaN(numericValue) ? 0 : parseFloat(numericValue / 100);
|
|
43839
|
+
dataCellStyle2.numFmt = numberFormat[j];
|
|
43840
|
+
} else if (columnType[j] === "s") {
|
|
43822
43841
|
if (lineData[j] === "0") {
|
|
43823
43842
|
worksheet.getCell(rowsNow + i, j + 1).value = 0;
|
|
43824
43843
|
} else if (lineData[j] !== void 0 && lineData[j] !== null) {
|
|
@@ -43868,7 +43887,11 @@ function exportJsonToExcel(excelData) {
|
|
|
43868
43887
|
}
|
|
43869
43888
|
}
|
|
43870
43889
|
if (!mergedCells.has(cellKey)) {
|
|
43871
|
-
if (columnType[j] === "
|
|
43890
|
+
if (columnType[j] === "p" && lineData[j]) {
|
|
43891
|
+
const numericValue = typeof lineData[j].value === "string" ? parseFloat(lineData[j].value.replace(/,/g, "")) : lineData[j].value;
|
|
43892
|
+
worksheet.getCell(rowsNow + i, j + 1).value = isNaN(numericValue) ? 0 : parseFloat(numericValue / 100);
|
|
43893
|
+
dataCellStyle2.numFmt = numberFormat[j];
|
|
43894
|
+
} else if (columnType[j] === "s") {
|
|
43872
43895
|
if (lineData[j] === "0") {
|
|
43873
43896
|
worksheet.getCell(rowsNow + i, j + 1).value = 0;
|
|
43874
43897
|
} else if (lineData[j] !== void 0 && lineData[j] !== null) {
|