Files
Arbitrate-FrontendH5/src/api/room.js
T

69 lines
2.5 KiB
JavaScript
Raw Normal View History

2024-01-18 10:46:33 +08:00
import axios from "@/utils/request";
2024-04-19 18:15:23 +08:00
// let baseUrlZC = 'https://api.xayunmei.com/zhongcaiapi';
// let baseUrl = 'https://api.xayunmei.com/tiaojieapitest';
// let baseUrl = 'http://121.40.189.20:6001';
2024-01-18 10:46:33 +08:00
// 开始云端录制
export function startVideo(data) {
let appType = sessionStorage.getItem('type');
if (appType == 'tiaojie') {
2024-04-19 18:15:23 +08:00
return axios.post(`tiaojie/video/openCloudRecording`, data);
} else {
2024-04-19 18:15:23 +08:00
return axios.post(`zhongcai/video/openCloudRecording`, data);
}
2024-01-18 10:46:33 +08:00
}
// 结束云端录制
export function stopVideo(data) {
let appType = sessionStorage.getItem('type');
if (appType == 'tiaojie') {
2024-04-19 18:15:23 +08:00
return axios.post(`tiaojie/video/closeDeleteCloudRecording?taskId=${data}`);
} else {
2024-04-19 18:15:23 +08:00
return axios.post(`zhongcai/video/closeDeleteCloudRecording?taskId=${data}`);
}
2024-01-18 10:46:33 +08:00
}
// 解散房间
export function destructionRoom(data) {
let appType = sessionStorage.getItem('type');
if (appType == 'tiaojie') {
2024-04-19 18:15:23 +08:00
return axios.post(`tiaojie/video/dissolveRoom`, data);
} else {
2024-04-19 18:15:23 +08:00
return axios.post(`zhongcai/video/dissolveRoom`, data);
}
2024-01-18 10:46:33 +08:00
}
// 根据html字符串转pdf并且和案件关联
export function htmlToPDF(data) {
let appType = sessionStorage.getItem('type');
if (appType == 'tiaojie') {
2024-04-19 18:15:23 +08:00
return axios.post(`tiaojie/video/htmlToPDF`, data);
} else {
2024-04-19 18:15:23 +08:00
return axios.post(`zhongcai/video/htmlToPDF`, data);
}
2024-01-18 10:46:33 +08:00
}
// 根据userId查询该用户是否是秘书
2024-04-08 16:23:29 +08:00
export function secretaryRoleByUserId(userId, caseId) {
let appType = sessionStorage.getItem('type');
if (appType == 'tiaojie') {
2024-04-19 18:15:23 +08:00
return axios.get(`tiaojie/video/secretaryRoleByUserId?userId=${userId}&caseId=${caseId}`);
} else {
2024-04-19 18:15:23 +08:00
return axios.get(`zhongcai/video/secretaryRoleByUserId?userId=${userId}`);
}
2024-01-18 10:46:33 +08:00
}
2024-04-08 16:23:29 +08:00
// 获取证据列表
export function selectById(caseId) {
2024-04-19 18:15:23 +08:00
return axios.get(`tiaojie/caseApplication/selectById?id=${caseId}`);
2024-04-08 16:23:29 +08:00
}
// 根据案件id查询登录人是否为申请人被申请人
export function selectRoleMenuByCaseId(caseId) {
2024-04-19 18:15:23 +08:00
return axios.get(`tiaojie/video/selectRoleMenuByCaseId?caseId=${caseId}`);
2024-04-08 16:23:29 +08:00
}
2024-04-15 09:40:00 +08:00
// 保存onlyOffice文档
export function saveOnlyOfficeFile(data) {
2024-04-19 18:15:23 +08:00
return axios.post(`tiaojie/caseApplication/saveOnlyOfficeFile`, data);
2024-04-15 09:40:00 +08:00
}
//获取当前用户的操作权限
export function getMenuPermsByUser(caseId) {
2024-04-19 18:15:23 +08:00
return axios.get(`tiaojie/system/menu/getMenuPermsByUser`);
}
// 上传文件
export function videoUpload(data) {
return axios.post(`tiaojie/video/upload`,data);
2024-04-15 09:40:00 +08:00
}