Commit a5918480 authored by Trisno's avatar Trisno

update 138

parent 7a62214c
{
"expo": {
"extra" : {
"buildNumber" : "136",
"buildNumber" : "138",
"remarks": ""
},
......
......@@ -231,7 +231,7 @@ class Auth extends React.Component {
fontFamily: 'Gotham-Black',
color: 'white',
textAlign: 'center'
}, title: 'PROFILE'
}, title: i18n.t('profile').toUpperCase()
}} />
<Stack.Screen name="UpdateVersion" component={UpdateVersion}
options={{ headerShown: false }}
......@@ -372,7 +372,7 @@ class Auth extends React.Component {
fontFamily: 'Gotham-Black',
color: 'white',
textAlign: 'center'
}, title: 'PROFILE'
}, title: i18n.t('profile').toUpperCase()
}} />
<Stack.Screen name="Change Profil" component={ChangeProfile} />
<Stack.Screen name="Change language" component={ChangeLanguage}
......@@ -387,7 +387,7 @@ class Auth extends React.Component {
fontSize: 20,
color: 'white',
textAlign: 'center'
}, title: 'LANGUAGE'
}, title: i18n.t('language')
}}
/>
<Stack.Screen name="Change password" component={ChangePassword} options={{
......@@ -400,7 +400,7 @@ class Auth extends React.Component {
fontFamily: 'Gotham-Black',
color: 'white',
textAlign: 'center'
}, title: 'CHANGE PASSWORD'
}, title: i18n.t('changepassword')
}} />
<Stack.Screen name="Card Activation" component={CardActivation} options={{
headerStyle: { backgroundColor: '#CFB368' },
......@@ -841,7 +841,7 @@ class Auth extends React.Component {
color: 'white',
fontSize: 20,
},
title: 'REWARD SELECT'
title: i18n.t('titlerewardhistory')
}} />
</Stack.Navigator>
)
......
......@@ -196,7 +196,7 @@ class MenuSelection extends React.Component {
let next_category = this.state.listCategory[index_next_category]
let index_end = _.findIndex(this.props.menu_item, ['name', next_category.name])
let filter_item = this.props.menu_item.slice(index_start, index_end);
this.setState({
data_before_search: filter_item
......@@ -213,7 +213,7 @@ class MenuSelection extends React.Component {
renderTabBar = ({ item }) => {
return (
<View style={{ flex: 0.5}}>
<View style={{ flex: 0.5 }}>
<TouchableOpacity onPress={() => this.filterSubcategory(item)}>
{item.image === '' ? (
<View style={{ height: 60, width: 60, top: 5 }} />
......@@ -357,7 +357,7 @@ class MenuSelection extends React.Component {
) : (
<StatusBar backgroundColor='#CFB368' />
)}
<View style={{ flex: 0.5,paddingTop: StatusBar.currentHeight, marginHorizontal:10, borderBottomWidth:1, paddingBottom:5, borderColor:'#838383' }}>
<View style={{ flex: 0.5, paddingTop: StatusBar.currentHeight, marginHorizontal: 10, borderBottomWidth: 1, paddingBottom: 5, borderColor: '#838383' }}>
<FlatList horizontal={true} style={{ flexDirection: 'row' }}
showsHorizontalScrollIndicator={false}
data={this.state.listCategory}
......@@ -376,7 +376,7 @@ class MenuSelection extends React.Component {
<FlatList
data={this.state.data_before_search}
renderItem={this.renderItem}
keyExtractor={item => item.id}
ref={(ref) => { this.flatListRef = ref; }}
initialNumToRender={5}
......@@ -402,10 +402,19 @@ class MenuSelection extends React.Component {
<View style={{ flex: 1, height: 100 }}>
<TouchableOpacity onPress={() => this.props.navigation.navigate('Shopping Cart')}>
<View>
<View style={{ height: 40, borderRadius: 10, width: '68%', backgroundColor: '#CFB368', marginRight: 20, marginLeft: 40, top: 15, flexDirection: 'row', marginBottom: 30 }}>
<Image source={(require('../assets/icon/icon-order.png'))} style={{ height: 40, width: 40, tintColor: 'white', }}></Image>
<Text style={{ fontFamily: 'Gotham-Light', color: 'white', fontSize: 16, alignSelf: 'center', textAlign: 'center' }}>{i18n.t('Viewcart')}</Text>
</View>
{
this.props.language == 'id' ? (
<View style={{ height: 40, borderRadius: 10, width: '86%', backgroundColor: '#CFB368', marginRight: 20, marginLeft: 16, top: 15, flexDirection: 'row', marginBottom: 30 }}>
<Image source={(require('../assets/icon/icon-order.png'))} style={{ height: 40, width: 40, tintColor: 'white', }}></Image>
<Text style={{ fontFamily: 'Gotham-Light', color: 'white', fontSize: 16, alignSelf: 'center', textAlign: 'center' }}>{i18n.t('Viewcart')}</Text>
</View>
) : (
<View style={{ height: 40, borderRadius: 10, width: '68%', backgroundColor: '#CFB368', marginRight: 20, marginLeft: 40, top: 15, flexDirection: 'row', marginBottom: 30 }}>
<Image source={(require('../assets/icon/icon-order.png'))} style={{ height: 40, width: 40, tintColor: 'white', }}></Image>
<Text style={{ fontFamily: 'Gotham-Light', color: 'white', fontSize: 16, alignSelf: 'center', textAlign: 'center' }}>{i18n.t('Viewcart')}</Text>
</View>
)
}
</View>
</TouchableOpacity>
</View>
......
......@@ -14,25 +14,40 @@ import requestParams from '../helper/requestParams';
var date = [
"Pilih", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21",
i18n.t('pilih'), "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21",
"22", "23", "24", "25", "26", "27", "28", "29", "30", "31"
]
var month = [
"Pilih", "Januari", "Februari", "Maret", "April", "Mei", "Juni", "Juli", "Agustus", "September",
i18n.t('pilih'), "Januari", "Februari", "Maret", "April", "Mei", "Juni", "Juli", "Agustus", "September",
"Oktober", "November", "Desember"
]
var year = [
"Pilih", "1960", "1961", "1962", "1963", "1964", "1965", "1966", "1967", "1968", "1969", "1970", "1971",
i18n.t('pilih'), "1960", "1961", "1962", "1963", "1964", "1965", "1966", "1967", "1968", "1969", "1970", "1971",
"1972", "1973", "1974", "1975", "1976", "1977", "1978", "1979", "1980", "1981", "1982", "1983", "1984", "1985", "1986", "1987",
"1988", "1989", "1990", "1991", "1992", "1993", "1994", "1995", "1996", "1997", "1998", "1999", "2000", "2001", "2002", "2003", "2004",
"2005", "2006", "2007"
]
class NewRegister extends React.Component {
constructor(props) {
super(props);
this.state = ({
dateAndroid : [
i18n.t('pilih'), "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21",
"22", "23", "24", "25", "26", "27", "28", "29", "30", "31"
],
monthAndroid : [
i18n.t('pilih'), "Januari", "Februari", "Maret", "April", "Mei", "Juni", "Juli", "Agustus", "September",
"Oktober", "November", "Desember"
],
yearAndroid : [
i18n.t('pilih'), "1960", "1961", "1962", "1963", "1964", "1965", "1966", "1967", "1968", "1969", "1970", "1971",
"1972", "1973", "1974", "1975", "1976", "1977", "1978", "1979", "1980", "1981", "1982", "1983", "1984", "1985", "1986", "1987",
"1988", "1989", "1990", "1991", "1992", "1993", "1994", "1995", "1996", "1997", "1998", "1999", "2000", "2001", "2002", "2003", "2004",
"2005", "2006", "2007"
],
caretHidden: true,
email: "",
password: "",
......@@ -45,7 +60,7 @@ class NewRegister extends React.Component {
dob_year: "",
dob_month: "",
dob_day: "",
list_gender: [],
list_gender: { "0": i18n.t('other'), "1": i18n.t('male'), "2": i18n.t('female') },
gender_list: [],
list_domicilie: [],
list_profesion: [],
......@@ -98,11 +113,12 @@ class NewRegister extends React.Component {
}
}
this.setState({
list_gender: list_gender,
// list_gender: list_gender,
list_profesion: list_profesion,
list_domicilie: list_domicilie,
gender_list: gender_list,
})
// console.log(this.state.list_gender)
})
}
......@@ -247,7 +263,7 @@ class NewRegister extends React.Component {
this.props.navigation.navigate('Email Confirmation')
}
}
],
{ cancelable: false }
......@@ -396,7 +412,7 @@ class NewRegister extends React.Component {
selectedValue={this.state.dob_day}
style={{ height: 35, width: 90 }}
onValueChange={(itemValue, itemIndex) => this.setState({ dob_day: itemValue })}>
{date.map((itemValue, itemIndex) => {
{this.state.dateAndroid.map((itemValue, itemIndex) => {
return (<Picker.Item label={itemValue} value={itemValue} key={itemIndex} />)
})}
......@@ -410,7 +426,7 @@ class NewRegister extends React.Component {
onValueChange={(itemValue, itemIndex) =>
this.setState({ dob_month: itemValue })
}>
{month.map((itemValue, itemIndex) => {
{this.state.monthAndroid.map((itemValue, itemIndex) => {
return (<Picker.Item label={itemValue} value={itemIndex} key={itemIndex} />)
})}
</Picker>
......@@ -423,7 +439,7 @@ class NewRegister extends React.Component {
onValueChange={(itemValue, itemIndex) =>
this.setState({ dob_year: itemValue })
}>
{year.map((itemValue, itemIndex) => {
{this.state.yearAndroid.map((itemValue, itemIndex) => {
return (<Picker.Item label={itemValue} value={itemValue} key={itemIndex} />)
})}
</Picker>
......@@ -450,7 +466,7 @@ class NewRegister extends React.Component {
<View style={styles.pickerGender}>
<Picker selectedValue={this.state.gender}
onValueChange={(itemValue, itemIndex) => this.setState({ gender: itemValue })}>
<Picker.Item label='Pilih' value='' />
<Picker.Item label={i18n.t('pilih')} value='' />
{
Object.entries(this.state.list_gender).map((item, key) =>
<Picker.Item label={item[1]} key={key} value={item[0]}>
......
......@@ -13,7 +13,7 @@ class RedeemCode extends React.Component {
super(props);
this.handleBackButtonClick = this.handleBackButtonClick.bind(this)
this.state = {
in_process_redeem: false,
in_process_redeem: true,
}
}
......@@ -40,6 +40,7 @@ class RedeemCode extends React.Component {
}
Axios.post(this.props.BASE_URL + 'crm/v2/point/check', params).then(res => {
let in_process_redeem = res.data.in_process_redeem
console.log(res.data.in_process_redeem)
this.setState({
in_process_redeem: in_process_redeem
})
......
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