Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
N
new_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
new_excelso
Commits
2ff5f384
Commit
2ff5f384
authored
Aug 20, 2020
by
Trisno
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change base url to production
parent
9d2f043b
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
46 additions
and
25 deletions
+46
-25
App.js
App.js
+2
-2
globalReducer.js
redux/globalReducer.js
+1
-1
ChangeEmail.js
view/ChangeEmail.js
+3
-2
Home.js
view/Home.js
+1
-1
NewPassword.js
view/NewPassword.js
+3
-2
NewsDetail.js
view/NewsDetail.js
+15
-2
OutletDetails.js
view/OutletDetails.js
+2
-1
PaymentCode.js
view/PaymentCode.js
+4
-3
PrivacyStatement.js
view/PrivacyStatement.js
+2
-1
RatingOrder.js
view/RatingOrder.js
+3
-2
RedeemCode.js
view/RedeemCode.js
+1
-1
RewardSelect.js
view/RewardSelect.js
+2
-2
TransactionDetail.js
view/TransactionDetail.js
+2
-1
UpgradePremium.js
view/UpgradePremium.js
+5
-4
No files found.
App.js
View file @
2ff5f384
...
...
@@ -80,8 +80,8 @@ export default function App() {
}
const
handleNotification
=
notification
=>
{
//
console.log('Notification Origin : ' + JSON.stringify(notification.origin))
//
console.log('Notification Payload Data : ' + JSON.stringify(notification.data))
console
.
log
(
'Notification Origin : '
+
JSON
.
stringify
(
notification
.
origin
))
console
.
log
(
'Notification Payload Data : '
+
JSON
.
stringify
(
notification
.
data
))
const
origin
=
notification
.
origin
;
const
data
=
notification
.
data
;
...
...
redux/globalReducer.js
View file @
2ff5f384
...
...
@@ -93,7 +93,7 @@ const globalState = {
card_number
:
""
,
BASE_URL
:
'https://excelsocrm
.ravintoladev
.com/'
,
BASE_URL
:
'https://excelsocrm
2.ravintolasky
.com/'
,
kaspro_account_number
:
''
,
is_expired_date
:
true
,
...
...
view/ChangeEmail.js
View file @
2ff5f384
...
...
@@ -28,7 +28,7 @@ class ChangeEmail extends React.Component {
"registration_id"
:
this
.
props
.
registration_id
}
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/auth/register_change_email'
,
paramater
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/auth/register_change_email'
,
paramater
).
then
(
res
=>
{
// console.log(res);
let
loginProps
=
{
email
:
this
.
state
.
email
...
...
@@ -181,7 +181,8 @@ const mapDispatchToProps = (dispacth) => {
}
const
mapStateToProps
=
(
state
)
=>
{
return
{
registration_id
:
state
.
registration_id
registration_id
:
state
.
registration_id
,
BASE_URL
:
state
.
BASE_URL
,
}
}
...
...
view/Home.js
View file @
2ff5f384
...
...
@@ -90,7 +90,7 @@ class Home extends React.Component {
let
params
=
Object
.
assign
(
requestParams
,
{
session_id
:
this
.
props
.
session_id
,
})
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/inbox/unread_count'
,
params
).
then
(
respon
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/inbox/unread_count'
,
params
).
then
(
respon
=>
{
let
res
=
respon
.
data
.
unread_count
this
.
setState
({
...
...
view/NewPassword.js
View file @
2ff5f384
...
...
@@ -85,7 +85,7 @@ class NewPassword extends React.Component {
'password_confirmation'
:
this
.
state
.
password_confirmation
}
// console.log(params);
Axios
.
post
(
BASE_URL_NEW_PASSWORD
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'crm/v2/auth/reset_password'
,
params
).
then
(
res
=>
{
let
isSubmit
=
{
isSubmitResetPassword
:
false
}
...
...
@@ -204,7 +204,8 @@ const mapStateToProps = (state) => {
console
.
log
(
JSON
.
stringify
(
state
))
return
{
email
:
state
.
email
,
isSubmitResetPassword
:
state
.
isSubmitResetPassword
isSubmitResetPassword
:
state
.
isSubmitResetPassword
,
BASE_URL
:
state
.
BASE_URL
,
}
}
...
...
view/NewsDetail.js
View file @
2ff5f384
...
...
@@ -2,11 +2,13 @@ import React from 'react';
import
{
View
,
Text
,
StyleSheet
,
Dimensions
,
Alert
}
from
'react-native'
;
import
{
Image
}
from
'react-native-elements'
;
import
Axios
from
'axios'
;
import
{
connect
}
from
'react-redux'
;
import
{
TouchableOpacity
,
ScrollView
}
from
'react-native-gesture-handler'
;
import
HTML
from
'react-native-render-html'
;
import
{
getStatusBarHeight
}
from
'react-native-status-bar-height'
;
import
MyStatusBar
from
'./MyStatusBar'
;
export
default
class
NewsDetail
extends
React
.
Component
{
class
NewsDetail
extends
React
.
Component
{
constructor
(
props
)
{
super
(
props
);
this
.
state
=
{
...
...
@@ -36,7 +38,7 @@ export default class NewsDetail extends React.Component {
get_news_detail
(
slug
)
{
try
{
Axios
.
get
(
'https://excelsocrm.ravintoladev.com/
cms/v2/detail/'
+
slug
).
then
(
res
=>
{
Axios
.
get
(
this
.
props
.
BASE_URL
+
'
cms/v2/detail/'
+
slug
).
then
(
res
=>
{
const
detail
=
res
.
data
;
this
.
setState
({
title
:
detail
.
title
,
...
...
@@ -130,3 +132,14 @@ const styles = StyleSheet.create({
}
})
const
mapStateToProps
=
(
state
)
=>
{
return
{
session_id
:
state
.
session_id
,
language
:
state
.
language
,
BASE_URL
:
state
.
BASE_URL
,
}
}
export
default
connect
(
mapStateToProps
)(
NewsDetail
);
\ No newline at end of file
view/OutletDetails.js
View file @
2ff5f384
...
...
@@ -32,7 +32,7 @@ class OutletDetail extends React.Component {
}
// console.log("INI PARAMETERNYA" + JSON.stringify(params))
Axios
.
post
(
"https://excelsocrm.ravintoladev.com/
crm/v2/outlet/get_detail"
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
"
crm/v2/outlet/get_detail"
,
params
).
then
(
res
=>
{
let
data_details
=
res
.
data
.
outlet
let
lat
=
data_details
.
lat
let
long
=
data_details
.
long
...
...
@@ -116,6 +116,7 @@ const mapStateToProps = (state) => {
session_id
:
state
.
session_id
,
outlet_id
:
state
.
outlet_id
,
name_outlet
:
state
.
name_outlet
,
BASE_URL
:
state
.
BASE_URL
,
}
}
...
...
view/PaymentCode.js
View file @
2ff5f384
...
...
@@ -28,7 +28,7 @@ class PaymentCode extends React.Component {
session_id
:
this
.
props
.
session_id
}
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/member/get_profile'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/member/get_profile'
,
params
).
then
(
res
=>
{
// console.log('INI RESPONNYA : ' + JSON.stringify(res.data))
const
dataCard
=
res
.
data
...
...
@@ -62,7 +62,7 @@ class PaymentCode extends React.Component {
}
Axios
.
post
(
'http://excelsocrm.ravintoladev.com/
crm/v2/point/redeem'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/point/redeem'
,
params
).
then
(
res
=>
{
Alert
.
alert
(
''
,
i18n
.
t
(
'successRedeem'
))
}).
catch
(
error
=>
{
let
response
=
error
.
response
.
data
;
...
...
@@ -148,7 +148,8 @@ const mapStateToProps = (state) => {
return
{
session_id
:
state
.
session_id
,
language
:
state
.
language
,
pageEmailConfirmation
:
state
.
pageEmailConfirmation
pageEmailConfirmation
:
state
.
pageEmailConfirmation
,
BASE_URL
:
state
.
BASE_URL
,
}
}
...
...
view/PrivacyStatement.js
View file @
2ff5f384
...
...
@@ -29,7 +29,7 @@ class PrivacyStatement extends React.Component {
getPrivacyStatement
()
{
try
{
Axios
.
get
(
'https://excelsocrm.ravintoladev.com/
cms/v2/detail/privacy-statement'
).
then
(
res
=>
{
Axios
.
get
(
this
.
props
.
BASE_URL
+
'
cms/v2/detail/privacy-statement'
).
then
(
res
=>
{
// console.log('ini res data nya : ' + JSON.stringify(res.data))
const
respon
=
res
.
data
this
.
setState
({
...
...
@@ -147,6 +147,7 @@ const styles = StyleSheet.create({
const
mapStateToProps
=
(
state
)
=>
{
return
{
language
:
state
.
language
,
BASE_URL
:
state
.
BASE_URL
,
}
}
...
...
view/RatingOrder.js
View file @
2ff5f384
...
...
@@ -37,7 +37,7 @@ class RatingOrder extends React.Component {
transaction_id
:
this
.
props
.
route
.
params
.
idTrans
}
// console.log("PARAMETER : " + JSON.stringify(params))
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/transaction/detail'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/transaction/detail'
,
params
).
then
(
res
=>
{
let
data
=
res
.
data
// console.log('ini data' + JSON.stringify(data))
// console.log("INI OUTLET "+ data.outlet)
...
...
@@ -88,7 +88,7 @@ class RatingOrder extends React.Component {
Alert
.
alert
(
''
,
i18n
.
t
(
'reviewMustFill'
));
}
else
{
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/review/transaction'
,
parameter
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/review/transaction'
,
parameter
).
then
(
res
=>
{
Alert
.
alert
(
''
,
i18n
.
t
(
'thanksForReview'
))
this
.
props
.
navigation
.
navigate
(
'Home'
);
...
...
@@ -198,6 +198,7 @@ const mapStateToProps = (state) => {
session_id
:
state
.
session_id
,
lat
:
state
.
lat
,
long
:
state
.
long
,
BASE_URL
:
state
.
BASE_URL
,
}
}
...
...
view/RedeemCode.js
View file @
2ff5f384
...
...
@@ -57,7 +57,7 @@ class RedeemCode extends React.Component {
session_id
:
this
.
props
.
session_id
,
}
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/point/refund'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/point/refund'
,
params
).
then
(
res
=>
{
console
.
log
(
res
.
data
)
let
redeemProps
=
{
...
...
view/RewardSelect.js
View file @
2ff5f384
...
...
@@ -46,7 +46,7 @@ class RewardSelect extends React.Component {
session_id
:
this
.
props
.
session_id
,
reward_id
:
item
.
id
})
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/reward/get_detail'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/reward/get_detail'
,
params
).
then
(
res
=>
{
// console.log(res.data.reward)
let
detail
=
res
.
data
.
reward
let
voucherProps
=
{
...
...
@@ -67,7 +67,7 @@ class RewardSelect extends React.Component {
let
params
=
Object
.
assign
(
requestParams
,{
session_id
:
this
.
props
.
session_id
,
})
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/reward/get_list'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/reward/get_list'
,
params
).
then
(
res
=>
{
let
data
=
res
.
data
.
rewards
// console.log(data)
data
.
map
((
item
,
key
)
=>
{
...
...
view/TransactionDetail.js
View file @
2ff5f384
...
...
@@ -38,7 +38,7 @@ class TransactionDetail extends React.Component {
session_id
:
this
.
props
.
session_id
,
transaction_id
:
this
.
props
.
route
.
params
.
idTrans
}
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/transaction/detail'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/transaction/detail'
,
params
).
then
(
res
=>
{
// console.log("INI DATA NYA LHOOOOO ......." + JSON.stringify(res.data))
let
data
=
res
.
data
// console.log(data)
...
...
@@ -306,6 +306,7 @@ const mapStateToProps = (state) => {
return
{
session_id
:
state
.
session_id
,
BASE_URL
:
state
.
BASE_URL
}
}
...
...
view/UpgradePremium.js
View file @
2ff5f384
...
...
@@ -93,7 +93,7 @@ class UpgradePremium extends React.Component {
let
params
=
{
session_id
:
this
.
props
.
session_id
}
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/member/get_profile'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/member/get_profile'
,
params
).
then
(
res
=>
{
let
data
=
res
.
data
this
.
setState
({
birthDate
:
data
.
dob_day
+
"-"
+
data
.
dob_month
+
"-"
+
data
.
dob_year
,
...
...
@@ -106,7 +106,7 @@ class UpgradePremium extends React.Component {
}
getProvince
()
{
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/member/get_province'
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/member/get_province'
).
then
(
res
=>
{
let
dataProv
=
res
.
data
.
data
// console.log('ini res nya prov : ' + JSON.stringify(dataProv))
let
list_prov
=
[]
...
...
@@ -168,7 +168,7 @@ class UpgradePremium extends React.Component {
}
// console.log(params.customer_image);
Axios
.
post
(
'https://excelsocrm.ravintoladev.com/
crm/v2/card/upgrade_premium'
,
params
).
then
(
res
=>
{
Axios
.
post
(
this
.
props
.
BASE_URL
+
'
crm/v2/card/upgrade_premium'
,
params
).
then
(
res
=>
{
// console.log('ini res ' + JSON.stringify(res.data))
Alert
.
alert
(
''
,
...
...
@@ -502,7 +502,8 @@ const mapStateToProps = (state) => {
BASE64_ID
:
state
.
BASE64_ID
,
BASE64_SELFIE
:
state
.
BASE64_SELFIE
,
img64
:
state
.
img64
,
id_card64
:
state
.
id_card64
id_card64
:
state
.
id_card64
,
BASE_URL
:
state
.
BASE_URL
}
}
...
...
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