import { ElMessage, ElMessageBox } from "element-plus";
先引入
ElMessageBox.confirm("是否确认下载所有数据?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(async () => {
proxy.download(
"/prod-control/network/export",
{
...queryParams.value,
},
`水网导出.xlsx`
);
})
.catch(() => {
ElMessage({
type: "info",
message: "下载失败",
});
});