huangxiaoming 2 лет назад
Родитель
Сommit
5acd4cc50e

+ 4 - 0
src/api/index.ts

@@ -1,6 +1,7 @@
 import { config } from './../../config'
 import axios from 'axios'
 import { headerData } from './reqHeaders'
+import { Toast } from 'vant'
 
 
 
@@ -31,7 +32,10 @@ $axios.interceptors.response.use(
   (response) => {
     // console.log(response, 78)
     if (response.data.isSuccess === 'T') {
+      // console.log("response.data=",response.data)
       return response.data.body
+    }else{
+      Toast(response.data.errorMsg || '系统异常')
     }
   }
 )

+ 26 - 0
src/components/DetailCustom/FengXianSaoMiao.vue

@@ -0,0 +1,26 @@
+<!--
+ * @Description: 
+ * @Author: 狼牙
+ * @Email: huangxiaoming@winhc.cn
+ * @Date: 2022-04-17 20:52:13
+ * @LastEditTime: 2022-04-17 21:01:05
+ * @LastEditors: 狼牙
+-->
+<template>
+  <div>
+    <!-- <component :is="store.selectDemension.detailCustomRender"></component> -->
+    <div>123</div>
+  </div>
+</template>
+
+<script lang="ts" setup>
+  import { useDemensionDetailStore } from '@/store/demensionDetail'
+  const store = useDemensionDetailStore()
+
+</script>
+
+<style lang="scss" scoped>
+
+
+</style>
+

+ 1 - 1
src/components/ListCustom/GongShangXinXi.vue

@@ -137,7 +137,6 @@
                   details.historyNames
                     ? details.historyNames
                       .split("\t;\t")
-                      .filter((i:number) => i)
                       .join("、")
                     : "-"
                 }}
@@ -242,6 +241,7 @@
       entityType: useDemensionListStore().entityType
     }
     const res:any = await $axios.get('lawyer-workbench/risk/dimension/page',{params})
+    
     details.value = res
     loadingSkeleton.value = false
   }

+ 25 - 0
src/js-pages/company-detail/FengXianSaoMiao/index.ts

@@ -0,0 +1,25 @@
+/*
+ * @Description: 
+ * @Author: 狼牙
+ * @Email: huangxiaoming@winhc.cn
+ * @Date: 2022-04-17 20:10:14
+ * @LastEditTime: 2022-04-17 21:30:19
+ * @LastEditors: 狼牙
+ */
+import { DemensionPagesInter } from '../../types'
+import FengXianSaoMiaoPage from '@/components/DetailCustom/FengXianSaoMiao.vue'
+import { shallowRef } from 'vue'
+export const FengXianSaoMiao: DemensionPagesInter = {
+  projectName: '风险扫描',
+  list: [
+    
+    {
+      routing: 'FengXianSaoMiao',
+      code: '',
+      title: '风险扫瞄',
+      companyId: 'ab154ca9fbaeb0fe6ae3cfb17359855e',
+      detailCustomRender: shallowRef(FengXianSaoMiaoPage)
+    }
+  ]
+}
+

+ 1 - 1
src/js-pages/company-detail/JiBenXinXi/index.ts

@@ -1,4 +1,4 @@
-import { DemensionPagesInter } from './../../types'
+import { DemensionPagesInter } from '../../types'
 import SheBaoRenShuVue from '@/components/ListCustom/SheBaoRenShu.vue'
 import NianDuBaoGao from '@/components/DetailCustom/NianDuBaoGao.vue'
 import CaiWuShuJu from '@/components/ListCustom/CaiWuShuJu.vue'

+ 3 - 1
src/js-pages/company-detail/index.ts

@@ -6,6 +6,8 @@ import { FaLvFengXian } from './FaLvFengXian/index'
 import { JianZhuXinXi } from './JianZhuXinXi/index'
 import { JingYingXinXi } from './JingYingXinXi/index'
 import { ZhiShiChanQuan } from './ZhiShiChanQuan/index'
+import { FengXianSaoMiao } from './FengXianSaoMiao/index'
+
 
 const companyDetail: TotalDemensionInter = {
   companyName: '企业详情',
@@ -20,6 +22,6 @@ console.log('JingYingFengXian:' + JingYingFengXian.list.length)
 console.log('JingYingXinXi:' + JingYingXinXi.list.length)
 console.log('ZhiShiChanQuan:' + ZhiShiChanQuan.list.length)
 
-companyDetail.list.push(FaLvFengXian, JiBenXinXi, JianZhuXinXi, QiYeRongZi, JingYingFengXian, JingYingXinXi, ZhiShiChanQuan)
+companyDetail.list.push(FaLvFengXian, JiBenXinXi, JianZhuXinXi, QiYeRongZi, JingYingFengXian, JingYingXinXi, ZhiShiChanQuan,FengXianSaoMiao)
 
 export default companyDetail

+ 5 - 2
src/store/demensionDetail.ts

@@ -25,8 +25,11 @@ export const useDemensionDetailStore = defineStore({
       } else {
         return demensionInfo.allDemensionArr
       }
-
-      this.getDetail()
+      //风险扫描走特殊情况,直接进去页面调用接口
+      if(!(routerName === 'FengXianSaoMiao')){
+        this.getDetail()
+      }
+      
     },
     async getDetail() {
       const route = useRoute()

+ 3 - 2
src/utils/utils.ts

@@ -55,8 +55,9 @@ export const $getDemension = (routerName?: string) => {
     return arr.reduce((total, item: any) => item.list ? demensionArr(item.list) : allDemensionArr.push(item), [])
   }
   demensionArr(pagesArr)
-  const selectDemension = allDemensionArr.find(item => (routerName ? `/${routerName}` : route.path) === `/${item.routing}`)!
-
+  console.log("allDemensionArr=",allDemensionArr)
+  const selectDemension = allDemensionArr.find(item => (routerName ? `/${routerName}` : route.path) === `/${item.routing}`)
+  
   return {
     selectDemension,
     allDemensionArr

+ 1 - 1
src/views/demension/detail.vue

@@ -45,7 +45,7 @@
         </div>
       </div>
     </div>
-    <GlSiFaCase v-if="store.info.caseNo && store.selectDemension.detailType" :caseNo="store.info.caseNo" :rowKey="store.info.rowKey"></GlSiFaCase>
+    <GlSiFaCase v-if="store.info?.caseNo && store.selectDemension.detailType" :caseNo="store.info.caseNo" :rowKey="store.info.rowKey"></GlSiFaCase>
     <DetailCustomComponent v-if="store.selectDemension" />
   </div>
 </template>