Commit 12857be8 authored by nano's avatar nano

fix password must input

parent 6893752b
...@@ -44,7 +44,7 @@ class EmailForm extends React.Component { ...@@ -44,7 +44,7 @@ class EmailForm extends React.Component {
label: messages.email, label: messages.email,
hasFeedback: true, hasFeedback: true,
validateStatus: checkEmail, validateStatus: checkEmail,
help: isEmailExists ? 'email exists' : '', extra: isEmailExists ? '//i18n email exists' : '',
...formItemLayout, ...formItemLayout,
}, },
decorator: { decorator: {
...@@ -87,7 +87,7 @@ class EmailForm extends React.Component { ...@@ -87,7 +87,7 @@ class EmailForm extends React.Component {
</FormItem> </FormItem>
<FormItem {...passwordProps.fromItem}> <FormItem {...passwordProps.fromItem}>
{getFieldDecorator('password')( {getFieldDecorator('password', { ...passwordProps.decorator })(
<Input {...passwordProps.input} />, <Input {...passwordProps.input} />,
)} )}
</FormItem> </FormItem>
......
import React from 'react';
const Example = () => {
return (
<div>
Example
</div>
);
};
Example.propTypes = {};
export default Example;
...@@ -62,7 +62,7 @@ class EmailForm extends React.Component { ...@@ -62,7 +62,7 @@ class EmailForm extends React.Component {
const passwordProps = { const passwordProps = {
fromItem: { fromItem: {
label: 'old passwrod', label: messages['old-password'],
...formItemLayout, ...formItemLayout,
}, },
decorator: { decorator: {
......
...@@ -43,7 +43,7 @@ class EmailForm extends React.Component { ...@@ -43,7 +43,7 @@ class EmailForm extends React.Component {
label: messages.email, label: messages.email,
hasFeedback: true, hasFeedback: true,
validateStatus: checkEmail, validateStatus: checkEmail,
help: isEmailExists ? 'email exists' : '', extra: isEmailExists ? '//i18n email exists' : '',
...formItemLayout, ...formItemLayout,
}, },
decorator: { decorator: {
......
...@@ -43,7 +43,7 @@ class EmailForm extends React.Component { ...@@ -43,7 +43,7 @@ class EmailForm extends React.Component {
label: messages.username, label: messages.username,
hasFeedback: true, hasFeedback: true,
validateStatus: checkUsername, validateStatus: checkUsername,
help: isUserNameExists ? 'username exists' : '', extra: isUserNameExists ? 'username exists' : '',
...formItemLayout, ...formItemLayout,
}, },
decorator: { decorator: {
...@@ -84,7 +84,7 @@ class EmailForm extends React.Component { ...@@ -84,7 +84,7 @@ class EmailForm extends React.Component {
</FormItem> </FormItem>
<FormItem {...passwordProps.fromItem}> <FormItem {...passwordProps.fromItem}>
{getFieldDecorator('password')( {getFieldDecorator('password', { ...passwordProps.decorator })(
<Input {...passwordProps.input} />, <Input {...passwordProps.input} />,
)} )}
</FormItem> </FormItem>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment