From e8cdd22396d68871bed48610530a89063d63bb40 Mon Sep 17 00:00:00 2001
From: yz3456 <2753272399@qq.com>
Date: 星期二, 06 八月 2024 08:33:28 +0800
Subject: [PATCH] 修改了直播时间和用户管理父母

---
 ruoyi-ui/src/views/system/user/index.vue |    5 +++++
 ruoyi-ui/src/views/meeting/Home.vue      |   29 +++++++++++++++++++++++++----
 2 files changed, 30 insertions(+), 4 deletions(-)

diff --git a/ruoyi-ui/src/views/meeting/Home.vue b/ruoyi-ui/src/views/meeting/Home.vue
index 337d8e3..e09ac85 100644
--- a/ruoyi-ui/src/views/meeting/Home.vue
+++ b/ruoyi-ui/src/views/meeting/Home.vue
@@ -80,6 +80,7 @@
     return {
       user:{},
       showComponent: false,
+      time:undefined,
       loading: true,
       // 浼氳鍩烘湰淇℃伅
       sdkAppId: 1600032250,
@@ -97,9 +98,10 @@
 
 computed: {
     isStartExercise() {
-      let roomId = this.roomId
+      let roomId = this.roomId;
       let userId = this.userId;
-      return { roomId, userId };
+      let time = this.time
+      return { roomId, userId, time };
     }
 },
 
@@ -110,10 +112,11 @@
       handler(n) {
         if (n.roomId && n.userId) {
           // 鍒ゆ柇杩欎袱涓�煎悓鏃跺瓨鍦�
-          // alert(this.userId)
-          // alert(this.roomId)
           this.loading = false;
           this.showComponent = true;
+        }
+        if(n.time == false){
+          this.showComponent = false;
         }
       },
     }
@@ -125,6 +128,23 @@
       const id = this.$route.params && this.$route.params.id;
       getWebcastInfo(id).then(response => {
         this.roomId = response.data.roomId
+        console.log(response.data,'datadtaadadsd')
+
+        let time = response.data.startTime.split(' ')[0]
+        // let now = new Date();
+        // let dateStr = now.toLocaleDateString().replaceAll('/','-'); // 鏈湴鏍煎紡鐨勬棩鏈熷瓧绗︿覆
+        const now = new Date();
+        const year = now.getFullYear();
+        const month = (now.getMonth() + 1).toString().padStart(2, '0');
+        const day = now.getDate().toString().padStart(2, '0');
+        let dateStr = `${year}-${month}-${day}`;
+        if(time == dateStr){
+          this.time = true
+        }else{
+          this.time = false
+          this.$modal.msgSuccess("涓嶅湪鐩存挱鏃堕棿鑼冨洿锛�");
+        }
+
       })
     },
     // 鑾峰彇鐢ㄦ埛鍚�
@@ -135,6 +155,7 @@
         // alert(this.userId)
         // alert(this.roomId)
       });
+
       // setTimeout(() => {
       //   this.loading = false;
       //   this.showComponent = true;
diff --git a/ruoyi-ui/src/views/system/user/index.vue b/ruoyi-ui/src/views/system/user/index.vue
index baf41eb..1ca6548 100644
--- a/ruoyi-ui/src/views/system/user/index.vue
+++ b/ruoyi-ui/src/views/system/user/index.vue
@@ -566,6 +566,7 @@
     handleClose(){
       this.pOID = ''
       this.allInfo2 = []
+      // this.reset();
       // alert(this.pOID)
     },
 
@@ -611,6 +612,8 @@
 				//alert(fid)
 				_this.$set(_this.form,'fid',_this.orfid);
 				this.$modal.msgSuccess("涓嶈兘閫夋嫨瀛愬瓩涓虹埗浜诧紒");
+        this.form.fid = undefined
+        this.form.mid = undefined
 			}
 		})
 	},
@@ -655,6 +658,8 @@
 				//alert(fid)
 				_this.$set(_this.form,'mid',_this.ormid);
 				this.$modal.msgSuccess("涓嶈兘閫夋嫨瀛愬瓩涓烘瘝浜诧紒");
+        this.form.fid = undefined
+        this.form.mid = undefined
 			}
 		})
 	},

--
Gitblit v1.9.1