1. async function exportUsers() {
    2. try {
    3. let { data } = await axios.get("/users/export", {
    4. responseType: "blob"
    5. });
    6. let URL = window.URL || window.webkitURL;
    7. let objectUrl = URL.createObjectURL(data);
    8. let a = document.createElement("a");
    9. a.href = objectUrl; // 文件流生成的url
    10. a.download = "未来软件工作室用户信息"; // 文件名
    11. document.body.appendChild(a);
    12. a.click();
    13. a.remove();
    14. } catch {
    15. }
    16. }