index.js 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. import request from '@/utils/request'
  2. // 获得当前登录用户所属单位的微型消防站列表
  3. export function getStation(data) {
  4. return request({
  5. url: '/admin-api/backend/micro-station/page',
  6. method: 'get',
  7. params: data
  8. })
  9. }
  10. // 更新当前登录用户所属单位的微型消防站
  11. export function updateStation(data) {
  12. return request({
  13. url: '/admin-api/backend/micro-station/update',
  14. method: 'post',
  15. data: data
  16. })
  17. }
  18. // 删除
  19. export function delStation(query) {
  20. return request({
  21. url: '/admin-api/backend/micro-station/delete',
  22. method: 'post',
  23. params: query
  24. })
  25. }
  26. // 创建消防站
  27. export function createStation(data) {
  28. return request({
  29. url: '/admin-api/backend/micro-station/create',
  30. method: 'post',
  31. data: data
  32. })
  33. }
  34. // orgId的数据来源
  35. // 参数需要传递:"orgId": 0, "pageNo": 1, "pageSize": 10, "userId": 0
  36. export function getOrgId(data) {
  37. return request({
  38. url: '/admin-api/backend/user-org/getOneUser2OrgList',
  39. method: 'post',
  40. data: data
  41. })
  42. }
  43. //获取微型消防站运行列表
  44. export function getStationEvent(data) {
  45. return request({
  46. url: '/admin-api/backend/micro-station-event/page',
  47. method: 'get',
  48. params: data
  49. })
  50. }
  51. //创建微型消防站事件
  52. export function createStationEvent(data) {
  53. return request({
  54. url: '/admin-api/backend/micro-station-event/create',
  55. method: 'post',
  56. data: data
  57. })
  58. }
  59. //获取单位维保报告
  60. export function getOrgReport(data) {
  61. return request({
  62. url: '/admin-api/backend/org-report/page',
  63. method: 'get',
  64. params: data
  65. })
  66. }
  67. //创建单位维保 报告记录
  68. export function createOrgReport(data) {
  69. return request({
  70. url: '/admin-api/backend/org-report/create',
  71. method: 'post',
  72. data: data
  73. })
  74. }
  75. /// 删除单位维保报告
  76. export function delOrgReport(query) {
  77. return request({
  78. url: '/admin-api/backend/org-report/delete',
  79. method: 'DELETE',
  80. params: query
  81. })
  82. }
  83. //删除微型消防站事件
  84. export function delMicrostation(query) {
  85. return request({
  86. url: '/admin-api/backend/micro-station-event/delete',
  87. method: 'DELETE',
  88. params: query
  89. })
  90. }
  91. export function getOneMicrostation(data) {
  92. return request({
  93. url: '/admin-api/backend/micro-station-event/get',
  94. method: 'get',
  95. params: data
  96. })
  97. }
  98. //编辑微型消防站事件
  99. export function updateOrgReport(data) {
  100. return request({
  101. url: '/admin-api/backend/micro-station-event/update',
  102. method: 'post',
  103. data: data
  104. })
  105. }