in src/routes/Document/components/AddAndUpdateTag.js [65:123]
render() {
const { onCancel, form, name = "", tagDesc = "", visible } = this.props;
const { getFieldDecorator } = form;
const formItemLayout = {
labelCol: {
sm: { span: 5 }
},
wrapperCol: {
sm: { span: 19 }
}
};
return (
<Modal
visible={visible}
onCancel={onCancel}
onOk={this.handleSubmit}
closable={false}
forceRender
>
<Form className="login-form" {...formItemLayout}>
<Form.Item label={getIntlContent("SHENYU.DOCUMENT.TAG.NAME")}>
{getFieldDecorator("name", {
rules: [
{
required: true,
message: getIntlContent("SHENYU.DOCUMENT.TAG.NAME")
}
],
initialValue: name
})(
<Input placeholder={getIntlContent("SHENYU.DOCUMENT.TAG.NAME")} />
)}
</Form.Item>
<Form.Item label={getIntlContent("SHENYU.DOCUMENT.TAG.DESC")}>
{getFieldDecorator("tagDesc", {
rules: [
{
required: true,
message: getIntlContent("SHENYU.DOCUMENT.TAG.DESC")
}
],
initialValue: tagDesc
})(
<Input placeholder={getIntlContent("SHENYU.DOCUMENT.TAG.DESC")} />
)}
</Form.Item>
<Form.Item hidden>
{getFieldDecorator("parentTagId")(<Input />)}
</Form.Item>
<Form.Item hidden>{getFieldDecorator("id")(<Input />)}</Form.Item>
</Form>
</Modal>
);
}
}