
import request from '../utils/request'
// 顶部轮询5指标
export const getOverDatas = (data) =>
    request({
        url: '/holo/area-index-analysis/realtime',
        method: 'get',
    })
export const eventAlarm = (data) =>
    request({
        url: '/holo/event-info/alarm',
        method: 'get',
    })
export const api_getCrossData = (data) =>
    request({
        url: '/web/crossConfig/listLaneInfo',
        method: 'post',
        data: data
    })
export const api_phaseByTimeList = (data) =>
    request({
        url: '/web/planSend/phaseListByTimeSingleRing',
        method: 'post',
        data: data
    })
export const equip_camera = (data) =>
    request({
        url: '/holo/device-camera/list',
        method: 'get',
    })


// 检测器位置信息
export const getDetetors = () =>request({
    url: '/holo/detector/list',
    method: 'get',
})

export const crossInfo = () => request({
    url: '/holo/base-cross-info/list',
    method: 'get',
})


export const eventInfo = (data) => request({
    url: '/holo/event-info/list',
    method: 'get',
    params: data
})

export const inletWayRealTime = (data) => request({
    url: '/holo/analysis-rid-entrace-indicator/realtime',
    method: 'get',
    params: data
})

export const inletWayTimeBetw = (data) => request({
    url: '/holo/analysis-rid-entrace-indicator/time-slot',
    method: 'get',
    params: data
})

export const inletWayTurnRealTime = (data) =>request({
    url: '/holo/analysis-rid-turn-indicators/realtime',
    method: 'get',
    params: data
})

export const inletWayTurnTimeBetw = (data) => request({
    url: '/holo/analysis-rid-turn-indicators/time-slot',
    method: 'get',
    params: data
})

export const roadRealTime = (data) => request({
    url: '/holo/analysis-rid-lane-indicators/realtime',
    method: 'get',
    params: data
})

export const roadTimeBetw = (data) =>request({
    url: '/holo/analysis-rid-lane-indicators/time-slot',
    method: 'get',
    params: data
})

export const getRoadsTurn = (data) => request({
    url: '/holo/base-lane-info/list',
    method: 'get',
    params: data,
})

export const trafficEByTime = (data) =>request({
    url: '/holo/analysis-event-trend/list',
    method: 'get',
})

// 区域时段雷达图
export const areaList = () => request({
    url: '/holo/area-index-analysis/list',
    method: 'get',
})

// 路口交通流量分析
export const crossFlow = () =>request({
    url: '/holo/cross-flow/list',
    method: 'get',
})

// 路段交通流量分析
export const ridFlow = () =>request({
    url: '/holo/rid-flow/list',
    method: 'get',
})

// 路口详情 - 路口交通指标
export const crossIndex = (data) =>request({
    url: '/holo/analysis-cross-indicators/query',
    method: 'get',
    params: data
})

export const eventAnalysis = () =>request({
    url: '/holo/event-analysis/list',
    method: 'get',
})

export const eventAnalysisV2 = (params) =>request({
    url: '/holo/event-analysis/queryByType',
    method: 'get',
    params: params
})

export const areaRecent = () =>request({
    url: '/holo/area-index-analysis/recently',
    method: 'get',
})


export const pedNonAnalysis = () =>request({
    url: '/holo/ped-nonmotor-analysis/list',
    method: 'get',
})


//信号评价-路口配置列表
export const api_getCrossData_opt = (data) =>request({
    url: '/opt/diagno/listLaneInfo',
    method: 'post',
    data: data
})


// 设备图层接口

export const equip_radar = () =>request({
    url: '/holo/device-radar/list',
    method: 'get',
})

export const equip_signal = () =>request({
    url: '/holo/device-signal/list',
    method: 'get',
})

export const equip_weather = () =>request({
    url: '/holo/device-weather/list',
    method: 'get',
})

// 首页非机动车美团/饿了么统计
export const noVehicleDetail = () =>request({
    url: '/holo/analysis-cross-non-motor/category-monitor',
    method: 'get',
})

// 首页非机动车趋势
export const noVehicleTrend = () => request({
    url: '/holo/analysis-cross-non-motor/category-monitor-trend',
    method: 'get',
})


export const api_getCameraTable = (data) =>
    request({
        url: '/holo/analysis-statistic-data-lane/page',
        method: 'post',
        data: data
    })
