Browse Source

feat 会议场景弹窗

anxiaoxia 1 year ago
parent
commit
556a381fa2

+ 116 - 0
src/packagesEnv/pages/officehome/Meeting/pop-meet-scene.wpy

@@ -0,0 +1,116 @@
+<style lang="less" scoped>
+.meet-popup {
+    position: relative;
+    height: 580rpx;
+    width: 622rpx;
+    text-align: center;
+    .meet_head {
+        width: 100%;
+        height: 90rpx;
+        background: #96f2e366;
+    }
+    .meet_head_bg {
+        width: 100%;
+        height: 150rpx;
+        border-radius: 0 0 50% 50%;
+        background: #96f2e366;
+    }
+
+    .meet_body {
+        .meet_body_text {
+            font-family: PingFang SC;
+            font-size: 28rpx;
+            font-weight: 400;
+            line-height: 44rpx;
+            color: #8b949e;
+        }
+    }
+    .meet_content {
+        padding-top: 58rpx;
+        padding-bottom: 16rpx;
+        .meet-title {
+            font-family: PingFang SC;
+            font-size: 36rpx;
+            font-weight: 600;
+            line-height: 56rpx;
+            color: #8b949e;
+            .name {
+                color: #1b2129;
+                margin-left: 14rpx;
+                margin-right: 14rpx;
+            }
+        }
+    }
+
+    .meet_dis {
+        position: absolute;
+        bottom: 0px;
+        display: flex;
+        align-items: center;
+        justify-content: center;
+        height: 96rpx;
+        width: 100%;
+        border-top: 1rpx solid #e8ecf0;
+        .meet_dis_btn {
+            font-family: PingFang SC;
+            font-size: 32rpx;
+            font-weight: 400;
+            line-height: 48rpx;
+            color: #1db1b2;
+        }
+    }
+}
+</style>
+
+<template>
+    <div
+        class="meet-popup"
+    >
+        <div class="meet_head">
+        </div>
+        <div class="meet_head_bg"></div>
+        <div class="meet_content">
+            <span class="meet-title">切换至<span class="name">{{sceneDetail.name}}</span>场景</span>
+        </div>
+        <div class="meet_body">
+            <div
+                class="meet_body_text"
+                v-for="(item,idx) in sceneDetail.textObj"
+                :key="idx"
+            >
+                <span>{{item.text}}</span>
+            </div>
+        </div>
+        <div
+            class="meet_dis"
+            @click.stop="hideScene"
+        >
+            <span class="meet_dis_btn">知道了</span>
+        </div>
+    </div>
+</template>
+<script>
+import wepy from '@wepy/core'
+import config from '@/config'
+
+wepy.component({
+  props: {
+    sceneDetail: Object
+  },
+  data: {
+
+  },
+  watch: {
+    sceneDetail: {
+      handler(val) {},
+      immediate: true
+    }
+  },
+  methods: {
+    hideScene() {
+      this.$emit('close-scene-show', false)
+    }
+  }
+
+})
+</script>

+ 7 - 90
src/packagesEnv/pages/officehome/index.wpy

@@ -506,29 +506,12 @@
             <!--场景 - 详情 -->
             <!--场景 - 详情 -->
             <div
             <div
                 v-if="options.roomType !='开放'"
                 v-if="options.roomType !='开放'"
-                class="scene-popup meet-popup"
+                class="meet-popup"
             >
             >
-                <div class="meet_head">
-                </div>
-                <div class="meet_head_bg"></div>
-                <div class="meet_content">
-                    <span class="meet-title">切换至<span class="name">{{sceneDetail.name}}</span>场景</span>
-                </div>
-                <div class="scene-popup-body">
-                    <div
-                        class="body-item"
-                        v-for="(item,idx) in sceneDetail.textObj"
-                        :key="idx"
-                    >
-                        <span>{{item.text}}</span>
-                    </div>
-                </div>
-                <div
-                    class="meet_dis"
-                    @click.stop="hideScene"
-                >
-                    <span class="meet_dis_btn">知道了</span>
-                </div>
+                <pop-scene 
+                    :sceneDetail="sceneDetail" 
+                    @close-scene-show="hideScene">
+                </pop-scene>  
             </div>
             </div>
 
 
         </van-popup>
         </van-popup>
@@ -801,20 +784,7 @@ wepy.page({
     headScene: '', // 头部文案
     headScene: '', // 头部文案
     headImg: '', // 头部背景图片
     headImg: '', // 头部背景图片
     options: { roomType: null, spaceId: 'Sp1101080259c4434730d12144ba890fe11f796d3143' }, // 本地数据
     options: { roomType: null, spaceId: 'Sp1101080259c4434730d12144ba890fe11f796d3143' }, // 本地数据
-        // TODO sceneDetail:null
-    sceneDetail: {
-      id: 2,
-      code: 'ADJOURNMENT',
-      name: '散会',
-      img: 'beover.svg',
-      checked: false,
-      textObj: [
-        {
-          text: '会议室内设备已切换至节能模式',
-          status: 'ok'
-        }
-      ]
-    },
+    sceneDetail: null,
     popList: [],
     popList: [],
         // 上班=ATWORK 讨论=DISCUSSING 投影=PROJECTING 散会=ADJOURNMENT 下班=OFFWORK
         // 上班=ATWORK 讨论=DISCUSSING 投影=PROJECTING 散会=ADJOURNMENT 下班=OFFWORK
     meetingRoomSence: [
     meetingRoomSence: [
@@ -2755,60 +2725,6 @@ page {
         }
         }
     }
     }
 }
 }
-.meet-popup {
-    position: relative;
-    height: 580rpx;
-    text-align: center;
-    .meet_head {
-        width: 100%;
-        height: 90rpx;
-        background: #96f2e366;
-    }
-    .meet_head_bg {
-        width: 100%;
-        height: 150rpx;
-        border-radius: 0 0 50% 50%;
-        background: #96f2e366;
-    }
-
-    .scene-popup-body {
-        margin-left: 0rpx;
-        margin-right: 0rpx;
-        align-items: center;
-    }
-    .meet_content {
-        .meet-title {
-            font-family: PingFang SC;
-            font-size: 36rpx;
-            font-weight: 600;
-            line-height: 56rpx;
-            color: #8b949e;
-            .name {
-                color: #1b2129;
-                margin-left: 14rpx;
-                margin-right: 14rpx;
-            }
-        }
-    }
-
-    .meet_dis {
-        position: absolute;
-        bottom: 0px;
-        display: flex;
-        align-items: center;
-        justify-content: center;
-        height: 96rpx;
-        width: 100%;
-        border-top: 1rpx solid #e8ecf0;
-        .meet_dis_btn {
-            font-family: PingFang SC;
-            font-size: 32rpx;
-            font-weight: 400;
-            line-height: 48rpx;
-            color: #1db1b2;
-        }
-    }
-}
 .allclose-popup {
 .allclose-popup {
     height: auto;
     height: auto;
     padding-bottom: 60rpx;
     padding-bottom: 60rpx;
@@ -2929,6 +2845,7 @@ usingComponents: {
     "work-overtime":"./workOvertime",
     "work-overtime":"./workOvertime",
     "work-overtime-hand":"./workOvertime-hand",
     "work-overtime-hand":"./workOvertime-hand",
     "space-basic":"./Header/space-basic",
     "space-basic":"./Header/space-basic",
+    "pop-scene":"./Meeting/pop-meet-scene.wpy",
     "work-off":"./components/work-off",
     "work-off":"./components/work-off",
     "work-scene-hand":"./components/work-scene-hand",
     "work-scene-hand":"./components/work-scene-hand",
     "work-scene":"./components/work-scene",
     "work-scene":"./components/work-scene",