diff --git a/frontend/public/index.html b/frontend/public/index.html index 7889af3..21797d0 100644 --- a/frontend/public/index.html +++ b/frontend/public/index.html @@ -13,7 +13,7 @@ We're sorry but vue-antd-pro doesn't work properly without JavaScript enabled. Please enable it to continue.
-
Loading
+
加载中
diff --git a/frontend/src/views/room/Room.vue b/frontend/src/views/room/Room.vue index 01ddedb..a269ab0 100644 --- a/frontend/src/views/room/Room.vue +++ b/frontend/src/views/room/Room.vue @@ -29,11 +29,6 @@ 编辑 - - - 删除 - - 座位管理 二维码 @@ -106,13 +101,6 @@ this.state.loading = false }) }, - handleDelete (room) { - api.deleteRoom(room.id) - .then(data => { - this.$notification.success({ message: '成功', description: '成功删除房间', key: 'SUCCESS' }) - this.getData() - }) - }, handleDownload () { } diff --git a/frontend/src/views/room/RoomDetail.vue b/frontend/src/views/room/RoomDetail.vue index 4fec26a..7b5e3e4 100644 --- a/frontend/src/views/room/RoomDetail.vue +++ b/frontend/src/views/room/RoomDetail.vue @@ -65,7 +65,16 @@ 保存 - + + + 删除 + + + 返回 @@ -130,6 +139,13 @@ } ) }, + handleDelete () { + api.deleteRoom(this.id) + .then(data => { + this.$notification.success({ message: '成功', description: '成功删除房间', key: 'SUCCESS' }) + this.$router.push({ name: 'room' }) + }) + }, }, computed: { isEdit () { diff --git a/frontend/vue.config.js b/frontend/vue.config.js index 1de1239..37f9c6d 100644 --- a/frontend/vue.config.js +++ b/frontend/vue.config.js @@ -64,14 +64,6 @@ module.exports = { ws: false, changeOrigin: true } - // '/gateway': { - // target: 'https://www.easy-mock.com/mock/5b7bce071f130e5b7fe8cd7d/antd-pro', - // ws: false, - // changeOrigin: true, - // pathRewrite: { - // '^/gateway': '/api' - // } - // } } },