/*
 * @Author: 许宏杰
 * @Date: 2022-03-31 15:28:43
 * @LastEditors: 许宏杰
 * @LastEditTime: 2022-05-24 09:48:55
 * @FilePath: \taicangpopulationpc\src\api\home\index.js
 */
import request from "@/utils/request";

// 获取网格员id
export function getNetWorkId(params) {
  return request({
    url: "/taicangpop/data/getparentid",
    method: "GET",
    params,
  });
}

//查询总数统计数据列表
export function getTotaldata(params) {
  return request({
    url: "/taicangpop/data/totaldata",
    method: "GET",
    params,
  });
}
//查询颜色列表
export function getColorList(params) {
  return request({
    url: "/taicangpop/data/grouphousedata",
    method: "GET",
    params,
  });
}
//页面初始化（加载网格排名）
export function initGetNetWorkData(params) {
  return request({
    url: "/taicangpop/data/parenttimedata",
    method: "GET",
    params,
  });
}
//根据网格园名字进行排名
export function netWorkNameP(params) {
  return request({
    url: "/taicangpop/data/parentpersondata",
    method: "GET",
    params,
  });
}
//echatr图标数据
export function echartsData(params) {
  return request({
    url: "/taicangpop/data/timedata",
    method: "GET",
    params,
  });
}

//输入框搜索

export function inputSearch(params) {
  return request({
    url: "/taicangpop/data/getxinxi",
    method: "GET",
    params,
  });
}

//网格员帅选简介
export function getNectWorkOffice(params) {
  return request({
    url: "/taicangpop/data/getpeopellist",
    method: "GET",
    params,
  });
}
//根据person查询数据
export function getPersonData(params) {
  return request({
    url: "/taicangpop/data/persontimedata",
    method: "GET",
    params,
  });
}
//根据person时间百分比查询数据
export function getPersonTimePm(params) {
  return request({
    url: "/taicangpop/data/personparenttimedata",
    method: "GET",
    params,
  });
}
//根据person人百分比查询数据
export function getPersonremPm(params) {
  return request({
    url: "/taicangpop/data/personparentpersondata",
    method: "GET",
    params,
  });
}
//获取小区信息
export function getxiaoqu(deptId) {
  return request({
    url: `/taicangpop/data/${deptId}`,
    method: "GET",
  });
}
//预警列表
export function getWarningList(params) {
  return request({
    url: "/taicangpop/data/getyujing",
    method: "GET",
    params,
  });
}
//回收中心
export function getRecycleList(params) {
  return request({
    url: "/taicangpop/recycle/list",
    method: "GET",
    params,
  });
}
//导出搜索中心
export function exportSearch(params) {
  return request({
    url: "/taicangpop/data/exportxinxi",
    method: "GET",
    params,
  });
}
//导出预警列表
export function exportyujing(params) {
  return request({
    url: "/taicangpop/data/exportyujing",
    method: "GET",
    params,
  });
}

// 回收站导出
export function exportHuishou(params) {
  return request({
    url: "/taicangpop/recycle/export",
    method: "GET",
    params,
  });
}
//回收表恢复
export function recoverData(data) {
  return request({
    url: "/taicangpop/recycle",
    method: "POST",
    data,
  });
}
//删除回收中心数据
export function removeData(ids) {
  return request({
    url: `/taicangpop/recycle/${ids}`,
    method: "DELETE",
  });
}

//获取日志中心list
export function getLog(params) {
  return request({
    url: "/taicangpop/log/list",
    method: "GET",
    params,
  });
}
//导出日志中心数据
export function exportLog(params) {
  return request({
    url: "/taicangpop/log/export",
    method: "GET",
    params,
  });
}

export function getrealTime(params) {
  return request({
    url: "/taicangpop/tc/tcUpdate",
    method: "get",
    params,
  });
}
