소스 검색

【功能优化】MALL:商品新增时,增加 keepalive 缓存

YunaiV 10 달 전
부모
커밋
df8b1fbc0d
2개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      src/router/modules/remaining.ts
  2. 1 1
      src/views/mall/product/spu/form/index.vue

+ 1 - 1
src/router/modules/remaining.ts

@@ -361,7 +361,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
         component: () => import('@/views/mall/product/spu/form/index.vue'),
         name: 'ProductSpuAdd',
         meta: {
-          noCache: true,
+          noCache: false, // 需要缓存
           hidden: true,
           canTo: true,
           icon: 'ep:edit',

+ 1 - 1
src/views/mall/product/spu/form/index.vue

@@ -63,7 +63,7 @@ import SkuForm from './SkuForm.vue'
 import DeliveryForm from './DeliveryForm.vue'
 import { convertToInteger, floatToFixed2, formatToFraction } from '@/utils'
 
-defineOptions({ name: 'ProductSpuForm' })
+defineOptions({ name: 'ProductSpuAdd' })
 
 const { t } = useI18n() // 国际化
 const message = useMessage() // 消息弹窗