mirror of
https://gitee.com/dapppp/ruoyi-plus-vben5.git
synced 2026-04-14 04:53:14 +08:00
refactor: 移除 Modal 组件直接导入,统一使用 window.modal 调用
将项目中直接导入的 antdv-next Modal 组件替换为通过 window.modal 调用,提升代码一致性 删除不再使用的 table-switch.vue 组件
This commit is contained in:
@@ -8,7 +8,7 @@ import { h, ref } from 'vue';
|
||||
import { CodeMirror, Page, useVbenModal } from '@vben/common-ui';
|
||||
|
||||
import { useClipboard } from '@vueuse/core';
|
||||
import { Alert, Card, Modal, RadioGroup, Switch } from 'antdv-next';
|
||||
import { Alert, Card, RadioGroup, Switch } from 'antdv-next';
|
||||
|
||||
import { FileUpload, ImageUpload } from '#/components/upload';
|
||||
|
||||
@@ -22,7 +22,7 @@ const multipleImageId = ref<string[]>(['1905537674682916865']);
|
||||
const multipleFileId = ref<string[]>(['1905191167882518529']);
|
||||
|
||||
function handlePreview(file: UploadFile) {
|
||||
Modal.info({
|
||||
window.modal.info({
|
||||
content: h('div', { class: 'break-all' }, JSON.stringify(file, null, 2)),
|
||||
maskClosable: true,
|
||||
});
|
||||
|
||||
@@ -3,7 +3,7 @@ import { h } from 'vue';
|
||||
|
||||
import { JsonPreview, useVbenModal } from '@vben/common-ui';
|
||||
|
||||
import { Modal, Space } from 'antdv-next';
|
||||
import { Space } from 'antdv-next';
|
||||
|
||||
import { useVbenForm } from '#/adapter/form';
|
||||
|
||||
@@ -35,7 +35,7 @@ async function getValues() {
|
||||
const v = await formApi.getValues();
|
||||
console.log(v);
|
||||
|
||||
Modal.info({
|
||||
window.modal.info({
|
||||
content: () => h(JsonPreview, { data: v }),
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
@@ -5,7 +5,7 @@ import { nextTick, onMounted } from 'vue';
|
||||
|
||||
import { JsonPreview } from '@vben/common-ui';
|
||||
|
||||
import { Button, Input, InputNumber, Modal, Select, Space } from 'antdv-next';
|
||||
import { Button, Input, InputNumber, Select, Space } from 'antdv-next';
|
||||
|
||||
import { useVbenVxeGrid } from '#/adapter/vxe-table';
|
||||
|
||||
@@ -248,7 +248,7 @@ function getData() {
|
||||
const data = tableApi.grid.getTableData();
|
||||
const { fullData } = data;
|
||||
console.log(fullData);
|
||||
Modal.info({
|
||||
window.modal.info({
|
||||
title: '提示',
|
||||
content: (
|
||||
<div class="max-h-[350px] overflow-y-auto">
|
||||
|
||||
Reference in New Issue
Block a user