Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
C
clone_excelso
Project
Project
Details
Activity
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
Prasetya Saputra
clone_excelso
Commits
31d8beef
Commit
31d8beef
authored
Jun 05, 2020
by
Wahyu Adjie Prasetyo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
placeholder
parent
9749b55e
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
109 additions
and
75 deletions
+109
-75
Auth.js
view/Auth.js
+26
-3
CardActivation.js
view/CardActivation.js
+4
-2
Home.js
view/Home.js
+76
-69
MenuConfirmation.js
view/MenuConfirmation.js
+2
-1
MenuSelection.js
view/MenuSelection.js
+1
-0
No files found.
view/Auth.js
View file @
31d8beef
...
...
@@ -194,8 +194,19 @@ class Auth extends React.Component {
<
/
>
)
:
this
.
props
.
pageEmailConfirmation
===
true
?
(
<>
<
Stack
.
Screen
name
=
"Email Confirmation"
component
=
{
EmailConfirmation
}
/
>
<
Stack
.
Screen
name
=
"Login"
component
=
{
Login
}
/
>
<
Stack
.
Screen
name
=
"Email Confirmation"
component
=
{
EmailConfirmation
}
options
=
{{
headerStyle
:
{
backgroundColor
:
'#CFB368'
},
headerTitleContainerStyle
:
{
alignContent
:
'center'
},
headerTitleAlign
:
'center'
,
headerTintColor
:
'#fff'
,
headerTitleStyle
:
{
alignSelf
:
'center'
,
fontFamily
:
'Gotham-Black'
,
color
:
'white'
,
textAlign
:
'center'
},
title
:
'EMAIL CONFIRMATION'
}}
/
>
<
Stack
.
Screen
name
=
"Login"
component
=
{
Login
}
options
=
{{
headerShown
:
false
}}
/
>
<
Stack
.
Screen
name
=
"LoginWelcome"
component
=
{
WelcomeLog
}
options
=
{{
headerShown
:
false
,
}}
/
>
...
...
@@ -301,7 +312,19 @@ class Auth extends React.Component {
title
:
'TRANSFER BALANCE'
}}
/
>
<
Stack
.
Screen
name
=
"Register"
component
=
{
Register
}
/
>
<
Stack
.
Screen
name
=
"Email Confirmation"
component
=
{
EmailConfirmation
}
/
>
<
Stack
.
Screen
name
=
"Email Confirmation"
component
=
{
EmailConfirmation
}
options
=
{{
headerStyle
:
{
backgroundColor
:
'#CFB368'
},
headerTitleContainerStyle
:
{
alignContent
:
'center'
},
headerTitleAlign
:
'center'
,
headerTintColor
:
'#fff'
,
headerTitleStyle
:
{
alignSelf
:
'center'
,
fontFamily
:
'Gotham-Black'
,
fontSize
:
20
,
color
:
'white'
,
textAlign
:
'center'
},
title
:
'EMAIL CONFIRMATION'
}}
/
>
<
Stack
.
Screen
name
=
"Upgrade Premium"
component
=
{
UpgradePremium
}
options
=
{{
headerStyle
:
{
backgroundColor
:
'#CFB368'
},
...
...
view/CardActivation.js
View file @
31d8beef
...
...
@@ -154,9 +154,11 @@ class CardActivation extends React.Component {
}
{
this
.
state
.
timer
===
0
?
(
<
View
style
=
{{
width
:
90
,
height
:
40
,
alignSelf
:
'center'
,
margin
:
20
,
top
:
0
}}
>
<
Button
title
=
"Resend Token"
onPress
=
{()
=>
this
.
ResendToken
()}
><
/Button
>
<
TouchableOpacity
onPress
=
{()
=>
this
.
ResendToken
()}
>
<
View
style
=
{{
height
:
40
,
borderRadius
:
20
,
backgroundColor
:
'#CFB368'
,
margin
:
20
,
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
fontFamily
:
'Gotham-Black'
,
color
:
'white'
,
fontSize
:
20
,
textAlign
:
'center'
,
margin
:
15
}}
>
Resend
Token
<
/Text
>
<
/View
>
<
/TouchableOpacity
>
)
:
(
null
)}
<
View
style
=
{
styles
.
field_email
}
>
...
...
view/Home.js
View file @
31d8beef
...
...
@@ -31,7 +31,8 @@ class Home extends React.Component {
my_long
:
0
,
indicator
:
true
,
slider_height
:
350
,
slugs
:
[]
slugs
:
[],
placeholder
:
true
}
}
...
...
@@ -81,8 +82,6 @@ class Home extends React.Component {
let
latitude
=
location
.
coords
.
latitude
;
let
longitude
=
location
.
coords
.
longitude
;
this
.
setState
({
my_lat
:
latitude
,
my_long
:
longitude
...
...
@@ -111,9 +110,10 @@ class Home extends React.Component {
}
this
.
setState
({
images
:
imageLink
,
slugs
:
slugs
slugs
:
slugs
,
placeholder
:
false
})
}).
catch
(
error
=>
{
}).
catch
(
error
=>
{
const
{
navigation
}
=
this
.
props
let
response
=
error
.
response
.
data
...
...
@@ -142,11 +142,9 @@ class Home extends React.Component {
indicator
:
false
})
}).
catch
(
error
=>
{
// console.log("INI ERROR " + error);
// const { navigation } = this.props
// let response = error.response.data
// session(response, navigation)
// Alert.alert(response.msg);
let
response
=
error
.
response
.
data
session
(
response
,
navigation
)
Alert
.
alert
(
response
.
msg
);
})
}
...
...
@@ -178,13 +176,13 @@ class Home extends React.Component {
const
{
navigation
}
=
this
.
props
let
response_data
=
error
.
response
.
data
let
error_status
=
error
.
response
.
status
session
(
response_data
,
error_status
,
navigation
)
session
(
response_data
,
error_status
,
navigation
)
})
}
_useBalance
(){
if
(
this
.
props
.
in_payment
)
{
_useBalance
()
{
if
(
this
.
props
.
in_payment
)
{
this
.
props
.
navigation
.
navigate
(
'Redeem Code'
)
}
else
{
this
.
props
.
navigation
.
navigate
(
'UseBalance'
)
...
...
@@ -211,7 +209,6 @@ class Home extends React.Component {
}
else
{
Alert
.
alert
(
'Belum dapat outlet terdekat'
)
}
}
render
()
{
...
...
@@ -232,6 +229,9 @@ class Home extends React.Component {
<
/TouchableOpacity
>
<
/View
>
<
/View
>
<
View
style
=
{{
flex
:
2
}}
>
{
this
.
state
.
images
.
length
?
(
<
SliderBox
images
=
{
this
.
state
.
images
}
onCurrentImagePressed
=
{
index
=>
console
.
log
(
`image
${
index
}
pressed`
)}
...
...
@@ -264,8 +264,15 @@ class Home extends React.Component {
width
:
'100%'
,
}}
imageLoadingColor
=
'#c7c7c7'
onCurrentImagePressed
=
{(
index
)
=>
this
.
props
.
navigation
.
navigate
(
'News Detail'
,
{
slug
:
this
.
state
.
slugs
[
index
]
})}
onCurrentImagePressed
=
{(
index
)
=>
this
.
props
.
navigation
.
navigate
(
'News Detail'
,
{
slug
:
this
.
state
.
slugs
[
index
]
})}
/
>
)
:
(
<
View
style
=
{{
height
:
this
.
state
.
slider_height
,
backgroundColor
:
'#838383'
,
justifyContent
:
'center'
}}
>
<
ActivityIndicator
size
=
"large"
color
=
"#c9af6d"
/>
<
/View
>
)
}
<
/View
>
<
/View
>
<
View
style
=
{
styles
.
content
}
>
<
View
style
=
{
styles
.
card
}
>
...
...
@@ -287,13 +294,13 @@ class Home extends React.Component {
{
/* <Text style={{ textAlign: 'center', fontSize: 12, }}>
{i18n.t('orderInfo')}
</Text> */
}
<
Text
style
=
{{
textAlign
:
'center'
,
fontSize
:
12
,
fontFamily
:
'Gotham-Black'
,
color
:
'#838383'
}}
>
<
Text
style
=
{{
textAlign
:
'center'
,
fontSize
:
12
,
fontFamily
:
'Gotham-Black'
,
color
:
'#838383'
}}
>
YOU
WILL
PICKUP
YOUR
ORDER
AT
<
/Text
>
{
this
.
state
.
indicator
==
true
?
(
<
ActivityIndicator
size
=
"small"
color
=
"#c9af6d"
/>
)
:
(
<
Text
style
=
{{
textAlign
:
"center"
,
fontSize
:
12
,
top
:
5
,
fontFamily
:
'Gotham-Light'
,
color
:
'#838383'
}}
>
<
Text
style
=
{{
textAlign
:
"center"
,
fontSize
:
12
,
top
:
5
,
fontFamily
:
'Gotham-Light'
,
color
:
'#838383'
}}
>
Excelso
{
this
.
props
.
name_outlet
}
<
/Text
>
)}
...
...
@@ -335,7 +342,7 @@ class Home extends React.Component {
{
/* <Text>
YOUR CARD NUMBER | {this.state.expire_date}
</Text> */
}
<
View
style
=
{{
flexDirection
:
'row'
,
flex
:
1
,
paddingBottom
:
5
}}
>
<
View
style
=
{{
flexDirection
:
'row'
,
flex
:
1
,
paddingBottom
:
5
}}
>
<
View
style
=
{{
flex
:
0.5
}}
>
<
Text
style
=
{{
fontSize
:
10
,
fontFamily
:
'Gotham-Light'
}}
>
YOUR
CARD
NUMBER
<
/Text
>
<
/View
>
...
...
@@ -360,8 +367,8 @@ class Home extends React.Component {
{
/* <Text>{i18n.t('balance')}</Text> */
}
<
Text
style
=
{{
fontSize
:
14
,
fontFamily
:
'Gotham-Light'
}}
>
BALANCE
<
/Text
>
<
/View
>
<
View
style
=
{{
flex
:
0.7
,
alignItems
:
'center'
}}
>
<
Text
style
=
{{
fontSize
:
14
,
fontFamily
:
'Gotham-Black'
,
color
:
'gray'
}}
>
IDR
{
this
.
state
.
balance
}
<
/Text
>
<
View
style
=
{{
flex
:
0.7
,
alignItems
:
'center'
}}
>
<
Text
style
=
{{
fontSize
:
14
,
fontFamily
:
'Gotham-Black'
,
color
:
'gray'
}}
>
IDR
{
this
.
state
.
balance
}
<
/Text
>
<
/View
>
<
/View
>
...
...
@@ -375,8 +382,8 @@ class Home extends React.Component {
{
/* <Text>{i18n.t('balance')}</Text> */
}
<
Text
style
=
{{
fontSize
:
14
,
fontFamily
:
'Gotham-Light'
}}
>
POINTS
<
/Text
>
<
/View
>
<
View
style
=
{{
flex
:
0.7
,
alignItems
:
'center'
}}
>
<
Text
style
=
{{
fontSize
:
14
,
fontFamily
:
'Gotham-Black'
,
color
:
'gray'
}}
>
IDR
{
this
.
state
.
point
}
<
/Text
>
<
View
style
=
{{
flex
:
0.7
,
alignItems
:
'center'
}}
>
<
Text
style
=
{{
fontSize
:
14
,
fontFamily
:
'Gotham-Black'
,
color
:
'gray'
}}
>
IDR
{
this
.
state
.
point
}
<
/Text
>
<
/View
>
<
/View
>
<
/Card
>
...
...
@@ -389,14 +396,14 @@ class Home extends React.Component {
// style={styles.submitUpgradePemium}
activeOpacity
=
{.
5
}
onPress
=
{()
=>
this
.
props
.
navigation
.
navigate
(
'TopUpInfo'
)}
>
<
View
style
=
{
styles
.
topUseBalance
}
>
<
Text
style
=
{{
textAlign
:
'center'
,
color
:
'white'
,
fontFamily
:
'Gotham-Black'
,
fontSize
:
1
6
}}
>
TOP
BALANCE
<
/Text
>
<
Text
style
=
{{
textAlign
:
'center'
,
color
:
'white'
,
fontFamily
:
'Gotham-Black'
,
fontSize
:
1
5
}}
>
TOP
BALANCE
<
/Text
>
<
/View
>
<
/TouchableOpacity
>
<
TouchableOpacity
// style={styles.submitUpgradePemium}
activeOpacity
=
{.
5
}
onPress
=
{()
=>
this
.
_useBalance
()}
>
<
View
style
=
{
styles
.
topUseBalance
}
>
<
Text
style
=
{{
textAlign
:
'center'
,
color
:
'white'
,
fontFamily
:
'Gotham-Black'
,
fontSize
:
1
6
}}
>
USE
BALANCE
<
/Text
>
<
Text
style
=
{{
textAlign
:
'center'
,
color
:
'white'
,
fontFamily
:
'Gotham-Black'
,
fontSize
:
1
5
}}
>
USE
BALANCE
<
/Text
>
<
/View
>
<
/TouchableOpacity
>
<
/View
>
...
...
@@ -439,8 +446,8 @@ const styles = StyleSheet.create({
alignItems
:
'center'
},
buttonDelivery
:
{
justifyContent
:
'center'
,
height
:
40
,
justifyContent
:
'center'
,
height
:
40
,
marginTop
:
10
,
paddingTop
:
15
,
paddingBottom
:
15
,
...
...
@@ -454,7 +461,7 @@ const styles = StyleSheet.create({
top
:
-
20
,
},
buttonPickup
:
{
justifyContent
:
'center'
,
justifyContent
:
'center'
,
height
:
40
,
marginTop
:
10
,
paddingTop
:
15
,
...
...
@@ -470,9 +477,9 @@ const styles = StyleSheet.create({
},
submitOrder
:
{
height
:
40
,
height
:
40
,
margin
:
10
,
paddingTop
:
10
,
paddingTop
:
10
,
backgroundColor
:
'#CFB368'
,
borderRadius
:
10
,
borderWidth
:
0
,
...
...
@@ -481,10 +488,10 @@ const styles = StyleSheet.create({
topUseBalance
:
{
flex
:
0.5
,
height
:
40
,
height
:
40
,
backgroundColor
:
'green'
,
top
:
20
,
margin
:
5
,
margin
:
5
,
padding
:
10
,
paddingHorizontal
:
15
,
borderRadius
:
10
,
...
...
view/MenuConfirmation.js
View file @
31d8beef
...
...
@@ -117,7 +117,8 @@ class MenuConfirmation extends React.Component {
}).
catch
(
error
=>
{
console
.
log
(
error
.
response
)
if
(
error
.
response
.
status
<=
500
)
{
Alert
.
alert
(
String
(
error
.
response
.
status
),
'Internal Server Error'
)
let
response
=
error
.
response
.
data
;
Alert
.
alert
(
''
,
response
.
msg
);
}
else
{
let
response
=
error
.
response
.
data
;
Alert
.
alert
(
''
,
response
.
msg
);
...
...
view/MenuSelection.js
View file @
31d8beef
...
...
@@ -353,6 +353,7 @@ const styles = StyleSheet.create({
container
:
{
flex
:
1
,
backgroundColor
:
'white'
,
},
// shadow: {
...
...
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