king
2024-09-25 c46e208fc65742bf02d43235a28143abbf3eb7ea
src/index.js
@@ -168,6 +168,11 @@
      if (GLOB.cloudServiceApi) {
        GLOB.mainSystemApi = GLOB.cloudServiceApi
      }
      if (config.systemRun === 'backend') {
        config.systemRun = '' // hs 不使用后端替换
        GLOB.backend = true
      }
    }
    if (process.env.NODE_ENV === 'production') { // 用于校验是否存在开发权限
@@ -183,14 +188,14 @@
      GLOB.baseurl = GLOB.location + '/' + GLOB.service
      GLOB.linkurl = GLOB.baseurl + 'index.html'
      GLOB.dataFormat = false
      let mark = sessionStorage.getItem('system_mark')
      let _mark = `sys_${GLOB.service.replace('/', '') || 'service'}`
      if (mark && mark !== _mark) {
        sessionStorage.clear()
      }
      sessionStorage.setItem('system_mark', _mark)
    }
    let mark = sessionStorage.getItem('system_mark')
    let _mark = `sys_${GLOB.service.replace('/', '') || 'service'}`
    if (mark && mark !== _mark) {
      sessionStorage.clear()
    }
    sessionStorage.setItem('system_mark', _mark)
    if (config.mainkey && GLOB.sysType !== 'cloud' && config.mainkey !== options.cakey) {
      GLOB.localkey = GLOB.appkey
@@ -346,6 +351,7 @@
    }
    if (config.systemRun === 'backend') {
      GLOB.debugger = false
      Object.defineProperty(window, 'backend', {
        writable: false,
        value: true