| | |
| | | |
| | | state = { |
| | | dict: sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS, |
| | | oriId: Utils.getuuid(), // 搜索表单Id |
| | | formId: '', // 搜索表单Id |
| | | match: null, // 搜索条件匹配规则 |
| | | style: null, // 搜索条件类型 |
| | |
| | | } else { // 合并请求,区分本地及系统 |
| | | // 外联数据库替换 |
| | | if (window.GLOB.externalDatabase !== null) { |
| | | _option.sql = _option.sql.replace(/@db@/ig, `[${window.GLOB.externalDatabase}]..`) |
| | | _option.sql = _option.sql.replace(/@db@/ig, window.GLOB.externalDatabase) |
| | | } |
| | | if (item.database === 'sso') { |
| | | mainItems.push(`select '${item.field}' as obj_name,'${_option.field}' as arr_field,'${window.btoa(window.encodeURIComponent(_option.sql))}' as LText`) |
| | |
| | | |
| | | if (showButton) { |
| | | fields.push( |
| | | <Col span={6} style={{ whiteSpace: 'nowrap' }} key="actions"> |
| | | <Col span={6} style={{ whiteSpace: 'nowrap' }} className="search-button" key="actions"> |
| | | <Form.Item label={' '} colon={false} style={{ minHeight: '40px' }}> |
| | | <Button type="primary" onClick={this.handleSearch}> |
| | | {dict['main.search']} |
| | |
| | | } |
| | | |
| | | return ( |
| | | <Form {...formItemLayout} className={`top-search ${float}`} style={searchStyle} id={this.state.formId}> |
| | | <Form {...formItemLayout} className={`top-search ${float}`} style={searchStyle} id={this.state.formId || this.state.oriId}> |
| | | <Row gutter={24}>{this.getFields()}</Row> |
| | | </Form> |
| | | ) |