index.js 1.8 KB
import api from "../index";
import baseUrl from "../baseUrl";
export default {
  getEventType() {
    return api.get(`${baseUrl}/api/v1/codes/event_types`);
  },
  getTrafficType(params) {
    //类型统计
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/traffic/type`, params);
  },
  getKeyVehicle(params) {
    //重点车辆
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/traffic/key/vehicle`,params);
  },
  getTrafficSnap(params) {
    //今日抓拍
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/traffic/snap`, params)
  },
  getTrafficHour(params) {
    //今日事件趋势
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/traffic/hour`, params)
  },
  getBehaviorType(params) {
    //综治类型统计
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/behavior/type`, params);
  },
  getBehaviorArea(params) {
    //区域事件统计
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/behavior/area`, params);
  },
  getBehaviorSna(params) {
    //今日抓拍量
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/behavior/snap`, params);
  },
  getBehaviorHour(params) {
    //今日事件趋势
    return api.get(`${baseUrl}/api/v1/datahandle/statistics/behavior/hour`, params);
  },
  getDevList(devid, vtype) {
    // 获取设备信息
    return api.get(`${baseUrl}/api/v1/devconf_fx/devs/9cb6e39adc5176b81879f6c22f1d962/vchan_struct?s=1578967233185&limit=1000000`);
  },
  addShowUrl(params) {
    //添加展示
    return api.post(`${baseUrl}/api/v1/datahandle/vchan/conf`, params);
  },
  editShowUrl(params, unid) {
    //添加展示
    return api.post(`${baseUrl}/api/v1/datahandle/vchan/conf/${unid}`, params);
  },
  getShowUrl(params) {
    //修改展示
    return api.get(`${baseUrl}/api/v1/datahandle/vchan/conf`, params);
  },
}