king
2023-08-26 3f0f0b7e222cf0c159b6f646af7084ed4c29e409
src/utils/utils.js
@@ -967,7 +967,15 @@
      let _colindex = cols[cindex] || (cindex + 1)
      let _position = (_topline + lindex + 1) + '行 ' + _colindex + '列 '
      if (/^Nvarchar/ig.test(col.type)) {
      if (col.import === 'init') {
        if (/^Nvarchar/ig.test(col.type)) {
          val = ''
        } else if (/^Decimal/ig.test(col.type) || /^int/ig.test(col.type)) {
          val = 0
        } else if (col.type === 'date') {
          val = '1949-10-01'
        }
      } else if (/^Nvarchar/ig.test(col.type)) {
        val = val + ''
        if (/'/.test(val)) {
@@ -1160,7 +1168,7 @@
      _sqlBottom = _sqlBottom.replace(/@\$|\$@/ig, '').replace(/@datam@/ig, '\'\'')
    }
    if (window.GLOB.debugger === true || (window.debugger === true && window.GLOB.sysType !== 'cloud')) {
    if (window.GLOB.debugger === true) {
      let fsql = `
      ${_sql}
      ${_sqlInsert}
@@ -1395,7 +1403,7 @@
      _sqlBottom = _sqlBottom.replace(/@\$|\$@/ig, '').replace(/@datam@/ig, '\'\'')
    }
    if (window.GLOB.debugger === true || (window.debugger === true && window.GLOB.sysType !== 'cloud')) {
    if (window.GLOB.debugger === true) {
      let fsql = `
      ${_sql}
      ${_sqlInsert}
@@ -2186,7 +2194,7 @@
    _sql = _sql.replace(/@datam@/ig, '\'\'')
  }
  if (window.GLOB.debugger === true || (window.debugger === true && window.GLOB.sysType !== 'cloud')) {
  if (window.GLOB.debugger === true) {
    // _sql = _sql.replace(/\n\s{8}/ig, '\n')
    console.info(_sql)
  }