Commit 7f0913d4 authored by superman's avatar superman

update

parent 12f10146
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -25,7 +25,9 @@ import {
formItemLayout,
smallFormItemLayout,
footerFormSubmitLayout,
handleUpload
handleUpload,
NULL,
mobileSecrecy
} from '../../utils';
import Layout from '../../components/Layout/Layout';
......@@ -66,33 +68,41 @@ export default class Commission extends Component {
return (
<Layout header={header}>
<Spin spinning={loading}>
<Form horizontal onSubmit={this.handleSubmit.bind(this)}>
{
item &&
<Form className="main-form" horizontal onSubmit={this.handleSubmit.bind(this)}>
<Form.Item label="产品" {...smallFormItemLayout}>
<p>{item && item.title}</p>
<p>{item.title || NULL}</p>
</Form.Item>
<Form.Item label="理财师" {...smallFormItemLayout}>
{
item.user ?
((item.user.username || NULL) + ' - ' +
(mobileSecrecy(item.user.mobile) || NULL))
:
NULL
}
</Form.Item>
<Form.Item label="确认打款金额" {...smallFormItemLayout}>
<Input placeholder="确认打款金额"
readOnly
{...getFieldProps('remittanceAmount', {
initialValue: item && item.remittanceAmount
})} />
{
item.remittanceAmount || NULL
}
</Form.Item>
<Form.Item label="实际佣金" {...smallFormItemLayout}>
<Input placeholder="实际佣金"
readOnly
{...getFieldProps('realReturn', {
initialValue: item && item.commission
})} />
{
item.commission || NULL
}
</Form.Item>
<Form.Item {...footerFormSubmitLayout} style={{marginTop:30}}>
<Button type="primary" htmlType="submit" loading={loading}><Icon type="save"/>发放</Button>
<Button type="primary" htmlType="submit" loading={loading}><Icon
type="save"/>发放</Button>
<Button onClick={e=>{e.preventDefault(); this.props.history.goBack();}}
style={{marginLeft:'1em'}}>
<Icon type="rollback"/>返回
</Button>
</Form.Item>
</Form>
}
</Spin>
</Layout>
);
......
......@@ -221,3 +221,7 @@ export function remittanceAuditStatusToString(status) {
return '未定义';
}
}
export function mobileSecrecy(mobile){
return (mobile+'').replace(/^(\d{3})(\d{4})(\d{4})$/g, (b,c,d,e)=>(c+'****'+e));
}
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