monitor.js 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. import request from '@/utils/request'
  2. // 获取左侧动态感知设备
  3. export function selectDeviceType() {
  4. return request({
  5. url: '/center-agriculture/monitor/selectDeviceType',
  6. method: 'post',
  7. })
  8. }
  9. // 根据设备类型查看列表
  10. export function selectCameraByDeptId(deptId) {
  11. return request({
  12. url: '/center-agriculture/monitor/selectCameraByDeptId',
  13. method: 'post',
  14. data: {
  15. "deptId": deptId
  16. }
  17. })
  18. }
  19. // 获取重点区域
  20. export function selectKeyAreaList() {
  21. return request({
  22. url: '/center-data/importarea/listImportareaFegin',
  23. method: 'post',
  24. data: {
  25. areaType: "6"
  26. }
  27. })
  28. }
  29. //获取点位周边摄像头
  30. export function findCameraByEventCoordinate(longitude, latitude) {
  31. // longitude = '124.41986560821533';
  32. // latitude = '43.08817137032747';
  33. return request({
  34. url: '/center-traffic/traffic/findCameraByEventCoordinate?longitude=' + longitude + "&latitude=" + latitude +
  35. "&type=1",
  36. method: 'get',
  37. })
  38. }
  39. //根据部门ID获取具有查看权限的摄像头
  40. export function getCamerasByDeptId(deptId) {
  41. return request({
  42. url: '/center-traffic/traffic/getCamerasByDeptId?deptId=' + deptId,
  43. method: 'get',
  44. })
  45. }
  46. //转到固定点位
  47. export function rotation(lng, lat, list) {
  48. // lng = '124.41986560821533';
  49. // lat = '43.08817137032747';
  50. return request({
  51. url: '/center-traffic/traffic/rotation',
  52. method: 'post',
  53. data: {
  54. lng: lng,
  55. lat: lat,
  56. list: list
  57. }
  58. })
  59. }
  60. // 获取重点区域
  61. export function getRegionalFlag(id) {
  62. return request({
  63. url: '/center-fire/VisuForestCloudMapController/getRegionalFlag/' + id,
  64. method: 'get',
  65. })
  66. }
  67. //根据部门id查询部门及部门以下的数据,没有则默认查询所有
  68. export function getSensorListByDeptId(deptId) {
  69. return request({
  70. url: '/center-fire/VisuForestMonitorCenterController/getSensorListByDeptId?deptId=' + deptId,
  71. method: 'get',
  72. })
  73. }
  74. //根据部门id查询部门及部门以下的数据,没有则默认查询所有
  75. export function getDlblistBydeptId(deptId) {
  76. let url = "";
  77. if(deptId!=null){
  78. url= '/center-fire/VisuForestMonitorCenterController/getDlblistBydeptId?deptId=' + deptId;
  79. }else{
  80. url= '/center-fire/VisuForestMonitorCenterController/getDlblistBydeptId';
  81. }
  82. return request({
  83. url: url,
  84. method: 'get',
  85. })
  86. }
  87. //根据部门id查询部门及部门以下的数据,没有则默认查询所有
  88. export function getMonitorDeviceAndDataList(deptId) {
  89. let url = "";
  90. if(deptId!=null){
  91. url= '/center-monitor/device/getMonitorDeviceAndDataList?deptId=' + deptId+"&type=7";
  92. }else{
  93. url= '/center-monitor/device/getMonitorDeviceAndDataList'+"&type=7";
  94. }
  95. return request({
  96. url: url,
  97. method: 'get',
  98. })
  99. }