king
2020-06-04 113313a0496f958860a156b4330960e0d12522a7
src/utils/utils.js
@@ -2,8 +2,6 @@
import md5 from 'md5'
import options from '@/store/options.js'
const service = window.GLOB.service ? (/\/$/.test(window.GLOB.service) ? window.GLOB.service : window.GLOB.service + '/') : ''
export default class Utils {
  /**
   * @description 生成32位uuid string + 时间
@@ -553,9 +551,9 @@
    let baseurl = ''
    if (process.env.NODE_ENV === 'production') {
      baseurl = document.location.origin + '/' + service
      baseurl = document.location.origin + '/' + window.GLOB.service
    } else {
      baseurl = 'http://qingqiumarket.cn/' + service
      baseurl = window.GLOB.location + window.GLOB.service
    }
    // if (!/Content\/images\/upload\//.test(url)) {
    //   baseurl = baseurl + 'Content/images/upload/'
@@ -576,7 +574,7 @@
    if (options.cloudServiceApi) {
      baseurl = options.cloudServiceApi.replace(/webapi(.*)$/, '')
    } else {
      baseurl = document.location.origin + '/' + service
      baseurl = document.location.origin + '/' + window.GLOB.service
    }
    return url.match(/^http/) || url.match(/^\/\//) ? url : baseurl + url