diff --git a/src/api/videoCommunication.js b/src/api/videoCommunication.js
index 5c9a610..8913e2b 100644
--- a/src/api/videoCommunication.js
+++ b/src/api/videoCommunication.js
@@ -1,5 +1,12 @@
import request from '@/utils/request'
-
+// 视讯-加入会议
+export function postConsultationInfo(data) {
+ return request({
+ url: '/consultation/info',
+ method: 'post',
+ data
+ })
+}
// 视讯-会议列表
export function getConsultationList(data) {
return request({
diff --git a/src/views/videoCommunication/index.vue b/src/views/videoCommunication/index.vue
index 70c5954..6d78c06 100644
--- a/src/views/videoCommunication/index.vue
+++ b/src/views/videoCommunication/index.vue
@@ -9,7 +9,7 @@
import {
+ postConsultationInfo,
getConsultationList,
getConsultationMeetingInfo,
} from "@/api/videoCommunication";
@@ -183,7 +184,7 @@ export default {
name: "VideoPage",
data() {
return {
- meetingCode: "",
+ room_id: "",
loading: false,
queryParams: {
page: 1,
@@ -248,30 +249,27 @@ export default {
},
// 口令入会
joinMeeting() {
- if (!this.meetingCode.trim()) {
- this.$message.warning("请输入数字口令");
+ if (!this.room_id.trim()) {
+ this.$message.warning("入会口令格式错误");
return;
}
this.loading = true;
// 模拟接口调用
- // joinMeeting({ meetingCode: this.meetingCode })
- // .then(() => {
- // this.$message.success("成功加入会议");
- // this.meetingCode = "";
- // })
- // .catch(() => {
- // this.$message.error("入会失败,请检查口令是否正确");
- // })
- // .finally(() => {
- // this.loading = false;
- // });
-
- // 模拟请求
- setTimeout(() => {
- this.$message.success("成功加入会议");
- this.meetingCode = "";
- this.loading = false;
- }, 500);
+ postConsultationInfo({
+ consultation_id: 0,
+ from_history: 0,
+ room_id: this.room_id,
+ })
+ .then(() => {
+ this.$message.success("成功加入会议");
+ this.room_id = "";
+ })
+ .catch(() => {
+ this.$message.error("入会失败,请检查口令是否正确");
+ })
+ .finally(() => {
+ this.loading = false;
+ });
},
// 处理会议模式点击