index.js 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300
  1. import axios from "axios";
  2. import request from "@/tools/request";
  3. const headers = {
  4. isPower: true,
  5. };
  6. //获取风电场站
  7. export function getStation(data, timeout = 5000) {
  8. return request({
  9. baseURL: process.env.VUE_APP_TEST,
  10. url: "/base/station",
  11. method: "get",
  12. headers,
  13. timeout,
  14. });
  15. }
  16. //获取光伏电站
  17. export function getGfstation(data, timeout = 5000) {
  18. return request({
  19. baseURL: process.env.VUE_APP_TEST,
  20. url: "/base/gfstation",
  21. method: "get",
  22. headers,
  23. timeout,
  24. });
  25. }
  26. // 获取风机设备
  27. export function getWtByStation(data, timeout = 5000) {
  28. return request({
  29. baseURL: process.env.VUE_APP_TEST,
  30. url: "/base/windturbine",
  31. method: "get",
  32. params: data,
  33. headers,
  34. timeout,
  35. });
  36. }
  37. // 获取光伏设备
  38. export function getWtByGfstation(data, timeout = 5000) {
  39. return request({
  40. baseURL: process.env.VUE_APP_TEST,
  41. url: "base/inverter",
  42. method: "get",
  43. params: data,
  44. headers,
  45. timeout,
  46. });
  47. }
  48. // 风电准备树
  49. export function getPrepareTree(data, timeout = 5000) {
  50. return request({
  51. baseURL: process.env.VUE_APP_TEST,
  52. url: "/power/prepare/tree",
  53. method: "get",
  54. headers,
  55. timeout,
  56. });
  57. }
  58. // 风电处理树
  59. export function getProcessTree(data, timeout = 5000) {
  60. return request({
  61. baseURL: process.env.VUE_APP_TEST,
  62. url: "/power/process/tree",
  63. method: "get",
  64. headers,
  65. timeout,
  66. });
  67. }
  68. // 风电拟合树
  69. export function getWindFittingTree(data, timeout = 5000) {
  70. return request({
  71. baseURL: process.env.VUE_APP_TEST,
  72. url: "/power/fitting/tree",
  73. method: "get",
  74. headers,
  75. timeout,
  76. });
  77. }
  78. // 风电准备表单
  79. export function getPrepareExcelShow(data, timeout = 5000) {
  80. return request({
  81. baseURL: process.env.VUE_APP_TEST,
  82. url: "/power/prepare/show",
  83. method: "get",
  84. params: data,
  85. headers,
  86. timeout,
  87. });
  88. }
  89. // 风电处理表单
  90. export function getProcessExcelShow(data, timeout = 5000) {
  91. return request({
  92. baseURL: process.env.VUE_APP_TEST,
  93. url: "/power/prepare/show",
  94. method: "get",
  95. params: data,
  96. headers,
  97. timeout,
  98. });
  99. }
  100. // 风电准备表格数据
  101. export function getPrepareData(data, timeout = 5000) {
  102. return request({
  103. baseURL: process.env.VUE_APP_TEST,
  104. url: "/power/prepare/data",
  105. method: "get",
  106. params: data,
  107. headers,
  108. timeout,
  109. });
  110. }
  111. // 风电处理表格数据
  112. export function getProcessData(data, timeout = 5000) {
  113. return request({
  114. baseURL: process.env.VUE_APP_TEST,
  115. url: "/power/process/show",
  116. method: "get",
  117. params: data,
  118. headers,
  119. timeout,
  120. });
  121. }
  122. //
  123. export function fittingCurveSave(data, timeout = 5000) {
  124. return request({
  125. baseURL: process.env.VUE_APP_TEST,
  126. url: "/power/fitting/curve/save",
  127. method: "get",
  128. params: data,
  129. headers,
  130. timeout,
  131. });
  132. }
  133. // 树项删除
  134. export function dataOptionDel(data, timeout = 5000) {
  135. return request({
  136. baseURL: process.env.VUE_APP_TEST,
  137. url: "/data/option/delete",
  138. method: "get",
  139. params: data,
  140. headers,
  141. timeout,
  142. });
  143. }
  144. export function filesDel(data, timeout = 5000) {
  145. return request({
  146. baseURL: process.env.VUE_APP_TEST,
  147. url: "/delete/files",
  148. method: "get",
  149. params: data,
  150. headers,
  151. timeout,
  152. });
  153. }
  154. //光伏准备表单
  155. export function lightPrepareExcelShow(data, timeout = 5000) {
  156. return request({
  157. baseURL: process.env.VUE_APP_TEST,
  158. url: "/new/photovol/datas",
  159. method: "get",
  160. params: data,
  161. headers,
  162. timeout,
  163. });
  164. }
  165. // 光伏准备树
  166. export function getLightPrepareTree(data, timeout = 5000) {
  167. return request({
  168. baseURL: process.env.VUE_APP_TEST,
  169. url: "/new/photovol/allfilelist",
  170. method: "get",
  171. headers,
  172. timeout,
  173. });
  174. }
  175. // 光伏准备表格数据
  176. export function getLightPrepareData(data, timeout = 5000) {
  177. return request({
  178. baseURL: process.env.VUE_APP_TEST,
  179. url: "/new/photovol/filelist",
  180. method: "get",
  181. params: data,
  182. headers,
  183. timeout,
  184. });
  185. }
  186. // 风电拟合表单
  187. export function getWindFittingExcelShow(data, timeout = 5000) {
  188. return request({
  189. baseURL: process.env.VUE_APP_TEST,
  190. url: "/power/fitting/curve",
  191. method: "get",
  192. params: data,
  193. headers,
  194. timeout,
  195. });
  196. }
  197. // 风电拟合表格
  198. export function getWindFittingShow(data, timeout = 5000) {
  199. return request({
  200. baseURL: process.env.VUE_APP_TEST,
  201. url: "/power/fitting/show",
  202. method: "get",
  203. params: data,
  204. headers,
  205. timeout,
  206. });
  207. }
  208. export function getWindFittingData(data, timeout = 5000) {
  209. return request({
  210. baseURL: process.env.VUE_APP_TEST,
  211. url: "/power/fitting/data",
  212. method: "get",
  213. params: data,
  214. headers,
  215. timeout,
  216. });
  217. }
  218. export function getWindFittingFilter(data, timeout = 5000) {
  219. return request({
  220. baseURL: process.env.VUE_APP_TEST,
  221. url: "/power/fitting/filter",
  222. method: "get",
  223. params: data,
  224. headers,
  225. timeout,
  226. });
  227. }
  228. export function getWindFittingAlarms(data, timeout = 5000) {
  229. return request({
  230. baseURL: process.env.VUE_APP_TEST,
  231. url: "/power/fitting/alarms",
  232. method: "get",
  233. params: data,
  234. headers,
  235. timeout,
  236. });
  237. }
  238. export function getWindRoses(data, timeout = 5000) {
  239. return request({
  240. baseURL: process.env.VUE_APP_TEST,
  241. url: "/wind/roses",
  242. method: "get",
  243. params: data,
  244. headers,
  245. timeout,
  246. });
  247. }
  248. export function getWindDeviationRatio(data, timeout = 5000) {
  249. return request({
  250. baseURL: process.env.VUE_APP_TEST,
  251. url: "/wind/deviation/ratio",
  252. method: "get",
  253. params: data,
  254. headers,
  255. timeout,
  256. });
  257. }
  258. export function getWindFittingLine(data, timeout = 5000) {
  259. return request({
  260. baseURL: process.env.VUE_APP_TEST,
  261. url: "/power/fitting/line",
  262. method: "get",
  263. params: data,
  264. headers,
  265. timeout,
  266. });
  267. }
  268. export function getWindFittingTime(data, timeout = 15000) {
  269. return request({
  270. baseURL: process.env.VUE_APP_TEST,
  271. url: "/power/fitting/time",
  272. method: "get",
  273. params: data,
  274. headers,
  275. timeout,
  276. });
  277. }
  278. export function getWindRatedPower(data, timeout = 15000) {
  279. return request({
  280. baseURL: process.env.VUE_APP_TEST,
  281. url: "/rated/power",
  282. method: "get",
  283. params: data,
  284. headers,
  285. timeout,
  286. });
  287. }