环卫车小程序前端代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
1.2 KiB

5 months ago
4 months ago
5 months ago
4 months ago
5 months ago
4 months ago
5 months ago
4 months ago
5 months ago
  1. import Vue from 'vue'
  2. import utils from './utils/utils.js'
  3. // 当前环境
  4. const type = 'prod'
  5. // 环境配置
  6. const config = {
  7. dev : {
  8. baseUrl : 'http://augcl.natapp1.cc/employ-api',
  9. },
  10. prod : {
  11. baseUrl : 'https://employadmin.augcl.com/employ-api',
  12. }
  13. }
  14. // 默认配置
  15. const defaultConfig = {
  16. mapKey : 'XMBBZ-BCPCV-SXPPQ-5Y7MY-PHZXK-YFFVU',
  17. aliOss : {
  18. // url : 'https://tennis-oss.xzaiyp.top/',
  19. url:"https://image.jthj8.com/",
  20. config : {
  21. //桶的地址
  22. region: 'oss-cn-guangzhou',
  23. //id
  24. // accessKeyId:'LTAI5tNycA46YTwm383dRvMV',
  25. accessKeyId:"LTAI5tMJitfHeQ8jNAikvEu7",
  26. //密钥
  27. // accessKeySecret:'tAdbYQCmdur6jbZ8hjvgB7T1Z52mIG',
  28. accessKeySecret:"GodE2mPZiW2WhiMtEkPhNNOThLlSRj",
  29. //桶的名字
  30. // bucket: 'zhuoqiu-image',
  31. bucket:"jthj8",
  32. // endpoint:'oss-cn-guangzhou.aliyuncs.com',
  33. endpoint:"oss-cn-guangzhou.aliyuncs.com"
  34. }
  35. },
  36. }
  37. uni.$u.setConfig({
  38. // 修改$uv.config对象的属性
  39. config: {
  40. // 修改默认单位为rpx,相当于执行 uni.$uv.config.unit = 'rpx'
  41. unit: 'px'
  42. },
  43. })
  44. Vue.prototype.$config = utils.deepMergeObject(defaultConfig, config[type])
  45. // Vue.prototype.$api = api
  46. export default Vue.prototype.$config