index.js 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. import axios from "axios";
  2. import request from "@/tools/request";
  3. const headers = {
  4. isPower: true,
  5. };
  6. export function getStation(data, timeout = 5000) {
  7. return request({
  8. baseURL: process.env.VUE_APP_TEST,
  9. url: "/base/station",
  10. method: "get",
  11. headers,
  12. timeout,
  13. });
  14. }
  15. export function getWtByStation(data, timeout = 5000) {
  16. return request({
  17. baseURL: process.env.VUE_APP_TEST,
  18. url: "/base/windturbine",
  19. method: "get",
  20. params: data,
  21. headers,
  22. timeout,
  23. });
  24. }
  25. export function getPrepareTree(data, timeout = 5000) {
  26. return request({
  27. baseURL: process.env.VUE_APP_TEST,
  28. url: "/power/prepare/tree",
  29. method: "get",
  30. headers,
  31. timeout,
  32. });
  33. }
  34. export function getProcessTree(data, timeout = 5000) {
  35. return request({
  36. baseURL: process.env.VUE_APP_TEST,
  37. url: "/power/process/tree",
  38. method: "get",
  39. headers,
  40. timeout,
  41. });
  42. }
  43. export function getPrepareExcelShow(data, timeout = 5000) {
  44. return request({
  45. baseURL: process.env.VUE_APP_TEST,
  46. url: "/power/prepare/show",
  47. method: "get",
  48. params: data,
  49. headers,
  50. timeout,
  51. });
  52. }
  53. export function getProcessExcelShow(data, timeout = 5000) {
  54. return request({
  55. baseURL: process.env.VUE_APP_TEST,
  56. url: "/power/prepare/show",
  57. method: "get",
  58. params: data,
  59. headers,
  60. timeout,
  61. });
  62. }
  63. export function getPrepareData(data, timeout = 5000) {
  64. return request({
  65. baseURL: process.env.VUE_APP_TEST,
  66. url: "/power/prepare/data",
  67. method: "get",
  68. params: data,
  69. headers,
  70. timeout,
  71. });
  72. }
  73. export function getProcessData(data, timeout = 5000) {
  74. return request({
  75. baseURL: process.env.VUE_APP_TEST,
  76. url: "/power/prepare/data",
  77. method: "get",
  78. params: data,
  79. headers,
  80. timeout,
  81. });
  82. }
  83. export function fittingCurveSave(data, timeout = 5000) {
  84. return request({
  85. baseURL: process.env.VUE_APP_TEST,
  86. url: "/power/fitting/curve/save",
  87. method: "get",
  88. params: data,
  89. headers,
  90. timeout,
  91. });
  92. }
  93. export function dataOptionDel(data, timeout = 5000) {
  94. return request({
  95. baseURL: process.env.VUE_APP_TEST,
  96. url: "/data/option/delete",
  97. method: "get",
  98. params: data,
  99. headers,
  100. timeout,
  101. });
  102. }
  103. export function filesDel(data, timeout = 5000) {
  104. return request({
  105. baseURL: process.env.VUE_APP_TEST,
  106. url: "/data/option/delete",
  107. method: "get",
  108. params: data,
  109. headers,
  110. timeout,
  111. });
  112. }