Browse Source

fix: 解决楼层数据重复的问题

chenzhen2 2 years ago
parent
commit
905d29b400

+ 1 - 1
src/views/choiceSpace/choiceSpace.vue

@@ -41,7 +41,7 @@
             <van-checkbox
               class="item-check"
               v-model="item.checked"
-              @change="updateWorkSpace(item)"
+              @click="updateWorkSpace(item)"
               shape="square"
             ></van-checkbox>
           </div>

+ 35 - 20
src/views/envmonitor/components/Air.vue

@@ -4,8 +4,8 @@
       <div class="air-desc">
         <p class="air-title">空调</p>
         <p class="air-temperature">
-          {{ airData.tempSet ? airData.tempSet : "--" }}
-          <sup>℃</sup>
+          {{ airData.tempSet ? airData.tempSet : "" }}
+          <sup v-if="airData.tempSet">℃</sup>
         </p>
         <!-- <p class="air-model">
           <span v-if="modeName">
@@ -110,8 +110,8 @@
               airSetText.toWhere === 'toCold' || airSetText.toWhere === 'toWarm'
             "
           >
-            <div class="air-temp-num">{{ temperature }}</div>
-            <div
+            <!-- <div class="air-temp-num">{{ temperature }}</div> -->
+            <!-- <div
               class="air-temp-num"
               :class="{
                 'arrow-cooling': airSetText.toWhere == 'toCold',
@@ -119,23 +119,30 @@
               }"
             >
+            </div> -->
+            <div v-if="airSetText.notice" class="air-temp-num">
+              {{ airSetText.notice }}
             </div>
-            <div v-if="airSetText.designTemperature" class="air-temp-num">
-              {{ airSetText.designTemperature }}
+            <div v-else class="air-temp-load">
+              <van-loading type="spinner" />
             </div>
-            <div v-else class="air-temp-num-load">
+            <!-- <div v-else class="air-temp-num-load">
               <img
                 style="padding-top: 4px; height: 20px; width: 20px"
                 :src="parseImgUrl('page-officehome', 'loading.svg')"
               />
-            </div>
+            </div> -->
           </div>
-          <p v-if="airSetText.notice" class="air-notice">
-            <span>{{ airSetText.notice }}</span>
+          <p
+            v-if="airSetText.remark && airSetText.remark.length"
+            class="air-notice"
+          >
+            <span
+              v-for="(remarkItem, index) in airSetText.remark"
+              :key="'remark' + index"
+              >{{ remarkItem }}</span
+            >
           </p>
-          <div v-else class="air-temp-load">
-            <van-loading type="spinner" />
-          </div>
         </div>
         <div class="dialog-btns" @click.stop="closeDialog">
           <span>确定</span>
@@ -208,7 +215,7 @@ export default defineComponent({
   setup(props, contx) {
     const propsVal = props;
     let airData: any = {
-      avg: "--", // 算法调节温度(目标值)
+      avg: "", // 算法调节温度(目标值)
       icon: 1, // 固定框文案ID 7 为关机,其它都是开机
       spaceStatus: "", // 固定框文案展示
       notice: "", // 弹框文案展示
@@ -236,6 +243,7 @@ export default defineComponent({
       airSetText: {
         // 空调反馈文案
         notice: "",
+        remark: [],
         nowImg: "",
         toWhere: "",
         designTemperature: 0,
@@ -357,6 +365,7 @@ export default defineComponent({
             if (type === "feedback") {
               if (resData.notice) {
                 proxyData.airSetText.notice = resData.notice;
+                proxyData.airSetText.remark = resData.remark.split("*");
                 if (proxyData.feedbackTimer) {
                   clearTimeout(proxyData.feedbackTimer); // 拿到反馈文案清除定时器
                   proxyData.getAirInfoToTimer();
@@ -481,6 +490,7 @@ export default defineComponent({
          */
         // 温度切换的时候调整文案
         proxyData.airSetText.notice = "";
+        proxyData.airSetText.remark = [];
         const paramObj = {
           projectId: propsVal.projectId, // 项目id
           objectId: propsVal.spaceId, // 空间id
@@ -504,6 +514,7 @@ export default defineComponent({
             if (btnType !== "sw") {
               if (resData.notice) {
                 proxyData.airSetText.notice = resData.notice;
+                proxyData.airSetText.remark = resData.remark.split("*");
               } else {
                 proxyData.getFeedbackTimer(btnType, resData.id);
               }
@@ -746,7 +757,7 @@ export default defineComponent({
 .air-dialog-content {
   position: relative;
   width: 100%;
-  height: 360px;
+  height: 340px;
 
   .dialog-top {
     position: relative;
@@ -809,17 +820,21 @@ export default defineComponent({
   }
 
   .air-notice {
-    padding-top: 25px;
+    padding-top: 10px;
     padding-left: 48px;
     padding-right: 48px;
-    text-align: left;
-    display: flex;
+    text-align: center;
+    // display: flex;
     justify-content: center;
     font-family: PingFang SC;
     font-size: 15px;
     font-weight: 400;
     line-height: 21px;
     color: rgba(77, 82, 98, 1);
+    span {
+      display: block;
+      padding-bottom: 5px;
+    }
   }
 
   .air-temp-load {
@@ -843,8 +858,8 @@ export default defineComponent({
   line-height: 1;
   color: #4d5262;
   background: #ffffff;
-  box-shadow: 0px 0px 1px rgba(0, 0, 0, 0.05), 0px 4px 15px rgba(0, 0, 0, 0.15);
-  border-radius: 25px;
+  border: 1px solid #c4c4c4;
+  border-radius: 30px;
   cursor: pointer;
 
   span {

+ 2 - 2
src/views/envmonitor/components/Contact/index.vue

@@ -11,12 +11,12 @@
       <div class="contact">
         <div class="code-box">
           <img :src="imgUrl + '&key=' + contantDetail.wechatQrCode" alt="" />
-          <div class="title">客微信二维码</div>
+          <div class="title">客微信二维码</div>
         </div>
         <div class="phone-box">
           <img :src="parseImgUrl('ipdImages', 'phone-icon.svg')" alt="" />
           <div class="title">{{ contantDetail.phone }}</div>
-          <div class="concat-text">客户电话联系方式</div>
+          <div class="concat-text">联系方式</div>
         </div>
       </div>
       <buttons class="dailog-btn" @click="closeDailog">我知道了</buttons>

+ 3 - 3
src/views/envmonitor/components/Curtain.vue

@@ -12,7 +12,7 @@
         <div class="show-all" @click="showAll" v-if="isShowChildLight">
           <van-icon
             :name="lightIcon"
-            class="light-icon"
+            class="curtain-icon"
           />
           <span>显示全部</span>
         </div>
@@ -380,11 +380,11 @@ export default defineComponent({
     padding-right: 10px;
   }
 
-  padding-top: 10px;
+  padding-top: 28px;
   padding-bottom: 22px;
   font-size: 14px;
   line-height: 16px;
-  color: #C4C4C4;
+  color: #c4c4c4;
   margin: 0px 5px;
 }
 

+ 1 - 1
src/views/envmonitor/components/workOvertime/WorkConfig.vue

@@ -2,7 +2,7 @@
   <div class="scene-config">
     <!--开放办公区-->
     <div class="time-box" :class="timerText.classColor">
-      <!-- <img :src="parseImgUrl('page-officehome', 'work.svg')" alt="" /> -->
+      <img :src="parseImgUrl('page-officehome', 'work.svg')" alt="" />
       <div class="time-text">
         <span>{{ timerText.text }}</span>
         <span>{{ timerText.timer }}</span>

+ 3 - 2
src/views/envmonitor/components/workOvertime/index.vue

@@ -1003,6 +1003,7 @@ export default defineComponent({
       // 关闭加班弹窗
       closeWorkTimer() {
         proxyData.formBtn = false;
+        context.emit("closeWork");
       },
       // 提交申请
       addWorkTimer() {
@@ -1160,7 +1161,7 @@ export default defineComponent({
 
     .date-item-active {
       background: rgba(206, 159, 39, 0.4);
-      border: 1px solid rgba(206, 159, 39, 0.4);
+      border: none;
     }
   }
 
@@ -1241,7 +1242,7 @@ export default defineComponent({
         top: 0;
         width: 20px;
         height: 100px;
-        right: -5px;
+        right: -8px;
         z-index: 999;
         //left: 286px;