| | |
| | | |
| | | class CustomMenuForm extends Component { |
| | | static propTpyes = { |
| | | dict: PropTypes.object, // 字典项 |
| | | config: PropTypes.object, |
| | | MenuId: PropTypes.string, |
| | | adapters: PropTypes.array, |
| | |
| | | } |
| | | |
| | | render() { |
| | | const { dict, config, adapters } = this.props |
| | | const { config, adapters } = this.props |
| | | const { getFieldDecorator } = this.props.form |
| | | const formItemLayout = { |
| | | labelCol: { |
| | |
| | | <Form {...formItemLayout} className="custom-menu-form"> |
| | | <Row> |
| | | <Col span={24}> |
| | | <Form.Item label={dict['mob.menu'] + dict['mob.name']}> |
| | | <Form.Item label="菜单名称"> |
| | | {getFieldDecorator('MenuName', { |
| | | initialValue: config.MenuName, |
| | | rules: [ |
| | | { |
| | | required: true, |
| | | message: dict['mob.required.input'] + dict['mob.menu'] + dict['mob.name'] + '!' |
| | | message: '请输入菜单名称!' |
| | | } |
| | | ] |
| | | })(<Input placeholder="" autoComplete="off" onChange={this.changeName}/>)} |
| | | </Form.Item> |
| | | </Col> |
| | | <Col span={24}> |
| | | <Form.Item label={dict['mob.menu'] + dict['mob.param']}> |
| | | <Form.Item label="菜单参数"> |
| | | {getFieldDecorator('MenuNo', { |
| | | initialValue: config.MenuNo, |
| | | rules: [ |
| | | { |
| | | required: true, |
| | | message: dict['mob.required.input'] + dict['mob.menu'] + dict['mob.param'] + '!' |
| | | message: '请输入菜单参数!' |
| | | } |
| | | ] |
| | | })(<Input placeholder="" autoComplete="off" onChange={this.changeNo}/>)} |
| | |
| | | rules: [ |
| | | { |
| | | required: true, |
| | | message: dict['mob.required.input'] + '时长!' |
| | | message: '请输入时长!' |
| | | } |
| | | ] |
| | | })( |
| | |
| | | rules: [ |
| | | { |
| | | required: true, |
| | | message: dict['mob.required.input'] + '停留时间!' |
| | | message: '请输入停留时间!' |
| | | } |
| | | ] |
| | | })( |