This commit is contained in:
sunleking 2020-11-02 11:23:33 +08:00
commit 4d2b1df3e5
1352 changed files with 61396 additions and 84923 deletions

View File

@ -1,5 +1,5 @@
# just a flag
NODE_ENV = 'production'
NODE_ENV = 'test'
# base api
VUE_APP_BASE_API = 'https://test.joylink.club/jlcloud'

1
.gitignore vendored
View File

@ -6,6 +6,7 @@ yarn-debug.log*
yarn-error.log*
package-lock.json
tests/**/coverage/
/src/utils/baseUrl.js
# Editor directories and files
.idea

View File

@ -4,19 +4,22 @@ pipeline {
label 'master'
}
}
stages {
stage('Package') {
tools {
nodejs 'nodejs-10'
}
steps {
sh 'npm update'
sh 'npm install'
sh 'npm run build'
}
}
stage('Publish') {
steps {
sh 'mkdir -p /usr/local/joylink/jlclient'
sh 'rm -rf /usr/local/joylink/jlclient/*'
sh 'cp -rf ./dist/* /usr/local/joylink/jlclient'
}
}

View File

@ -4,20 +4,23 @@ pipeline {
label 'master'
}
}
stages {
stage('Package') {
tools {
nodejs 'nodejs-10'
}
steps {
sh 'npm update'
sh 'npm install'
sh 'npm run test'
}
}
stage('Publish') {
steps {
sh 'cp -rf ./dist/* /usr/local/joylink/jlclient'
sh 'mkdir -p /usr/local/joylink/jlclient'
sh 'rm -rf /usr/local/joylink/jlclient/*'
sh 'cp -rf ./dist/* /usr/local/joylink/jlclient'
}
}
}

View File

@ -35,6 +35,7 @@
"stompjs": "^2.3.3",
"storejs": "^1.0.25",
"three": "^0.107.0",
"video.js": "^7.8.4",
"vue": "^2.6.10",
"vue-i18n": "^8.12.0",
"vue-quill-editor": "^3.0.6",
@ -76,7 +77,7 @@
"serve-static": "^1.13.2",
"svg-sprite-loader": "4.1.3",
"svgo": "1.2.2",
"vue-template-compiler": "2.6.11"
"vue-template-compiler": "^2.6.11"
},
"engines": {
"node": ">=8.9",

View File

@ -8,8 +8,8 @@
<!-- cdn.bootcss.com替换成cdnjs.cloudflare.com/ajax/libs -->
<title><%= webpackConfig.name %></title>
<script src="/static/inflate.min.js"></script>
<script src="/static/three.min.js"></script>
<script src="<%= BASE_URL %>inflate.min.js"></script>
<script src="<%= BASE_URL %>three.min.js"></script>
<!--<% if (process.env.VUE_APP_PRO !== 'local') { %>-->
<!--<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/element-ui/2.7.2/theme-chalk/index.css">-->
<!--<link href="https://cdnjs.cloudflare.com/ajax/libs/nprogress/0.2.0/nprogress.min.css" rel="stylesheet">-->

15
public/inflate.min.js vendored Normal file
View File

@ -0,0 +1,15 @@
/** @license zlib.js 2012 - imaya [ https://github.com/imaya/zlib.js ] The MIT License */(function() {'use strict';var l=void 0,aa=this;function r(c,d){var a=c.split("."),b=aa;!(a[0]in b)&&b.execScript&&b.execScript("var "+a[0]);for(var e;a.length&&(e=a.shift());)!a.length&&d!==l?b[e]=d:b=b[e]?b[e]:b[e]={}};var t="undefined"!==typeof Uint8Array&&"undefined"!==typeof Uint16Array&&"undefined"!==typeof Uint32Array&&"undefined"!==typeof DataView;function v(c){var d=c.length,a=0,b=Number.POSITIVE_INFINITY,e,f,g,h,k,m,n,p,s,x;for(p=0;p<d;++p)c[p]>a&&(a=c[p]),c[p]<b&&(b=c[p]);e=1<<a;f=new (t?Uint32Array:Array)(e);g=1;h=0;for(k=2;g<=a;){for(p=0;p<d;++p)if(c[p]===g){m=0;n=h;for(s=0;s<g;++s)m=m<<1|n&1,n>>=1;x=g<<16|p;for(s=m;s<e;s+=k)f[s]=x;++h}++g;h<<=1;k<<=1}return[f,a,b]};function w(c,d){this.g=[];this.h=32768;this.d=this.f=this.a=this.l=0;this.input=t?new Uint8Array(c):c;this.m=!1;this.i=y;this.r=!1;if(d||!(d={}))d.index&&(this.a=d.index),d.bufferSize&&(this.h=d.bufferSize),d.bufferType&&(this.i=d.bufferType),d.resize&&(this.r=d.resize);switch(this.i){case A:this.b=32768;this.c=new (t?Uint8Array:Array)(32768+this.h+258);break;case y:this.b=0;this.c=new (t?Uint8Array:Array)(this.h);this.e=this.z;this.n=this.v;this.j=this.w;break;default:throw Error("invalid inflate mode");
}}var A=0,y=1,B={t:A,s:y};
w.prototype.k=function(){for(;!this.m;){var c=C(this,3);c&1&&(this.m=!0);c>>>=1;switch(c){case 0:var d=this.input,a=this.a,b=this.c,e=this.b,f=d.length,g=l,h=l,k=b.length,m=l;this.d=this.f=0;if(a+1>=f)throw Error("invalid uncompressed block header: LEN");g=d[a++]|d[a++]<<8;if(a+1>=f)throw Error("invalid uncompressed block header: NLEN");h=d[a++]|d[a++]<<8;if(g===~h)throw Error("invalid uncompressed block header: length verify");if(a+g>d.length)throw Error("input buffer is broken");switch(this.i){case A:for(;e+
g>b.length;){m=k-e;g-=m;if(t)b.set(d.subarray(a,a+m),e),e+=m,a+=m;else for(;m--;)b[e++]=d[a++];this.b=e;b=this.e();e=this.b}break;case y:for(;e+g>b.length;)b=this.e({p:2});break;default:throw Error("invalid inflate mode");}if(t)b.set(d.subarray(a,a+g),e),e+=g,a+=g;else for(;g--;)b[e++]=d[a++];this.a=a;this.b=e;this.c=b;break;case 1:this.j(ba,ca);break;case 2:for(var n=C(this,5)+257,p=C(this,5)+1,s=C(this,4)+4,x=new (t?Uint8Array:Array)(D.length),S=l,T=l,U=l,u=l,M=l,F=l,z=l,q=l,V=l,q=0;q<s;++q)x[D[q]]=
C(this,3);if(!t){q=s;for(s=x.length;q<s;++q)x[D[q]]=0}S=v(x);u=new (t?Uint8Array:Array)(n+p);q=0;for(V=n+p;q<V;)switch(M=E(this,S),M){case 16:for(z=3+C(this,2);z--;)u[q++]=F;break;case 17:for(z=3+C(this,3);z--;)u[q++]=0;F=0;break;case 18:for(z=11+C(this,7);z--;)u[q++]=0;F=0;break;default:F=u[q++]=M}T=t?v(u.subarray(0,n)):v(u.slice(0,n));U=t?v(u.subarray(n)):v(u.slice(n));this.j(T,U);break;default:throw Error("unknown BTYPE: "+c);}}return this.n()};
var G=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],D=t?new Uint16Array(G):G,H=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,258,258],I=t?new Uint16Array(H):H,J=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0],K=t?new Uint8Array(J):J,L=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577],da=t?new Uint16Array(L):L,ea=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,
13,13],N=t?new Uint8Array(ea):ea,O=new (t?Uint8Array:Array)(288),P,fa;P=0;for(fa=O.length;P<fa;++P)O[P]=143>=P?8:255>=P?9:279>=P?7:8;var ba=v(O),Q=new (t?Uint8Array:Array)(30),R,ga;R=0;for(ga=Q.length;R<ga;++R)Q[R]=5;var ca=v(Q);function C(c,d){for(var a=c.f,b=c.d,e=c.input,f=c.a,g=e.length,h;b<d;){if(f>=g)throw Error("input buffer is broken");a|=e[f++]<<b;b+=8}h=a&(1<<d)-1;c.f=a>>>d;c.d=b-d;c.a=f;return h}
function E(c,d){for(var a=c.f,b=c.d,e=c.input,f=c.a,g=e.length,h=d[0],k=d[1],m,n;b<k&&!(f>=g);)a|=e[f++]<<b,b+=8;m=h[a&(1<<k)-1];n=m>>>16;if(n>b)throw Error("invalid code length: "+n);c.f=a>>n;c.d=b-n;c.a=f;return m&65535}
w.prototype.j=function(c,d){var a=this.c,b=this.b;this.o=c;for(var e=a.length-258,f,g,h,k;256!==(f=E(this,c));)if(256>f)b>=e&&(this.b=b,a=this.e(),b=this.b),a[b++]=f;else{g=f-257;k=I[g];0<K[g]&&(k+=C(this,K[g]));f=E(this,d);h=da[f];0<N[f]&&(h+=C(this,N[f]));b>=e&&(this.b=b,a=this.e(),b=this.b);for(;k--;)a[b]=a[b++-h]}for(;8<=this.d;)this.d-=8,this.a--;this.b=b};
w.prototype.w=function(c,d){var a=this.c,b=this.b;this.o=c;for(var e=a.length,f,g,h,k;256!==(f=E(this,c));)if(256>f)b>=e&&(a=this.e(),e=a.length),a[b++]=f;else{g=f-257;k=I[g];0<K[g]&&(k+=C(this,K[g]));f=E(this,d);h=da[f];0<N[f]&&(h+=C(this,N[f]));b+k>e&&(a=this.e(),e=a.length);for(;k--;)a[b]=a[b++-h]}for(;8<=this.d;)this.d-=8,this.a--;this.b=b};
w.prototype.e=function(){var c=new (t?Uint8Array:Array)(this.b-32768),d=this.b-32768,a,b,e=this.c;if(t)c.set(e.subarray(32768,c.length));else{a=0;for(b=c.length;a<b;++a)c[a]=e[a+32768]}this.g.push(c);this.l+=c.length;if(t)e.set(e.subarray(d,d+32768));else for(a=0;32768>a;++a)e[a]=e[d+a];this.b=32768;return e};
w.prototype.z=function(c){var d,a=this.input.length/this.a+1|0,b,e,f,g=this.input,h=this.c;c&&("number"===typeof c.p&&(a=c.p),"number"===typeof c.u&&(a+=c.u));2>a?(b=(g.length-this.a)/this.o[2],f=258*(b/2)|0,e=f<h.length?h.length+f:h.length<<1):e=h.length*a;t?(d=new Uint8Array(e),d.set(h)):d=h;return this.c=d};
w.prototype.n=function(){var c=0,d=this.c,a=this.g,b,e=new (t?Uint8Array:Array)(this.l+(this.b-32768)),f,g,h,k;if(0===a.length)return t?this.c.subarray(32768,this.b):this.c.slice(32768,this.b);f=0;for(g=a.length;f<g;++f){b=a[f];h=0;for(k=b.length;h<k;++h)e[c++]=b[h]}f=32768;for(g=this.b;f<g;++f)e[c++]=d[f];this.g=[];return this.buffer=e};
w.prototype.v=function(){var c,d=this.b;t?this.r?(c=new Uint8Array(d),c.set(this.c.subarray(0,d))):c=this.c.subarray(0,d):(this.c.length>d&&(this.c.length=d),c=this.c);return this.buffer=c};function W(c,d){var a,b;this.input=c;this.a=0;if(d||!(d={}))d.index&&(this.a=d.index),d.verify&&(this.A=d.verify);a=c[this.a++];b=c[this.a++];switch(a&15){case ha:this.method=ha;break;default:throw Error("unsupported compression method");}if(0!==((a<<8)+b)%31)throw Error("invalid fcheck flag:"+((a<<8)+b)%31);if(b&32)throw Error("fdict flag is not supported");this.q=new w(c,{index:this.a,bufferSize:d.bufferSize,bufferType:d.bufferType,resize:d.resize})}
W.prototype.k=function(){var c=this.input,d,a;d=this.q.k();this.a=this.q.a;if(this.A){a=(c[this.a++]<<24|c[this.a++]<<16|c[this.a++]<<8|c[this.a++])>>>0;var b=d;if("string"===typeof b){var e=b.split(""),f,g;f=0;for(g=e.length;f<g;f++)e[f]=(e[f].charCodeAt(0)&255)>>>0;b=e}for(var h=1,k=0,m=b.length,n,p=0;0<m;){n=1024<m?1024:m;m-=n;do h+=b[p++],k+=h;while(--n);h%=65521;k%=65521}if(a!==(k<<16|h)>>>0)throw Error("invalid adler-32 checksum");}return d};var ha=8;r("Zlib.Inflate",W);r("Zlib.Inflate.prototype.decompress",W.prototype.k);var X={ADAPTIVE:B.s,BLOCK:B.t},Y,Z,$,ia;if(Object.keys)Y=Object.keys(X);else for(Z in Y=[],$=0,X)Y[$++]=Z;$=0;for(ia=Y.length;$<ia;++$)Z=Y[$],r("Zlib.Inflate.BufferType."+Z,X[Z]);}).call(this);

1023
public/three.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -2,6 +2,7 @@
<div id="app">
<router-view />
<deomon-topic ref="deomonTopic" />
<img v-show="loading" :src="loadingImg" style="position: absolute;top: 0;left: 0;width: 100%;height: 100%;z-index: 2003">
</div>
</template>
@ -11,6 +12,7 @@ import { getSessionStorage } from '@/utils/auth';
import { loginInfo, ProjectIcon } from '@/scripts/ProjectConfig';
import DeomonTopic from '@/views/demonstration/deomonTopic';
import WindowResizeHandler from '@/mixin/WindowResizeHandler';
import LoadingImg from '@/assets/loading.gif';
export default {
name: 'App',
@ -20,6 +22,12 @@ export default {
mixins: [
WindowResizeHandler
],
data() {
return {
loadingImg: LoadingImg,
loading: false
};
},
computed: {
path() {
return window.location.pathname;
@ -47,6 +55,12 @@ export default {
}
});
});
},
'$store.state.app.transitionAnimationsCount': function(val) {
this.loading = true;
},
'$store.state.app.animationsCloseCount': function(val) {
this.loading = false;
}
},
created() {

View File

@ -1,300 +1,6 @@
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
});
}
// 创建/获取会话id
export function getConversation(data) {
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
});
}
// 获取语音历史记录
export function getHistoryVoice(code) {
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
}
});
}
// 文字聊天 发送语音
export function chatWithAudio(file, group) {
return request({
url: `/api/jointTraining/chatWithAudio?group=${group}`,
method: 'post',
data: file
});
}
// 文字聊天 发送语音(新版)
export function chatWithAudioNew(file, group) {
return request({
url: `/api/v1/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
});
}
// 创建房间
export function postCreateRoom(data) {
return request({
url: `/api/jointTraining/room`,
method: 'post',
data: data
});
}
// 检查房间存在
export function checkRoomExist(params) {
return request({
url: `/api/simulationRoom`,
method: 'get',
params
});
}
// 获取房间详情
export function postRoomDetail(group) {
return request({
url: `/api/jointTraining/room/${group}`,
method: 'get'
});
}
// 销毁房间
export function deljointTrainRoom(group) {
return request({
url: `/api/jointTraining/room`,
method: 'delete',
params: {
group: group
}
});
}
// 查询有权限房间列表
export function getjointTrainList(params) {
return request({
url: `/api/jointTraining/room/list`,
method: 'get',
params: params
});
}
// 加入房间
export function getjointTraining(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
});
}
// 获取房间里的用户列表
export function getJointTrainRoomUserList(group) {
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
}
});
}
// 开始联合演练
export function startJointTraining(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
}
});
}
// 踢出用户
export function putJointTrainingUserkicked(userId, 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
}
});
}
// 结束仿真返回房间
export function putJointTrainingSimulationUser(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
}
});
}
/**
* 权限获取(房间权限)
*/
export function getPermissionJoint(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
});
}
// 删除真实设备和仿真对象连接
export function delRealDevice(id, 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'
});
}
// 获取房间真实设备连接关系
export function getRealDevicesInRoom(group) {
return request({
url: `/api/jointTraining/room/${group}/realDevice/connect`,
method: 'get'
});
}
// 更新真实设备的连接关系
export function updateRealDevices(group, data) {
return request({
url: `/api/jointTraining/room/${group}/realDevice`,
method: 'put',
data: data
});
}
// 真实设备是否被其他仿真使用
export function realDeviceIsUsed(group, projectCode) {
return request({
url: `/api/jointTraining/room/${group}/realDeviceUsed`,
method: 'get',
params: {
projectCode: projectCode
}
});
}
// 获取仿真成员列表(新版地图)
export function getSimulationMembersNew(group) {
return request({
@ -302,36 +8,12 @@ export function getSimulationMembersNew(group) {
method: 'get'
});
}
// 获取仿真会话消息列表(新版地图)
export function getSimulationContextListNew(group, conversationId) {
return request({
url: `/simulation/${group}/conversation/${conversationId}`,
method: 'get'
});
}
// 接受其他人的会话邀请 (新版地图)
export function acceptCoversitionInvite(group, conversationId) {
return request({
url: `/simulation/${group}/${conversationId}/accept`,
method: 'put'
});
}
/** 发起会话 */
export function startConversition(group, data) {
export function startConversition(group, data, sign) {
return request({
url: `/api/simulation/${group}/conversation`,
url: `/api/simulation/${group}/conversation?object=${sign}`,
method: 'post',
data: data
});
}
/** 根据会话id获取仿真会话 */
export function getSimulationConversition(group, conversationId) {
return request({
url: `/api/simulation/${group}/conversation/${conversationId}`,
method: 'get'
data
});
}
/** 发送会话消息 */
@ -363,3 +45,11 @@ export function getAllConversition(group) {
method: 'get'
});
}
/** 语音播完的接口 */
export function overConversationMessage(group, conversationMessageId) {
return request({
url: `/api/v1/competitionPractical/${group}/audio/over/${conversationMessageId}`,
method: 'put'
});
}

41
src/api/company.js Normal file
View File

@ -0,0 +1,41 @@
import request from '@/utils/request';
/** 获取公司列表 */
export function getCompanyList() {
return request({
url: '/api/company',
method: 'get'
});
}
/** 添加公司信息 */
export function addCompany(data) {
return request({
url: '/api/company',
method: 'post',
data: data
});
}
/** 删除公司信息 */
export function deleteCompany(id) {
return request({
url: `/api/company/${id}`,
method: 'delete'
});
}
/** 更新公司信息 */
export function updateCompany(id, data) {
return request({
url: `/api/company/${id}`,
method: 'put',
data
});
}
/** 分页查询公司列表 */
export function getCompanyListPaging(params) {
return request({
url: `/api/company/paging`,
method: 'get',
params
});
}

View File

@ -7,20 +7,7 @@ export function refereeExitSimulation(group) {
method: 'delete'
});
}
/** 裁判进入仿真 */
export function refereeEnterSimulation(group) {
return request({
url: `/api/v1/competition/room/${group}/refree`,
method: 'post'
});
}
/** 裁判查询竞赛人员的房间列表 */
export function refereeGetCompetitionList(id) {
return request({
url: `/api/v1/competition/${id}/room`,
method: 'get'
});
}
/** 参赛者创建演练房间 */
export function participantCreatTrainingRoom(id, data) {
return request({
@ -30,32 +17,6 @@ export function participantCreatTrainingRoom(id, data) {
});
}
/** 分页获取地图下的实操列表 */
export function getQuestionListByMapId(params) {
return request({
url: `/api/v1/competitionPractical`,
method: 'get',
params
});
}
// 加载试卷
export function loadingPaper(competitionId, data) {
return request({
url: `/api/v1/competition/${competitionId}/testPaper`,
method: 'post',
data
});
}
/** 竞赛报名 */
export function postSignUp(id, data) {
return request({
url: `/api/race/${id}/signUp`,
method: 'post',
data
});
}
/** 查询用户是否已经报名该竞赛 */
export function getIsSignUp(raceId, params = {}) {
return request({
@ -65,24 +26,6 @@ export function getIsSignUp(raceId, params = {}) {
});
}
/** 分页查询竞赛报名人员 */
export function getRaceUserList(params) {
return request({
url: `/api/race/${params.raceId}/raceUser/page`,
method: 'get',
params
});
}
/** 裁判打分 */
export function putRefereeScoring(data) {
return request({
url: `/api/v1/competition/referee/scoring`,
method: 'put',
data
});
}
/** 提交试卷 */
export function postCompetitionTheory(data) {
return request({
@ -92,14 +35,6 @@ export function postCompetitionTheory(data) {
});
}
/** 查询本竞赛用的实操列表 */
export function getCompetitionPractical(competitionId) {
return request({
url: `/api/v1/competitionPractical/competition/${competitionId}`,
method: 'get'
});
}
/** 查询竞赛报名人员详情 */
export function getRaceUserById(raceId) {
return request({
@ -178,64 +113,149 @@ export function getPracticalCompetitionResult(competitionId) {
});
}
/** 回访准备 */
export function playBackReady(params) {
// 以下drts项目使用
/** 项目获取试题列表 */
export function getItemListByProjectCode(projectCode, params) {
return request({
url: `/api/v1/simulationRecord/playback/ready`,
url: `api/v1/competitionTheory/project/${projectCode}`,
method: 'get',
params
});
}
/** 设置倍速 */
export function setPlaySpeed(params) {
/** 项目更新练习的试题的进度列表 */
export function updatePracticeQuestionProgress(projectCode, params) {
return request({
url: `/api/v1/simulationRecord/playback/setPlaySpeed`,
method: 'get',
url: `/api/questionProgress/project/${projectCode}`,
method: 'post',
params
});
}
/** 开始播放 */
export function startPlaying(params) {
/** 项目更新练习的试题的进度列表 */
export function getPracticeQuestionProgress(projectCode) {
return request({
url: `/api/v1/simulationRecord/playback/startPlaying`,
method: 'get',
params
});
}
/** 暂停播放 */
export function playingPause(params) {
return request({
url: `/api/v1/simulationRecord/playback/pausePlaying`,
method: 'get',
params
});
}
/** 结束播放 */
export function endPlaying(params) {
return request({
url: `/api/v1/simulationRecord/playback/endPlaying`,
method: 'get',
params
});
}
/** 从暂停中播放 */
export function fromPauseToPlay(params) {
return request({
url: `/api/v1/simulationRecord/playback/playing`,
method: 'get',
params
});
}
/** 裁判查询理论考试结果 */
export function getTheroyCompetitionResult(competitionId, raceUserId) {
return request({
url: `api/v1/competitionTheory/detail/competition/${competitionId}/raceUser/${raceUserId}`,
url: `/api/questionProgress/project/${projectCode}`,
method: 'get'
});
}
/** 项目提交试卷 */
export function submitPracticeQuestionData(projectCode, data) {
return request({
url: `/api/v1/competitionTheory/project/${projectCode}/submit`,
method: 'post',
data
});
}
/** 获取场景列表 */
export function getCompetitionPracticalScene(params) {
return request({
url: `/api/v1/competitionPractical`,
method: 'get',
params: params
});
}
/** 添加场景 */
export function addCompetitionPracticalScene(data) {
return request({
url: `/api/v1/competitionPractical`,
method: 'post',
data
});
}
/** 删除场景 */
export function deleteCompetitionPracticalScene(sceneId) {
return request({
url: `/api/v1/competitionPractical/${sceneId}`,
method: 'delete'
});
}
/** 更新场景 */
export function updateCompetitionPracticalScene(data) {
return request({
url: `/api/v1/competitionPractical`,
method: 'PUT',
data
});
}
/** 获取场景 */
export function getCompetitionPracticalSceneById(id) {
return request({
url: `/api/v1/competitionPractical/detail/${id}`,
method: 'get'
});
}
/** 更新步骤数据 */
export function updateCompetitionPracticalStep(data) {
return request({
url: `/api/v1/competitionPractical/detail`,
method: 'POST',
data
});
}
/** 加载场景 */
export function loadCompetitionPracticalScene(group, id) {
return request({
url: `/api/v1/competitionPractical/load/${group}/${id}`,
method: 'PUT'
});
}
/** 场景开始演出 */
export function competitionPracticalSceneStart(group, memberId, mode) {
return request({
url: `/api/v1/competitionPractical/start/${group}?memberId=${memberId}&mode=${mode}`,
method: 'PUT'
});
}
/** 退出场景 */
export function competitionPracticalSceneExit(group) {
return request({
url: `/api/v1/competitionPractical/exit/${group}`,
method: 'PUT'
});
}
/** 结束场景 */
export function competitionPracticalSceneFinish(group, data) {
return request({
url: `/api/v1/competitionPractical/finish/${group}`,
method: 'PUT',
data
});
}
/** 获取空白运营数据 */
export function getEmptyOperationalStatistics(group) {
return request({
url: `/api/v1/competitionPractical/detail/os/${group}`,
method: 'GET'
});
}
/** 草稿场景数据导入*/
export function postSceneImport(scriptId, name, data) {
return request({
url: `/api/v1/competitionPractical/${scriptId}/import?name=${name}`,
method: 'post',
data: data,
time: 60000
});
}
/** 草稿场景数据导出 */
export function getSceneExport(id) {
return request({
url: `/api/v1/competitionPractical/${id}/export`,
method: 'get'
});
}

View File

@ -138,28 +138,10 @@ export function previewRunPlan(planId) {
});
}
/** 加载剧本 */
export function loadDraftScript(scriptId, memberId, group) {
return request({
url: `/api/simulation/${group}/scriptDraft/${scriptId}?memberId=${memberId}`,
method: 'post'
});
}
/** 剧本预览选择角色 */
export function loadDraftScriptNew(memberId, group) {
return request({
// url: `/simulation/${group}/choosePlay?memberId=${memberId}`,
url: `/api/scriptSimulation/${group}/chooseMemberAndStart?memberId=${memberId}`,
method: 'put'
});
}
/** 获取已发布的有地图的城市列表*/
export function publisMapCityList(data) {
return request({
url: `/api/map/city?dicCode=${data}`,
method: 'get'
});
}

View File

@ -67,3 +67,19 @@ export function getIbpInfoByStation(mapId, stationCode) {
method: 'get'
});
}
// 获取IBP盘数据
export function getIbpList(params) {
return request({
url: `/api/ibp/list`,
method: 'get',
params: params
});
}
// 复制ibp盘数据
export function copyIbpData(data) {
return request({
url: `/api/draftIbp/copy`,
method: 'post',
data: data
});
}

17
src/api/iscs.js Normal file
View File

@ -0,0 +1,17 @@
import request from '@/utils/request';
// 保存ISCS数据
export function saveIscsElement(data) {
return request({
url: '/api/v1/iscs/saveElements',
method: 'post',
data
});
}
// 获取ISCS数据
export function getIscsData(params) {
return request({
url: '/api/v1/iscs',
method: 'get',
params
});
}

View File

@ -3,11 +3,16 @@ import request from '@/utils/request';
import { getBaseUrl } from '@/utils/baseUrl';
const BASE_API = getBaseUrl();
export const JL3D_LOCAL_STATIC = "/cbtc/static";
let uploadurl = null;
let asseturl = null;
if(BASE_API == "https://test.joylink.club/jlcloud"){
uploadurl = "https://joylink.club/jlfile";
asseturl = "https://joylink.club/oss/joylink";
// uploadurl = "https://test.joylink.club/jlfile";
// asseturl = "https://test.joylink.club/oss/joylink";
}else if(BASE_API == "https://joylink.club/jlcloud"){
@ -16,12 +21,13 @@ if(BASE_API == "https://test.joylink.club/jlcloud"){
}else{
// uploadurl = "https://joylink.club/jlfile";
// asseturl = "https://joylink.club/oss/joylink";
uploadurl = "../static";
asseturl = "../static";
uploadurl = JL3D_LOCAL_STATIC;
asseturl = JL3D_LOCAL_STATIC;
}
const BASE_UPLOAD_API = uploadurl;
export const BASE_ASSET_API = asseturl;
export function getUploadModelUrl() {
return (BASE_UPLOAD_API+"/api/upload/MODEL?appId=00001&appSecret=joylink00001");
}

View File

@ -87,4 +87,18 @@ export function forceDeleteLesson(lessonId) {
method: 'delete'
});
}
/** 一键生成课程和试卷 */
export function aKeyGeneratingLesson(data) {
return request({
url: `/api/lesson/generating`,
method: 'post',
data: data
});
}
/** 根据课程ID获取班级 */
export function getExamClassList(lessonId) {
return request({
url: `/api/lesson/${lessonId}/classes`,
method: 'get'
});
}

View File

@ -85,15 +85,6 @@ export function getLessonChapterDetail(data) {
});
}
/** 发布课程*/
export function publishLesson(data) {
return request({
url: `/api/lessonDraft/${data.id}/publish`,
method: 'post',
data: data
});
}
/** 课程章节拖拽排序*/
export function dragSortLessonChapter(data) {
return request({

View File

@ -16,14 +16,6 @@ export function getPublishMapListOnline() {
});
}
/** 根据皮肤获取发布地图列表*/
export function getPublishMapListByLineCode(lineCode) {
return request({
url: `/api/map/${lineCode}/list`,
method: 'get'
});
}
/** 根据地图id获取地图版本信息*/
export function getPublishMapVersionById(id) {
return request({
@ -107,15 +99,6 @@ export function putMapOffLine(mapId) {
});
}
// /** 修改发布地图名称*/
// export function updatePublishMapName(data) {
// return request({
// url: `/api/map/${data.mapId}/updateName`,
// method: 'put',
// data: data
// });
// }
// 检测地图名称唯一性
export function checkMapName(name) {
return request({
@ -133,23 +116,6 @@ export function getPublishMapDetailList(params, code) {
});
}
/** 获取有屏蔽门的站台列表*/
export function hasDoorStationList(mapId) {
return request({
url: `/api/map/${mapId}/stand/hasDoor`,
method: 'get'
});
}
// /** 修改发布地图城市*/
// export function updatePublishMapCity(data) {
// return request({
// url: `/api/map/${data.mapId}/city`,
// method: 'put',
// data: data
// });
// }
// 修改地图基本信息
export function updatePublishMapInfo(data) {
return request({
@ -254,3 +220,19 @@ export function getStandListByStationCode(id, stationCode) {
method: 'get'
});
}
/** 获取已发布的有地图的城市列表*/
export function publisMapCityList(data) {
return request({
url: `/api/map/city?dicCode=${data}`,
method: 'get'
});
}
/** 新版地图根据仿真mapId获取仿真地图数据 */
export function getNewMapDataByMapId(mapId) {
return request({
url: `/api/map/${mapId}/mapData`,
method: 'get'
});
}

View File

@ -60,15 +60,6 @@ export function saveMap(data) {
});
}
// 保存新草稿地图
// export function saveNewMap(data) {
// return request({
// url: `/api/mapBuild/${data.mapId}/saveNewElements`,
// method: 'post',
// data: data
// });
// }
/** 草稿地图另存为*/
export function saveAsMap(data) {
return request({
@ -124,78 +115,6 @@ export function getBuildMapExport(mapId) {
});
}
/** 查询进路列表*/
export function listRouteRoute(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/route`,
method: 'get',
params: params
});
}
/** 查询进路地图列表*/
export function listRouteMapRoute(mapId) {
return request({
url: `/api/mapBuild/${mapId}/route/all`,
method: 'get'
});
}
/** 查询进路明细*/
export function queryRouteRouteDetail(data) {
return request({
url: `/api/mapBuild/route/${data.id}`,
method: 'get'
});
}
/** 创建进路*/
export function createRouteRoute(data) {
return request({
url: `/api/mapBuild/route`,
method: 'post',
data: data
});
}
/** 删除进路*/
export function deleteRouteRoute(id) {
return request({
url: `/api/mapBuild/route/${id}`,
method: 'delete'
});
}
/** 更新进路*/
export function updateRouteRoute(data) {
return request({
url: `/api/mapBuild/route/${data.id}`,
method: 'put',
data: data
});
}
/** 创建联动道岔*/
export function createLinkageSwitch(data) {
return request({
url: `/api/mapBuild/switchCoupled`,
method: 'post',
data: data
});
}
/** 删除联动道岔*/
export function deleteLinkageSwitch(coupleId) {
return request({
url: `/api/mapBuild/switchCoupled/${coupleId}`,
method: 'delete'
});
}
/** get联动道岔列表*/
export function listLinkageSwitch(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/switchCoupled`,
method: 'get',
params: params
});
}
/** 草稿地图数据校验*/
export function verifyMap(id) {
return request({
@ -204,49 +123,6 @@ export function verifyMap(id) {
});
}
/** 分页查询交路数据*/
export function listRouting(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/routing`,
method: 'get',
params: params
});
}
/** 创建交路*/
export function addRouting(data) {
return request({
url: `/api/mapBuild/routing`,
method: 'post',
data: data
});
}
/** 删除交路*/
export function deleteRouting(routingId) {
return request({
url: `/api/mapBuild/routing/${routingId}`,
method: 'delete'
});
}
/** 获取交路详情*/
export function getRouting(routingId) {
return request({
url: `/api/mapBuild/routing/${routingId}`,
method: 'get'
});
}
/** 更新交路*/
export function updateRouting(data) {
return request({
url: `/api/mapBuild/routing/${data.id}`,
method: 'put',
data: data
});
}
/** 分页查询交路数据(新版)*/
export function listRoutingData(mapId, params) {
return request({
@ -307,49 +183,6 @@ export function generateStationRunData(routingId) {
});
}
// 创建自动信号 old旧数据
export function postAutoSignal(data) {
return request({
url: `/api/mapBuild/autoSignal`,
method: 'post',
data: data
});
}
// 删除自动信号 old旧数据
export function delAutoSignal(autoSignalId) {
return request({
url: `/api/mapBuild/autoSignal/${autoSignalId}`,
method: 'delete'
});
}
// 分页获取自动信号列表 old旧数据
export function getAutoSignalList(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/autoSignal`,
method: 'get',
params
});
}
// 获取自动信号详情 old旧数据
export function getAutoSignalDetail(autoSignalId) {
return request({
url: `/api/mapBuild/autoSignal/${autoSignalId}`,
method: 'get'
});
}
// 更新自动信号 old旧数据
export function putAutoSignal(data) {
return request({
url: `/api/mapBuild/autoSignal/${data.autoSignalId}`,
method: 'put',
data: data
});
}
// 分页获取自动信号列表 new新数据
export function getAutoSignalListNew(mapId, params) {
return request({
@ -392,14 +225,6 @@ export function putAutoSignalNew(data) {
data: data
});
}
export function getListByCityCode(cityCode) {
return request({
url: `/api/mapBuild/${cityCode}/list`,
method: 'get'
});
}
// 创建信号机接近区段
export function postApproachSection(data) {
return request({
@ -464,12 +289,6 @@ export function delContinueProtect(id) {
method: 'delete'
});
}
export function getContinueProtectById(id) {
return request({
url: `/api/mapBuild/overlap/${id}`,
method: 'get'
});
}
export function getContinueProtectList(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/overlap/paging`,
@ -545,15 +364,6 @@ export function getRouteNewList(mapId, params) {
params
});
}
// 获取自动折返分组列表
export function getAutoReentryGroupList(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/autoReentry/group/reentryTrack`,
method: 'get',
params
});
}
// 新建进路侧防
export function postFlankProtection(data) {
return request({
@ -642,3 +452,54 @@ export function generateCI (mapId) {
method: 'post'
});
}
/** 创建目的码 */
export function createStationDestination(data) {
return request({
url: `/api/mapBuild/${data.mapId}/destinationCodeDefinition`,
method: 'post',
data
});
}
/** 更新目的码 */
export function updateStationDestination(data) {
return request({
url: `/api/mapBuild/${data.mapId}/destinationCodeDefinition`,
method: 'put',
data
});
}
/** 目的码列表分页查询 */
export function getStationDestinationList(mapId, params) {
return request({
url: `/api/mapBuild/${mapId}/destinationCodeDefinition`,
method: 'get',
params
});
}
/** 目的码查询 */
export function getStationDestinationDetail(mapId, code) {
return request({
url: `/api/mapBuild/${mapId}/${code}/destinationCodeDefinition`,
method: 'get'
});
}
/** 目的码查询 */
export function deleteStationDestination(mapId, code) {
return request({
url: `/api/mapBuild/${mapId}/${code}/destinationCodeDefinition`,
method: 'delete'
});
}
/** 根据group查询目的码 */
export function getSimulationDestinationList(group) {
return request({
url: `/simulation/${group}/destinationCode/list`,
method: 'get'
});
}

View File

@ -1,44 +1,2 @@
import request from '@/utils/request';
// import request from '@/utils/request';
/** 获取路径单元列表*/
export function getRouteUnitList(id, data) {
return request({
url: `/api/mapBuild/${id}/routeUnit`,
method: 'get',
params: data
});
}
/** 创建路径单元*/
export function addRouteUnit(data) {
return request({
url: `/api/mapBuild/routeUnit`,
method: 'post',
data: data
});
}
/** 删除路径单元*/
export function delRouteUnit(id) {
return request({
url: `/api/mapBuild/routeUnit/${id}`,
method: 'DELETE'
});
}
/** 获取路径单元*/
export function getRouteUnit(id) {
return request({
url: `/api/mapBuild/routeUnit/${id}`,
method: 'get'
});
}
/** 更新路径单元*/
export function setRouteUnit(data) {
return request({
url: `/api/mapBuild/routeUnit/${data.id}`,
method: 'put',
data: data
});
}

View File

@ -1,29 +1,5 @@
import request from '@/utils/request';
/** 开始实训 0*/
export function startTraining(args, group) {
return request({
url: `/api/training/${args.id}/start`,
method: 'get',
params: {
group
}
});
}
/** 实训结束*/
export function endTraining(args, group) {
return request({
url: `/api/training/${args.lessonId}/${args.id}/end`,
method: 'get',
params: {
mode: args.mode,
usedTime: args.usedTime,
group
}
});
}
/** 发送步骤数据*/
export function sendTrainingNextStep(data, group) {
return request({
@ -35,32 +11,6 @@ export function sendTrainingNextStep(data, group) {
}
});
}
/** 获取章节基本信息 0*/
export function getTrainingDetail(trainingId) {
return request({
url: `/api/training/${trainingId}`,
method: 'get'
});
}
/** 添加实训 0*/
export function addTraining(data) {
return request({
url: '/api/training',
method: 'post',
data: data
});
}
/** 获取实训步骤数据 0*/
export function getTrainingStepsDetail(trainingId, params) {
return request({
url: `/api/training/${trainingId}/detail`,
method: 'get',
params: params
});
}
/** 查询实训列表 0*/
export function pageQueryTraining(params) {
return request({
@ -69,41 +19,6 @@ export function pageQueryTraining(params) {
params: params
});
}
/** 自动生成实训操作 0*/
export function addAutoTraining(data) {
return request({
url: `/api/training/generate`,
method: 'post',
data: data
});
}
/** 修改自动删除实训操作 0*/
export function updateAutoTraining(data) {
return request({
url: `/api/training/batchUpdateGenerate`,
method: 'put',
data: data
});
}
/** 删除自动生成实训 0*/
export function deleteAutoTraining(params) {
return request({
url: `/api/training/generate`,
method: 'delete',
params: params
});
}
/** 获取用户实训列表 0*/
export function getTrainingList(data) {
return request({
url: `/api/training/list`,
method: 'get',
params: data
});
}
export function sendCommand(group, command) {
return request({
url: `/api/training/deviceChange?group=${group}`,
@ -125,29 +40,6 @@ export function sendCommandNew(group, commandDefinitionId, command) {
data: command
});
}
// 添加用户实训数据 0
export function addUserTraining(data) {
return request({
url: `/api/training/userTraining`,
method: 'post',
data: data
});
}
// 更新用户实训数据 0
export function putUserTraining(data) {
return request({
url: `/api/training/userTraining/${data.id}`,
method: 'put',
data: data
});
}
// 清除实训数据 0
export function deleteUserTraining(statsId) {
return request({
url: `/api/training/userTraining/${statsId}`,
method: 'delete'
});
}
/** 开始实训 (新版地图) */
export function startTrainingNew (args, group) {
@ -184,7 +76,8 @@ export function getTrainingDetailNew(trainingId) {
url: `/api/v1/training/${trainingId}`,
method: 'get'
});
}/** 添加实训(新版地图) */
}
/** 添加实训(新版地图) */
export function addTrainingNew(data) {
return request({
url: '/api/v1/training',

View File

@ -1,34 +1,5 @@
import request from '@/utils/request';
// 文字聊天 发送文字
export function chatWithTextNew(data, group) {
return request({
url: `/api/v1/jointTraining/chatWithText?group=${group}`,
method: 'post',
data: {
message: data
}
});
}
// 生成分发二维码
export function getJoinTrainCodeNew(data, group) {
return request({
url: `/api/v1/jointTraining/qrCode?group=${group}`,
method: 'post',
data: data
});
}
// 创建房间
export function postCreateRoomNew(data) {
return request({
url: `/api/v1/jointTraining/room`,
method: 'post',
data: data
});
}
// 检查房间存在
export function checkRoomExistNew(params) {
return request({
@ -38,45 +9,6 @@ export function checkRoomExistNew(params) {
});
}
// 获取房间详情
export function postRoomDetailNew(group) {
return request({
url: `/api/v1/jointTraining/room/${group}`,
method: 'get'
});
}
// 销毁房间
export function deljointTrainRoomNew(group) {
return request({
url: `/api/v1/jointTraining/room`,
method: 'delete',
params: {
group: group
}
});
}
// 查询有权限房间列表
export function getjointTrainListNew(params) {
return request({
url: `/api/v1/jointTraining/room/list`,
method: 'get',
params: params
});
}
// 加入房间
export function getjointTrainingNew(group) {
return request({
url: `/api/v1/jointTraining/room/join`,
method: 'put',
params: {
group: group
}
});
}
// 设置人员角色
export function putUserRolesNew(data, group) {
return request({
@ -86,70 +18,6 @@ export function putUserRolesNew(data, group) {
});
}
// 获取房间里的用户列表
export function getJointTrainRoomUserListNew(group) {
return request({
url: `/api/v1/jointTraining/room/${group}/user/list`,
method: 'get'
});
}
// 离开房间接口
export function putJointTrainingExitNew(group) {
return request({
url: `/api/v1/jointTraining/room/exit`,
method: 'put',
params: {
group: group
}
});
}
// 开始联合演练
export function startJointTrainingNew(group) {
return request({
url: `/api/v1/jointTraining/room/simulation`,
method: 'post',
params: {
group: group
}
});
}
// 获取个人信息
export function getUserRolesNew(group) {
return request({
url: `/api/v1/jointTraining/room/user/role`,
method: 'get',
params: {
group: group
}
});
}
// 踢出用户
export function putJointTrainingUserkickedNew(userId, group) {
return request({
url: `/api/v1/jointTraining/room/user`,
method: 'put',
params: {
userId: userId,
group: group
}
});
}
// 管理员结束所有人的仿真
export function putJointTrainingSimulationNew(group) {
return request({
url: `/api/v1/jointTraining/room/simulation/all`,
method: 'put',
params: {
group: group
}
});
}
// 结束仿真返回房间
export function putJointTrainingSimulationUserNew(group) {
return request({
@ -160,90 +28,3 @@ export function putJointTrainingSimulationUserNew(group) {
}
});
}
// 进入仿真
export function putJointTrainingSimulationEntranceNew(group) {
return request({
url: `/api/v1/jointTraining/room/simulation/user/entrance`,
method: 'put',
params: {
group: group
}
});
}
/**
* 权限获取(房间权限)
*/
export function getPermissionJointNew(group) {
return request({
url: '/api/v1/jointTraining/qrCode',
method: 'get',
params: {
group: group
}
});
}
// 添加或更新真实设备和仿真对象连接
export function setRealDeviceNew(group, data) {
return request({
url: `/api/v1/jointTraining/room/realDevice?group=${group}`,
method: 'post',
data: data
});
}
// 删除真实设备和仿真对象连接
export function delRealDeviceNew(id, group) {
return request({
url: `/api/v1/jointTraining/room/realDevice/${id}`,
method: 'delete',
params: { group: group }
});
}
// 获取真实设备列表
export function getRealDevicesNew(group) {
return request({
url: `/api/v1/jointTraining/room/${group}/devices`,
method: 'get'
});
}
// 获取房间真实设备连接关系
export function getRealDevicesInRoomNew(group) {
return request({
url: `/api/v1/jointTraining/room/${group}/realDevice/connect`,
method: 'get'
});
}
// 更新真实设备的连接关系
export function updateRealDevicesNew(group, data) {
return request({
url: `/api/v1/jointTraining/room/${group}/realDevice`,
method: 'put',
data: data
});
}
// 真实设备是否被其他仿真使用
export function realDeviceIsUsedNew(group, projectCode) {
return request({
url: `/api/v1/jointTraining/room/${group}/realDeviceUsed`,
method: 'get',
params: {
projectCode: projectCode
}
});
}
// 获取所有需要值班员的车站(新版)
export function getAvailableStaionList(mapId) {
return request({
url: `/api/map/${mapId}/station/needSupervisor`,
method: 'get'
});
}

View File

@ -10,15 +10,6 @@ export function getLessonPermissonPageList(params) {
});
}
/** 创建课程权限*/
export function createLessonPermisson(data) {
return request({
url: '/api/permission',
method: 'post',
data: data
});
}
/** 获取权限详情*/
export function getPermissonDetail(id) {
return request({
@ -44,14 +35,6 @@ export function postPermissonList(mapId) {
});
}
/** 获取用户某课程某段时间内可用的权限数量*/
export function getTotalRemains(params) {
return request({
url: '/api/userPermission/totalRemains',
method: 'get',
params: params
});
}
/** 设置权限失效或有效*/
export function setLessonPermisson(data) {
return request({
@ -61,25 +44,7 @@ export function setLessonPermisson(data) {
});
}
/** 设置权限失效或有效*/
export function getPermissionList(id) {
return request({
url: `/api/permission/${id}`,
method: 'get'
});
}
/** 获取大屏权限列表*/
export function queryPermissionScreen() {
return request({
url: `/api/userPermission/bigScreen`,
method: 'get'
});
}
/**
* 用户权限列表
*/
/** 用户权限列表*/
export function listPermision(params) {
return request({
url: `/api/userPermission`,
@ -88,9 +53,7 @@ export function listPermision(params) {
});
}
/**
* 个人权限列表
*/
/** 个人权限列表*/
export function listUserPermision(params) {
return request({
url: `/api/userPermission/my`,
@ -99,14 +62,6 @@ export function listUserPermision(params) {
});
}
/** 用户权限列表 */
export function getDistribute(id) {
return request({
url: `/api/distribute/${id}`,
method: 'get'
});
}
/** 设置权限所有者 */
export function putPermissionOwner(data) {
return request({

View File

@ -48,10 +48,7 @@ export function update(data) {
});
}
/**
* 根据字典code获取明细列表
* @param {*} code
*/
/** 根据字典code获取明细列表*/
export function getDetailList(code) {
return request({
url: '/api/dictionary/getDetailListByCode',

View File

@ -1,32 +1,5 @@
import request from '@/utils/request';
/** 权限转增*/
export function getLessons(data) {
return request({
url: '/api/distribute/getLessons',
method: 'get',
data: data
});
}
/** 权限分发*/
export function giveLessons(data) {
return request({
url: '/api/distribute/distribute',
method: 'post',
data: data
});
}
/** 权限转增*/
export function permissionTurnAdd(data) {
return request({
url: '/api/distribute/transfer',
method: 'post',
data: data
});
}
/** 权限获取*/
export function getPermission(state) {
return request({
@ -35,24 +8,6 @@ export function getPermission(state) {
});
}
/** 接收课程权限*/
export function receiveLessons(data) {
return request({
url: '/api/distribute/receiveLessons',
method: 'get',
data: data
});
}
/** 考试权限分发*/
export function giveExams(data) {
return request({
url: `/api/distribute/giveExams`,
method: 'post',
data: data
});
}
/** 权限打包分页查询*/
export function listPackagePermission(params) {
return request({
@ -62,15 +17,6 @@ export function listPackagePermission(params) {
});
}
/** 打包权限*/
export function packagePermissionDistribute(data) {
return request({
url: `/api/distribute/givePermission/package`,
method: 'post',
data: data
});
}
/** 权限回收*/
export function restorePackagePermission(id) {
return request({
@ -97,32 +43,6 @@ export function getPermissionPackageDetail(id, params) {
});
}
/** 权限分发打包*/
export function permissionDistributePackage(data) {
return request({
url: `/api/distribute/package`,
method: 'post',
data: data
});
}
/** 权限分发解包*/
export function permissionDistributeUnPackage(permissionId) {
return request({
url: `/api/distribute/${permissionId}/unPackage`,
method: 'delete'
});
}
/** 查询可打包的权限分发*/
export function listCanPackagePermission(params) {
return request({
url: `/api/distribute/package`,
method: 'get',
params: params
});
}
// 设置权限分发列表 权限失效
export function setCommodityStatus(id) {
return request({
@ -148,11 +68,3 @@ export function givePermission(data) {
data: data
});
}
/** 查询权限分发领取用户列表 */
export function distributeUsers(distributeId) {
return request({
url: `/api/distribute/${distributeId}/distributeUsers`,
method: 'get'
});
}

View File

@ -93,19 +93,3 @@ export function updateExamRules(data) {
data: data
});
}
/** 根据课程ID获取试卷 */
export function getExamParperList(lessonId) {
return request({
url: `/api/exam/${lessonId}/list`,
method: 'get'
});
}
/** 根据课程ID获取班级 */
export function getExamClassList(lessonId) {
return request({
url: `/api/lesson/${lessonId}/classes`,
method: 'get'
});
}

View File

@ -9,9 +9,7 @@ export function getCommodityDetailByParams(data) {
});
}
/**
* 获取商品明细列表
*/
/** 获取商品明细列表*/
export function getCommodityList(params) {
return request({
url: '/api/goods',
@ -20,20 +18,7 @@ export function getCommodityList(params) {
});
}
/**
* 保存商品明细列表
*/
export function saveCommodityList(params) {
return request({
url: '/api/goods',
method: 'post',
data: params
});
}
/**
* 删除商品明细
*/
/** 删除商品明细*/
export function delCommodity(id) {
return request({
url: `/api/goods/${id}`,
@ -41,29 +26,7 @@ export function delCommodity(id) {
});
}
/**
* 获取商品地图产品课程列表
*/
export function getMapLesson() {
return request({
url: `/api/goods/tree`,
method: 'get'
});
}
/**
* 获取商品地图产品课程列表
*/
export function getCommodityDetailById(id) {
return request({
url: `/api/goods/${id}`,
method: 'get'
});
}
/**
* 获取商品地图产品课程列表
*/
/** 获取商品地图,产品,课程列表*/
export function updataCommodityList(data) {
return request({
url: `/api/goods/${data.id}`,
@ -72,9 +35,7 @@ export function updataCommodityList(data) {
});
}
/**
* 设置失效或有效切换
*/
/** 设置失效或有效切换*/
export function setCommodityStatus(id) {
return request({
url: `/api/goods/${id}/status`,
@ -110,44 +71,6 @@ export function getGoodsList() {
});
}
// 根据权限id查询商品
export function getGoodsByPermissionId(id) {
return request({
url: `/api/goods/permissionId`,
method: 'get',
params: {
permissionId: id
}
});
}
// 创建商品
export function postsPermissionGoods(data) {
return request({
// url: `/api/goods`,
url: `/api/goods/create/list`,
method: 'post',
data: data
});
}
// 创建万能权限商品
export function postPermissionIdsGoods(data) {
return request({
url: `/api/goods/permissionIds`,
method: 'post',
data: data
});
}
// 创建万能权限商品
export function postCreatePackage(data) {
return request({
url: `/api/goods/create/package`,
method: 'post',
data: data
});
}
// 获取订单对应的商品列表
export function getGoodsListByOrderId(id) {
return request({

View File

@ -26,14 +26,6 @@ export function delSkinCode(id) {
});
}
/** 根据id查询真实线路 */
export function querySkinCode(id) {
return request({
url: `/api/realLine/${id}`,
method: 'get'
});
}
/** 修改真实线路*/
export function updateSkinCode(data) {
return request({
@ -60,23 +52,6 @@ export function putRealLineConfig(id, data) {
});
}
/** 通过皮肤Code更新地图皮肤*/
export function updateSkinCodeByCode(data) {
return request({
url: `/api/realLine/${data.code}/update`,
method: 'put',
data: data
});
}
/** 检查code是否存在*/
export function querySkinCodeExistByCode(code) {
return request({
url: `/api/realLine/${code}/exist`,
method: 'get'
});
}
/** 获取真实线路列表*/
export function getLineCodeList() {
return request({

View File

@ -10,15 +10,6 @@ export function getOrderPageList(params) {
});
}
/** 根据ID获取订单数据*/
export function getOrderDetail(id, params) {
return request({
url: `/api/order/${id}`,
method: 'get',
params: params
});
}
/** 创建一个订单*/
export function createOrder(data) {
return request({
@ -37,31 +28,6 @@ export function updateOrder(data) {
});
}
export function deleteOrder(id) {
return request({
url: `/api/order/${id}`,
method: 'delete'
});
}
/** 订单权限领取*/
export function getOrder(params) {
return request({
url: '/api/order/getOrder',
method: 'get',
params: params
});
}
/** 订单权限分发*/
export function giveOrder(data) {
return request({
url: '/api/order/giveOrder',
method: 'post',
data: data
});
}
/** 订单续费*/
export function getOrderCharge(id) {
return request({
@ -104,14 +70,6 @@ export function cancalOrder(orderId) {
});
}
// 万能权限查询权限包商品
export function postFindPermission(ids) {
return request({
url: `/api/goods/permissionIds?ids=${ids}`,
method: 'get'
});
}
// 获取订单的分发二维码
export function getDistributeFromOrder(orderCode) {
return request({

View File

@ -1,29 +1,4 @@
import request from '@/utils/request';
/** 注册用户*/
export function createUserInfo(data) {
return request({
url: '/api/userinfo/create',
method: 'put',
data: data
});
}
/** 根据用户Id获取用户信息*/
export function getUserInfoByOpenId(params) {
return request({
url: '/api/userinfo/getByOpenId',
method: 'get',
params: params
});
}
/** 根据姓名或者手机号查询用户*/
export function getUserInfoByNameOrMobile(params) {
return request({
url: '/api/userinfo/nameOrMobile',
method: 'get',
params: params
});
}
/** 查询用户参数*/
export function getUserConfigInfo() {
@ -33,15 +8,6 @@ export function getUserConfigInfo() {
});
}
/** 设置用户参数*/
export function setUserConfigInfo(data) {
return request({
url: '/api/user/config',
method: 'post',
data: data
});
}
/** 获取销售列表*/
export function getSellerList() {
return request({
@ -85,10 +51,10 @@ export function saveUserSubscribe(data) {
});
}
// 修改用户权限
// 修改用户信息
export function putRoles(data) {
return request({
url: `/api/user/${data.id}/role`,
url: `/api/user/${data.id}/info`,
method: 'put',
data: data
});
@ -211,14 +177,6 @@ export function exportStudentResults(projectCode, data) {
data: data
});
}
// 生成绑定微信二维码
export function getWxQrCode(params) {
return request({
url: `/api/user/wmurl`,
method: 'get',
params: params
});
}
// 获取微信小程序绑定二维码
export function getBindWxQrCodeUrl() {

View File

@ -51,22 +51,6 @@ export function delPublishExam(id) {
});
}
/** 删除用户实训*/
export function delTrainingList() {
return request({
url: `/api/userExam/list`,
method: 'delet'
});
}
/** 设置试卷失效 */
export function setExamGive(id) {
return request({
url: `/api/userExam/${id}/abandon`,
method: 'put'
});
}
export function updateExam(data) {
return request({
url: `/api/userExam/${data.id}`,

View File

@ -23,13 +23,6 @@ export function getProjectDeviceList(params) {
params:params
});
}
// export function getProjectDeviceList(params) {
// return request({
// url: `/api/device/paging`,
// method: 'get',
// params:params
// });
// }
/** 删除项目设备 */
export function deleteProjectDevice(id) {
return request({
@ -92,14 +85,7 @@ export function setPscConfig(id, data) {
data: data
});
}
/** 查询项目下的所有设备 */
export function getAllDeviceInProject(params) {
return request({
url: `/api/project/device/project`,
method: 'get',
params
});
}
/** 添加/修改ibp设备配置 */
export function setVrIbpConfig(id, data) {
return request({
@ -183,3 +169,11 @@ export function setSandboxConfig(id, data) {
data: data
});
}
/** 添加/修改联锁工作站配置 */
export function setIlwConfig(id, data) {
return request({
url: `/api/device/${id}/config/ilw`,
method: 'put',
data: data
});
}

View File

@ -1,10 +1,57 @@
import request from '@/utils/request';
/** 推送通知消息*/
export function pushMessage(data) {
return request({
url: `/api/pushMessage`,
method: 'post',
data: data
data
});
}
export function pushSysNotice(data) {
return request({
url: `/api/v1/sysNotice?noticeType=${data.noticeType}`,
method: 'post',
data
});
}
export function postLicense(data) {
return request({
url: `/api/license`,
method: 'post',
data
});
}
export function postLicenseValidate(data) {
return request({
url: `/api/license/validate`,
method: 'post',
// baseURL: 'https://joylink.club/jlcloud',
data
});
}
export function postLicenseLocal(data) {
return request({
url: `/api/license/local`,
method: 'post',
data
});
}
export function getPagingQueryList(params) {
return request({
url: `/api/license/pagingQuery`,
method: 'get',
params
});
}
export function putLicenseValid(id) {
return request({
url: `/api/license/${id}/invalidating`,
method: 'put'
});
}

34
src/api/questionsRule.js Normal file
View File

@ -0,0 +1,34 @@
import request from '@/utils/request';
/** 添加出题规则 */
export function addQuestionRule(data) {
return request({
url: `/api/questionsRule`,
method: 'post',
data
});
}
/** 分页获取规则列表 */
export function getQustionRuleListPage(params) {
return request({
url: `/api/questionsRule/paging`,
method: 'get',
params
});
}
/** 删除出题规则 */
export function deleteQuestionRule(id) {
return request({
url: `/api/questionsRule/${id}`,
method: 'delete'
});
}
/** 更改出题规则内容 */
export function updateQuestionRule(id, data) {
return request({
url: `/api/questionsRule/${id}`,
method: 'put',
data: data
});
}

View File

@ -1,35 +1,17 @@
import request from '@/utils/request';
/** 分页查询竞赛 */
export function getRaceList(params) {
/** 导入项目试题库 */
export function importQuestionBand(data, companyId) {
return request({
url: `/api/race`,
method: 'get',
params: params
});
}
/** 创建竞赛 */
export function createRace(data) {
return request({
url: `/api/race`,
url: `/api/questionBank/questions/import?id=${companyId}`,
method: 'post',
data
});
}
/** 修改竞赛信息 */
export function updateRace(id, data) {
/** 查询公司下题目类型数量 */
export function selectQuestionTypeNum(companyId) {
return request({
url: `/api/race/${id}`,
method: 'put',
data
});
}
/** 获取实操试题列表(题库)*/
export function getPracticeList(params) {
return request({
url: `/api/v1/competitionPractical`,
method: 'get',
params
url: `/api/questionBank/type/number?companyId=${companyId}`,
method: 'get'
});
}

197
src/api/rpTools.js Normal file
View File

@ -0,0 +1,197 @@
import request from '@/utils/request';
/**
* 查询线路列表
*/
export function listLines() {
return request({
url: `/api/rpTools/map`,
method: 'get'
})
}
/**
* 查询线路列表
*/
export function listStations(lineId) {
return request({
url: `/api/rpTools/${lineId}/station`,
method: 'get'
})
}
/**
* 更新线路车站
*/
export function updateStation(stationId, data) {
return request({
url: `/api/rpTools/station/${stationId}`,
method: 'put',
data
})
}
/**
* 查询运行图列表
*/
export function listRps() {
return request({
url: `/api/rpTools`,
method: 'get'
});
}
/** 创建运行图*/
export function createRp(data) {
return request({
url: `/api/rpTools`,
method: 'post',
data
});
}
/**
* 删除运行图组
*/
export function deleteRp(groupId) {
return request({
url: `/api/rpTools/${groupId}`,
method: 'delete'
})
}
/** 获取运行图配置*/
export function getRpConfig(planId) {
return request({
url: `/api/rpTools/${planId}/config`,
method: 'get'
});
}
/** 修改运行图配置*/
export function modifyRpConfig(planId, data) {
return request({
url: `/api/rpTools/${planId}/config`,
method: 'put',
data
});
}
/** 获取运行图数据*/
export function getRpTools(planId) {
return request({
url: `/api/rpTools/${planId}`,
method: 'get'
});
}
/** 添加车次*/
export function addRpTrip(planId, data) {
return request({
url: `/api/rpTools/${planId}/trip`,
method: 'post',
data
});
}
/** 删除车次*/
export function delRpTrip(planId, tripNo) {
return request({
url: `/api/rpTools/${planId}/${tripNo}/trip`,
method: 'delete'
});
}
/** 平移服务*/
export function translateRpService(planId, serviceNo, data) {
return request({
url: `/api/rpTools/${planId}/${serviceNo}/service`,
method: 'put',
data
});
}
/** 删除服务*/
export function delRpService(planId, serviceNo) {
return request({
url: `/api/rpTools/${planId}/${serviceNo}/service`,
method: 'delete'
});
}
/** 添加区域*/
export function createRpArea(planId, data) {
return request({
url: `/api/rpTools/${planId}/area`,
method: 'post',
data
});
}
/** 修改区域*/
export function modifyRpArea(planId, areaNo, data) {
return request({
url: `/api/rpTools/${planId}/${areaNo}/area`,
method: 'put',
data
});
}
/** 修改区域文字*/
export function modifyAreaNote(planId, areaNo, data) {
return request({
url: `/api/rpTools/${planId}/${areaNo}/text`,
method: 'put',
data
});
}
/** 删除区域*/
export function delRpArea(planId, areaNo) {
return request({
url: `/api/rpTools/${planId}/${areaNo}/area`,
method: 'delete'
});
}
/** 修改运行时间*/
export function justTripNoRunning(planId, tripNo, data) {
return request({
url: `/api/rpTools/${planId}/${tripNo}/running`,
method: 'put',
data
});
}
/** 修改停站时间*/
export function justTripNoStop(planId, tripNo, data) {
return request({
url: `/api/rpTools/${planId}/${tripNo}/stop`,
method: 'put',
data
});
}
/** 修改折返时间*/
export function justTripTurnBack(planId, tripNo, data) {
return request({
url: `/api/rpTools/${planId}/${tripNo}/turnBack`,
method: 'put',
data
});
}
/** 开始编辑*/
export function startRpEdit(planId) {
return request({
url: `/api/rpTools/${planId}/edit`,
method: 'put'
})
}
/** 开始编辑*/
export function endRpEdit(planId) {
return request({
url: `/api/rpTools/${planId}/endEdit`,
method: 'put'
})
}

View File

@ -1,19 +1,6 @@
import request from '@/utils/request';
/**
* 新建地图速度等级列表
*/
export function newSpeedLevels(data) {
return request({
url: '/api/runPlan/draft/speed',
method: 'post',
data: data
});
}
/**
* 获取运行图的车站列表
*/
/** 获取运行图的车站列表*/
export function getStationList(mapId) {
return request({
url: `/api/runPlan/draft/station/${mapId}`,
@ -30,20 +17,7 @@ export function populatingGenericData(planId, data) {
});
}
/**
* 创建运行图
*/
export function newRunPlan(data) {
return request({
url: '/api/runPlan/draft',
method: 'post',
data: data
});
}
/**
* 查询运行图获取数据
*/
/** 查询运行图获取数据*/
export function queryRunPlan(planId) {
return request({
url: `/api/runPlan/draft/${planId}`,
@ -96,9 +70,7 @@ export function publishRunPlan(data) {
});
}
/**
* 导入真实运行图
*/
/** 导入真实运行图*/
export function importRunPlan(data) {
return request({
url: `/api/runPlan/draft/${data.mapId}/prdPlan`,
@ -115,13 +87,6 @@ export function getRpListByMapId(mapId) {
});
}
/** 获取站间运行时间*/
export function getStationRunning(mapId) {
return request({
url: `/api/runPlan/draft/${mapId}/stationRunning`,
method: 'get'
});
}
/** 获取地图原始站间运行等级 */
export function getMapStationRun(mapId) {
return request({
@ -188,6 +153,15 @@ export function addPlanService(data) {
});
}
/** 修改计划*/
export function updatePlanService(planId, serviceNumber, data) {
return request({
url: `/api/runPlan/draft/${planId}/service/${serviceNumber}`,
method: 'put',
data: data
});
}
/** 删除计划*/
export function deletePlanService(data) {
return request({
@ -243,6 +217,22 @@ export function getRoutingBySDTNumber(params) {
});
}
/** 修改计划号*/
export function updateServiceNumber(planId, serviceNumber, newServiceNumber) {
return request({
url: `/api/runPlan/draft/${planId}/service/${serviceNumber}/serviceNumber?newServiceNumber=${newServiceNumber}`,
method: 'put'
});
}
/** 修改任务车次号*/
export function updateTripNumber(planId, SDTNumber, tripNumber) {
return request({
url: `/api/runPlan/draft/${planId}/trip/${SDTNumber}/tripNumber?tripNumber=${tripNumber}`,
method: 'put'
});
}
/** 运行图仿真测试*/
export function runPlanNotify({ planId }) {
return request({

View File

@ -1,58 +1,12 @@
import request from '@/utils/request';
export function querySecheduling(group, 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
});
}
export function getSchedulingAllTrains(group) {
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
});
}
export function saveScheduling(group, data) {
return request({
url: `/api/scheduling/${group}/save`,
method: 'post',
data
});
}
export function generateSchedulingAgain(group) {
return request({
url: `/api/scheduling/${group}/rebuild`,
method: 'delete'
});
}
/** 生成地图通用派班计划 */
export function generateCommonScheduling (data) {
return request({
url: `/api/v1/scheduling/generate/common`,
method: 'post',
data
});
}
/** 查询某天的派班计划 */
export function querySechedulingNew (group, params) {
return request({

View File

@ -1,15 +1,5 @@
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
});
}
/** 分页查找上线的剧本(新版)*/
export function getScriptPageListOnlineNew(params) {
return request({
@ -19,14 +9,6 @@ export function getScriptPageListOnlineNew(params) {
});
}
/** 通过ID查询发布的剧本的详细信息 */
export function getScriptById(id) {
return request({
url: `/api/script/${id}/detail`,
method: 'get'
});
}
/** 通过ID查询发布的剧本的详细信息(新版) */
export function getScriptByIdNew(id) {
return request({
@ -35,14 +17,6 @@ export function getScriptByIdNew(id) {
});
}
/** 通过group查询未发布剧本的详细信息 */
export function getDraftScriptByGroup(group) {
return request({
url: `/api/simulation/${group}/script/loadedScript`,
method: 'get'
});
}
/** 通过group查询未发布剧本的详细信息(新版) */
export function getDraftScriptByGroupNew(group) {
return request({
@ -52,7 +26,7 @@ export function getDraftScriptByGroupNew(group) {
}
/** 剧本撤销发布 */
export function retractScript(id, data) {
export function retractScript(id) {
return request({
url: `/api/script/draft/${id}/retract`,
method: 'put'
@ -127,3 +101,20 @@ export function getAllSelectedScriptRole(group) {
});
}
/** 草稿剧本数据导入*/
export function postScriptImport(mapId, name, data) {
return request({
url: `/api/script/draft/${mapId}/import?name=${name}`,
method: 'post',
data: data,
time: 60000
});
}
/** 草稿剧本数据导出 */
export function getScriptExport(id) {
return request({
url: `/api/script/draft/${id}/export`,
method: 'get'
});
}

View File

@ -1,23 +1,5 @@
import request from '@/utils/request';
/** 获取故障规则列表*/
export function getFailureGenerateRules(params) {
return request({
url: `/api/simulation/failureGenerateRules`,
method: 'get',
params: params
});
}
/** 设置自动故障*/
export function setFailureMode(data, group) {
return request({
url: `/api/simulation/${group}/failureMode`,
method: 'post',
data: data
});
}
/** 设置自动故障(新版)*/
export function setFailureModeNew(data, group) {
return request({
@ -26,8 +8,14 @@ export function setFailureModeNew(data, group) {
data: data
});
}
/** 获取仿真待触发的故障列表*/
/** 取消自动故障 */
export function cancelFailureModeNew(id, group) {
return request({
url: `/simulation/${group}/faultMode/${id}`,
method: 'put'
});
}
/** 查询已设置所有的自动触发故障*/
export function getSimulationFaultRules(group) {
return request({
url: `/simulation/${group}/faultMode/faultRule`,
@ -35,15 +23,6 @@ export function getSimulationFaultRules(group) {
});
}
// 创建故障规则(新版)
export function addFailureRule(data) {
return request({
url: `/api/v1/faultRule`,
method: 'post',
data: data
});
}
/** 根据id删除故障规则 */
export function deleteFailureRule(id) {
return request({
@ -52,56 +31,7 @@ export function deleteFailureRule(id) {
});
}
/** 获取故障规则列表(新版)*/
export function getFailureRulesNew(params) {
return request({
url: `/api/v1/faultRule/page`,
method: 'get',
params: params
});
}
// 修改故障规则(新版)
export function modifyFailureRule(data) {
return request({
url: `/api/v1/faultRule`,
method: 'put',
data: data
});
}
/** 通过id获取故障规则(新版)*/
export function getFailureRulesByIdNew(id) {
return request({
url: `/api/v1/faultRule/${id}`,
method: 'get'
});
}
/**
* 仿真系统按计划行车
*/
export function runDiagramStart(params, group) {
return request({
url: `/api/simulation/${group}/start`,
method: 'put',
params: params
});
}
/**
* 仿真系统结束计划行车
*/
export function runDiagramOver(group) {
return request({
url: `/api/simulation/${group}/over`,
method: 'put'
});
}
/**
* 退出仿真系统
*/
/** 退出仿真系统*/
export function runDiagramQuit(group) {
return request({
url: `/api/simulation/${group}/quit`,
@ -109,43 +39,6 @@ export function runDiagramQuit(group) {
});
}
/** 获取仿真系统时间*/
export function runDiagramGetTime(group) {
return request({
url: `/api/simulation/${group}/systemTime`,
method: 'get'
});
}
// 查看是否开始按计划行车
export function runDiagramIsStart(group) {
return request({
url: `/api/simulation/${group}/isRunPlanStart`,
method: 'get'
});
}
/**
* 仿真系统CBTC
* @param {*} mapId
*/
export function simulationNotify({ mapId, prdType }) {
return request({
url: `/api/simulation/${mapId}/${prdType}`,
method: 'get'
});
}
/**
* 实训系统CBTC
* @param {*} data
*/
export function trainingNotify({ trainingId }) {
return request({
url: `/api/simulation/training/${trainingId}`,
method: 'get'
});
}
/** 实训系统(新版地图) */
export function trainingNotifyNew({ trainingId }) {
return request({
@ -153,16 +46,7 @@ export function trainingNotifyNew({ trainingId }) {
method: 'get'
});
}
/**
* 考试系统CBTC
* @param {*} data
*/
export function examNotify({ examId }) {
return request({
url: `/api/simulation/exam/${examId}`,
method: 'get'
});
}
/** 考试系统(新版地图)*/
export function examNotifyNew({ examId }) {
return request({
@ -205,30 +89,6 @@ export function deleteSimulationStats(statsId) {
});
}
/** 获取用户鼠标左键选中的设备信息*/
export function letfMouseSelectDevice(deviceCode, group) {
return request({
url: `/api/simulation/${group}/device/${deviceCode}`,
method: 'get'
});
}
/** 获取每日运行图*/
export function getEveryDayRunPlanData(group) {
return request({
url: `/api/simulation/${group}/runPlan`,
method: 'get'
});
}
/** 录制脚本仿真*/
export function scriptRecordNotify(scriptId) {
return request({
url: `/api/simulation/scriptWrite/${scriptId}`,
method: 'get'
});
}
/** 录制脚本仿真(新版)*/
export function scriptRecordNotifyNew(scriptId) {
return request({
@ -237,14 +97,6 @@ export function scriptRecordNotifyNew(scriptId) {
});
}
/** 保存剧本背景*/
export function saveScriptScenes(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/scenes`,
method: 'put'
});
}
/** 保存剧本背景(新版)*/
export function saveScriptScenesNew(group) {
return request({
@ -261,14 +113,6 @@ export function scriptRePreview(group) {
});
}
/** 保存录制任务数据*/
export function saveScriptData(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/saveData`,
method: 'put'
});
}
/** 保存录制任务数据(新版)*/
export function saveScriptDataNew(group) {
return request({
@ -277,15 +121,6 @@ export function saveScriptDataNew(group) {
});
}
/** 更新任务地图定位信息*/
export function updateMapLocation(group, data) {
return request({
url: `/api/simulation/${group}/scriptWrite/mapLocation`,
method: 'put',
data
});
}
/** 更新任务地图定位信息(新版)*/
export function updateMapLocationNew(group, data) {
return request({
@ -295,82 +130,6 @@ export function updateMapLocationNew(group, data) {
});
}
/** 获取剧本编制的所有成员角色*/
export function getScriptMemberData(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/members`,
method: 'get'
});
}
/** 获取剧本出演成员角色 */
export function getScriptPlayMember(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/players`,
method: 'get'
});
}
/** 获取剧本出演成员角色(新版地图) */
export function getScriptPlayMemberNew(group) {
return request({
url: `/api/scriptSimulation/${group}/allPlayer`,
method: 'get'
});
}
/** 取消剧本演出成员角色 */
export function cancleScriptMembers(group, data) {
return request({
url: `/api/simulation/${group}/scriptWrite/removePlayers`,
method: 'put',
data
});
}
/** 取消剧本演出成员角色 */
export function cancleScriptMembersNew(group, data) {
return request({
url: `/api/scriptSimulation/${group}/removePlayers`,
method: 'put',
data
});
}
/** 选择剧本演出成员角色 */
export function selectScriptMembers(group, data) {
return request({
url: `/api/simulation/${group}/scriptWrite/choosePlayers`,
method: 'put',
data
});
}
/** 选择剧本演出成员角色 (新版地图)*/
export function selectScriptMembersNew(group, data) {
return request({
url: `/api/scriptSimulation/${group}/choosePlayers`,
method: 'put',
data
});
}
/** 修改剧本演出成员性别 */
export function modifyScriptMemberSex(group, playerId, data) {
return request({
url: `/api/simulation/${group}/scriptWrite/player/${playerId}?gender=${data.gender}`,
method: 'put'
});
}
/** 清除仿真剧本数据*/
export function dumpScriptData(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/saveData`,
method: 'delete'
});
}
/** 清除仿真剧本数据(新版)*/
export function dumpScriptDataNew(group) {
return request({
@ -379,57 +138,6 @@ export function dumpScriptDataNew(group) {
});
}
/** 查询录制剧本步骤*/
export function queryScriptStep(group) {
return request({
url: `/api/simulation/${group}/scriptRecordStage`,
method: 'get'
});
}
/** 获取指定时间里可加载列车的个数*/
export function getDesignatedTimeTrainNum(params, group) {
return request({
url: `/api/simulation/${group}/plan/trainNum`,
method: 'get',
params
});
}
/** 添加剧本动作 */
export function addScriptAction(group, data) {
return request({
url: `/api/simulation/${group}/scriptWrite/action`,
method: 'post',
data
});
}
/** 添加剧本动作(新版) */
export function addScriptActionNew(group, data) {
return request({
url: `/api/scriptSimulation/${group}/addAction`,
method: 'PUT',
data
});
}
/** 删除剧本动作 */
export function deleteScriptAction(group, actionId) {
return request({
url: `/api/simulation/${group}/scriptWrite/action/${actionId}`,
method: 'delete'
});
}
/** 修改剧本动作 */
export function modifyScriptAction(group, actionId, data) {
return request({
url: `/api/simulation/${group}/scriptWrite/action/${actionId}`,
method: 'put',
data
});
}
/** 修改剧本动作(新版) */
export function modifyScriptActionNew(group, data) {
return request({
@ -455,22 +163,6 @@ export function deleteExistingSimulation(group) {
method: 'delete'
});
}
/** 根据设备类型获取设备列表 */
export function getDeviceCodeByDeviceType(group, params) {
return request({
url: `/api/simulation/${group}/deviceType/devices`,
method: 'get',
params
});
}
/** 获取任务录制的数据 */
export function getScriptRecord(group) {
return request({
url: `/api/simulation/${group}/scriptWrite`,
method: 'get'
});
}
/** 获取任务录制的所有动作(新版)*/
export function getScriptAllAction(group) {
@ -480,22 +172,6 @@ export function getScriptAllAction(group) {
});
}
/** 加载任务*/
export function loadQuest(questId, memberId, group) {
return request({
url: `/api/simulation/${group}/quest/${questId}?memberId=${memberId}`,
method: 'post'
});
}
/** 加载剧本 */
export function loadScript(scriptId, memberId, group) {
return request({
url: `api/simulation/${group}/script/${scriptId}?memberId=${memberId}`,
method: 'post'
});
}
/** 加载剧本(新版) */
export function loadScriptNew(scriptId, memberId, group) {
return request({
@ -504,14 +180,6 @@ export function loadScriptNew(scriptId, memberId, group) {
});
}
/** 退出剧本*/
export function quitScript(group) {
return request({
url: `/api/simulation/${group}/script`,
method: 'delete'
});
}
/** 退出剧本(新版)*/
export function quitScriptNew(group) {
return request({
@ -520,48 +188,6 @@ export function quitScriptNew(group) {
});
}
/** 退出任务*/
export function quitQuest(group) {
return request({
url: `/api/simulation/${group}/quest`,
method: 'put'
});
}
/** 根据group获取仿真对象*/
export function getSimulationInfo(group) {
return request({
url: `/api/simulation/${group}`,
method: 'get'
});
}
/** 获取可用的设备指令*/
export function getAvailableDeviceCommand(params) {
return request({
url: `/api/simulation/deviceCommand/available`,
method: 'get',
params
});
}
/** 保存/修改任务剧本*/
export function saveTaskScript(group, data) {
return request({
url: `/api/simulation/${group}/questRecord/script`,
method: 'post',
data
});
}
/** 暂停剧本编制的仿真 */
export function scriptPause(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/pause`,
method: 'post'
});
}
/** 暂停仿真 */
export function simulationPause(group) {
return request({
@ -570,54 +196,19 @@ export function simulationPause(group) {
});
}
/** 恢复仿真运行并执行刚编辑的剧本动作 */
export function executeScript(group) {
return request({
url: `/api/simulation/${group}/scriptWrite/execute`,
method: 'post'
});
}
/** 恢复仿真运行并执行刚编辑的剧本动作(新版) */
export function executeScriptNew(group) {
return request({
// url: `/api/scriptSimulation/${group}/recoverAndExecute`,
url: `/simulation/${group}/resume`,
method: 'PUT'
});
}
/** 生成用户自己的当日运行图*/
export function generateDayRunPlan(planId, group) {
return request({
url: `/api/simulation/${group}/loadRunPlan/${planId}`,
method: 'post'
});
}
/** 创建派班计划仿真*/
export function schedulingNotify(params) {
return request({
url: `/api/scheduling/simulation`,
method: 'post',
params
});
}
/** 获取PLC网关 */
export function getPlcGateway(group) {
return request({
url: `/api/simulation/${group}/plcGateway`,
method: 'get'
});
}
/** 处理ibp盘事件 */
export function handlerIbpEvent(group, data) {
export function handlerIbpEvent(group, button, stationCode) {
return request({
url: `/api/simulation/${group}/ibp/event`,
method: 'post',
data: data
url: `/simulation/${group}/ibp/${button}?stationCode=${stationCode}`,
method: 'put'
});
}
@ -660,22 +251,6 @@ export function getNewMapDataByGroup(group) {
});
}
/** 新版地图根据仿真mapId获取仿真地图数据 */
export function getNewMapDataByMapId(mapId) {
return request({
url: `/api/map/${mapId}/mapData`,
method: 'get'
});
}
/** 新版地图指令操作定义 */
export function newMapOperate(group, operationId, data) {
return request({
url: `/simulation/${group}/operate/${operationId}`,
method: 'post',
data: data
});
}
/** 新版地图根据group获取仿真运行图 */
export function getEveryDayRunPlanNew(group) {
return request({
@ -700,15 +275,6 @@ export function clearSimulation(group) {
});
}
/** 查询进路信息*/
export function querySignalStatus(group, params) {
return request({
url: `/api/simulation/${group}/status/signal`,
method: 'get',
params
});
}
/** 获取仿真运行图车次号列表 */
export function getTripNumberList(group) {
return request({
@ -757,6 +323,14 @@ export function getTrainDetailBytripNumber(group, params) {
params: params
});
}
/** 根据车次号和表号获取列车信息 */
export function getTrainDetailByStNumber(group, params) {
return request({
url: `/simulation/${group}/planTripInfoBySt`,
method: 'get',
params: params
});
}
/** 获取新版综合仿真仿真成员列表 */
export function getSimulationMemberList(group) {
return request({
@ -799,3 +373,26 @@ export function putSimulationDisconnectById(group, id) {
method: 'put'
});
}
// 获取IBP盘初始状态
export function getIbpInitialState (group, stationCode) {
return request({
url: `/simulation/${group}/${stationCode}/ibp/status`,
method: 'get'
});
}
// 获取报警列表
export function getAlarmList(group, params) {
return request({
url: `/simulation/${group}/alarm`,
method: 'get',
params:params
});
}
// 报警确认
export function confirmAlarm(group, data) {
return request({
url: `/simulation/${group}/alarm/confirm`,
method: 'put',
data
});
}

View File

@ -1,89 +1 @@
import request from '@/utils/request';
// 课程列表
export function getLessonList(code) {
return request({
url: '/api/stats/lesson/list',
method: 'get',
params: {
wmCode: code
}
});
}
// 课程内实训数据统计
export function getLessonTimeChart(data) {
return request({
url: `/api/stats/lesson/${data.id}/stats`,
method: 'get',
params: {
wmCode: data.code
}
});
}
// 查询参与考试的课程列表
export function getExamTree(code) {
return request({
url: '/api/stats/exam/lessonList',
method: 'get',
params: {
wmCode: code
}
});
}
// 查询参与考试的试题列表
export function getstatsExamList(data) {
return request({
url: `/api/stats/exam/${data.lessonId}/list`,
method: 'get',
params: {
wmCode: data.code
}
});
}
// 个人考试数据统计
export function getExamChart(data) {
return request({
url: `/api/stats/exam/${data.examId}/stats`,
method: 'get',
params: {
wmCode: data.code
}
});
}
// 个人关注地图数据统计列表
export function getRelevanceMapList(code) {
return request({
url: `/api/user/subscribe`,
method: 'get',
params: {
wmCode: code
}
});
}
// 仿真地图下产品列表
export function getSimulationPrdList(mapId, code) {
return request({
url: `/api/stats/simulation/${mapId}/prdList`,
method: 'get',
params: {
wmCode: code
}
});
}
// 个人仿真数据统计
export function getSimulationTimeChart(data) {
return request({
url: `/api/stats/simulation/${data.mapId}/stats`,
method: 'get',
params: {
wmCode: data.code
}
});
}
// import request from '@/utils/request';

View File

@ -1,75 +1,68 @@
import request from '@/utils/request';
/** 根据cityCode后去对应地图及其子系统 */
export function getTrainingSystemList(cityCode, params) {
/** 根据cityCode后去对应地图及其子系统 */
return request({
url: `/api/mapSystem/city/${cityCode}`,
method: 'get',
params
});
}
/** 根据mapId生成地图子系统 */
export function generateMapSystem(mapId) {
/** 根据mapId生成地图子系统 */
return request({
url: `/api/mapSystem/generate/${mapId}`,
method: 'post'
});
}
/** 查询子系统信息 */
export function getSubSystemInfo(id) {
/** 查询子系统信息 */
return request({
url: `/api/mapSystem/${id}`,
method: 'get'
});
}
/** 查询子系统详情*/
export function getSubSystemDetail(id) {
/** 查询子系统详情*/
return request({
url: `/api/mapSystem/${id}/detail`,
method: 'get'
});
}
/** 分页查询地图系统 */
export function getMapSystemPageList(params) {
/** 分页查询地图系统 */
return request({
url: `/api/mapSystem`,
method: 'get',
params
});
}
/** 创建地图系统 */
export function createMapSubSystem(data) {
/** 创建地图系统 */
return request({
url: `/api/mapSystem`,
method: 'post',
data: data
});
}
/** 查询子系统信息 */
export function updateSubSystem(id, data) {
/** 查询子系统信息 */
return request({
url: `/api/mapSystem/${id}`,
method: 'put',
data: data
});
}
/** 删除地图系统 */
export function deleteSubSystem(id) {
/** 删除地图系统 */
return request({
url: `/api/mapSystem/${id}`,
method: 'delete'
});
}
/** 根据项目编号查询地图子系统 */
export function getSubSystemByProjectCode() {
/** 根据项目编号查询地图子系统 */
return request({
url: `/api/mapSystem/project`,
method: 'get'

BIN
src/assets/buzzer.mp3 Normal file

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 258 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Some files were not shown because too many files have changed in this diff Show More