config.js 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. // 配置文件
  2. const env = wx.getAccountInfoSync().miniProgram;
  3. // 请求根路径
  4. let baseUrl = "http://8.136.199.33:8500/api",
  5. pcUrl,
  6. reportLinkUrl,
  7. intemalLinkUrl,
  8. reportStrategyUrl,
  9. ficcReport;
  10. if (env.envVersion === "develop") {
  11. //开发
  12. baseUrl = "http://8.136.199.33:8500/api";
  13. pcUrl = "https://cygxpctest.hzinsights.com/cygx_pc";
  14. reportLinkUrl = "http://xcxh5test.hzinsights.com/xcx_h5/raiReportDtl";
  15. intemalLinkUrl = "http://xcxh5test.hzinsights.com/xcx_h5/internalDetials";
  16. reportStrategyUrl = "http://xcxh5test.hzinsights.com/xcx_h5/strategyReport";
  17. ficcReport = "http://xcxh5test.hzinsights.com/xcx_h5/ficcReportDtl";
  18. } else if (env.envVersion === "trial") {
  19. //体验版
  20. baseUrl = "http://8.136.199.33:8500/api"; // 测试
  21. //baseUrl = "https://cygx.hzinsights.com/api"; //生产
  22. pcUrl = "https://cygxpctest.hzinsights.com/cygx_pc"; // 测试
  23. //pcUrl = "https://cygxpc.hzinsights.com/cygx_pc"; //生产
  24. reportLinkUrl = "http://xcxh5test.hzinsights.com/xcx_h5/raiReportDtl"; //测试
  25. //reportLinkUrl = "https://details.hzinsights.com/raiReportDtl"; //生产
  26. intemalLinkUrl = "http://xcxh5test.hzinsights.com/xcx_h5/internalDetials";
  27. reportStrategyUrl = "http://xcxh5test.hzinsights.com/xcx_h5/strategyReport"; //测试
  28. //reportStrategyUrl = "https://details.hzinsights.com/strategyReport"; //生产
  29. ficcReport = "http://xcxh5test.hzinsights.com/xcx_h5/ficcReportDtl";
  30. } else if (env.envVersion === "release") {
  31. //正式版
  32. baseUrl = "https://cygx.hzinsights.com/api";
  33. pcUrl = "https://cygxpc.hzinsights.com/cygx_pc"; //生产
  34. reportLinkUrl = "https://details.hzinsights.com/raiReportDtl"; //生产
  35. intemalLinkUrl = "https://details.hzinsights.com/internalDetials"; //生产
  36. reportStrategyUrl = "https://details.hzinsights.com/strategyReport"; //生产
  37. ficcReport = "https://details.hzinsights.com/ficcReportDtl";
  38. }
  39. module.exports = {
  40. baseUrl,
  41. pcUrl,
  42. reportLinkUrl,
  43. reportStrategyUrl,
  44. intemalLinkUrl,
  45. ficcReport,
  46. };