无用的接口删除

This commit is contained in:
joylink_cuiweidong 2019-11-12 17:06:12 +08:00
parent 83ebe5eae9
commit b690e1baed
5 changed files with 334 additions and 375 deletions

View File

@ -2,265 +2,256 @@
import request from '@/utils/request';
export function postDataBd(data) {
return request({
url: `/api/audio/bd?group=${data.group}&conversationId=${data.conversationId}`,
method: 'post',
data: data.file
});
return request({
url: `/api/audio/bd?group=${data.group}&conversationId=${data.conversationId}`,
method: 'post',
data: data.file
});
}
// 创建/获取会话id
export function getConversation(data) {
return request({
url: `/api/audio/conversation`,
method: 'get',
params: {
group: data.group,
userId: data.userId,
code: data.code
}
});
return request({
url: `/api/audio/conversation`,
method: 'get',
params: {
group: data.group,
userId: data.userId,
code: data.code
}
});
}
export function postDataXf(data) {
return request({
url: `/api/audio/xf`,
method: 'post',
data: data
});
return request({
url: `/api/audio/xf`,
method: 'post',
data: data
});
}
// 获取语音历史记录
export function getHistoryVoice(code) {
return request({
url: `/api/audio/${code}/history`,
method: 'get'
});
return request({
url: `/api/audio/${code}/history`,
method: 'get'
});
}
// 文字聊天 发送文字
export function chatWithText(data, group) {
return request({
url: `/api/jointTraining/chatWithText?group=${group}`,
method: 'post',
data: {
message: data
}
});
return request({
url: `/api/jointTraining/chatWithText?group=${group}`,
method: 'post',
data: {
message: data
}
});
}
// 文字聊天 发送文字
export function chatWithAudio(file, group) {
return request({
url: `/api/jointTraining/chatWithAudio?group=${group}`,
method: 'post',
data: file
});
}
// 文字聊天 发送文字
// 生成分发二维码
export function getJoinTrainCode(data, group) {
return request({
url: `/api/jointTraining/qrCode?group=${group}`,
method: 'post',
data: data
});
return request({
url: `/api/jointTraining/qrCode?group=${group}`,
method: 'post',
data: data
});
}
// 创建房间
export function postCreateRoom(data) {
return request({
url: `/api/jointTraining/room`,
method: 'post',
data: data
});
return request({
url: `/api/jointTraining/room`,
method: 'post',
data: data
});
}
// 检查房间存在
export function checkRoomExist(params) {
return request({
url: `/api/simulationRoom`,
method: 'get',
params
});
return request({
url: `/api/simulationRoom`,
method: 'get',
params
});
}
// 获取房间详情
export function postRoomDetail(group) {
return request({
url: `/api/jointTraining/room/${group}`,
method: 'get'
});
return request({
url: `/api/jointTraining/room/${group}`,
method: 'get'
});
}
// 销毁房间
export function deljointTrainRoom(group) {
return request({
url: `/api/jointTraining/room`,
method: 'delete',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room`,
method: 'delete',
params: {
group: group
}
});
}
// 查询有权限房间列表
export function getjointTrainList() {
return request({
url: `/api/jointTraining/room/list`,
method: 'get'
});
return request({
url: `/api/jointTraining/room/list`,
method: 'get'
});
}
// 加入房间
export function getjointTraining(group) {
return request({
url: `/api/jointTraining/room/join`,
method: 'put',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/join`,
method: 'put',
params: {
group: group
}
});
}
// 设置人员角色
export function putUserRoles(data, group) {
return request({
url: `/api/jointTraining/room/user/role?group=${group}`,
method: 'put',
data: data
});
return request({
url: `/api/jointTraining/room/user/role?group=${group}`,
method: 'put',
data: data
});
}
// 设置人员角色
// 获取房间里的用户列表
export function getJointTrainRoomUserList(group) {
return request({
url: `/api/jointTraining/room/${group}/user/list`,
method: 'get'
});
return request({
url: `/api/jointTraining/room/${group}/user/list`,
method: 'get'
});
}
// 离开房间接口
export function putJointTrainingExit(group) {
return request({
url: `/api/jointTraining/room/exit`,
method: 'put',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/exit`,
method: 'put',
params: {
group: group
}
});
}
// 开始联合演练
export function startJointTraining(group) {
return request({
url: `/api/jointTraining/room/simulation`,
method: 'post',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/simulation`,
method: 'post',
params: {
group: group
}
});
}
// 获取个人信息
export function getUserRoles(group) {
return request({
url: `/api/jointTraining/room/user/role`,
method: 'get',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/user/role`,
method: 'get',
params: {
group: group
}
});
}
// 返回房间
export function putJointTrainingState() {
return request({
url: `/api/jointTraining/room/back`,
method: 'put'
});
return request({
url: `/api/jointTraining/room/back`,
method: 'put'
});
}
// 踢出用户
export function putJointTrainingUserkicked(userId, group) {
return request({
url: `/api/jointTraining/room/user`,
method: 'put',
params: {
userId: userId,
group: group
}
});
return request({
url: `/api/jointTraining/room/user`,
method: 'put',
params: {
userId: userId,
group: group
}
});
}
// 管理员结束所有人的仿真
export function putJointTrainingSimulation(group) {
return request({
url: `/api/jointTraining/room/simulation/all`,
method: 'put',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/simulation/all`,
method: 'put',
params: {
group: group
}
});
}
// 结束仿真返回房间
export function putJointTrainingSimulationUser(group) {
return request({
url: `/api/jointTraining/room/simulation/user/exit`,
method: 'put',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/simulation/user/exit`,
method: 'put',
params: {
group: group
}
});
}
// 进入仿真
export function putJointTrainingSimulationEntrance(group) {
return request({
url: `/api/jointTraining/room/simulation/user/entrance`,
method: 'put',
params: {
group: group
}
});
return request({
url: `/api/jointTraining/room/simulation/user/entrance`,
method: 'put',
params: {
group: group
}
});
}
/**
* 权限获取(房间权限)
*/
export function getPermissionJoint(group) {
return request({
url: '/api/jointTraining/qrCode',
method: 'get',
params: {
group: group
}
});
return request({
url: '/api/jointTraining/qrCode',
method: 'get',
params: {
group: group
}
});
}
// 添加或更新真实设备和仿真对象连接
export function setRealDevice(group, data) {
return request({
url: `/api/jointTraining/room/realDevice?group=${group}`,
method: 'post',
data: data
});
return request({
url: `/api/jointTraining/room/realDevice?group=${group}`,
method: 'post',
data: data
});
}
// 删除真实设备和仿真对象连接
export function delRealDevice(id, group) {
return request({
url: `/api/jointTraining/room/realDevice/${id}`,
method: 'delete',
params: { group: group }
});
return request({
url: `/api/jointTraining/room/realDevice/${id}`,
method: 'delete',
params: { group: group }
});
}
// 获取真实设备列表
export function getRealDevices(group) {
return request({
url: `/api/jointTraining/room/${group}/devices`,
method: 'get'
});
return request({
url: `/api/jointTraining/room/${group}/devices`,
method: 'get'
});
}

View File

@ -1,188 +1,164 @@
import request from '@/utils/request';
export function getDraftLesson(params, mapId) {
/** 根据mapId获取草稿课程 */
return request({
url: `/api/mapSystem/findDraftLessonBy/${mapId}`,
method: 'get',
params
});
}
/** 获取用户地图树 */
export function getUserMapTree(cityCode) {
return request({
url: `/api/mapSystem/findDraftMapByCityCode?cityCode=${cityCode}`,
method: 'get'
});
}
/** 运行图*/
export function getRpListByUserMapId(mapId) {
return request({
url: `/api/draftMap/runPlan/findByDraftMapId/${mapId}`,
method: 'get'
});
return request({
url: `/api/draftMap/runPlan/findByDraftMapId/${mapId}`,
method: 'get'
});
}
export function getMapList(cityCode) {
/** 根据cityCode获取地图列表 */
return request({
url: `/api/mapSystem/queryMapByCityCode/${cityCode}`,
method: 'get'
});
/** 根据cityCode获取地图列表 */
return request({
url: `/api/mapSystem/queryMapByCityCode/${cityCode}`,
method: 'get'
});
}
/** 获取用户自己的运行图详情*/
export function getRpDetailByUserMapId(planId) {
return request({
url: `/api/draftMap/runPlan/selectDiagramData/${planId}`,
method: 'get'
});
return request({
url: `/api/draftMap/runPlan/selectDiagramData/${planId}`,
method: 'get'
});
}
/** 获取用户自己创建的草稿地图详情*/
export function getUserMapDetailByMapId(mapId) {
return request({
url: `/api/mapBuild/findById/${mapId}`,
method: 'get'
});
return request({
url: `/api/mapBuild/findById/${mapId}`,
method: 'get'
});
}
/** 用户自己的运行图仿真测试*/
export function runUserPlanNotify({ planId }) {
return request({
url: `/api/draftMap/runPlan/simulationCheck/${planId}`,
method: 'get'
});
return request({
url: `/api/draftMap/runPlan/simulationCheck/${planId}`,
method: 'get'
});
}
/** 管理员获取需审核的课程列表 */
export function reviewLessonList(params) {
return request({
url: `/api/review/query/lesson`,
method: 'get',
params
});
return request({
url: `/api/review/query/lesson`,
method: 'get',
params
});
}
/** 管理员发布课程接口 */
export function adminPublishLesson(data, id) {
return request({
url: `/api/review/${id}/publishLesson`,
method: 'post',
data: data
});
return request({
url: `/api/review/${id}/publishLesson`,
method: 'post',
data: data
});
}
/** 管理员驳回课程发布申请 */
export function rejectedLessonRelease(data, id) {
return request({
url: `/api/review/lesson/${id}`,
method: 'post',
data: data
});
return request({
url: `/api/review/lesson/${id}`,
method: 'post',
data: data
});
}
/** 普通用户申请课程发布和撤销申请 */
export function releaseOrCancel(id, status) {
return request({
url: `/api/review/lesson/releaseOrCancel/${id}/${status}`,
method: 'get'
});
return request({
url: `/api/review/lesson/releaseOrCancel/${id}/${status}`,
method: 'get'
});
}
/** 管理员获取需审核的剧本列表 ok */
export function reviewScriptList(params) {
return request({
url: `/api/review/query/script`,
method: 'get',
params
});
return request({
url: `/api/review/query/script`,
method: 'get',
params
});
}
/** 管理员发布剧本 ok */
export function publishScript(id) {
return request({
url: `/api/review/${id}/publishScript`,
method: 'post'
});
return request({
url: `/api/review/${id}/publishScript`,
method: 'post'
});
}
/** 管理员剧本申请驳回 ok */
export function rejectScript(id, data) {
return request({
url: `/api/review/script/${id}`,
method: 'post',
data: data
});
return request({
url: `/api/review/script/${id}`,
method: 'post',
data: data
});
}
/** 管理员获取需审核的运行图列表 */
export function reviewRunPlanList(params) {
return request({
url: `/api/review/query/runPlan`,
method: 'get',
params
});
return request({
url: `/api/review/query/runPlan`,
method: 'get',
params
});
}
/** 管理员发布运行图 */
export function publishRunPlan(planId, data) {
return request({
url: `/api/review/${planId}/publishRunPlan`,
method: 'post',
data: data
});
return request({
url: `/api/review/${planId}/publishRunPlan`,
method: 'post',
data: data
});
}
/** 普通用户申请或撤销运行图发布 */
export function releaseOrCancelRunPlan(planId, status) {
return request({
url: `/api/review/runPlan/releaseOrCancel/${planId}/${status}`,
method: 'get'
});
return request({
url: `/api/review/runPlan/releaseOrCancel/${planId}/${status}`,
method: 'get'
});
}
/** 管理员运行图申请驳回 */
export function rejectRunPlan(id, data) {
return request({
url: `/api/review/runPlan/${id}`,
method: 'post',
data: data
});
}
/** 用户申请发布剧本或者撤销剧本申请 */
export function releaseScript(id, status) {
return request({
url: `/api/review/script/releaseOrCancel/${id}/${status}`,
method: 'get'
});
return request({
url: `/api/review/runPlan/${id}`,
method: 'post',
data: data
});
}
/** 查看课程详情 */
export function reviewLessonDetail(id) {
return request({
url: `/api/review/previewLesson/${id}`,
method: 'get'
});
return request({
url: `/api/review/previewLesson/${id}`,
method: 'get'
});
}
/** 管理员预览草稿运行图*/
export function previewRunPlan(planId) {
return request({
url: `/api/review/previewRunPlan/${planId}`,
method: 'get'
});
return request({
url: `/api/review/previewRunPlan/${planId}`,
method: 'get'
});
}
/** 加载剧本 */
export function loadDraftScript(scriptId, memberId, group) {
return request({
url: `api/simulation/${group}/scriptDraft/${scriptId}?memberId=${memberId}`,
method: 'post'
});
return request({
url: `api/simulation/${group}/scriptDraft/${scriptId}?memberId=${memberId}`,
method: 'post'
});
}
/** 获取已发布的有地图的城市列表*/
export function publisMapCityList(data) {
return request({
url: `/api/map/city?dicCode=${data}`,
method: 'get'
});
return request({
url: `/api/map/city?dicCode=${data}`,
method: 'get'
});
}

View File

@ -1,76 +1,76 @@
import request from '@/utils/request';
// 账号密码 其他系统
export function login(params) {
return request({
url: '/api/login',
method: 'post',
data: params
});
return request({
url: '/api/login',
method: 'post',
data: params
});
}
// 获取登陆url 二维码 其他系统
// 获取微信登陆二维码 url 其他系统
export function getLoginUrl(params) {
return request({
url: '/api/login/url',
method: 'get',
params: params
});
return request({
url: '/api/login/url',
method: 'get',
params: params
});
}
// 获取登陆url 小程序二维码
// 获取微信小程序登陆二维码
export function getLoginWmurl(params) {
return request({
url: '/api/login/wmurl',
method: 'get',
params: params
});
return request({
url: '/api/login/wmurl',
method: 'get',
params: params
});
}
// 获取登录信息
export function getInfo(token) {
return request({
url: '/api/login/getUserInfo',
method: 'get',
params: { token }
});
return request({
url: '/api/login/getUserInfo',
method: 'get',
params: { token }
});
}
// 登出
export function logout(token) {
return request({
url: '/api/login/logout',
method: 'get',
params: {
token
}
});
return request({
url: '/api/login/logout',
method: 'get',
params: {
token
}
});
}
// 检查登陆状态
export function checkLoginStatus(sessionId) {
return new Promise((resolve, reject) => {
request({
url: '/api/login/checkStatus',
method: 'get',
params: {
sessionId: sessionId
}
}).then(response => {
if (response.data.status === '2') {
resolve(response);
} else {
reject(response);
}
}).catch(error => {
reject(error);
});
});
return new Promise((resolve, reject) => {
request({
url: '/api/login/checkStatus',
method: 'get',
params: {
sessionId: sessionId
}
}).then(response => {
if (response.data.status === '2') {
resolve(response);
} else {
reject(response);
}
}).catch(error => {
reject(error);
});
});
}
// 检测持续在线 防止掉线在大屏或者仿真系统下
export function checkLoginLine() {
return request({
url: '/api/cache/heartBeat',
method: 'get'
});
return request({
url: '/api/cache/heartBeat',
method: 'get'
});
}

View File

@ -1,47 +1,47 @@
import request from '@/utils/request';
export function querySecheduling(group, params) {
return request({
url: `/api/scheduling/${group}/day`,
method: 'get',
params
});
return request({
url: `/api/scheduling/${group}/day`,
method: 'get',
params
});
}
export function generateScheduling(group, params) {
return request({
url: `/api/scheduling/${group}/generate`,
method: 'post',
params
});
return request({
url: `/api/scheduling/${group}/generate`,
method: 'post',
params
});
}
export function getSchedulingAllTrains(group) {
return request({
url: `/api/scheduling/${group}/train/all`,
method: 'get'
});
return request({
url: `/api/scheduling/${group}/train/all`,
method: 'get'
});
}
export function checkScheduling(group, data) {
return request({
url: `/api/scheduling/${group}/check`,
method: 'post',
data
});
return request({
url: `/api/scheduling/${group}/check`,
method: 'post',
data
});
}
export function saveScheduling(group, data) {
return request({
url: `/api/scheduling/${group}/save`,
method: 'post',
data
});
return request({
url: `/api/scheduling/${group}/save`,
method: 'post',
data
});
}
export function generateSchedulingAgain(group) {
return request({
url: `/api/scheduling/${group}/rebuild`,
method: 'delete'
});
return request({
url: `/api/scheduling/${group}/rebuild`,
method: 'delete'
});
}

View File

@ -2,33 +2,25 @@ import request from '@/utils/request';
/** 分页查找上线的剧本*/
export function getScriptPageListOnline(params) {
return request({
url: `/api/script/paging/online`,
// url: `/api/script/paging/published`,
method: 'get',
params: params
});
}
/** 通过ID查询剧本的基础信息 */
export function getScriptByIdList(id) {
return request({
url: `/api/script/${id}/basic`,
method: 'get'
});
return request({
url: `/api/script/paging/online`,
// url: `/api/script/paging/published`,
method: 'get',
params: params
});
}
/** 通过ID查询发布的剧本的详细信息 */
export function getScriptById(id) {
return request({
url: `/api/script/${id}/detail`,
method: 'get'
});
return request({
url: `/api/script/${id}/detail`,
method: 'get'
});
}
/** 通过ID查询未发布剧本的详细信息 */
export function getDraftScriptByGroup(group) {
return request({
url: `/api/simulation/${group}/script/loadedScript`,
method: 'get'
});
return request({
url: `/api/simulation/${group}/script/loadedScript`,
method: 'get'
});
}