| | |
| | | exportExcel = (data) => { |
| | | const { btn } = this.props |
| | | |
| | | let columns = btn.verify.columns.filter(col => col.output !== 'false') |
| | | |
| | | try { |
| | | let imgCol = btn.verify.columns.filter(col => col.type === 'image')[0] |
| | | let imgCol = columns.filter(col => col.type === 'image')[0] |
| | | |
| | | if (imgCol) { |
| | | const column = btn.verify.columns.map(item => { |
| | | const column = columns.map(item => { |
| | | let col = { |
| | | title: item.Text, |
| | | key: item.Column, |
| | |
| | | |
| | | item.$Index = index + 1 + '' |
| | | |
| | | btn.verify.columns.forEach((col, i) => { |
| | | columns.forEach((col, i) => { |
| | | if (item[col.Column] && col.abs === 'true') { |
| | | _row[col.Column] = Math.abs(item[col.Column]) |
| | | } else { |
| | |
| | | let colwidth = [] |
| | | let abses = [] |
| | | |
| | | btn.verify.columns.forEach(col => { |
| | | columns.forEach(col => { |
| | | if (_topRow[col.Column]) return |
| | | |
| | | _header.push(col.Column) |
| | |
| | | } |
| | | |
| | | // 测试系统打印查询语句 |
| | | if ((options.sysType === 'local' && !window.GLOB.systemType) || window.debugger === true) { |
| | | if (window.GLOB.debugger === true || (window.debugger === true && options.sysType !== 'cloud')) { |
| | | param.custom_script && console.info(`${LText ? '' : '/*不执行默认sql*/\n'}${param.custom_script}`) |
| | | LText && console.info(LText) |
| | | } |
| | |
| | | execSuccess = (res) => { |
| | | const { btn } = this.props |
| | | |
| | | if (res && res.ErrCode === 'S') { // 执行成功 |
| | | if (res && (res.ErrCode === 'S' || !res.ErrCode)) { // 执行成功 |
| | | notification.success({ |
| | | top: 92, |
| | | message: res.ErrMesg || this.state.dict['main.action.confirm.success'], |
| | |
| | | className={'mk-btn mk-' + btn.class} |
| | | icon={btn.icon} |
| | | disabled={disabled} |
| | | title={disabled ? (btn.reason || '') : ''} |
| | | onClick={(e) => {e.stopPropagation(); this.actionTrigger()}} |
| | | loading={loading} |
| | | >{btn.label}</Button> |
| | |
| | | return ( |
| | | <Button |
| | | type="link" |
| | | title={show === 'icon' ? btn.label : ''} |
| | | title={disabled ? (btn.reason || '') : (show === 'icon' ? btn.label : '')} |
| | | loading={loading} |
| | | disabled={disabled} |
| | | style={btn.style} |