| | |
| | | const { config, setting } = this.props |
| | | |
| | | let menu = window.GLOB.customMenu |
| | | let modules = MenuUtils.getSupModules(menu.components, config.uuid, menu.interfaces) |
| | | let modules = [] |
| | | let ismain = false |
| | | |
| | | if (menu.Template === 'BaseTable') { |
| | | ismain = config.name === '主表' |
| | | } |
| | | |
| | | if (config.type === 'interface') { |
| | | menu.components.forEach(item => { |
| | | if (item.type === 'module' && item.subtype === 'account') { |
| | | modules.push({ |
| | | value: item.uuid, |
| | | label: item.name |
| | | }) |
| | | } |
| | | }) |
| | | } else { |
| | | modules = MenuUtils.getSupModules(menu.components, config.uuid, menu.interfaces) |
| | | } |
| | | |
| | | modules.unshift({ |
| | |
| | | } |
| | | |
| | | render() { |
| | | const { columns, config } = this.props |
| | | const { columns, config, hasMainSearch } = this.props |
| | | const { getFieldDecorator } = this.props.form |
| | | const { setting, modules, innerRules, innertip, MenuType, visible } = this.state |
| | | |
| | |
| | | sm: { span: 16 } |
| | | } |
| | | } |
| | | let hasUp = !['balcony', 'menubar', 'commonbar', 'tabbar', 'invTable'].includes(config.subtype) && (!config.wrap || config.wrap.supType !== 'multi') && MenuType !== 'billPrint' |
| | | |
| | | return ( |
| | | <div className="model-datasource-setting-form-box"> |
| | |
| | | </Radio.Group>)} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | {!['balcony', 'menubar', 'commonbar', 'tabbar', 'invTable'].includes(config.subtype) && (!config.wrap || config.wrap.supType !== 'multi') && MenuType !== 'billPrint' ? <Col span={8}> |
| | | {hasUp ? <Col span={8}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title={'该组件如果受其他组件控制,请选项相应的组件,没有时选“无”。'}> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | |
| | | initialValue: setting.useMSearch || 'true' |
| | | })( |
| | | <Radio.Group onChange={(e) => {this.onOptionChange(e.target.value, 'useMSearch')}}> |
| | | <Radio value="true">使用</Radio> |
| | | <Radio value="true">使用{!hasMainSearch ? <Tooltip placement="top" title="无可使用的外部搜索条件"><span className="mk-dot"></span></Tooltip> : null}</Radio> |
| | | <Radio value="false">不使用</Radio> |
| | | </Radio.Group> |
| | | )} |
| | |
| | | </Col> : null} |
| | | {config.subtype === 'dualdatacard' ? <Col span={8}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="子表在主表中的数据集名称。"> |
| | | <Tooltip placement="topLeft" title="子表在主表中的数据集名称,使用 sub_data_string 时数据以 JSON 字符串形式返回(字段集中需添加 sub_data_string 字段);当主表字段存在 sub_data_string 且值不为空时,优先使用主表的 sub_data_string。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | 子表字段 |
| | | </Tooltip> |
| | |
| | | })(<InputNumber min={0} max={60000} precision={0} />)} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | {hasUp && setting.supModule && setting.supModule[0] && setting.supModule[0] !== 'empty' ? <Col span={8}> |
| | | <Form.Item label={ |
| | | <Tooltip placement="topLeft" title="未获取到上级主键值的提示文本。"> |
| | | <QuestionCircleOutlined className="mk-form-tip" /> |
| | | 上级空值提示 |
| | | </Tooltip> |
| | | }> |
| | | {getFieldDecorator('supModTip', { |
| | | initialValue: setting.supModTip || '' |
| | | })( |
| | | <Input placeholder={''} autoComplete="off" /> |
| | | )} |
| | | </Form.Item> |
| | | </Col> : null} |
| | | </Row> |
| | | </Form> |
| | | <Modal |