Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
T
taochepaiRN
Project
Project
Details
Activity
Releases
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
shangbj
taochepaiRN
Commits
fca68a54
Commit
fca68a54
authored
Jun 21, 2018
by
zhaixiaoou
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://gitlab.dev.daikuan.com/cross-end/taochepaiRN
parents
08c8ae03
1b13ce0c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
23 deletions
+9
-23
Market.js
src/containers/tabs/Market.js
+4
-14
auctionInitialState.js
src/reducers/auction/auctionInitialState.js
+2
-6
auctionReducer.js
src/reducers/auction/auctionReducer.js
+3
-3
No files found.
src/containers/tabs/Market.js
View file @
fca68a54
...
...
@@ -39,13 +39,10 @@ class Market extends Component {
},
1000
);
}
// <TouchableOpacity onPress={ this.onButtonPress.bind(this) }>
// <Text>获取测试列表数据</Text>
// </TouchableOpacity>
render
()
{
const
{
navigate
}
=
this
.
props
.
navigation
;
const
listData
=
this
.
props
.
auction
;
console
.
log
(
'listData'
,
this
.
props
.
auction
);
const
{
listData
}
=
this
.
props
.
auction
;
return
(
<
View
style
=
{
styles
.
container
}
>
...
...
@@ -58,11 +55,6 @@ class Market extends Component {
<
/View
>
);
}
onButtonPress
()
{
this
.
props
.
actions
.
getLongAuctionList
();
console
.
log
(
'auction'
,
this
.
props
.
auction
);
}
}
const
actions
=
[
...
...
@@ -71,7 +63,7 @@ const actions = [
function
mapStateToProps
(
state
)
{
return
{
...
state
auction
:
state
.
auction
.
toJS
(),
};
}
...
...
@@ -92,9 +84,7 @@ export default connect(mapStateToProps, mapDispatchToProps)(Market);
const
styles
=
StyleSheet
.
create
({
container
:
{
flex
:
1
,
backgroundColor
:
'#ffffff'
,
// alignItems: 'center',
// justifyContent: 'center'
backgroundColor
:
'#ffffff'
},
webviewWrap
:
{
width
:
Screen
.
width
,
...
...
src/reducers/auction/auctionInitialState.js
View file @
fca68a54
import
{
Record
,
fromJS
}
from
'immutable'
;
const
InitialState
=
{
const
InitialState
=
fromJS
(
{
listData
:
[]
};
// Record({
// listData: fromJS([])
// });
});
export
default
InitialState
;
src/reducers/auction/auctionReducer.js
View file @
fca68a54
...
...
@@ -8,11 +8,11 @@ const { GET_LIST_SUCC } = require('../actionTypes').default;
// alert(error.errorMessage || '网络错误');
// }
export
default
function
auctionReducer
(
state
=
initialState
,
action
)
{
export
default
function
auctionReducer
(
state
=
initialState
,
action
)
{
switch
(
action
.
type
)
{
case
GET_LIST_SUCC
:
{
const
listData
=
action
.
payload
;
return
state
.
listData
=
listData
;
const
listData
=
fromJS
(
action
.
payload
)
;
return
state
.
setIn
([
'listData'
],
listData
)
;
}
}
return
state
;
...
...
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