| | |
| | | import React from 'react' |
| | | import { useDrag, useDrop } from 'react-dnd' |
| | | import { Icon, Button, Select, DatePicker } from 'antd' |
| | | import { Icon, Button, Select, DatePicker, Input } from 'antd' |
| | | import moment from 'moment' |
| | | import ItemTypes from './itemtypes' |
| | | import './index.scss' |
| | |
| | | </div> |
| | | <div className="ant-col ant-form-item-control-wrapper"> |
| | | {card.type === 'text' && |
| | | <div className="ant-form-item-control"> |
| | | <span className="ant-form-item-children"> |
| | | <input placeholder="" autoComplete="off" type="text" readOnly={true} className="ant-input" /> |
| | | </span> |
| | | </div> |
| | | <Input style={{marginTop: '4px'}} defaultValue={card.initval} /> |
| | | } |
| | | {card.type === 'select' && |
| | | <Select defaultValue="lucy"></Select> |
| | | {(card.type === 'select' || card.type === 'link') && |
| | | <Select defaultValue={card.initval}></Select> |
| | | } |
| | | {card.type === 'dateday' && |
| | | <DatePicker defaultValue={card.initval ? moment(card.initval, 'YYYY-MM-DD') : null} /> |
| | |
| | | } |
| | | {type === 'columns' && |
| | | <span className="ant-table-header-column"> |
| | | <div className="ant-table-column-sorters" style={{textAlign: card.Align}}> |
| | | <div className="ant-table-column-sorters" title={card.label} style={{textAlign: card.Align}}> |
| | | <span className="ant-table-column-title">{card.label}</span> |
| | | {card.IsSort === 'true' && <span className="ant-table-column-sorter"> |
| | | <Icon type="caret-up" /> |