refactor: download.ts 使用@vben/utils替换
This commit is contained in:
@@ -7,6 +7,7 @@ import type { SystemSmsChannelApi } from '#/api/system/sms/channel';
|
||||
|
||||
import { Page, useVbenModal } from '@vben/common-ui';
|
||||
import { Download, Plus } from '@vben/icons';
|
||||
import { downloadFileFromBlobPart } from '@vben/utils';
|
||||
|
||||
import { Button, message } from 'ant-design-vue';
|
||||
|
||||
@@ -18,7 +19,6 @@ import {
|
||||
} from '#/api/system/sms/channel';
|
||||
import { DocAlert } from '#/components/doc-alert';
|
||||
import { $t } from '#/locales';
|
||||
import { downloadByData } from '#/utils/download';
|
||||
|
||||
import { useGridColumns, useGridFormSchema } from './data';
|
||||
import Form from './modules/form.vue';
|
||||
@@ -36,7 +36,7 @@ function onRefresh() {
|
||||
/** 导出表格 */
|
||||
async function onExport() {
|
||||
const data = await exportSmsChannel(await gridApi.formApi.getValues());
|
||||
downloadByData(data, '短信渠道.xls');
|
||||
downloadFileFromBlobPart({ fileName: '短信渠道.xls', source: data });
|
||||
}
|
||||
|
||||
/** 创建短信渠道 */
|
||||
|
||||
Reference in New Issue
Block a user