| | |
| | | item.hidden = false |
| | | } else if (item.key === 'width' && card.elemType === 'avatar' && card.type === 'picture') { |
| | | item.hidden = false |
| | | } else if (item.key === 'radius' && card.elemType === 'avatar' && card.type === 'picture') { |
| | | item.hidden = false |
| | | } |
| | | return item |
| | | }) |
| | |
| | | item.max = card.widthType === 'ratio' ? 100 : 500 |
| | | } else if (item.key === 'size') { |
| | | item.hidden = value !== 'icon' |
| | | } else if (item.key === 'radius') { |
| | | item.hidden = value !== 'picture' |
| | | } |
| | | |
| | | return item |
| | |
| | | message: this.props.dict['form.required.input'] + item.label + '!' |
| | | } |
| | | ] |
| | | })(<InputNumber min={item.min} max={item.max} precision={0} />)} |
| | | })(<InputNumber min={item.min} max={item.max} precision={item.precision || 0} />)} |
| | | </Form.Item> |
| | | </Col> |
| | | ) |
| | |
| | | } |
| | | ] |
| | | })( |
| | | <Radio.Group onChange={(e) => {this.typeChange(item.key, e.target.value)}}> |
| | | <Radio.Group disabled={item.readonly} onChange={(e) => {this.typeChange(item.key, e.target.value)}}> |
| | | { |
| | | item.options.map(option => { |
| | | return ( |
| | |
| | | let column = columns.filter(col => col.value === values.field)[0] |
| | | values.icon = column.icon |
| | | values.color = column.color |
| | | |
| | | values.avatarWidth = values.size |
| | | } else if (values.widthType === 'absolute') { |
| | | values.avatarWidth = values.width |
| | | } else { |
| | | values.avatarWidth = values.width + '%' |
| | | } |
| | | } |
| | | |