whj 10 달 전
부모
커밋
06b927dbcc
2개의 변경된 파일11개의 추가작업 그리고 5개의 파일을 삭제
  1. 1 1
      src/views/custom/relation/CustomRelation.vue
  2. 10 4
      src/views/custom/relation/modules/Detail.vue

+ 1 - 1
src/views/custom/relation/CustomRelation.vue

@@ -155,7 +155,7 @@ export default {
       },
       optionAlertShow: false,
       categoryMap: {},
-      childrenMaps: [],
+      childrenMaps: {},
     }
   },
   created() {

+ 10 - 4
src/views/custom/relation/modules/Detail.vue

@@ -8,8 +8,8 @@
       </a-col>
     </a-row>
     <detail-list title="" :col="2">
-      <detail-list-item term="模板分类">{{ model.category }}</detail-list-item>
-      <detail-list-item term="表单分类">{{ model.type }}</detail-list-item>
+      <detail-list-item term="模板分类">{{ categoryMap[model.category] }}</detail-list-item>
+      <detail-list-item term="表单分类">{{ this.childrenMaps[model.category][model.type] }}</detail-list-item>
       <detail-list-item term="备注">{{ model.remark }}</detail-list-item>
       <detail-list-item term="更新时间">{{ model.updateTime }}</detail-list-item>
       <detail-list-item term="更新人">{{ model.updateUserName }}</detail-list-item>
@@ -26,7 +26,7 @@
 <script>
 import DetailList from '@/components/tools/DetailList'
 const DetailListItem = DetailList.Item
-import { componentBaseList } from '@/views/custom/form/modules/component/modules/components'
+import { componentBaseList, componenHidetList } from '@/views/custom/form/modules/component/modules/components'
 
 export default {
   name: 'CustomRelationDetail',
@@ -38,7 +38,7 @@ export default {
     return {
       confirmLoading: false,
       mdl: {},
-      componentBaseList,
+      componentBaseList: [...componentBaseList, ...componenHidetList],
       modalTitle: null,
       visible: false,
       // 下拉框map
@@ -71,10 +71,16 @@ export default {
           key: 'value',
         },
       ],
+      categoryMap: {},
+      childrenMaps: {},
     }
   },
   created() {
     // 下拉框map
+    this.categoryMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.CATEGORY_TYPE)
+    this.DictCache.getChildrenList(this.DictCache.TYPE.CATEGORY_TYPE).forEach((item) => {
+      this.childrenMaps[item.value] = this.DictCache.getLabelByValueMapByType(item.code)
+    })
   },
   methods: {
     base(record) {