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
43
44
45
46
47
48
| /**
| * 现场巡查任务相关数据接口
| */
| import { get, post } from '../../services/baseRequset';
| import { inspectUrl, inspectPicUrl } from '../../config/index';
| import { transSceneType } from '../../model/sceneType';
|
| export default {
| /**
| * 查询总任务
| * @param {Object} area
| * {
| * starttime -- 开始时间,格式为 YYYY-MM-DD HH:mm:ss
| * endtime -- 结束时间,格式为 YYYY-MM-DD HH:mm:ss
| * }
| */
| fetchTopTasks: area => {
| return post(
| {
| url: `/task/find`,
| data: area,
| },
| inspectUrl,
| ).then(res => res.data);
| },
|
| /**
| * 获取每日任务统计信息
| * @param {String} topTaskId 总任务主键id
| * @param {String} userId 用户id,当用户类型userType为1(监管用户)时,会根据用户id获取其权限内的统计信息
| * @param {String} userType 用户类型,0:管理员;1:监管用户;2:政府部门;3:企业
| */
| fetchDayTasks(topTaskId, sceneTypeId, userId = '', userType = '0') {
| return get(
| {
| url: `/task/dayTask/${topTaskId}`,
| params: {
| userId,
| userType,
| sceneTypeId,
| },
| },
| inspectUrl,
| ).then(res => {
| return res.data;
| });
| },
| };
|
|