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
082d4d54
Commit
082d4d54
authored
Jun 23, 2020
by
Trisno
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update inbox
parent
e2b50a72
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
4 deletions
+16
-4
InboxDetail.js
view/InboxDetail.js
+1
-1
InboxList.js
view/InboxList.js
+15
-3
No files found.
view/InboxDetail.js
View file @
082d4d54
...
...
@@ -120,7 +120,7 @@ class InboxDetail extends React.Component {
<
AntDesign
name
=
"arrowleft"
size
=
{
22
}
color
=
"white"
/>
<
/TouchableOpacity
>
<
/View
>
<
View
style
=
{{
flex
:
0.8
,
alignItems
:
'
flex-end
'
}}
>
<
View
style
=
{{
flex
:
0.8
,
alignItems
:
'
center
'
}}
>
<
Text
style
=
{{
fontSize
:
20
,
fontFamily
:
'Gotham-Black'
,
color
:
'white'
}}
>
{
i18n
.
t
(
'headerInboxDetail'
)}
<
/Text
>
<
/View
>
<
View
style
=
{{
margin
:
15
,
flex
:
0.1
,
alignItems
:
'flex-end'
}}
>
...
...
view/InboxList.js
View file @
082d4d54
import
React
from
'react'
;
import
{
View
,
Text
,
BackHandler
,
StyleSheet
,
ScrollView
,
Alert
,
TouchableOpacity
,
ActivityIndicator
}
from
'react-native'
;
import
{
View
,
Text
,
BackHandler
,
StyleSheet
,
ScrollView
,
Alert
,
TouchableOpacity
,
ActivityIndicator
,
RefreshControl
}
from
'react-native'
;
import
{
connect
}
from
'react-redux'
;
import
Axios
from
'axios'
;
import
i18n
from
'i18n-js'
;
...
...
@@ -13,7 +13,8 @@ class InboxList extends React.Component {
this
.
handleBackButtonClick
=
this
.
handleBackButtonClick
.
bind
(
this
)
this
.
state
=
{
inbox_list
:
[],
indicator
:
true
indicator
:
true
,
refreshing
:
false
}
}
...
...
@@ -39,6 +40,16 @@ class InboxList extends React.Component {
return
true
;
}
onRefresh
()
{
this
.
setState
({
refreshing
:
true
})
this
.
getInbox
()
this
.
setState
({
refreshing
:
false
})
}
getInbox
()
{
let
params
=
{
session_id
:
this
.
props
.
session_id
...
...
@@ -64,7 +75,8 @@ class InboxList extends React.Component {
render
()
{
return
(
<
View
style
=
{
styles
.
container
}
>
<
ScrollView
style
=
{
styles
.
body
}
>
<
ScrollView
style
=
{
styles
.
body
}
refreshControl
=
{
<
RefreshControl
refreshing
=
{
this
.
state
.
refreshing
}
onRefresh
=
{()
=>
this
.
onRefresh
()}
/>}
>
{
this
.
state
.
indicator
?
(
<
ActivityIndicator
style
=
{{
justifyContent
:
"center"
,
marginTop
:
100
}}
size
=
"large"
color
=
"#c9af6d"
/>
)
:
this
.
state
.
inbox_list
.
length
?
(
...
...
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