mirror of
https://gitee.com/beijing_hongye_huicheng/lilishop-ui.git
synced 2026-09-21 12:22:03 +08:00
优化财务相关功能
This commit is contained in:
15
seller/src/utils/downloadBlob.js
Normal file
15
seller/src/utils/downloadBlob.js
Normal file
@@ -0,0 +1,15 @@
|
||||
/**
|
||||
* 触发浏览器下载 blob 响应
|
||||
*/
|
||||
export function downloadBlob(blob, filename) {
|
||||
if (!blob) return;
|
||||
const link = document.createElement("a");
|
||||
link.style.display = "none";
|
||||
const url = window.URL.createObjectURL(new Blob([blob]));
|
||||
link.href = url;
|
||||
link.download = filename;
|
||||
document.body.appendChild(link);
|
||||
link.click();
|
||||
document.body.removeChild(link);
|
||||
window.URL.revokeObjectURL(url);
|
||||
}
|
||||
@@ -126,8 +126,6 @@ export function unixSellerBillStatus(status_code) {
|
||||
return "已出账";
|
||||
case "CHECK":
|
||||
return "已对账";
|
||||
case "EXAMINE":
|
||||
return "已审核";
|
||||
case "PAY":
|
||||
return "已结算";
|
||||
case "COMPLETE":
|
||||
|
||||
Reference in New Issue
Block a user