From ac525619519abb580672bb78611ccf2a9b0a3dcb Mon Sep 17 00:00:00 2001 From: PQZ Date: Thu, 31 Oct 2024 15:43:11 +0800 Subject: [PATCH 1/2] 1 --- pages/project/project.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/project/project.vue b/pages/project/project.vue index b189f5e..706d44d 100644 --- a/pages/project/project.vue +++ b/pages/project/project.vue @@ -88,7 +88,7 @@ export default { }, methods: { submit() { - if (this.project.name == null || this.project.code == null || this.project.cost == null || this.project.price == null || this.project.spec == null || this.project.unit == null || this.project.manHour == null){ + if (this.project.name == null||this.project.name == ''){ uni.showToast({ title: '请完善信息', icon: 'none' From 6294138abebb7429667b7ab670603d475484ba84 Mon Sep 17 00:00:00 2001 From: PQZ Date: Thu, 31 Oct 2024 17:14:15 +0800 Subject: [PATCH 2/2] 111 --- components/tabBar/tabBar.vue | 1 + config.js | 4 ++-- pages-home/home/home.vue | 9 ++++++++- pages/my/myInfo.vue | 7 +++++++ 4 files changed, 18 insertions(+), 3 deletions(-) diff --git a/components/tabBar/tabBar.vue b/components/tabBar/tabBar.vue index 18aee8e..5d98139 100644 --- a/components/tabBar/tabBar.vue +++ b/components/tabBar/tabBar.vue @@ -161,6 +161,7 @@ console.log("发出提示音", res); // this.getbottom(); this.dianyidain() + this.$emit('socketSuccess') }) } diff --git a/config.js b/config.js index 5fcf339..1d95872 100644 --- a/config.js +++ b/config.js @@ -2,12 +2,12 @@ module.exports = { // baseUrl: 'https://www.nuoyunr.com', // baseUrl: 'http://124.222.105.7:48080', - baseUrl: 'http://192.168.1.17:48080', + baseUrl: 'http://192.168.1.4:48080', // baseUrl: "http://localhost:48080", imagesUrl: 'http://shequ.0315e.com/static/images/pages/', baseImageUrl: 'https://www.nuoyunr.com/minio/', shareUrl: 'https://www.lighting-it.cn/share?inviteId=', - wsUrl: 'ws://192.168.1.17:48080', + wsUrl: 'ws://192.168.1.4:48080', //com.carService.qx // 应用信息 appInfo: { diff --git a/pages-home/home/home.vue b/pages-home/home/home.vue index 93e78fc..e1f51cb 100644 --- a/pages-home/home/home.vue +++ b/pages-home/home/home.vue @@ -104,7 +104,7 @@ - + @@ -217,6 +217,13 @@ export default { } }, methods: { + + socketSuccess(){ + this.getNoReadNum() + this.onRefresherrefresh() + console.log('通知并刷新成功') + }, + gotoMsg(){ //去消息中心 uni.navigateTo({ diff --git a/pages/my/myInfo.vue b/pages/my/myInfo.vue index a94d66e..5e30423 100644 --- a/pages/my/myInfo.vue +++ b/pages/my/myInfo.vue @@ -53,6 +53,9 @@ import { removeTenantId, removeToken,removeUserInfo,removeJSONData,removeStrData } from '@/utils/auth' +import { + closeMsgSocket, +} from '@/utils/tebBarSocket' const UQRCode = require('uqrcodejs'); export default { components: { @@ -124,6 +127,10 @@ export default { uni.navigateTo({ url: '/pages/login/login' }) + if(this.$msgSocket){ + closeMsgSocket(this.$msgSocket) + } + }else{ uni.showToast({ title: res.msg,