From e83e0dd1b6fffd09c48561f3b69fa5a50df4a942 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 04 二月 2021 19:01:01 +0800 Subject: [PATCH] 2021-02-04 --- src/utils/utils.js | 13 ++++++++++++- 1 files changed, 12 insertions(+), 1 deletions(-) diff --git a/src/utils/utils.js b/src/utils/utils.js index b1d5fcd..8d35665 100644 --- a/src/utils/utils.js +++ b/src/utils/utils.js @@ -718,6 +718,17 @@ sql = `select ${item.type === 'checkcard' ? 'top 20' : ''} ${arrfield} from (select distinct ${arrfield} from ${_datasource}) a` } + if (sessionStorage.getItem('dataM') === 'true') { // 鏁版嵁鏉冮檺 + sql = sql.replace(/\$@/ig, '/*') + sql = sql.replace(/@\$/ig, '*/') + } else { + sql = sql.replace(/@\$|\$@/ig, '') + } + + if ((window.GLOB.systemType !== 'production' && options.sysType !== 'cloud') || window.debugger === true) { + console.info(sql) + } + return { sql: sql, field: arrfield @@ -1266,7 +1277,7 @@ } // 澶辨晥楠岃瘉锛屾坊鍔犳暟鎹椂涓嶇敤 - if (btn.sqlType !== 'insert' && verify.invalid === 'true' && setting.dataresource) { + if (btn.sqlType !== 'insert' && btn.Ot !== 'notRequired' && verify.invalid === 'true' && setting.dataresource) { let datasource = setting.dataresource if (/\s/.test(datasource) && !/tb$/.test(datasource)) { // 鎷兼帴鍒悕 datasource = '(' + datasource + ') tb' -- Gitblit v1.8.0