perf: 优化导出导入
This commit is contained in:
17
apps/web-antd/src/views/crm/product/index.ts
Normal file
17
apps/web-antd/src/views/crm/product/index.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import { defineAsyncComponent } from 'vue';
|
||||
|
||||
export const ProductDetailsInfo = defineAsyncComponent(
|
||||
() => import('./modules/detail-info.vue'),
|
||||
);
|
||||
|
||||
export const ProductForm = defineAsyncComponent(
|
||||
() => import('./modules/form.vue'),
|
||||
);
|
||||
|
||||
export const ProductDetails = defineAsyncComponent(
|
||||
() => import('./modules/detail.vue'),
|
||||
);
|
||||
|
||||
export const ProductDetailsList = defineAsyncComponent(
|
||||
() => import('./modules/detail-list.vue'),
|
||||
);
|
||||
@@ -2,7 +2,7 @@
|
||||
import type { CrmProductApi } from '#/api/crm/product';
|
||||
import type { SystemOperateLogApi } from '#/api/system/operate-log';
|
||||
|
||||
import { defineAsyncComponent, onMounted, ref } from 'vue';
|
||||
import { onMounted, ref } from 'vue';
|
||||
import { useRoute, useRouter } from 'vue-router';
|
||||
|
||||
import { Page } from '@vben/common-ui';
|
||||
@@ -14,17 +14,11 @@ import { getOperateLogPage } from '#/api/crm/operateLog';
|
||||
import { BizTypeEnum } from '#/api/crm/permission';
|
||||
import { getProduct } from '#/api/crm/product';
|
||||
import { useDescription } from '#/components/description';
|
||||
import { AsyncOperateLog } from '#/components/operate-log';
|
||||
import { ProductDetailsInfo } from '#/views/crm/product';
|
||||
|
||||
import { useDetailSchema } from './detail-data';
|
||||
|
||||
const ProductDetailsInfo = defineAsyncComponent(
|
||||
() => import('./detail-info.vue'),
|
||||
);
|
||||
|
||||
const OperateLog = defineAsyncComponent(
|
||||
() => import('#/components/operate-log'),
|
||||
);
|
||||
|
||||
const loading = ref(false);
|
||||
|
||||
const route = useRoute();
|
||||
@@ -87,7 +81,7 @@ onMounted(() => {
|
||||
<ProductDetailsInfo :product="product" />
|
||||
</Tabs.TabPane>
|
||||
<Tabs.TabPane tab="操作日志" key="2" :force-render="true">
|
||||
<OperateLog :log-list="productLogList" />
|
||||
<AsyncOperateLog :log-list="productLogList" />
|
||||
</Tabs.TabPane>
|
||||
</Tabs>
|
||||
</Card>
|
||||
|
||||
Reference in New Issue
Block a user