fetch.js 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. import { $http } from "./config";
  2. export default {
  3. // 登录
  4. login(data) {
  5. return $http("/user/web/login", data);
  6. },
  7. // 获取首页信息
  8. getIndexData(data) {
  9. return $http("/index", data);
  10. },
  11. // 新增船东
  12. addShipOwner(data) {
  13. return $http("/shipOwner/add", data);
  14. },
  15. // 获取船东列表
  16. getShipOwnerList(data) {
  17. return $http("/shipOwner/list", data);
  18. },
  19. // 获取船东详情
  20. getShipOwnerDetail(data) {
  21. return $http("/shipOwner/detail", data);
  22. },
  23. // 更新船东信息
  24. updateShipOwner(data) {
  25. return $http("/shipOwner/update", data);
  26. },
  27. // 新增船舶
  28. addShip(data) {
  29. return $http("/ship/add", data);
  30. },
  31. // 删除船舶
  32. deleteShip(data) {
  33. return $http("/ship/delete", data);
  34. },
  35. // 删除船舶证书
  36. deleteShipCert(data) {
  37. return $http("/ship/delete/cert", data);
  38. },
  39. // 首页船舶详情
  40. getIndexShipDetail(data) {
  41. return $http("/index/detail", data);
  42. },
  43. // 船舶详情
  44. getShipDetail(data) {
  45. return $http("/ship/detail", data);
  46. },
  47. // 获取船舶列表
  48. getShipList(data) {
  49. return $http("/ship/list", data);
  50. },
  51. // 使用mmsi匹配船舶
  52. searchShip(data) {
  53. return $http("/ship/search", data);
  54. },
  55. // 更新船舶基础信息
  56. updateShip(data) {
  57. return $http("/ship/update", data);
  58. },
  59. // 更新证书有效期
  60. updateShipCertValid(data) {
  61. return $http("/ship/update/cert/valid", data);
  62. },
  63. // 获取证书/保险列表
  64. getCertList(data) {
  65. return $http("/cert/list", data);
  66. },
  67. // 获取初始化数据-新增船舶
  68. getAddShipCerts(data) {
  69. return $http("/cert/addShip/type", data);
  70. },
  71. // 获取证书及有效期类型-证书列表
  72. getCertListType(data) {
  73. return $http("/cert/certList/type", data);
  74. },
  75. };