| | |
| | | clearTimeout(timer) |
| | | if (/Shared Memory Provider|会话处于终止状态|当前命令发生了严重错误/.test(res.message)) { |
| | | res.message = '验证失败,请检查SQL中是否存在死循环。' |
| | | } else if (res.message === 'ROLLBACK TRANSACTION 请求没有对应的 BEGIN TRANSACTION。 EXECUTE 后的事务计数指示 BEGIN 和 COMMIT 语句的数目不匹配。上一计数 = 1,当前计数 = 0。 ROLLBACK TRANSACTION 请求没有对应的 BEGIN TRANSACTION。') { |
| | | res.ErrCode = '-2' |
| | | } |
| | | resolve(res) |
| | | }, () => { |
| | |
| | | if (_dataresource) { |
| | | if (custompage) { |
| | | _dataresource = `/*system_query*/select ${arr_field} from ${_dataresource} ${_search}` |
| | | } else if (setting.laypage === 'true' && setting.order) { |
| | | _dataresource = `/*system_query*/select top 10 ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${setting.order}) as rows from ${_dataresource} ${_search}) tmptable where rows > 0 order by tmptable.rows` |
| | | } else if (setting.order) { |
| | | _dataresource = `/*system_query*/select${setting.laypage === 'true' ? ' top 10' : ''} ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${setting.order}) as rows from ${_dataresource} ${_search}) tmptable ${setting.laypage === 'true' ? 'where rows > 0' : ''} order by tmptable.rows` |
| | | _dataresource = `/*system_query*/select ${arr_field} from (select ${arr_field} ,ROW_NUMBER() over(order by ${setting.order}) as rows from ${_dataresource} ${_search}) tmptable order by tmptable.rows` |
| | | } else { |
| | | _dataresource = `/*system_query*/select ${arr_field} from ${_dataresource} ${_search}` |
| | | } |
| | |
| | | |
| | | if ((position === 'mainline' || position === 'popclose') && config.setting.supModule && BID) { |
| | | MKEmitter.emit('reloadData', config.setting.supModule, BID) |
| | | } else if (position === 'grid' && config.wrap.datatype === 'static') { |
| | | this.setState({ |
| | | data: null |
| | | }, () => { |
| | | this.setState({data: {$$empty: true}}) |
| | | }) |
| | | } else { |
| | | this.loadData() |
| | | } |
| | |
| | | |
| | | if ((position === 'mainline' || position === 'popclose') && config.setting.supModule && BID) { |
| | | MKEmitter.emit('reloadData', config.setting.supModule, BID) |
| | | } else if (position === 'grid' && config.wrap.datatype === 'static') { |
| | | this.setState({ |
| | | data: null |
| | | }, () => { |
| | | this.setState({data: {$$empty: true}}) |
| | | }) |
| | | } else { |
| | | this.loadData() |
| | | } |
| | |
| | | |
| | | if ((position === 'mainline' || position === 'popclose') && config.setting.supModule && BID) { |
| | | MKEmitter.emit('reloadData', config.setting.supModule, BID) |
| | | } else if (position === 'grid' && config.wrap.datatype === 'static') { |
| | | this.setState({ |
| | | data: null |
| | | }, () => { |
| | | this.setState({data: {$$empty: true}}) |
| | | }) |
| | | } else { |
| | | this.loadData() |
| | | } |