/* empty css                   */import{h as t}from"./elementPlus.CqHltQSO.js";async function u({apiMethod:r,queryParams:c={},fileName:n="下载文件.xlsx",successMessage:s=()=>t.success("文件下载成功！"),errorMessage:a=()=>t.error("文件下载失败，请重试！")}){try{const o=await r(c),d=window.URL.createObjectURL(new Blob([o.data])),e=document.createElement("a");e.href=d,e.setAttribute("download",n),document.body.appendChild(e),e.click(),document.body.removeChild(e),s()}catch(o){a(),console.error("下载文件出错:",o)}}export{u};
