diff --git a/App.js b/App.js
index c4c9786..a64d1de 100644
--- a/App.js
+++ b/App.js
@@ -17,6 +17,8 @@ import HttpUtils from './HttpUtils.js';
import CodePush from "react-native-code-push";
import DeviceInfo from "react-native-device-info";
+import * as Animatable from 'react-native-animatable';
+
// 取得屏幕的宽高Dimensions
const { width, height } = Dimensions.get('window');
@@ -143,9 +145,10 @@ getAdDataList() {
.then(result => {
this.setState({
adDataList : result.data.list});
- this.setState({
- contentItem1 : this.state.adDataList[0]});
- })
+ if (this.state.adDataList.length > 0)
+ this.setState({
+ contentItem1 : this.state.adDataList[0]});
+ })
.catch(error => console.error(error))
}
@@ -193,12 +196,12 @@ render() {
-
+
-
+
{this.state.contentItem1.target.title}
{this.state.contentItem1.target.remark}
@@ -225,13 +228,14 @@ render() {
-
-
+
+
+
-
+
{this.state.contentItem1.target.title}
{this.state.contentItem1.target.remark}
@@ -257,14 +261,14 @@ render() {
-
+
-
+
-
+
{this.state.contentItem1.target.title}
{this.state.contentItem1.target.remark}
@@ -290,7 +294,7 @@ render() {
-
+
@@ -464,12 +468,12 @@ render() {
},
//layer content item top
- contentItemTopCover:{
+ contentItemTopCoverImg:{
flex: 5,
width:'100%',
height:'100%',
borderRadius:10,
- backgroundColor:'blue'
+ backgroundColor:'transparent'
},
contentItemTopDetail:{
flex: 6,