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
92d0fce3
Commit
92d0fce3
authored
Jul 28, 2016
by
superman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
3055db68
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
191 additions
and
151 deletions
+191
-151
.gitignore
.gitignore
+1
-0
workspace.xml
.idea/workspace.xml
+60
-50
DateTimeStatusForm.jsx
src/components/ProductForm/DateTimeStatusForm.jsx
+60
-55
ElementForm.jsx
src/components/ProductForm/ElementForm.jsx
+70
-46
No files found.
.gitignore
View file @
92d0fce3
node_modules
.DS_Store
.idea
.idea/workspace.xml
View file @
92d0fce3
This diff is collapsed.
Click to expand it.
src/components/ProductForm/DateTimeStatusForm.jsx
View file @
92d0fce3
...
...
@@ -25,6 +25,7 @@ import {
formatDateTime
,
arrayRemoveIndex
,
UUID
,
NULL
,
formItemLayout
,
smallFormItemLayout
,
footerFormSubmitLayout
...
...
@@ -91,6 +92,8 @@ export default class DateTimeSatausForm extends Component {
return
(
<
Spin
spinning=
{
loading
}
>
<
Form
horizontal
onSubmit=
{
this
.
handleSubmit
.
bind
(
this
)
}
>
<
Row
style=
{
{
padding
:
'0 20px'
}
}
>
<
Col
span=
"24"
>
{
!
isCreate
&&
<
Form
.
Item
label=
"产品状态"
{
...
formItemLayout
}
wrapperCol=
{
{
span
:
20
}
}
>
...
...
@@ -144,10 +147,12 @@ export default class DateTimeSatausForm extends Component {
!
this
.
props
.
isCreate
&&
<
Button
onClick=
{
e
=>
{
e
.
preventDefault
();
this
.
props
.
history
.
goBack
();}
}
style=
{
{
marginLeft
:
'1em'
}
}
>
<
Icon
type=
"rollback"
/>
返回
<
Icon
type=
"rollback"
/>
返回
</
Button
>
}
</
Form
.
Item
>
</
Col
>
</
Row
>
</
Form
>
</
Spin
>
);
...
...
src/components/ProductForm/ElementForm.jsx
View file @
92d0fce3
...
...
@@ -19,7 +19,7 @@ import {
Table
,
Spin
}
from
'antd'
;
import
{
arrayRemoveIndex
,
UUID
,
formItemLayout
,
smallFormItemLayout
,
footerFormSubmitLayout
}
from
'../../utils'
;
import
{
arrayRemoveIndex
,
NULL
,
UUID
,
formItemLayout
,
smallFormItemLayout
,
footerFormSubmitLayout
}
from
'../../utils'
;
export
function
CreateBaseElement
()
{
...
...
@@ -97,10 +97,15 @@ export default class ElementForm extends Component {
}
render
()
{
const
{
form
:{
getFieldProps
},
loading
}
=
this
.
props
;
const
{
form
:{
getFieldProps
},
loading
,
isEdit
}
=
this
.
props
;
return
(
<
Spin
spinning=
{
loading
}
>
<
Form
horizontal
onSubmit=
{
this
.
handleSubmit
.
bind
(
this
)
}
>
<
Row
style=
{
{
padding
:
'0 20px'
}
}
>
<
Col
span=
"24"
>
{
isEdit
?
<
div
>
<
Form
.
Item
>
<
h3
>
可以设置以下要素,或者自定义其他要素
</
h3
>
<
p
>
总规模、投资亮点、托管方、结算方式、资金用途、融资方、担保主体、风控措施、还款来源、发行方、认购起点、大小额配比
</
p
>
...
...
@@ -133,18 +138,37 @@ export default class ElementForm extends Component {
)
}
</
Form
.
Item
>
</
div
>
:
<
table
>
<
tbody
>
{
this
.
state
.
elements
.
map
(
item
=>
<
tr
>
<
th
>
{
item
.
title
}
</
th
>
<
td
>
{
item
.
content
||
NULL
}
</
td
>
</
tr
>
)
}
</
tbody
>
</
table
>
}
<
Form
.
Item
{
...
footerFormSubmitLayout
}
style=
{
{
marginTop
:
30
}
}
>
<
Button
onClick=
{
this
.
handleAddElement
.
bind
(
this
)
}
style=
{
{
marginRight
:
'1em'
}
}
><
Icon
type=
"plus"
/>
添加
</
Button
>
<
Button
type=
"primary"
htmlType=
"submit"
loading=
{
loading
}
><
Icon
type=
"save"
/>
保存
</
Button
>
<
Button
type=
"primary"
htmlType=
"submit"
loading=
{
loading
}
><
Icon
type=
"save"
/>
保存
</
Button
>
{
!
this
.
props
.
isCreate
&&
<
Button
onClick=
{
e
=>
{
e
.
preventDefault
();
this
.
props
.
history
.
goBack
();}
}
style=
{
{
marginLeft
:
'1em'
}
}
>
<
Icon
type=
"rollback"
/>
返回
<
Icon
type=
"rollback"
/>
返回
</
Button
>
}
</
Form
.
Item
>
</
Col
>
</
Row
>
</
Form
>
</
Spin
>
);
...
...
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