|
@@ -399,7 +399,10 @@
|
|
|
>
|
|
>
|
|
|
</template>
|
|
</template>
|
|
|
</div>
|
|
</div>
|
|
|
- <a-menu slot="overlay" @click="onMenuClick">
|
|
|
|
|
|
|
+ <a-menu
|
|
|
|
|
+ slot="overlay"
|
|
|
|
|
+ @click="(e) => onMenuClick(e, roomLive)"
|
|
|
|
|
+ >
|
|
|
<a-menu-item key="1"> 入住 </a-menu-item>
|
|
<a-menu-item key="1"> 入住 </a-menu-item>
|
|
|
<a-menu-item key="2"> 预定</a-menu-item>
|
|
<a-menu-item key="2"> 预定</a-menu-item>
|
|
|
<a-menu-item key="3"> 置脏 </a-menu-item>
|
|
<a-menu-item key="3"> 置脏 </a-menu-item>
|
|
@@ -890,14 +893,7 @@ export default {
|
|
|
this.roomStatusList = list;
|
|
this.roomStatusList = list;
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
- getAction("/rooms/cesRooms/realtime-rooms", {}).then((res) => {
|
|
|
|
|
- if (res.success) {
|
|
|
|
|
- res.result.forEach((row) => {
|
|
|
|
|
- this.$set(row, "collapse", 1);
|
|
|
|
|
- });
|
|
|
|
|
- this.roomList = res.result;
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.loadData();
|
|
|
},
|
|
},
|
|
|
mounted() {
|
|
mounted() {
|
|
|
// this.handleBillInfo();
|
|
// this.handleBillInfo();
|
|
@@ -923,14 +919,7 @@ export default {
|
|
|
},
|
|
},
|
|
|
tabsClick(e) {
|
|
tabsClick(e) {
|
|
|
if (e == "1") {
|
|
if (e == "1") {
|
|
|
- getAction("/rooms/cesRooms/realtime-rooms", {}).then((res) => {
|
|
|
|
|
- if (res.success) {
|
|
|
|
|
- res.result.forEach((row) => {
|
|
|
|
|
- this.$set(row, "collapse", 1);
|
|
|
|
|
- });
|
|
|
|
|
- this.roomList = res.result;
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.loadData();
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
getRoomStatusColor(roomStatus) {
|
|
getRoomStatusColor(roomStatus) {
|
|
@@ -964,26 +953,14 @@ export default {
|
|
|
},
|
|
},
|
|
|
scheduleClick(e) {
|
|
scheduleClick(e) {
|
|
|
var selectRoom = [];
|
|
var selectRoom = [];
|
|
|
- this.planList2.forEach((t) => {
|
|
|
|
|
- t.child.forEach((c) => {
|
|
|
|
|
- c.schedule.forEach((s) => {
|
|
|
|
|
- if (s.detail.check === 1) {
|
|
|
|
|
- selectRoom.push(s);
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.roomList.forEach((t) => {
|
|
|
|
|
+ t.rooms.forEach((c) => {
|
|
|
|
|
+ if (c.roomInfo.state === 88) {
|
|
|
|
|
+ c.roomInfo.marketPrice = c.layout.marketPrice;
|
|
|
|
|
+ selectRoom.push(c.roomInfo);
|
|
|
|
|
+ }
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
- // if (selectRoom.length === 0) {
|
|
|
|
|
- // this.$message.warning("请先选择房间");
|
|
|
|
|
- // return;
|
|
|
|
|
- // }
|
|
|
|
|
- // if (e.key == "1") {
|
|
|
|
|
- // this.$refs.ModalScheduleRoom.addList(selectRoom);
|
|
|
|
|
- // this.$refs.ModalScheduleRoom.title = "预定登记";
|
|
|
|
|
- // this.$refs.ModalScheduleRoom.disableSubmit = false;
|
|
|
|
|
- // } else {
|
|
|
|
|
- // this.addScheduleTeam();
|
|
|
|
|
- // }
|
|
|
|
|
this.$refs.ModalScheduleRoom.addList(selectRoom, e.key);
|
|
this.$refs.ModalScheduleRoom.addList(selectRoom, e.key);
|
|
|
this.$refs.ModalScheduleRoom.title =
|
|
this.$refs.ModalScheduleRoom.title =
|
|
|
e.key == "1" ? "散客预定登记" : "团队预定登记";
|
|
e.key == "1" ? "散客预定登记" : "团队预定登记";
|
|
@@ -992,19 +969,14 @@ export default {
|
|
|
handleMenuClick(e) {
|
|
handleMenuClick(e) {
|
|
|
console.log("click", e);
|
|
console.log("click", e);
|
|
|
var selectRoom = [];
|
|
var selectRoom = [];
|
|
|
- this.planList2.forEach((t) => {
|
|
|
|
|
- t.child.forEach((c) => {
|
|
|
|
|
- c.schedule.forEach((s) => {
|
|
|
|
|
- if (s.detail.check === 1) {
|
|
|
|
|
- selectRoom.push(s);
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.roomList.forEach((t) => {
|
|
|
|
|
+ t.rooms.forEach((c) => {
|
|
|
|
|
+ if (c.roomInfo.state === 88) {
|
|
|
|
|
+ c.roomInfo.marketPrice = c.layout.marketPrice;
|
|
|
|
|
+ selectRoom.push(c.roomInfo);
|
|
|
|
|
+ }
|
|
|
});
|
|
});
|
|
|
});
|
|
});
|
|
|
- // if (selectRoom.length === 0) {
|
|
|
|
|
- // this.$message.warning("请先选择房间");
|
|
|
|
|
- // return;
|
|
|
|
|
- // }
|
|
|
|
|
this.$refs.ModalBillRoomForm.addList(selectRoom, e.key);
|
|
this.$refs.ModalBillRoomForm.addList(selectRoom, e.key);
|
|
|
this.$refs.ModalBillRoomForm.title =
|
|
this.$refs.ModalBillRoomForm.title =
|
|
|
e.key == "1" ? "散客入住登记" : "团队入住登记";
|
|
e.key == "1" ? "散客入住登记" : "团队入住登记";
|
|
@@ -1083,14 +1055,32 @@ export default {
|
|
|
this.$refs.modalForm.title = "维修";
|
|
this.$refs.modalForm.title = "维修";
|
|
|
this.$refs.modalForm.disableSubmit = false;
|
|
this.$refs.modalForm.disableSubmit = false;
|
|
|
},
|
|
},
|
|
|
- onMenuClick(e) {
|
|
|
|
|
- console.log(e);
|
|
|
|
|
|
|
+ onMenuClick(e, row) {
|
|
|
|
|
+ console.log("e", e);
|
|
|
|
|
+ console.log("row", row);
|
|
|
|
|
+ var that = this;
|
|
|
if (e.key == "1") {
|
|
if (e.key == "1") {
|
|
|
- this.$refs.ModalBillRoomForm.addList([], e.key);
|
|
|
|
|
- this.$refs.ModalBillRoomForm.title = "散客入住登记";
|
|
|
|
|
- this.$refs.ModalBillRoomForm.disableSubmit = false;
|
|
|
|
|
|
|
+ if (row.bookingData && row.bookingData.bookingOrder) {
|
|
|
|
|
+ this.$confirm({
|
|
|
|
|
+ title: "提示",
|
|
|
|
|
+ content: "此房间有预定是否预定转入住?",
|
|
|
|
|
+ onOk: function () {
|
|
|
|
|
+ that.$router.push({
|
|
|
|
|
+ name: "room-scheduledetail",
|
|
|
|
|
+ params: {
|
|
|
|
|
+ id: row.bookingData.bookingOrder.bookingOrdersNo,
|
|
|
|
|
+ },
|
|
|
|
|
+ });
|
|
|
|
|
+ },
|
|
|
|
|
+ });
|
|
|
|
|
+ } else {
|
|
|
|
|
+ row.roomInfo.marketPrice = row.layout.marketPrice;
|
|
|
|
|
+ this.$refs.ModalBillRoomForm.addList([row.roomInfo], 1);
|
|
|
|
|
+ this.$refs.ModalBillRoomForm.title = "散客入住登记";
|
|
|
|
|
+ this.$refs.ModalBillRoomForm.disableSubmit = false;
|
|
|
|
|
+ }
|
|
|
} else if (e.key == "2") {
|
|
} else if (e.key == "2") {
|
|
|
- this.$refs.ModalScheduleRoom.addList([], e.key);
|
|
|
|
|
|
|
+ this.$refs.ModalScheduleRoom.addList([row.roomInfo], 1);
|
|
|
this.$refs.ModalScheduleRoom.title = "散客预定登记";
|
|
this.$refs.ModalScheduleRoom.title = "散客预定登记";
|
|
|
this.$refs.ModalScheduleRoom.disableSubmit = false;
|
|
this.$refs.ModalScheduleRoom.disableSubmit = false;
|
|
|
} else {
|
|
} else {
|
|
@@ -1100,6 +1090,7 @@ export default {
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
modalBillRoomFormOk(e) {
|
|
modalBillRoomFormOk(e) {
|
|
|
|
|
+ this.loadData();
|
|
|
console.log("e", e);
|
|
console.log("e", e);
|
|
|
this.$refs.ModalBillRoomInfo.add(e);
|
|
this.$refs.ModalBillRoomInfo.add(e);
|
|
|
this.$refs.ModalBillRoomInfo.title = "账单";
|
|
this.$refs.ModalBillRoomInfo.title = "账单";
|
|
@@ -1107,7 +1098,7 @@ export default {
|
|
|
},
|
|
},
|
|
|
modalFormOk(e) {
|
|
modalFormOk(e) {
|
|
|
console.log("e", e);
|
|
console.log("e", e);
|
|
|
- // this.loadData();
|
|
|
|
|
|
|
+ this.loadData();
|
|
|
this.$router.push({
|
|
this.$router.push({
|
|
|
// path: "/room/scheduledetail",
|
|
// path: "/room/scheduledetail",
|
|
|
// query: { id: e },
|
|
// query: { id: e },
|
|
@@ -1117,7 +1108,7 @@ export default {
|
|
|
},
|
|
},
|
|
|
modalTeamFormOk(e) {
|
|
modalTeamFormOk(e) {
|
|
|
console.log("e", e);
|
|
console.log("e", e);
|
|
|
- // this.loadData();
|
|
|
|
|
|
|
+ this.loadData();
|
|
|
this.$router.push({
|
|
this.$router.push({
|
|
|
// path: "/room/scheduledetail",
|
|
// path: "/room/scheduledetail",
|
|
|
// query: { id: e },
|
|
// query: { id: e },
|
|
@@ -1126,16 +1117,14 @@ export default {
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
loadData() {
|
|
loadData() {
|
|
|
- // var _info = JSON.parse(localStorage.getItem("storeInfo"));
|
|
|
|
|
- // getAction("/business/busMeetingRoomSchedule/fetch", {
|
|
|
|
|
- // startDate: this.startDate,
|
|
|
|
|
- // endDate: this.endDate,
|
|
|
|
|
- // hotelId: _info.id,
|
|
|
|
|
- // }).then((res) => {
|
|
|
|
|
- // if (res.success) {
|
|
|
|
|
- // this.planList2 = res.result;
|
|
|
|
|
- // }
|
|
|
|
|
- // });
|
|
|
|
|
|
|
+ getAction("/rooms/cesRooms/realtime-rooms", {}).then((res) => {
|
|
|
|
|
+ if (res.success) {
|
|
|
|
|
+ res.result.forEach((row) => {
|
|
|
|
|
+ this.$set(row, "collapse", 1);
|
|
|
|
|
+ });
|
|
|
|
|
+ this.roomList = res.result;
|
|
|
|
|
+ }
|
|
|
|
|
+ });
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
|
};
|
|
};
|