Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
shuniu-admin-react
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
superman
shuniu-admin-react
Commits
7f0913d4
Commit
7f0913d4
authored
Jul 29, 2016
by
superman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
12f10146
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
62 additions
and
48 deletions
+62
-48
index.js
dist/index.js
+20
-20
Commission.jsx
src/containers/Trade/Commission.jsx
+38
-28
utils.js
src/utils.js
+4
-0
No files found.
dist/index.js
View file @
7f0913d4
This diff is collapsed.
Click to expand it.
src/containers/Trade/Commission.jsx
View file @
7f0913d4
...
...
@@ -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
)
}
>
<
Form
.
Item
label=
"产品"
{
...
smallFormItemLayout
}
>
<
p
>
{
item
&&
item
.
title
}
</
p
>
</
Form
.
Item
>
<
Form
.
Item
label=
"确认打款金额"
{
...
smallFormItemLayout
}
>
<
Input
placeholder=
"确认打款金额"
readOnly
{
...
getFieldProps
('
remittanceAmount
',
{
initialValue
:
item
&&
item
.
remittanceAmount
})}
/>
</
Form
.
Item
>
<
Form
.
Item
label=
"实际佣金"
{
...
smallFormItemLayout
}
>
<
Input
placeholder=
"实际佣金"
readOnly
{
...
getFieldProps
('
realReturn
',
{
initialValue
:
item
&&
item
.
commission
})}
/>
</
Form
.
Item
>
<
Form
.
Item
{
...
footerFormSubmitLayout
}
style=
{
{
marginTop
:
30
}
}
>
<
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
>
{
item
&&
<
Form
className=
"main-form"
horizontal
onSubmit=
{
this
.
handleSubmit
.
bind
(
this
)
}
>
<
Form
.
Item
label=
"产品"
{
...
smallFormItemLayout
}
>
<
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
}
>
{
item
.
remittanceAmount
||
NULL
}
</
Form
.
Item
>
<
Form
.
Item
label=
"实际佣金"
{
...
smallFormItemLayout
}
>
{
item
.
commission
||
NULL
}
</
Form
.
Item
>
<
Form
.
Item
{
...
footerFormSubmitLayout
}
style=
{
{
marginTop
:
30
}
}
>
<
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
>
);
...
...
src/utils.js
View file @
7f0913d4
...
...
@@ -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
));
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment