jazz
2023-12-26 2471a9b321c22b7ad9aac423957fc8232980b5cd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
<template>
  <div v-if="isShow" class="mask" @click="hideDialog">
    <div class="xio_room_status_chg_dialog" @click.stop="noop">
      <div class="title">初始化房间状态(点击下方按钮直接更改房间状态)</div>
      <div class="btn_box flex flex-center">
        <div style="width: 100%;">
          <div class="line flex flex-ver flex-sb">
            <div class="btn_box_item flex flex-center white" @click="changeStatus('空闲', 0)">
              <div class="flex flex-ver">
                <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" @click="changeStatus('使用中', 1)">
              <div class="flex flex-ver">
                <div class="icon">
                  <img class="img" src="static/imgs/using.png">
                </div>
                <div class="tx white">使用中</div>
              </div>
            </div>
          </div>
          <div class="line flex flex-ver flex-sb">
            <div class="btn_box_item flex flex-center yellow" @click="changeStatus('客人休息', 2)">
              <div class="flex flex-ver">
                <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" @click="changeStatus('通知打扫', 3)">
              <div class="flex flex-ver">
                <div class="icon">
                  <img class="img" src="static/imgs/clear.png">
                </div>
                <div class="tx">通知打扫</div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>
 
<script>
export default {
  name: 'XioRoomStatusChg',
  props: {
    isActive: {
      type: Boolean,
      default: false
    }
  },
  data() {
    return {
      isShow: false
    }
  },
  methods: {
    noop() {
      return
    },
    // 更换状态
    changeStatus(tx, status) {
      this.$emit('changeStatus', { statusTx: tx, status: status * 1 })
    },
    // 显示弹窗
    showDialog() {
      this.isShow = true
    },
    // 关闭弹窗
    hideDialog() {
      this.isShow = false
    }
  }
}
</script>
 
<style scoped>
.xio_room_status_chg_dialog {
  width: 1105px;
  min-height: 602px;
  border-radius: 10px;
  background-color: rgba(255,255,255,1);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  -webkit-transform: translate(-50%, -50%);
  z-index: 1;
}
.xio_room_status_chg_dialog .title {
  line-height: 37px;
  color: rgba(16,16,16,1);
  font-size: 26px;
  text-align: left;
  font-family: PingFangSC-medium;
  padding: 37px 31px 16px 31px;
}
.xio_room_status_chg_dialog .btn_box {
  padding: 0 193px;
}
.xio_room_status_chg_dialog .btn_box .line {
  width: 100%;
}
.xio_room_status_chg_dialog .btn_box_item {
  width: 250px;
  height: 120px;
  line-height: 20px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0px 2px 6px 0px rgba(206,206,206,0.86);
  margin-top: 76px;
}
.xio_room_status_chg_dialog .btn_box_item.white {
  background-color: rgba(255,255,255,1);
}
.xio_room_status_chg_dialog .btn_box_item.blue {
  background-color: rgba(46,77,124,1);
}
.xio_room_status_chg_dialog .btn_box_item.yellow {
  background-color: rgba(255,199,115,1);
}
.xio_room_status_chg_dialog .btn_box_item.gray {
  background-color: rgba(206,206,206,1);
}
.xio_room_status_chg_dialog .btn_box_item .icon {
  width: 60px;
  height: 60px;
  display: block;
  margin-right: 17px;
}
.xio_room_status_chg_dialog .btn_box_item .icon .img {
  width: 100%;
  height: 100%;
}
.xio_room_status_chg_dialog .btn_box_item .tx {
  line-height: 37px;
  color: rgba(51,51,51,1);
  font-size: 26px;
  text-align: center;
  font-family: PingFangSC-medium;
}
.xio_room_status_chg_dialog .btn_box_item .tx.white {
  color: #ffffff;
}
</style>