king
2024-09-10 4d6b9f8a2d7b316633e43b489eae9ada949c07b5
src/views/mobdesign/index.jsx
@@ -11,7 +11,7 @@
import Api from '@/api'
import Utils from '@/utils/utils.js'
import MKEmitter from '@/utils/events.js'
import MenuUtils, { getTables, getFuncsAndInters, getLangTrans } from '@/utils/utils-custom.js'
import MenuUtils, { getTables, getFuncsAndInters, getOutMessage, getLangTrans, getAllSqls } from '@/utils/utils-custom.js'
import asyncComponent from '@/utils/asyncComponent'
import '@/assets/css/design.scss'
@@ -1481,6 +1481,51 @@
        delete config.force
      }
      let long_data = ''
      if (window.backend && config.enabled) {
        let sqls = getAllSqls(config)
        let _t = moment().format('YYYYMMDDHHmmss')
        let getguid = () => {
          let uuid = ''
          for (let i = 0; i < 18; i++) {
            uuid += String.fromCharCode(Math.floor(Math.random() * 26) + 65)
          }
          return uuid
        }
        long_data = []
        let oriIds = {}
        if (config.allSqls) {
          config.allSqls.forEach(item => {
            if (!item.md5) return
            oriIds[item.uuid + item.md5] = item.v_id
          })
        }
        config.allSqls = sqls.map(item => {
          let v_id = _t + getguid()
          if (oriIds[item.uuid + item.md5]) {
            v_id = oriIds[item.uuid + item.md5]
          }
          long_data.push(`${md5(window.GLOB.appkey + v_id)},${item.uuid},${v_id},${window.btoa(window.encodeURIComponent(item.LText))}`)
          return {
            uuid: item.uuid,
            v_id: v_id,
            type: item.type,
            reps: item.reps,
            md5: item.md5 || '',
            luser: item.luser === true
          }
        })
        long_data = long_data.join(';')
      } else {
        delete config.allSqls
      }
      if (config.cacheUseful !== 'true') {
        config.components = this.resetSyncQuery(config.components)
      }
@@ -1576,6 +1621,7 @@
      menus_used_list = window.btoa(window.encodeURIComponent(menus_used_list || 'del'))
      let interfaces = getFuncsAndInters(config)
      let msg = getOutMessage(config)
      roleParam.interfaces = interfaces
      let langSql = getLangTrans(config)
@@ -1591,9 +1637,10 @@
        TypeCharOne: sessionStorage.getItem('kei_no'),
        Typename: sessionStorage.getItem('typename'),
        MenuName: config.MenuName || '',
        PageParam: JSON.stringify({Template: 'webPage', interfaces}),
        PageParam: JSON.stringify({Template: 'webPage', interfaces, msg}),
        open_edition: config.open_edition,
        menus_rolelist: window.btoa(window.encodeURIComponent(JSON.stringify(roleParam))),
        long_data: long_data,
        // LText: '',
        // LTexttb: '',
        menus_used_list,