@@ -40,6 +39,7 @@
{{
approveStatus !== '通过' &&
+ !role &&
(carditem.attrType === '部门联系人' ||
carditem.attrType === '联系人电话')
? '请申请后查看'
@@ -50,6 +50,7 @@
:class="{
'blur-word':
approveStatus !== '通过' &&
+ !role &&
(carditem.attrType === '部门联系人' ||
carditem.attrType === '联系人电话'),
}"
@@ -80,7 +81,15 @@
import { pinyin } from 'pinyin-pro'
import { message } from 'ant-design-vue'
import { useRouter } from 'vue-router'
+ import { useStore } from 'vuex'
const router = useRouter()
+ const store = useStore()
+ const role = ref(false)
+ store.getters['user/roleList'].map((val) => {
+ if (val === '运维管理员') {
+ role.value = true
+ }
+ })
const approveStatus = ref('通过')
const whoShow1 = ref(whoShow)
let flag = ref(true)
diff --git a/front/src/views/detailsAll/components/LayerService/LayerServiceUsageMode.vue b/front/src/views/detailsAll/components/LayerService/LayerServiceUsageMode.vue
index f4f8eee2..f9c7ce3a 100644
--- a/front/src/views/detailsAll/components/LayerService/LayerServiceUsageMode.vue
+++ b/front/src/views/detailsAll/components/LayerService/LayerServiceUsageMode.vue
@@ -7,8 +7,7 @@
:type="dataFrom.englishTitle"
>
-
+
@@ -63,12 +62,14 @@
{{
- approveStatus === '通过'
+ approveStatus === '通过' || role
? item.people.value
: '请申请后查看'
}}
-
+
{{ item.people.value }}
@@ -78,12 +79,14 @@
{{
- approveStatus === '通过'
+ approveStatus === '通过' || role
? item.phone.value
: '请申请后查看'
}}
-
+
{{ item.phone.value }}
@@ -135,7 +138,15 @@
import { pinyin } from 'pinyin-pro'
import { ref, defineProps, watch } from 'vue'
import { useRouter } from 'vue-router'
+ import { useStore } from 'vuex'
const router = useRouter()
+ const store = useStore()
+ const role = ref(false)
+ store.getters['user/roleList'].map((val) => {
+ if (val === '运维管理员') {
+ role.value = true
+ }
+ })
const approveStatus = ref('通过')
const whoShow1 = ref(whoShow)
let dataFrom = ref({
From 3d90e736594b87be85e1a44389ee79aa9262a0cd Mon Sep 17 00:00:00 2001
From: a0049873 <79py69t9wb@privaterelay.appleid.com>
Date: Tue, 29 Nov 2022 17:37:10 +0800
Subject: [PATCH 3/3] =?UTF-8?q?=E5=B7=B2=E7=94=B3=E8=AF=B7=E5=88=97?=
=?UTF-8?q?=E8=A1=A8=E6=B7=BB=E5=8A=A0websocket?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
front/src/App.vue | 12 ++++++++++--
front/src/views/home/infrastructureApplication.vue | 6 +++++-
2 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/front/src/App.vue b/front/src/App.vue
index 73173a58..8644867e 100644
--- a/front/src/App.vue
+++ b/front/src/App.vue
@@ -2,7 +2,7 @@
* @Author: hisense.wuhongjian
* @Date: 2022-05-06 11:12:00
* @LastEditors: Light
- * @LastEditTime: 2022-11-24 10:53:41
+ * @LastEditTime: 2022-11-29 17:28:20
* @Description: 告诉大家这是什么
-->
@@ -19,13 +19,14 @@
import { getCategoryTreePage } from '@/api/personalCenter'
import zhCN from 'ant-design-vue/es/locale/zh_CN'
import Cookies from 'js-cookie'
- import { onBeforeUnmount, onMounted, watch, nextTick } from 'vue'
+ import { onBeforeUnmount, onMounted, watch, ref } from 'vue'
import { useRouter } from 'vue-router'
import mybus from '@/myplugins/mybus'
const router = useRouter()
const locale = zhCN
const token = Cookies.get('ucsToken')
+ const whoShow1 = ref(whoShow)
console.log('token=================>', token)
let ws = new WebSocket(
`ws://${window.SITE_CONFIG['websocketURL']}/websocket?token=${token}`
@@ -39,6 +40,13 @@
if (router.currentRoute.value.name === 'mynoticeView') {
mybus.emit('noticeListInit')
}
+ // 判断当前路由是否是待办列表
+ if (
+ router.currentRoute.value.name === 'DetailsPageconetent' &&
+ whoShow1.value.itShowXiHaiAn
+ ) {
+ mybus.emit('initDetailsPageconetent')
+ }
}
ws.onerror = function (e) {
console.log('WebSocket连接异常============================>', e)
diff --git a/front/src/views/home/infrastructureApplication.vue b/front/src/views/home/infrastructureApplication.vue
index 13ee5cf1..b8a699dc 100644
--- a/front/src/views/home/infrastructureApplication.vue
+++ b/front/src/views/home/infrastructureApplication.vue
@@ -2,7 +2,7 @@
* @Author: Light
* @Date: 2022-11-18 11:53:43
* @LastEditors: Light
- * @LastEditTime: 2022-11-29 11:50:25
+ * @LastEditTime: 2022-11-29 17:28:02
* @Description: 告诉大家这是什么
-->
@@ -447,8 +447,12 @@
}
}
})
+ mybus.on('initDetailsPageconetent', () => {
+ initApply()
+ })
onBeforeUnmount(() => {
mybus.off('selectCamera')
+ mybus.off('initDetailsPageconetent')
})