index.js
1.16 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import api from "../index";
import urls from "./urls";
export default {
//登陆
getTask(params, id) {
return api.get(urls.getTask, params);
},
editTask(params, taskid) {
return api.post(urls.editTask(taskid), params);
},
editRoi(taskid, subtaskid, params) {
return api.post(urls.editroi(taskid, subtaskid), params);
},
alternatestate(params, taskid, subtaskid) {
return api.post(urls.alternatestate(taskid, subtaskid), params);
},
algostate(params, taskid, subtaskid) {
return api.post(urls.algostate(taskid, subtaskid), params);
},
getSubTask(taskid) {
return api.get(urls.getSubTask(taskid));
},
getStream(devid, vrefid) {
return api.get(urls.getstream(devid, vrefid));
},
getPlayUrl(subid) {
return api.get(urls.getPlayUrl(subid)); // 获取播放地址
},
getTaskParams(taskid, subtaskid) {
return api.get(urls.getTaskParams(taskid, subtaskid));
},
cutpic(devid, vchanid, subtaskid) {
return api.get(urls.cutpic(devid, vchanid, subtaskid));
},
deleteTask(taskid) {
return api.delete(urls.deleteTask(taskid));
},
getConftypes(params) {
return api.get(urls.getConfParam, params);
}
};