api.js 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. const url = {
  2. library_url: 'http://ott80testlibrary.yifangjiaoyu.cn/mobile/page',
  3. schedule_url: 'http://ott80test-schedule.yifangjiaoyu.cn/mobile/schedule/',
  4. user_url: 'http://ott80test-base.yifangjiaoyu.cn/mobile/user',
  5. upload_img: 'http://ott80test-base.yifangjiaoyu.cn/file/upload',
  6. get_member: 'http://ott80test-trade.yifangjiaoyu.cn/customer/order/member',
  7. pay_url: 'http://ott80test-trade.yifangjiaoyu.cn/mobile',
  8. get_voucher: 'http://ott80test-trade.yifangjiaoyu.cn/mobile/voucher',
  9. get_isLogin: 'http://ott80test-base.yifangjiaoyu.cn/mobile/user/isLogin',
  10. get_showcase: 'http://ott80testlibrary.yifangjiaoyu.cn/mobile/page/showcase'
  11. };
  12. export default class APIConfig {
  13. static getLibraryUrl(path) {
  14. return url.library_url + path;
  15. }
  16. static getScheduleUrl(path) {
  17. return url.schedule_url + path;
  18. }
  19. static getUserUrl(path) {
  20. return url.user_url + path;
  21. }
  22. static getUploadImg() {
  23. return url.upload_img;
  24. }
  25. static getPayUrl() {
  26. return url.pay_url;
  27. }
  28. static getMemberUrl() {
  29. return url.get_member;
  30. }
  31. static getVoucherUrl() {
  32. return url.get_voucher;
  33. }
  34. static getIsLogin() {
  35. return url.get_isLogin;
  36. }
  37. static getShowCase(params) {
  38. console.log('url.get_showcase + params', url.get_showcase + params);
  39. return url.get_showcase + params;
  40. }
  41. }