Commit 179e48f2 authored by Trisno's avatar Trisno

translate order confirmation

parent 6b83a163
......@@ -109,12 +109,19 @@
"addMore":"+ ADD MORE",
"addVoucher":"+ ADD VOUCHER",
"removeVoucher":"Remove Voucher",
"viewDetail":"View Detail",
"payment":"PAYMENT",
"balanceUsed":"Balance Used",
"pointUsed":"Point Used",
"paymentMethods":"PAYMENT METHODS",
"yourBalance":"Your Balance",
"yourPoints":"Your Points",
"yourBalanceUsed":"Your Balance Used",
"yourPointsUsed":"Your Points Used",
"paymentDetails":"PAYMENT DETAILS"
"paymentDetails":"PAYMENT DETAILS",
"note":"Note",
"headerConfirmOrder":"CONFIRM YOUR ORDER",
"orderProcess":"ORDER PROCESS"
}
\ No newline at end of file
......@@ -58,10 +58,10 @@
"delivery": "ANTAR",
"rateDelivery": "Ongkos Kirim",
"price": "Harga",
"discount":"Diskon",
"discount": "Diskon",
"total": "TOTAL",
"checkout":"CHECKOUT@",
"headerShoppingCart":"SHOPPING CART@",
"checkout": "CHECKOUT@",
"headerShoppingCart": "SHOPPING CART@",
"pickup": "AMBIL",
"changepassword": "GANTI KATA SANDI",
"changeEmail": "GANTI EMAIL",
......@@ -111,10 +111,17 @@
"addMore": "+ TAMBAH LAGI",
"addVoucher": "+ TAMBAH VOUCHER",
"removeVoucher": "Hapus Voucher",
"viewDetail": "Lihat Detail",
"payment": "PEMBAYARAN",
"balanceUsed": "Saldo Digunakan",
"pointUsed": "Poin Digunakan",
"paymentMethods": "METODE PEMBAYARAN",
"yourBalance": "Saldo Kamu",
"yourPoints": "Poin Kamu",
"yourBalanceUsed": "Saldo Kamu Digunakan",
"yourPointsUsed": "Poin Kamu Digunakan",
"paymentDetails": "DETAIL PEMBAYARAN"
"paymentDetails": "DETAIL PEMBAYARAN",
"note":"Keterangan",
"headerConfirmOrder":"CONFIRM YOUR ORDER@",
"orderProcess":"PROSES PESANAN"
}
\ No newline at end of file
......@@ -711,7 +711,7 @@ class Auth extends React.Component {
color: 'white',
fontSize: 20,
},
title: 'CONFIRM YOUR ORDER'
title: i18n.t('headerConfirmOrder')
}} />
<Stack.Screen name="Date Time" component={DateTime} />
<Stack.Screen name="New Register" component={NewRegister}
......
......@@ -9,6 +9,7 @@ import moment from 'moment'
import { FontAwesome } from '@expo/vector-icons';
import NumberFormat from 'react-number-format';
import MyStatusBar from './MyStatusBar';
import i18n from 'i18n-js';
class MenuConfirmation extends React.Component {
constructor(props) {
super(props)
......@@ -250,18 +251,18 @@ class MenuConfirmation extends React.Component {
{
this.props.type_pickup == true ? (
<View style={{ flex: 0.2, justifyContent: 'center' }}>
<Text style={{ textAlign: 'right', fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>PICKUP</Text>
<Text style={{ textAlign: 'right', fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('pickup')}</Text>
</View>
) : (
<View style={{ flex: 0.2, justifyContent: 'center' }}>
<Text style={{ textAlign: 'right', fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>DELIVERY</Text>
<Text style={{ textAlign: 'right', fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('delivery')}</Text>
</View>
)
}
</View>
<View style={{ marginHorizontal: 10, paddingLeft: 10 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>PESANAN</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('yourOrders')}</Text>
</View>
{
this.props.order_item.map((item, index) => {
......@@ -285,7 +286,7 @@ class MenuConfirmation extends React.Component {
(item.note == undefined || item.note == "") ? (
null
) : (
<Text style={{ fontSize: 10, fontFamily: 'Gotham-Light', color: '#838383' }}>Keterangan : {item.note} </Text>
<Text style={{ fontSize: 10, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('note')} : {item.note} </Text>
)
}
......@@ -314,7 +315,7 @@ class MenuConfirmation extends React.Component {
</View>
<TouchableOpacity onPress={() => this.props.navigation.navigate('Reward Detail', { rewardId: this.props.voucher.id })}>
<View style={{ flex: 0.2, marginVertical: 10, paddingRight: 5 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#CFB368' }}>View Detail</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#CFB368' }}>{i18n.t('viewDetail')}</Text>
</View>
</TouchableOpacity>
</View>
......@@ -322,11 +323,11 @@ class MenuConfirmation extends React.Component {
)
}
<View style={{ borderTopWidth: 1, borderColor: '#838383', marginHorizontal: 10, paddingLeft: 10, padding: 10 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>PAYMENT</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('payment')}</Text>
</View>
<View style={{ flex: 1, flexDirection: 'row', justifyContent: 'space-between', marginTop: -10 }}>
<View style={{ flex: 0.5, margin: 10, paddingLeft: 20 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>Balance Used</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('balanceUsed')}</Text>
</View>
<View style={{ flex: 0.5, margin: 10, alignItems: 'flex-end', paddingRight: 5 }}>
{/* <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light' }}>{this.props.route.params.balanceUsed}</Text> */}
......@@ -335,7 +336,7 @@ class MenuConfirmation extends React.Component {
</View>
<View style={{ flex: 1, flexDirection: 'row', justifyContent: 'space-between', marginTop: -10 }}>
<View style={{ flex: 0.5, margin: 10, paddingLeft: 20 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>Point Used</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('pointUsed')}</Text>
</View>
<View style={{ flex: 0.5, margin: 10, alignItems: 'flex-end', paddingRight: 5 }}>
{/* <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light' }}>{this.props.route.params.pointused}</Text> */}
......@@ -344,7 +345,7 @@ class MenuConfirmation extends React.Component {
</View>
<View style={{ borderTopWidth: 1, borderColor: '#838383', margin: 10, paddingLeft: 10, padding: 10, paddingBottom: -10, flexDirection: 'row', justifyContent: 'space-between', flex: 1 }}>
<View style={{ flex: 0.6 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>Harga</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('price')}</Text>
</View>
<View style={{ flex: 0.4, marginRight: -5 }}>
{/* <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', textAlign: 'right', color:'#838383' }}>{total}</Text> */}
......@@ -357,7 +358,7 @@ class MenuConfirmation extends React.Component {
) : (
<View style={{ margin: 10, marginTop: -10, paddingLeft: 10, padding: 10, paddingBottom: -10, flexDirection: 'row', justifyContent: 'space-between', flex: 1 }}>
<View style={{ flex: 0.6 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>Voucher</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('discount')}</Text>
</View>
<View style={{ flex: 0.4, marginRight: -5 }}>
{/* <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', textAlign: 'right', color:'#838383' }}>- {this.props.voucher.reward.value}</Text> */}
......@@ -372,7 +373,7 @@ class MenuConfirmation extends React.Component {
) : (
<View style={{ margin: 10, marginTop: -10, paddingLeft: 10, padding: 10, paddingBottom: -10, flexDirection: 'row', justifyContent: 'space-between', flex: 1 }}>
<View style={{ flex: 0.6 }}>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>Ongkos Kirim</Text>
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: '#838383' }}>{i18n.t('rateDelivery')}</Text>
</View>
<View style={{ flex: 0.4, marginRight: -5 }}>
{/* <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', textAlign: 'right' }}>{this.props.grabamount}</Text> */}
......@@ -383,7 +384,7 @@ class MenuConfirmation extends React.Component {
}
<View style={{ marginVertical: 10, marginHorizontal: 9, paddingHorizontal: 10, flexDirection: 'row', justifyContent: 'space-between', flex: 1 }}>
<View style={{ flex: 0.6 }}>
<Text style={{ fontSize: 20, fontFamily: 'Gotham-Black', color: '#CFB368' }}>Total</Text>
<Text style={{ fontSize: 20, fontFamily: 'Gotham-Black', color: '#CFB368' }}>{i18n.t('total')}</Text>
</View>
{
this.props.value_voucher == '' ? (
......@@ -478,7 +479,7 @@ class MenuConfirmation extends React.Component {
</View> */}
<TouchableOpacity onPress={() => this.setOrder(this.props.type_pickup)}>
<View style={styles.button}>
<Text style={{ color: 'white', fontSize: 16, fontFamily: 'Gotham-Black' }}>Proses Pesanan</Text>
<Text style={{ color: 'white', fontSize: 16, fontFamily: 'Gotham-Black' }}>{i18n.t('orderProcess')}</Text>
</View>
</TouchableOpacity>
<View style={{ height: 30 }} />
......
......@@ -712,7 +712,7 @@ class ShoppingCart extends React.Component {
<Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: 'gray' }}>{i18n.t('discount')}</Text>
</View>
<View style={{ paddingRight: 20, paddingTop: 5, alignItems: 'flex-end' }}>
<NumberFormat decimalScale={0} value={this.props.voucher.reward.value} renderText={value => <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: 'gray' }}>Rp. {value}</Text>} displayType={'text'} thousandSeparator={true} prefix={''} />
<NumberFormat decimalScale={0} value={this.props.voucher.reward.value} renderText={value => <Text style={{ fontSize: 12, fontFamily: 'Gotham-Light', color: 'gray' }}>- Rp. {value}</Text>} displayType={'text'} thousandSeparator={true} prefix={''} />
</View>
</View>
......
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