sa2kit 1.6.106 → 1.6.112
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.js +9 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +9 -9
- package/dist/index.mjs.map +1 -1
- package/dist/showmasterpiece/index.js +9 -9
- package/dist/showmasterpiece/index.js.map +1 -1
- package/dist/showmasterpiece/index.mjs +9 -9
- package/dist/showmasterpiece/index.mjs.map +1 -1
- package/dist/showmasterpiece/ui/web/index.js +9 -9
- package/dist/showmasterpiece/ui/web/index.js.map +1 -1
- package/dist/showmasterpiece/ui/web/index.mjs +9 -9
- package/dist/showmasterpiece/ui/web/index.mjs.map +1 -1
- package/dist/showmasterpiece/web/index.js +9 -9
- package/dist/showmasterpiece/web/index.js.map +1 -1
- package/dist/showmasterpiece/web/index.mjs +9 -9
- package/dist/showmasterpiece/web/index.mjs.map +1 -1
- package/dist/universalExport/index.js +5 -5
- package/dist/universalExport/index.js.map +1 -1
- package/dist/universalExport/index.mjs +5 -5
- package/dist/universalExport/index.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -7317,11 +7317,8 @@ var UniversalExportClient = class {
|
|
|
7317
7317
|
};
|
|
7318
7318
|
if (typeof request.configId === "string") {
|
|
7319
7319
|
requestBody.configId = request.configId;
|
|
7320
|
-
} else {
|
|
7320
|
+
} else if (request.configId && typeof request.configId === "object") {
|
|
7321
7321
|
requestBody.config = request.configId;
|
|
7322
|
-
if (request.configId?.id) {
|
|
7323
|
-
requestBody.configId = request.configId.id;
|
|
7324
|
-
}
|
|
7325
7322
|
}
|
|
7326
7323
|
if (isDataArray) {
|
|
7327
7324
|
requestBody.data = request.dataSource;
|
|
@@ -7468,7 +7465,10 @@ var UniversalExportClient = class {
|
|
|
7468
7465
|
* 转换API返回的导出结果
|
|
7469
7466
|
*/
|
|
7470
7467
|
transformExportResultFromAPI(apiResult) {
|
|
7471
|
-
const fileBlob = this.createFileBlobFromBase64(
|
|
7468
|
+
const fileBlob = this.createFileBlobFromBase64(
|
|
7469
|
+
apiResult.fileData ?? apiResult.fileBlob,
|
|
7470
|
+
apiResult.fileName
|
|
7471
|
+
);
|
|
7472
7472
|
return {
|
|
7473
7473
|
exportId: apiResult.exportId,
|
|
7474
7474
|
fileName: apiResult.fileName,
|
|
@@ -8275,7 +8275,6 @@ var BookingAdminPanel = ({
|
|
|
8275
8275
|
config: exportConfig,
|
|
8276
8276
|
data: exportData,
|
|
8277
8277
|
customFileName: `\u9884\u8BA2\u4FE1\u606F_${(/* @__PURE__ */ new Date()).toISOString().split("T")[0]}${enableUserPriceCalculation ? "_\u542B\u7528\u6237\u603B\u4EF7" : ""}`,
|
|
8278
|
-
// 不传递分页参数,避免导出时被分页限制
|
|
8279
8278
|
pagination: void 0
|
|
8280
8279
|
})
|
|
8281
8280
|
});
|
|
@@ -8284,10 +8283,11 @@ var BookingAdminPanel = ({
|
|
|
8284
8283
|
throw new Error(errorData.error || `\u5BFC\u51FA\u5931\u8D25: ${response.statusText}`);
|
|
8285
8284
|
}
|
|
8286
8285
|
const responseData = await response.json();
|
|
8287
|
-
|
|
8286
|
+
const base64Payload = responseData.result?.fileData ?? responseData.result?.fileBlob;
|
|
8287
|
+
if (responseData.result && base64Payload) {
|
|
8288
8288
|
console.log("\u{1F4C1} [BookingAdminPanel] \u68C0\u6D4B\u5230\u6587\u4EF6\u6570\u636E\uFF0C\u5F00\u59CB\u4E0B\u8F7D");
|
|
8289
|
-
const {
|
|
8290
|
-
const binaryString = atob(
|
|
8289
|
+
const { fileName } = responseData.result;
|
|
8290
|
+
const binaryString = atob(base64Payload);
|
|
8291
8291
|
const bytes = new Uint8Array(binaryString.length);
|
|
8292
8292
|
for (let i = 0; i < binaryString.length; i++) {
|
|
8293
8293
|
bytes[i] = binaryString.charCodeAt(i);
|