From 878885c5872fe2fcd153a6571e75a27cb1025e97 Mon Sep 17 00:00:00 2001
From: jazz <jazzxhunter@163.com>
Date: 星期五, 08 十二月 2023 12:17:12 +0800
Subject: [PATCH] update_202312071736_项目-治疗室屏幕web-样式调整,适配ios浏览器v1

---
 src/pages/room/detail.vue |   87 +++++++++++++++++++++++++++++++++----------
 1 files changed, 66 insertions(+), 21 deletions(-)

diff --git a/src/pages/room/detail.vue b/src/pages/room/detail.vue
index 82bf9c3..244a76c 100644
--- a/src/pages/room/detail.vue
+++ b/src/pages/room/detail.vue
@@ -1,10 +1,14 @@
 <!--room-detail.vue-->
 <template>
-  <div class="page">
+  <div class="page flex flex-col">
     <div class="page_header flex flex-ver">
       <div class="left flex flex-ver" @click="back">
-        <img class="page_logo_1" src="../../assets/img/logo_1.png">
-        <img class="page_logo_2" src="../../assets/img/logo_2.png">
+        <div class="page_logo_1">
+          <img class="img" src="static/imgs/logo_1.png">
+        </div>
+        <div class="page_logo_2">
+          <img class="img" src="static/imgs/logo_2.png">
+        </div>
       </div>
       <div class="right flex-1 flex flex-jcfe flex-ver">
         <div class="reset_btn flex flex-center" @click="resetStatus">閲嶇疆鎴块棿鐘舵��</div>
@@ -17,7 +21,7 @@
       </div>
     </div>
     <!-- 鏈湁瀹夋帓 -->
-    <div v-if="!occupyInfoView && (!assignTreatList || !assignTreatList.length)" class="page_container flex flex-ver">
+    <div v-if="!occupyInfoView && (!assignTreatList || !assignTreatList.length)" class="page_container flex flex-1">
       <div class="main flex-1">
         <div v-if="roomInfo && roomInfo.roomNo" class="room_title">{{ roomInfo.roomNo }}</div>
         <div v-if="roomInfo" class="room_main_tip" style="margin-top: 93px;line-height: 186px;font-size: 140px;">-{{ statusTx[roomInfo.status] }}-</div>
@@ -25,25 +29,33 @@
           <div class="flex flex-ver">
             <div class="btn_box__item flex flex-center white" data-tx="绌洪棽" data-status="0" @click="statusChg">
               <div class="flex flex-ver">
-                <img class="icon" src="../../assets/img/free.png">
+                <div class="icon">
+                  <img class="img" src="static/imgs/free.png">
+                </div>
                 <div class="tx">绌洪棽</div>
               </div>
             </div>
             <div class="btn_box__item flex flex-center blue" data-tx="浣跨敤涓�" data-status="1" @click="statusChg">
               <div class="flex flex-ver">
-                <img class="icon" src="../../assets/img/using.png">
+                <div class="icon">
+                  <img class="img" src="static/imgs/using.png">
+                </div>
                 <div class="tx white">浣跨敤涓�</div>
               </div>
             </div>
             <div class="btn_box__item flex flex-center yellow" data-tx="瀹汉浼戞伅" data-status="2" @click="statusChg">
               <div class="flex flex-ver">
-                <img class="icon" src="../../assets/img/rest.png">
+                <div class="icon">
+                  <img class="img" src="static/imgs/rest.png">
+                </div>
                 <div class="tx">瀹汉浼戞伅</div>
               </div>
             </div>
             <div class="btn_box__item flex flex-center gray" data-tx="閫氱煡鎵撴壂" data-status="3" @click="statusChg">
               <div class="flex flex-ver">
-                <img class="icon" src="../../assets/img/clear.png">
+                <div class="icon">
+                  <img class="img" src="static/imgs/clear.png">
+                </div>
                 <div class="tx">閫氱煡鎵撴壂</div>
               </div>
             </div>
@@ -52,7 +64,7 @@
       </div>
     </div>
     <!-- 娌℃湁瀹汉鍜屾湁瀹夋帓 -->
-    <div v-if="!occupyInfoView && (assignTreatList && assignTreatList.length)" class="page_container flex flex-ver">
+    <div v-if="!occupyInfoView && (assignTreatList && assignTreatList.length)" class="page_container flex flex-1">
       <div class="main flex-1">
         <div v-if="roomInfo && roomInfo.roomNo" class="room_title">{{ roomInfo.roomNo }}</div>
         <div v-if="roomInfo" class="room_main_tip">-{{ statusTx[roomInfo.status] }}-</div>
@@ -82,7 +94,9 @@
                   <span class="tx flex-1 flex-1-w1 ell">{{ item.aDoctorName?item.aDoctorName+'(鍖荤敓)銆�':'' }}{{ item.aNurseName?item.aNurseName+'(鎶ゅ+)':'' }}</span>
                 </div>
                 <div class="guest_list__td flex flex-center">
-                  <img class="icon" src="../../assets/img/choose.png">
+                  <div class="icon">
+                    <img class="img" src="static/imgs/choose.png">
+                  </div>
                 </div>
               </div>
             </div>
@@ -91,7 +105,7 @@
       </div>
     </div>
     <!-- 瀹汉鍜屾湁瀹夋帓 -->
-    <div v-if="occupyInfoView && (assignTreatList && assignTreatList.length)" class="page_container flex flex-ver">
+    <div v-if="occupyInfoView && (assignTreatList && assignTreatList.length)" class="page_container flex flex-1">
       <div class="main flex-1">
         <div v-if="roomInfo && roomInfo.roomNo" class="room_title">{{ roomInfo.roomNo }}</div>
         <div class="room_content">
@@ -166,7 +180,9 @@
                   <span class="tx flex-1 flex-1-w1 ell">{{ item.aDoctorName?item.aDoctorName+'(鍖荤敓)銆�':'' }}{{ item.aNurseName?item.aNurseName+'(鎶ゅ+)':'' }}</span>
                 </div>
                 <div class="guest_list__td flex flex-center">
-                  <img class="icon" src="../../assets/img/choose.png">
+                  <div class="icon">
+                    <img class="img" src="static/imgs/choose.png">
+                  </div>
                 </div>
               </div>
             </div>
@@ -193,6 +209,7 @@
 import XioRoomStatusChg from '@/components/xio_room_status_chg'
 import Req from '../../utils/jun_httpInstall' // http 璇锋眰
 var isUseDefault = false // 鏄惁宸蹭娇鐢ㄩ粯璁ゅ浜�
+var isUseDefaultChg = 0// 宸蹭娇鐢ㄩ粯璁ゅ浜哄悗鎴块棿鏄惁鏈夋敼鍙樼姸鎬�
 export default {
   name: 'RoomDetail',
   components: {
@@ -217,8 +234,8 @@
         return this.occupyInfo
       // 娌℃湁鍗犵敤
       } else {
-        // 杩樻病浣跨敤榛樿瀹汉鍊�
-        if (!isUseDefault && this.assignTreatList && this.assignTreatList.length) {
+        // 杩樻病浣跨敤榛樿瀹汉鍊兼垨鑰呭凡浣跨敤榛樿瀹汉鍊艰繕娌℃敼鍙樼姸鎬侊紙閫傞厤杞锛�
+        if ((!isUseDefault || (isUseDefault && isUseDefaultChg === 0)) && this.assignTreatList && this.assignTreatList.length) {
           isUseDefault = true
           return this.assignTreatList[0]
         // 宸蹭娇鐢ㄨ繃榛樿瀹汉鍊�
@@ -240,8 +257,8 @@
       // 璁℃椂
       this.countGetTime(this, 'timeObj', 'detail')
       // 杞getData锛�8绉掍竴娆�
-      // this.pollingAjaxFn(this, 'getData', 'detail', 8000)
-      this.getData()
+      this.pollingAjaxFn(this, 'getData', 'detail', 8000)
+      // this.getData()
     },
     // 鑾峰彇鎴块棿璇︽儏
     getData() {
@@ -251,14 +268,23 @@
         params.shopRoomId = this.id
       }
       Req.http.post({
-        url: 'treat/screen/room/info',
+        url: 'guide/treat/screen/room/info',
         data: params,
         udData: { noLoading: true },
         header: { 'Content-Type': 'application/json' },
         mockData: {
           code: 100,
           msg: '',
-          data: {}
+          data: {
+            roomInfo: {
+              roomNo: 'xx',
+              status: 0 // 0绌洪棽 1浣跨敤 2浼戞伅 3鎵撴壂
+            },
+            assignTreatList: [{
+              startTime: '2023-12-08 00:00:00'
+            }],
+            occupyInfo: null
+          }
         }
       }).then((res) => {
         if (res && res.data) {
@@ -269,6 +295,9 @@
               o.startTime = `${st[0]}:${st[1]}`
             })
           }
+          // 宸叉湁鍗犵敤鐨勶紝鏇存敼宸蹭娇鐢ㄩ粯璁ゅ浜虹殑鐘舵��
+          res.data.occupyInfo && (isUseDefaultChg = 1)
+          res.data.occupyInfo && (isUseDefault = 1)
           // 鍗犵敤淇℃伅娌荤枟鏃堕棿澶勭悊
           if (res.data.occupyInfo && res.data.occupyInfo.startTime) {
             var ost = (res.data.occupyInfo.startTime).split(' ')[1].split(':')
@@ -284,6 +313,7 @@
     // 杩斿洖
     back() {
       isUseDefault = false
+      isUseDefaultChg = 0
       // 鍏抽棴璁℃椂
       this.stopCountGetTime('detail')
       // 鍏抽棴杞
@@ -326,7 +356,7 @@
         params.treatRecordId = item.id
       }
       Req.http.post({
-        url: 'treat/screen/room/status/update',
+        url: 'guide/treat/screen/room/status/update',
         data: params,
         header: { 'Content-Type': 'application/json' },
         mockData: {
@@ -335,6 +365,10 @@
           data: {}
         }
       }).then((res) => {
+        // 鍦ㄥ凡鏈夐粯璁ゅ浜虹殑鎯呭喌涓嬶紝鏀瑰彉鐘舵�佹洿鏀规爣璇嗭紙閫傞厤杞锛�
+        if (isUseDefault) {
+          isUseDefaultChg = 1
+        }
         // console.log('8888888888888888888888888888888888', res)
         cb && cb()
       })
@@ -392,6 +426,9 @@
 </style>
 
 <style scoped>
+.page{
+  overflow: auto;
+}
 .page_header .reset_btn {
   width: 200px;
   height: 60px;
@@ -405,7 +442,7 @@
   cursor: pointer;
 }
 .page_container .main {
-  height: 100%;
+  /* height: 100%; */
   border-radius: 10px;
   background-color: rgba(255,255,255,1);
   color: rgba(16,16,16,1);
@@ -467,6 +504,10 @@
   height: 60px;
   display: block;
   margin-right: 17px;
+}
+.page_container .main .btn_box__item .icon .img {
+  width: 100%;
+  height: 100%;
 }
 .page_container .main .btn_box__item .tx {
   line-height: 37px;
@@ -556,7 +597,7 @@
 .page_container .right {
   width: 686px;
   margin-left: 30px;
-  height: 100%;
+  /* height: 100%; */
 }
 .page_container .right_block {
   width: 100%;
@@ -603,6 +644,10 @@
   height: 20px;
   display: block;
 }
+.page_container .right .guest_list__td .icon .img {
+  width: 100%;
+  height: 100%;
+}
 .page_container .right .guest_list__td:nth-child(1) {
   width: 19.54%;
 }

--
Gitblit v1.8.0