Commit 6d4eafd2 by 潘际乾

页面的中文全部该为英文

parent f0119342
...@@ -3,14 +3,19 @@ import './index.less'; ...@@ -3,14 +3,19 @@ import './index.less';
import ReactDOM from 'react-dom'; import ReactDOM from 'react-dom';
import React from 'react'; import React from 'react';
import { browserHistory ,hashHistory} from 'react-router'; import { browserHistory ,hashHistory} from 'react-router';
import enUS from 'antd/lib/locale-provider/en_US';
import { LocaleProvider } from 'antd';
import Routes from '../routes/index'; import Routes from '../routes/index';
const Provider = require('react-redux').Provider; const Provider = require('react-redux').Provider;
const configureStore = require('../store/configureStore'); const configureStore = require('../store/configureStore');
const store = configureStore() const store = configureStore()
ReactDOM.render( ReactDOM.render(
<LocaleProvider locale={enUS}>
<Provider store={store}> <Provider store={store}>
<Routes history={hashHistory} /> <Routes history={hashHistory} />
</Provider>, </Provider>
</LocaleProvider>,
document.getElementById('root') document.getElementById('root')
); );
...@@ -30,9 +30,9 @@ export const mty=[ ...@@ -30,9 +30,9 @@ export const mty=[
{mty:"mt299",desp:"MT 299 Free Format Message"}, {mty:"mt299",desp:"MT 299 Free Format Message"},
{mty:"mt300",desp:"MT 300 Foreign Exchange Confirmation"}, {mty:"mt300",desp:"MT 300 Foreign Exchange Confirmation"},
//{mty:"mt305",desp:"MT 305 Foreign Currency Option Confirmation"}, {mty:"mt305",desp:"MT 305 Foreign Currency Option Confirmation"},
{mty:"mt320",desp:"MT 320 Fixed Loan/Deposit Confirmation"}, {mty:"mt320",desp:"MT 320 Fixed Loan/Deposit Confirmation"},
//{mty:"mt360",desp:"MT 360 Single Currency Interest Rate Derivative Confirmation"}, {mty:"mt360",desp:"MT 360 Single Currency Interest Rate Derivative Confirmation"},
{mty:"mt399",desp:"MT 399 Free Format Message"}, {mty:"mt399",desp:"MT 399 Free Format Message"},
{mty:"mt400",desp:"MT 400 Advice of Payment"}, {mty:"mt400",desp:"MT 400 Advice of Payment"},
...@@ -64,15 +64,15 @@ export const mty=[ ...@@ -64,15 +64,15 @@ export const mty=[
{mty:"mt592",desp:"MT 592 Request for Cancellation"}, {mty:"mt592",desp:"MT 592 Request for Cancellation"},
{mty:"mt595",desp:"MT 595 Queries"}, {mty:"mt595",desp:"MT 595 Queries"},
{mty:"mt596",desp:"MT 596 Answers"}, {mty:"mt596",desp:"MT 596 Answers"},
{mty:"mt598",desp:"MT 598 Proprietary Message"}, {mty:"mt598",desp:"MT 598 Proprietary Message"},*/
{mty:"mt599",desp:"MT 599 Free Format Message"}, // {mty:"mt599",desp:"MT 599 Free Format Message"},
{mty:"mt600",desp:"MT 600 Commodity Trade Confirmation"}, // {mty:"mt600",desp:"MT 600 Commodity Trade Confirmation"},
{mty:"mt605",desp:"MT 605 Commodity Notice to Receive"}, // {mty:"mt605",desp:"MT 605 Commodity Notice to Receive"},
{mty:"mt607",desp:"MT 607 Commodity Credit Advice"}, // {mty:"mt607",desp:"MT 607 Commodity Credit Advice"},
{mty:"mt620",desp:"MT 620 Commodity Fixed Loan/Deposit Confirmation"}, // {mty:"mt620",desp:"MT 620 Commodity Fixed Loan/Deposit Confirmation"},
*/
...@@ -134,7 +134,7 @@ export class LeadPage extends Component ...@@ -134,7 +134,7 @@ export class LeadPage extends Component
} }
columns = [{ columns = [{
title: <div> title: <div>
<Input placeholder="输入报文类型数字,快速筛选" size="large" onChange={e=>this.setState({fil:e.target.value})}/> <Input placeholder="Enter the message type number for quick screening" size="large" onChange={e=>this.setState({fil:e.target.value})}/>
</div>, </div>,
dataIndex: 'desp', dataIndex: 'desp',
key: 'desp', key: 'desp',
...@@ -157,10 +157,10 @@ export class LeadPage extends Component ...@@ -157,10 +157,10 @@ export class LeadPage extends Component
<Col span={3}/> <Col span={3}/>
<Col span={18}> <Col span={18}>
<Steps current={0}> <Steps current={0}>
<Step title="选择类型" description="选择报文类型" /> <Step title="Select type" description="Select message type" />
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
</Col> </Col>
<Col span={3}/> <Col span={3}/>
......
...@@ -16,16 +16,16 @@ const Step = Steps.Step; ...@@ -16,16 +16,16 @@ const Step = Steps.Step;
{ {
this.props.params.kind=='0'? this.props.params.kind=='0'?
<Steps current={1}> <Steps current={1}>
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
: :
<Steps current={2}> <Steps current={2}>
<Step title="选择类型" description="选择报文类型" /> <Step title="Select type" description="Select message type" />
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
} }
</Col> </Col>
......
...@@ -63,16 +63,16 @@ const Step = Steps.Step; ...@@ -63,16 +63,16 @@ const Step = Steps.Step;
{ {
this.props.params.kind=='0'? this.props.params.kind=='0'?
<Steps current={2}> <Steps current={2}>
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
: :
<Steps current={3}> <Steps current={3}>
<Step title="选择类型" description="选择报文类型" /> <Step title="Select type" description="Select message type" />
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
} }
</Col> </Col>
......
...@@ -96,7 +96,7 @@ export class SWFPage extends Component ...@@ -96,7 +96,7 @@ export class SWFPage extends Component
if( rcv_bic_err_msg || crs.hasError) if( rcv_bic_err_msg || crs.hasError)
{ {
//更新整个树 //更新整个树
notification.error({description:'输入存在错误,请按照提示检查!',message:'错误'}) notification.error({description:'There is an error in the input, please check according to the prompt!',message:'Error'})
this.props.actions.updateSndBic({snd_bic:this.props.snd_bic_info.snd_bic,err_msg:snd_bic_err_msg?snd_bic_err_msg.replace("收","发"):''}) this.props.actions.updateSndBic({snd_bic:this.props.snd_bic_info.snd_bic,err_msg:snd_bic_err_msg?snd_bic_err_msg.replace("收","发"):''})
this.props.actions.updateRcvBic({rcv_bic:this.props.rcv_bic_info.rcv_bic,err_msg:rcv_bic_err_msg}) this.props.actions.updateRcvBic({rcv_bic:this.props.rcv_bic_info.rcv_bic,err_msg:rcv_bic_err_msg})
this.props.actions.updateTreeValue() this.props.actions.updateTreeValue()
...@@ -118,7 +118,7 @@ export class SWFPage extends Component ...@@ -118,7 +118,7 @@ export class SWFPage extends Component
let wholeErrorMessage = MessageValidater(this.props.extra.msgtyp,swift_message_tree) let wholeErrorMessage = MessageValidater(this.props.extra.msgtyp,swift_message_tree)
if(wholeErrorMessage) if(wholeErrorMessage)
{ {
notification.error({description:'输入存在错误,请按照提示检查!',message:wholeErrorMessage}) notification.error({description:'There is an error in the input, please check according to the prompt!',message:wholeErrorMessage})
return return
} }
this.joinMessage(tags,arr) this.joinMessage(tags,arr)
...@@ -347,16 +347,16 @@ export class SWFPage extends Component ...@@ -347,16 +347,16 @@ export class SWFPage extends Component
{ {
!flag1? !flag1?
<Steps current={1}> <Steps current={1}>
<Step title="选择类型" description="选择报文类型" /> <Step title="Select type" description="Select message type" />
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
: :
<Steps current={0}> <Steps current={0}>
<Step title="报文编辑" description="编辑报文栏位值" /> <Step title="Message editing" description="Edit message field value" />
<Step title="预览报文" description="预览报文" /> <Step title="Preview message" description="Preview message" />
<Step title="编辑完成" description="已完成提交" /> <Step title="Edit complete" description="Submission completed" />
</Steps> </Steps>
} }
</Col> </Col>
...@@ -374,12 +374,12 @@ export class SWFPage extends Component ...@@ -374,12 +374,12 @@ export class SWFPage extends Component
<Col span={3}> <Col span={3}>
</Col> </Col>
<Col span={8}> <Col span={8}>
{/*<FormItem label="收报行BIC" required {...formItemLayout}> {/*<FormItem label="Receiving bank BIC" required {...formItemLayout}>
{ {
this.props.params.action=='redit' || (this.props.params.rcvbic && this.props.params.rcvbic!='NONE')? this.props.params.action=='redit' || (this.props.params.rcvbic && this.props.params.rcvbic!='NONE')?
<p style={{fontWeight:'bolder',fontSize:'1.2em',paddingBottom:'0em',paddingLeft:'1em',borderBottom:'1px solid #37b8f2'}}>{rcv_bic}</p> <p style={{fontWeight:'bolder',fontSize:'1.2em',paddingBottom:'0em',paddingLeft:'1em',borderBottom:'1px solid #37b8f2'}}>{rcv_bic}</p>
: :
<Input placeholder="收报行BIC" maxLength={11} value={rcv_bic} onChange={e=>this.props.actions.updateRcvBic(e.target.value)}/> <Input placeholder="Receiving bank BIC" maxLength={11} value={rcv_bic} onChange={e=>this.props.actions.updateRcvBic(e.target.value)}/>
} }
</FormItem> */} </FormItem> */}
<RCVBIC flag={false} rcv_bic={rcv_bic_info.rcv_bic} err_msg={rcv_bic_info.err_msg} onChange={(val,msg)=>{rcv_bic_info.rcv_bic=val;rcv_bic_info.err_msg=msg}}/> <RCVBIC flag={false} rcv_bic={rcv_bic_info.rcv_bic} err_msg={rcv_bic_info.err_msg} onChange={(val,msg)=>{rcv_bic_info.rcv_bic=val;rcv_bic_info.err_msg=msg}}/>
...@@ -394,7 +394,7 @@ export class SWFPage extends Component ...@@ -394,7 +394,7 @@ export class SWFPage extends Component
{ {
this.props.params.action == 'redit'||this.props.params.action == 'redit2'? this.props.params.action == 'redit'||this.props.params.action == 'redit2'?
<div> <div>
<Popconfirm placement="topLeft" title={"将丢失编辑的内容,确定重新加载?"} onConfirm={this.reload}> <Popconfirm placement="topLeft" title={"The edited content will be lost. Are you sure to reload?"} onConfirm={this.reload}>
<Button type="ghost" icon="reload" title="reload" style={{marginRight:'1em',width:'8em'}}>Reload</Button> <Button type="ghost" icon="reload" title="reload" style={{marginRight:'1em',width:'8em'}}>Reload</Button>
</Popconfirm> </Popconfirm>
<br/> <br/>
...@@ -409,7 +409,7 @@ export class SWFPage extends Component ...@@ -409,7 +409,7 @@ export class SWFPage extends Component
{ {
!this.isdirect? !this.isdirect?
<Popconfirm placement="topLeft" title={"将丢失编辑的内容,确定返回?"} onConfirm={()=>this.props.history.goBack()}> <Popconfirm placement="topLeft" title={"The edited content will be lost. Are you sure to return?"} onConfirm={()=>this.props.history.goBack()}>
<Button type="ghost" icon="cross" title="cancel" style={{marginRight:'1em',width:'8em'}} >Return</Button> <Button type="ghost" icon="cross" title="cancel" style={{marginRight:'1em',width:'8em'}} >Return</Button>
</Popconfirm> </Popconfirm>
:null :null
...@@ -465,10 +465,10 @@ function validateRCV_BIC(val) ...@@ -465,10 +465,10 @@ function validateRCV_BIC(val)
{ {
let err_msg = "" let err_msg = ""
if(!val) if(!val)
err_msg ='请填写收报行BIC' err_msg ='Please fill in the BIC of the receiving bank'
else if(!/^[A-Z]{4}[A-Z]{2}[A-Z0-9]{2}([A-Z0-9]{3})?$/.test(val)) else if(!/^[A-Z]{4}[A-Z]{2}[A-Z0-9]{2}([A-Z0-9]{3})?$/.test(val))
{ {
err_msg ='请填写正确BIC' err_msg ='Please fill in the correct BIC'
} }
return err_msg return err_msg
} }
...@@ -496,12 +496,12 @@ class SNDBIC extends Component{ ...@@ -496,12 +496,12 @@ class SNDBIC extends Component{
return (<FormItem return (<FormItem
help={this.state.err_msg} help={this.state.err_msg}
validateStatus={this.state.err_msg?'error':null} validateStatus={this.state.err_msg?'error':null}
label="发报行BIC" required {...formItemLayout}> label="Sending bank BIC" required {...formItemLayout}>
{ {
this.props.flag ? this.props.flag ?
<p style={{fontWeight:'bolder',fontSize:'1.2em',paddingBottom:'0em',paddingLeft:'1em',borderBottom:'1px solid #37b8f2'}}>{this.state.snd_bic}</p> <p style={{fontWeight:'bolder',fontSize:'1.2em',paddingBottom:'0em',paddingLeft:'1em',borderBottom:'1px solid #37b8f2'}}>{this.state.snd_bic}</p>
: :
<Input addonAfter={ <YBIC onSelect={obj=>this.onChange(obj.bic)} /> } placeholder="发报行BIC" maxLength={11} value={this.state.snd_bic} onChange={e=>this.onChange(e.target.value)}/> <Input addonAfter={ <YBIC onSelect={obj=>this.onChange(obj.bic)} /> } placeholder="Sending bank BIC" maxLength={11} value={this.state.snd_bic} onChange={e=>this.onChange(e.target.value)}/>
} }
</FormItem> ) </FormItem> )
} }
...@@ -531,12 +531,12 @@ class RCVBIC extends Component{ ...@@ -531,12 +531,12 @@ class RCVBIC extends Component{
return (<FormItem return (<FormItem
help={this.state.err_msg} help={this.state.err_msg}
validateStatus={this.state.err_msg?'error':null} validateStatus={this.state.err_msg?'error':null}
label="收报行BIC" required {...formItemLayout}> label="Receiving bank BIC" required {...formItemLayout}>
{ {
this.props.flag? this.props.flag?
<p style={{fontWeight:'bolder',fontSize:'1.2em',paddingBottom:'0em',paddingLeft:'1em',borderBottom:'1px solid #37b8f2'}}>{this.state.rcv_bic}</p> <p style={{fontWeight:'bolder',fontSize:'1.2em',paddingBottom:'0em',paddingLeft:'1em',borderBottom:'1px solid #37b8f2'}}>{this.state.rcv_bic}</p>
: :
<Input addonAfter={ <YBIC onSelect={obj=>this.onChange(obj.bic)} /> } placeholder="收报行BIC" maxLength={11} value={this.state.rcv_bic} onChange={e=>this.onChange(e.target.value)}/> <Input addonAfter={ <YBIC onSelect={obj=>this.onChange(obj.bic)} /> } placeholder="Receiving bank BIC" maxLength={11} value={this.state.rcv_bic} onChange={e=>this.onChange(e.target.value)}/>
} }
</FormItem> ) </FormItem> )
} }
......
...@@ -115,9 +115,9 @@ export function TagV(tag,status,value,tno,mty,seqlist,countMap={}) ...@@ -115,9 +115,9 @@ export function TagV(tag,status,value,tno,mty,seqlist,countMap={})
if(!new RegExp(`^${reg.reg}$`).test(val)) if(!new RegExp(`^${reg.reg}$`).test(val))
{ {
if(TagHelpTxtMap[tag]) if(TagHelpTxtMap[tag])
errmsg[key]= "请输入正确的格式:"+TagHelpTxtMap[tag] errmsg[key]= "Please enter the correct format:"+TagHelpTxtMap[tag]
else else
errmsg[key]="请输入正确的格式" errmsg[key]="Please enter the correct format"
} }
...@@ -127,9 +127,9 @@ export function TagV(tag,status,value,tno,mty,seqlist,countMap={}) ...@@ -127,9 +127,9 @@ export function TagV(tag,status,value,tno,mty,seqlist,countMap={})
if(!val) if(!val)
{ {
if(status=='M') //栏位已经填了值,或者该栏位必填 if(status=='M') //栏位已经填了值,或者该栏位必填
errmsg[key]="请填写必输项" errmsg[key]="Please fill in the required item"
else if(mval) else if(mval)
errmsg[key]="请填写完整" errmsg[key]="Please complete"
} }
else else
{ {
...@@ -161,9 +161,9 @@ export function TagV(tag,status,value,tno,mty,seqlist,countMap={}) ...@@ -161,9 +161,9 @@ export function TagV(tag,status,value,tno,mty,seqlist,countMap={})
if(!new RegExp(`^${reg.reg}$`).test(val)) if(!new RegExp(`^${reg.reg}$`).test(val))
{ {
if(TagHelpTxtMap[tag]) if(TagHelpTxtMap[tag])
errmsg[key]="请输入正确的格式:"+TagHelpTxtMap[tag] errmsg[key]="Please enter the correct format:"+TagHelpTxtMap[tag]
else else
errmsg[key]="请输入正确的格式" errmsg[key]="Please enter the correct format"
} }
} }
} }
...@@ -208,17 +208,17 @@ function TestAmt(amt,length) ...@@ -208,17 +208,17 @@ function TestAmt(amt,length)
{ {
if(!/^\d+(\.\d*)?$/.test(amt)) if(!/^\d+(\.\d*)?$/.test(amt))
{ {
return "请填写正确的金额" return "Please fill in the correct amount"
} }
let idx = amt.indexOf('.') let idx = amt.indexOf('.')
if(idx >= 0) if(idx >= 0)
{ {
if(amt.length > length + 1) if(amt.length > length + 1)
return "数字长度过长" return "The number length is too long"
}else }else
{ {
if(amt.length > length) if(amt.length > length)
return "数字长度过长" return "The number length is too long"
} }
return "" return ""
} }
......
...@@ -31,7 +31,7 @@ export default class T38J extends Component { ...@@ -31,7 +31,7 @@ export default class T38J extends Component {
obj['s' + i] = objtemp['s' + i] obj['s' + i] = objtemp['s' + i]
}); });
let mval = `${obj.s1 || ''}${obj.s|| ''}` let mval = `${obj.s1 || ''}${obj.s2|| ''}`
this.props.onValue([obj, mval]) this.props.onValue([obj, mval])
......
...@@ -79,7 +79,7 @@ export default class T59F extends Component ...@@ -79,7 +79,7 @@ export default class T59F extends Component
<FormItem <FormItem
label="Number/Name and Address" label="Number/Name and Address"
required={this.props.status=='M' || mval?'required':null} required={this.props.status=='M' || mval?'required':null}
help={errmsg.s2||'请替换模板为正常内容'} help={errmsg.s2||'Please replace the template with normal content'}
validateStatus={errmsg.s2?'error':'warning'} validateStatus={errmsg.s2?'error':'warning'}
> >
<TextArea type="textarea" onChange={e=>this.onChange(2,e.target.value)} value={value.s2||this.fisrt_temp} style={{imeMode:'disabled'}} placeholder="Number/Name and Address" rows={4} cols={35} maxLength={140}/> <TextArea type="textarea" onChange={e=>this.onChange(2,e.target.value)} value={value.s2||this.fisrt_temp} style={{imeMode:'disabled'}} placeholder="Number/Name and Address" rows={4} cols={35} maxLength={140}/>
......
...@@ -105,7 +105,7 @@ export default class YBIC extends Component ...@@ -105,7 +105,7 @@ export default class YBIC extends Component
<div> <div>
<Button size="small" type="primary" shape="circle" icon="search" title="Query Bank" <Button size="small" type="primary" shape="circle" icon="search" title="Query Bank"
onClick={()=>this.setState({visible:true})} /> onClick={()=>this.setState({visible:true})} />
<Modal title={this.props.pty?"查询我行机构":"查询银行机构"} visible={this.state.visible} onCancel={()=>this.setState({visible:false})} <Modal title={this.props.pty?"Query our institutions":"Enquiry banking Institution"} visible={this.state.visible} onCancel={()=>this.setState({visible:false})}
footer={null} footer={null}
width={800} width={800}
height={700} height={700}
...@@ -114,12 +114,12 @@ export default class YBIC extends Component ...@@ -114,12 +114,12 @@ export default class YBIC extends Component
<Row> <Row>
<Col span={11}> <Col span={11}>
<FormItem label="BIC Code" {...formItemLayout}> <FormItem label="BIC Code" {...formItemLayout}>
<Input value={this.state.bic} onChange={e=>this.setState({bic:e.target.value})} maxLength={11} style={{imeMode:'disabled'}} placeholder="BIC Code"/> <Input value={this.state.bic} onChange={e=>this.setState({bic:e.target.value})} maxLength={100} style={{imeMode:'disabled'}} placeholder="BIC Code"/>
</FormItem> </FormItem>
</Col> </Col>
<Col span={11}> <Col span={11}>
<FormItem label="Bank Name" {...formItemLayout}> <FormItem label="Bank Name" {...formItemLayout}>
<Input value={this.state.name} onChange={e=>this.setState({name:e.target.value})} maxLength={11} style={{imeMode:'disabled'}} placeholder="Bank Name"/> <Input value={this.state.name} onChange={e=>this.setState({name:e.target.value})} maxLength={100} style={{imeMode:'disabled'}} placeholder="Bank Name"/>
</FormItem> </FormItem>
</Col> </Col>
<Col span={2}> <Col span={2}>
......
...@@ -79,11 +79,11 @@ export default class TemplateSaver extends Component{ ...@@ -79,11 +79,11 @@ export default class TemplateSaver extends Component{
</Button> </Button>
<Modal ref="modal" <Modal ref="modal"
visible={this.state.visible} visible={this.state.visible}
title="保存模板" onOk={this.handleOk} onCancel={this.handleCancel} title="Save template" onOk={this.handleOk} onCancel={this.handleCancel}
footer={[ footer={[
<Button key="back" type="ghost" size="large" onClick={this.handleCancel}> </Button>, <Button key="back" type="ghost" size="large" onClick={this.handleCancel}>Back</Button>,
<Button key="submit" type="primary" size="large" loading={this.state.loading} onClick={this.handleOk}> <Button key="submit" type="primary" size="large" loading={this.state.loading} onClick={this.handleOk}>
Submit
</Button>, </Button>,
]} ]}
> >
...@@ -120,28 +120,28 @@ class TempForm extends Component{ ...@@ -120,28 +120,28 @@ class TempForm extends Component{
const { getFieldProps, getFieldError, isFieldValidating } = this.props.form; const { getFieldProps, getFieldError, isFieldValidating } = this.props.form;
const nameProps = getFieldProps('nam', { const nameProps = getFieldProps('nam', {
rules: [ rules: [
{ required: true, message: '填写模板名称' }, { required: true, message: 'Fill in the template name' },
], ],
}); });
const textareaProps = getFieldProps('txt', { const textareaProps = getFieldProps('txt', {
rules: [ rules: [
{ required: true, message: '填写报文备注' }, { required: true, message: 'Fill in message Remarks' },
], ],
}); });
return ( return (
<Form horizontal form={this.props.form}> <Form horizontal form={this.props.form}>
<FormItem <FormItem
{...formItemLayout} {...formItemLayout}
label="模板名称" label="Template name"
hasFeedback hasFeedback
> >
<Input name="nam" {...nameProps} type="text" maxLength={10} placeholder="请填写模板名称" /> <Input name="nam" {...nameProps} type="text" maxLength={10} placeholder="Please fill in the template name" />
</FormItem> </FormItem>
<FormItem <FormItem
{...formItemLayout} {...formItemLayout}
label="备注" label="Remarks"
> >
<Input {...textareaProps} type="textarea" placeholder="填写报文备注" name="txt" /> <Input {...textareaProps} type="textarea" placeholder="Fill in message Remarks" name="txt" />
</FormItem> </FormItem>
</Form> </Form>
......
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