Commit 4e0091d7 authored by Wahyu Adjie Prasetyo's avatar Wahyu Adjie Prasetyo

change account

parent 06b84cb9
...@@ -149,8 +149,6 @@ class Account extends React.Component { ...@@ -149,8 +149,6 @@ class Account extends React.Component {
const { navigation } = this.props const { navigation } = this.props
let response = error.response.data let response = error.response.data
session(response, navigation) session(response, navigation)
Alert.alert(response.msg);
console.log('ini error ' + error)
}) })
} }
...@@ -170,14 +168,13 @@ class Account extends React.Component { ...@@ -170,14 +168,13 @@ class Account extends React.Component {
} }
} }
_useBalance(){ _useBalance() {
if(this.props.in_payment){ if (this.props.in_payment) {
this.props.navigation.navigate('Redeem Code') this.props.navigation.navigate('Redeem Code')
} else { } else {
this.props.navigation.navigate('UseBalance') this.props.navigation.navigate('UseBalance')
} }
}
}
render() { render() {
...@@ -235,49 +232,49 @@ class Account extends React.Component { ...@@ -235,49 +232,49 @@ class Account extends React.Component {
<View> <View>
<View style={styles.Card}> <View style={styles.Card}>
<View style={styles.card}> <View style={styles.card}>
<View style={styles.card}> <View style={styles.card}>
<Card style={{ padding: 20,alignContent: 'center' }}> <Card style={{ padding: 20, alignContent: 'center' }}>
<View style={{ flexDirection: 'row', flex: 1, paddingBottom:5 }}> <View style={{ flexDirection: 'row', flex: 1, paddingBottom: 5 }}>
<View style={{ flex: 0.5 }}> <View style={{ flex: 0.5 }}>
<Text style={{ fontSize: 10, fontFamily: 'Gotham-Light' }}>YOUR CARD NUMBER</Text> <Text style={{ fontSize: 10, fontFamily: 'Gotham-Light' }}>YOUR CARD NUMBER</Text>
</View> </View>
<View style={{ flex: 0.5 }}> <View style={{ flex: 0.5 }}>
<Text style={{ fontSize: 10, textAlign: 'right', fontFamily: 'Gotham-Light' }}>Expired At {this.state.expire_date}</Text> <Text style={{ fontSize: 10, textAlign: 'right', fontFamily: 'Gotham-Light' }}>Expired At {this.state.expire_date}</Text>
</View> </View>
</View> </View>
<View style={{ paddingHorizontal: 10 }}> <View style={{ paddingHorizontal: 10 }}>
<Text style={{ textAlign: "center", fontSize: 30, color: '#c9af6d', fontFamily: 'Gotham-Black' }}> <Text style={{ textAlign: "center", fontSize: 30, color: '#c9af6d', fontFamily: 'Gotham-Black' }}>
{this.state.account_number} {this.state.account_number}
</Text> </Text>
</View> </View>
<View style={styles.line}></View> <View style={styles.line}></View>
<View style={{ flexDirection: 'row', flex: 1 }}> <View style={{ flexDirection: 'row', flex: 1 }}>
<View style={{ flex: 0.3, justifyContent: 'center' }}> <View style={{ flex: 0.3, justifyContent: 'center' }}>
{/* <Text>{i18n.t('balance')}</Text> */} {/* <Text>{i18n.t('balance')}</Text> */}
<Text style={{ fontSize: 14, fontFamily: 'Gotham-Light' }}>BALANCE</Text> <Text style={{ fontSize: 14, fontFamily: 'Gotham-Light' }}>BALANCE</Text>
</View> </View>
<View style={{ flex: 0.7, alignItems:'center'}}> <View style={{ flex: 0.7, alignItems: 'center' }}>
<Text style={{ fontSize: 14, fontFamily: 'Gotham-Black', color:'gray' }}>IDR {this.state.balance}</Text> <Text style={{ fontSize: 14, fontFamily: 'Gotham-Black', color: 'gray' }}>IDR {this.state.balance}</Text>
</View> </View>
</View> </View>
<View style={styles.line2}></View> <View style={styles.line2}></View>
{/* <Text style={{ textAlign: 'left', fontWeight: 'bold' }}> {/* <Text style={{ textAlign: 'left', fontWeight: 'bold' }}>
{i18n.t('point')} {this.state.point} {i18n.t('point')} {this.state.point}
</Text> */} </Text> */}
<View style={{ flexDirection: 'row', flex: 1 }}> <View style={{ flexDirection: 'row', flex: 1 }}>
<View style={{ flex: 0.3, justifyContent: 'center' }}> <View style={{ flex: 0.3, justifyContent: 'center' }}>
{/* <Text>{i18n.t('balance')}</Text> */} {/* <Text>{i18n.t('balance')}</Text> */}
<Text style={{ fontSize: 14, fontFamily: 'Gotham-Light' }}>POINTS</Text> <Text style={{ fontSize: 14, fontFamily: 'Gotham-Light' }}>POINTS</Text>
</View> </View>
<View style={{ flex: 0.7,alignItems:'center' }}> <View style={{ flex: 0.7, alignItems: 'center' }}>
<Text style={{ fontSize: 14, fontFamily: 'Gotham-Black', color:'gray' }}>IDR {this.state.points}</Text> <Text style={{ fontSize: 14, fontFamily: 'Gotham-Black', color: 'gray' }}>IDR {this.state.points}</Text>
</View> </View>
</View> </View>
</Card> </Card>
</View> </View>
</View> </View>
</View> </View>
<TouchableOpacity style={styles.submitTopUp} activeOpacity={.5} onPress={() => this.props.navigation.navigate('TopUpInfo')}> <TouchableOpacity style={styles.submitTopUp} activeOpacity={.5} onPress={() => this.props.navigation.navigate('TopUpInfo')}>
...@@ -332,7 +329,7 @@ class Account extends React.Component { ...@@ -332,7 +329,7 @@ class Account extends React.Component {
</Card> </Card>
</TouchableOpacity> </TouchableOpacity>
<View style={{ width: 5 }}></View> <View style={{ width: 5 }}></View>
<TouchableOpacity style={{ marginBottom: 5, margin: 4 }} onPress={() => this.TransferBalance()} > <TouchableOpacity style={{ marginBottom: 5, margin: 4 }} onPress={() => this.props.navigation.navigate('Renewal')}>
<Card style={{ height: 120, width: 155 }}> <Card style={{ height: 120, width: 155 }}>
<View style={{ height: 50, alignItems: 'center', padding: 10 }}> <View style={{ height: 50, alignItems: 'center', padding: 10 }}>
......
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