sa2kit 1.6.106 → 1.6.111
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 +11 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -7
- package/dist/index.mjs.map +1 -1
- package/dist/showmasterpiece/index.js +11 -7
- package/dist/showmasterpiece/index.js.map +1 -1
- package/dist/showmasterpiece/index.mjs +11 -7
- package/dist/showmasterpiece/index.mjs.map +1 -1
- package/dist/showmasterpiece/ui/web/index.js +11 -7
- package/dist/showmasterpiece/ui/web/index.js.map +1 -1
- package/dist/showmasterpiece/ui/web/index.mjs +11 -7
- package/dist/showmasterpiece/ui/web/index.mjs.map +1 -1
- package/dist/showmasterpiece/web/index.js +11 -7
- package/dist/showmasterpiece/web/index.js.map +1 -1
- package/dist/showmasterpiece/web/index.mjs +11 -7
- package/dist/showmasterpiece/web/index.mjs.map +1 -1
- package/dist/universalExport/index.js +6 -3
- package/dist/universalExport/index.js.map +1 -1
- package/dist/universalExport/index.mjs +6 -3
- package/dist/universalExport/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -15853,9 +15853,9 @@ var UniversalExportClient = class {
|
|
|
15853
15853
|
};
|
|
15854
15854
|
if (typeof request.configId === "string") {
|
|
15855
15855
|
requestBody.configId = request.configId;
|
|
15856
|
-
} else {
|
|
15856
|
+
} else if (request.configId && typeof request.configId === "object") {
|
|
15857
15857
|
requestBody.config = request.configId;
|
|
15858
|
-
if (request.configId
|
|
15858
|
+
if (request.configId.id) {
|
|
15859
15859
|
requestBody.configId = request.configId.id;
|
|
15860
15860
|
}
|
|
15861
15861
|
}
|
|
@@ -16004,7 +16004,10 @@ var UniversalExportClient = class {
|
|
|
16004
16004
|
* 转换API返回的导出结果
|
|
16005
16005
|
*/
|
|
16006
16006
|
transformExportResultFromAPI(apiResult) {
|
|
16007
|
-
const fileBlob = this.createFileBlobFromBase64(
|
|
16007
|
+
const fileBlob = this.createFileBlobFromBase64(
|
|
16008
|
+
apiResult.fileData ?? apiResult.fileBlob,
|
|
16009
|
+
apiResult.fileName
|
|
16010
|
+
);
|
|
16008
16011
|
return {
|
|
16009
16012
|
exportId: apiResult.exportId,
|
|
16010
16013
|
fileName: apiResult.fileName,
|
|
@@ -16808,10 +16811,10 @@ var BookingAdminPanel = ({
|
|
|
16808
16811
|
"Content-Type": "application/json"
|
|
16809
16812
|
},
|
|
16810
16813
|
body: JSON.stringify({
|
|
16814
|
+
configId: exportConfig.id,
|
|
16811
16815
|
config: exportConfig,
|
|
16812
16816
|
data: exportData,
|
|
16813
16817
|
customFileName: `\u9884\u8BA2\u4FE1\u606F_${(/* @__PURE__ */ new Date()).toISOString().split("T")[0]}${enableUserPriceCalculation ? "_\u542B\u7528\u6237\u603B\u4EF7" : ""}`,
|
|
16814
|
-
// 不传递分页参数,避免导出时被分页限制
|
|
16815
16818
|
pagination: void 0
|
|
16816
16819
|
})
|
|
16817
16820
|
});
|
|
@@ -16820,10 +16823,11 @@ var BookingAdminPanel = ({
|
|
|
16820
16823
|
throw new Error(errorData.error || `\u5BFC\u51FA\u5931\u8D25: ${response.statusText}`);
|
|
16821
16824
|
}
|
|
16822
16825
|
const responseData = await response.json();
|
|
16823
|
-
|
|
16826
|
+
const base64Payload = responseData.result?.fileData ?? responseData.result?.fileBlob;
|
|
16827
|
+
if (responseData.result && base64Payload) {
|
|
16824
16828
|
console.log("\u{1F4C1} [BookingAdminPanel] \u68C0\u6D4B\u5230\u6587\u4EF6\u6570\u636E\uFF0C\u5F00\u59CB\u4E0B\u8F7D");
|
|
16825
|
-
const {
|
|
16826
|
-
const binaryString = atob(
|
|
16829
|
+
const { fileName } = responseData.result;
|
|
16830
|
+
const binaryString = atob(base64Payload);
|
|
16827
16831
|
const bytes = new Uint8Array(binaryString.length);
|
|
16828
16832
|
for (let i = 0; i < binaryString.length; i++) {
|
|
16829
16833
|
bytes[i] = binaryString.charCodeAt(i);
|