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
ccbdabcf
Commit
ccbdabcf
authored
Jul 08, 2020
by
Wahyu Adjie Prasetyo
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
ssh://repo.cs.co.id:2222/wahyu/bahanoprek
# Conflicts: # view/MenuSelection.js
parents
3cf8e64b
22df3b8c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
7 deletions
+18
-7
app.json
app.json
+1
-1
MenuSelection.js
view/MenuSelection.js
+1
-1
TopUpInfo.js
view/TopUpInfo.js
+16
-5
No files found.
app.json
View file @
ccbdabcf
{
{
"expo"
:
{
"expo"
:
{
"extra"
:
{
"extra"
:
{
"buildNumber"
:
"1
09
"
,
"buildNumber"
:
"1
13
"
,
"remarks"
:
""
"remarks"
:
""
},
},
...
...
view/MenuSelection.js
View file @
ccbdabcf
...
@@ -382,7 +382,7 @@ class MenuSelection extends React.Component {
...
@@ -382,7 +382,7 @@ class MenuSelection extends React.Component {
data
=
{
this
.
state
.
data_before_search
}
data
=
{
this
.
state
.
data_before_search
}
renderItem
=
{
this
.
renderItem
}
renderItem
=
{
this
.
renderItem
}
keyExtractor
=
{
item
=>
item
.
id
}
keyExtractor
=
{
item
=>
item
.
id
}
//
ref={(ref) => { this.flatListRef = ref; }}
ref
=
{(
ref
)
=>
{
this
.
flatListRef
=
ref
;
}}
initialNumToRender
=
{
5
}
initialNumToRender
=
{
5
}
maxToRenderPerBatch
=
{
10
}
maxToRenderPerBatch
=
{
10
}
windowSize
=
{
10
}
windowSize
=
{
10
}
...
...
view/TopUpInfo.js
View file @
ccbdabcf
import
Axios
from
'axios'
;
import
Axios
from
'axios'
;
import
React
from
'react'
;
import
React
from
'react'
;
import
{
ScrollView
,
StyleSheet
,
Text
,
View
,
Image
,
StatusBar
}
from
'react-native'
;
import
{
ScrollView
,
StyleSheet
,
Text
,
View
,
Image
,
StatusBar
,
Clipboard
}
from
'react-native'
;
import
{
TouchableOpacity
}
from
'react-native-gesture-handler'
;
import
{
TouchableOpacity
}
from
'react-native-gesture-handler'
;
import
HTML
from
'react-native-render-html'
;
import
HTML
from
'react-native-render-html'
;
import
{
Collapse
,
CollapseHeader
,
CollapseBody
,
AccordionList
}
from
'accordion-collapse-react-native'
import
{
Collapse
,
CollapseHeader
,
CollapseBody
,
AccordionList
}
from
'accordion-collapse-react-native'
import
{
getStatusBarHeight
}
from
'react-native-status-bar-height'
;
import
{
getStatusBarHeight
}
from
'react-native-status-bar-height'
;
import
MyStatusBar
from
'./MyStatusBar'
;
import
MyStatusBar
from
'./MyStatusBar'
;
import
{
connect
}
from
'react-redux'
;
import
{
connect
}
from
'react-redux'
;
import
Toast
from
'react-native-tiny-toast'
;
class
TopUpInfo
extends
React
.
Component
{
class
TopUpInfo
extends
React
.
Component
{
constructor
(
props
)
{
constructor
(
props
)
{
super
(
props
);
super
(
props
);
this
.
state
=
{
this
.
state
=
{
...
@@ -19,16 +20,20 @@ import { connect } from 'react-redux';
...
@@ -19,16 +20,20 @@ import { connect } from 'react-redux';
}
}
componentDidMount
()
{
componentDidMount
()
{
console
.
log
(
"ii"
+
this
.
props
.
BASE_URL
)
// console.log("ii" + this.props.BASE_URL)
// console.log(this.props.BASE_URL + 'cms/v2/topup-info/' + this.props.session_id)
const
statusBarHeight
=
getStatusBarHeight
();
const
statusBarHeight
=
getStatusBarHeight
();
this
.
setState
({
this
.
setState
({
statusbar_height
:
statusBarHeight
statusbar_height
:
statusBarHeight
})
})
Axios
.
get
(
this
.
props
.
BASE_URL
+
'cms/v2/list/topup-info'
).
then
(
res
=>
{
Axios
.
get
(
this
.
props
.
BASE_URL
+
'cms/v2/topup_info/'
+
this
.
props
.
session_id
).
then
(
res
=>
{
let
data
=
res
.
data
;
let
data
=
res
.
data
;
this
.
setState
({
this
.
setState
({
topup_info
:
data
.
contents
topup_info
:
data
.
contents
})
})
}).
catch
(
error
=>
{
let
response
=
error
.
response
.
data
;
console
.
log
(
response
.
msg
);
})
})
}
}
...
@@ -56,7 +61,13 @@ import { connect } from 'react-redux';
...
@@ -56,7 +61,13 @@ import { connect } from 'react-redux';
<
/View
>
<
/View
>
<
/CollapseHeader
>
<
/CollapseHeader
>
<
CollapseBody
style
=
{{
marginHorizontal
:
20
}}
>
<
CollapseBody
style
=
{{
marginHorizontal
:
20
}}
>
<
HTML
html
=
{
item
.
content
}
tagsStyles
=
{{
p
:
{
fontFamily
:
'Gotham-Light'
,
marginTop
:
8
,
marginBottom
:
8
,
color
:
'#adadad'
},
blockquote
:
{
backgroundColor
:
"#f1f1f1"
,
padding
:
12
,
paddingBottom
:
0
,
marginTop
:
6
,
color
:
'#adadad'
},
ul
:
{
fontFamily
:
'Gotham-Light'
,
marginLeft
:
0
,
color
:
'#adadad'
,
paddingLeft
:
0
},
li
:
{
fontFamily
:
'Gotham-Light'
,
marginLeft
:
0
,
color
:
'#adadad'
,
paddingLeft
:
0
}
}}
/
>
<
HTML
html
=
{
item
.
content
}
tagsStyles
=
{{
p
:
{
fontFamily
:
'Gotham-Light'
,
marginTop
:
8
,
marginBottom
:
8
,
color
:
'#adadad'
},
blockquote
:
{
backgroundColor
:
"#f1f1f1"
,
padding
:
12
,
paddingBottom
:
0
,
marginTop
:
6
,
color
:
'#adadad'
},
ul
:
{
fontFamily
:
'Gotham-Light'
,
marginLeft
:
0
,
color
:
'#adadad'
,
paddingLeft
:
0
},
li
:
{
fontFamily
:
'Gotham-Light'
,
marginLeft
:
0
,
color
:
'#adadad'
,
paddingLeft
:
0
}
}}
onLinkPress
=
{(
event
,
href
)
=>
{
// console.log(href.replace('http://',''))
Clipboard
.
setString
(
href
.
replace
(
'http://'
,
''
))
Toast
.
show
(
'Copied To Clipboard'
)
}}
/
>
<
/CollapseBody
>
<
/CollapseBody
>
<
/Collapse
>
<
/Collapse
>
<
/View
>
<
/View
>
...
...
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