Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Ad1Appraisal-Mobile
Project
Project
Details
Activity
Releases
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
Dida Adams Arizona
Ad1Appraisal-Mobile
Commits
943d3f1d
Commit
943d3f1d
authored
Mar 06, 2020
by
Deni Rinaldi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
list appraisal
parent
d8db4024
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
78 additions
and
42 deletions
+78
-42
history.js
app/container/history/history.js
+48
-18
appraisal.js
app/container/home/appraisal/appraisal.js
+30
-11
sampleMenuAppraisal.js
app/container/home/appraisal/sampleMenuAppraisal.js
+0
-13
No files found.
app/container/history/history.js
View file @
943d3f1d
...
@@ -5,6 +5,7 @@ import M from 'moment'
...
@@ -5,6 +5,7 @@ import M from 'moment'
import
SvgAnimatedLinearGradient
from
'react-native-svg-animated-linear-gradient'
import
SvgAnimatedLinearGradient
from
'react-native-svg-animated-linear-gradient'
import
Svg
,
{
Circle
,
Rect
}
from
'react-native-svg'
import
Svg
,
{
Circle
,
Rect
}
from
'react-native-svg'
import
Colors
from
'../../library/colors'
;
import
Colors
from
'../../library/colors'
;
import
MaterialIcons
from
'react-native-vector-icons/MaterialIcons'
const
dateNow
=
M
().
format
(
'DD-MM-YYYY'
)
const
dateNow
=
M
().
format
(
'DD-MM-YYYY'
)
...
@@ -13,24 +14,27 @@ class History extends Component {
...
@@ -13,24 +14,27 @@ class History extends Component {
super
(
props
)
super
(
props
)
this
.
state
=
{
this
.
state
=
{
data
:
[
data
:
[
{
jam
:
'17.30'
,
tanggal
:
M
().
format
(
'DD-MM-YYYY'
)
},
{
jam
:
'17.30'
,
tanggal
:
M
().
format
(
'DD-MM-YYYY'
)
,
noKontrak
:
'K-01239912'
},
{
jam
:
'17.30'
,
tanggal
:
'06-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'06-03-2020'
,
noKontrak
:
'K-01239913'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
,
noKontrak
:
'K-01239914'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
,
noKontrak
:
'K-01239915'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
,
noKontrak
:
'K-01239916'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'05-03-2020'
,
noKontrak
:
'K-01239917'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
,
noKontrak
:
'K-01239918'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
,
noKontrak
:
'K-01239919'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
,
noKontrak
:
'K-01239920'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
,
noKontrak
:
'K-01239921'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'04-03-2020'
,
noKontrak
:
'K-01239922'
},
{
jam
:
'17.30'
,
tanggal
:
'03-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'03-03-2020'
,
noKontrak
:
'K-01239923'
},
{
jam
:
'17.30'
,
tanggal
:
'03-03-2020'
},
{
jam
:
'17.30'
,
tanggal
:
'03-03-2020'
,
noKontrak
:
'K-01239924'
},
],
],
date
:
new
Date
(),
date
:
new
Date
(),
yesterday
:
''
,
yesterday
:
''
,
loading
:
true
,
loading
:
true
,
dataLoad
:
false
dataLoad
:
false
,
OrientationStatus
:
''
,
Height_Layout
:
''
,
Width_Layout
:
''
,
}
}
}
}
...
@@ -43,10 +47,28 @@ class History extends Component {
...
@@ -43,10 +47,28 @@ class History extends Component {
},
2000
);
},
2000
);
}
}
DetectOrientation
()
{
if
(
this
.
state
.
Width_Layout
>
this
.
state
.
Height_Layout
)
{
this
.
setState
({
OrientationStatus
:
'Landscape'
});
}
else
{
this
.
setState
({
OrientationStatus
:
'Portrait'
});
}
}
render
()
{
render
()
{
return
(
return
(
<
Container
>
<
Container
<
View
style
=
{{
height
:
'10%'
,
width
:
'100%'
,
backgroundColor
:
'#e4b300'
,
zIndex
:
1
}}
>
onLayout
=
{(
event
)
=>
this
.
setState
({
Width_Layout
:
event
.
nativeEvent
.
layout
.
width
,
Height_Layout
:
event
.
nativeEvent
.
layout
.
height
},
()
=>
this
.
DetectOrientation
())}
>
<
View
style
=
{
this
.
state
.
OrientationStatus
==
'Landscape'
?
{
width
:
'100%'
,
backgroundColor
:
'#e4b300'
,
zIndex
:
1
,
height
:
80
}
:
{
width
:
'100%'
,
backgroundColor
:
'#e4b300'
,
zIndex
:
1
,
height
:
'10%'
}}
>
<
View
style
=
{{
alignItems
:
'center'
,
justifyContent
:
'center'
,
marginTop
:
20
}}
>
<
View
style
=
{{
alignItems
:
'center'
,
justifyContent
:
'center'
,
marginTop
:
20
}}
>
<
Text
style
=
{{
fontWeight
:
'bold'
,
fontSize
:
20
,
fontStyle
:
'italic'
}}
>
My
History
<
/Text
>
<
Text
style
=
{{
fontWeight
:
'bold'
,
fontSize
:
20
,
fontStyle
:
'italic'
}}
>
My
History
<
/Text
>
<
/View
>
<
/View
>
...
@@ -57,13 +79,20 @@ class History extends Component {
...
@@ -57,13 +79,20 @@ class History extends Component {
<
View
style
=
{{
backgroundColor
:
'#f5f5f5'
,
paddingHorizontal
:
20
,
zIndex
:
3
,
height
:
'90%'
}}
>
<
View
style
=
{{
backgroundColor
:
'#f5f5f5'
,
paddingHorizontal
:
20
,
zIndex
:
3
,
height
:
'90%'
}}
>
<
ScrollView
style
=
{
{
flex
:
1
}}
showsVerticalScrollIndicator
=
{
false
}
>
<
ScrollView
style
=
{
this
.
state
.
OrientationStatus
==
'Landscape'
?
{
flex
:
1
,
marginBottom
:
40
}
:
{
flex
:
1
}}
showsVerticalScrollIndicator
=
{
false
}
>
{
this
.
state
.
data
.
map
((
item
,
index
)
=>
{
{
this
.
state
.
data
.
map
((
item
,
index
)
=>
{
return
(
return
(
<
View
>
<
View
>
{
this
.
state
.
dataLoad
&&
(
{
this
.
state
.
dataLoad
&&
(
<
View
style
=
{{
marginTop
:
index
==
0
?
40
:
20
,
marginBottom
:
index
==
this
.
state
.
data
.
length
-
1
?
20
:
0
,
height
:
120
}}
>
<
View
style
=
{{
marginTop
:
index
==
0
?
40
:
20
,
marginBottom
:
index
==
this
.
state
.
data
.
length
-
1
?
20
:
0
,
height
:
120
}}
>
<
View
style
=
{{
width
:
'100%'
,
height
:
100
,
backgroundColor
:
'#fff'
,
borderRadius
:
10
}}
>
<
View
style
=
{{
width
:
'100%'
,
height
:
100
,
backgroundColor
:
'#fff'
,
borderRadius
:
10
,
padding
:
10
,
flexDirection
:
'row'
}}
>
<
View
style
=
{{
width
:
'70%'
}}
>
<
Text
style
=
{{
fontWeight
:
'700'
,
fontSize
:
16
}}
>
{
item
.
noKontrak
}
<
/Text
>
<
/View
>
<
View
style
=
{{
width
:
'30%'
,
justifyContent
:
'flex-end'
,
alignSelf
:
'center'
,
flexDirection
:
'row'
}}
>
<
Text
style
=
{{
color
:
'#e4b300'
}}
>
Detail
<
/Text
>
<
MaterialIcons
name
=
"navigate-next"
size
=
{
20
}
color
=
{
'#e4b300'
}
/
>
<
/View
>
<
/View
>
<
/View
>
<
Text
style
=
{{
textAlign
:
'right'
,
fontStyle
:
'italic'
,
fontSize
:
12
,
marginTop
:
5
,
color
:
'#cccccc'
}}
>
{
item
.
tanggal
==
String
(
dateNow
)
?
item
.
jam
:
item
.
tanggal
==
this
.
state
.
yesterday
?
'yesterday'
:
item
.
tanggal
}
<
/Text
>
<
Text
style
=
{{
textAlign
:
'right'
,
fontStyle
:
'italic'
,
fontSize
:
12
,
marginTop
:
5
,
color
:
'#cccccc'
}}
>
{
item
.
tanggal
==
String
(
dateNow
)
?
item
.
jam
:
item
.
tanggal
==
this
.
state
.
yesterday
?
'yesterday'
:
item
.
tanggal
}
<
/Text
>
<
/View
>
<
/View
>
...
@@ -74,6 +103,7 @@ class History extends Component {
...
@@ -74,6 +103,7 @@ class History extends Component {
borderRadius
=
{
200
}
borderRadius
=
{
200
}
marginTop
=
{
10
}
marginTop
=
{
10
}
width
=
{
'100%'
}
width
=
{
'100%'
}
duration
=
{
800
}
>
>
<
Rect
x
=
"0"
y
=
"30"
rx
=
"5"
ry
=
"1"
width
=
"1000"
height
=
"100"
/>
<
Rect
x
=
"0"
y
=
"30"
rx
=
"5"
ry
=
"1"
width
=
"1000"
height
=
"100"
/>
<
/SvgAnimatedLinearGradient
>
<
/SvgAnimatedLinearGradient
>
...
...
app/container/home/appraisal/appraisal.js
View file @
943d3f1d
...
@@ -9,8 +9,8 @@ export default class Appraisal extends Component {
...
@@ -9,8 +9,8 @@ export default class Appraisal extends Component {
super
(
props
)
super
(
props
)
this
.
state
=
{
this
.
state
=
{
arrayDummy
:
[
arrayDummy
:
[
{
noKontrak
:
'K-2001920'
,
namaWerehouse
:
'Branch-2'
,
petugas
:
'Dadang
'
,
tglTerima
:
'03-03-2020'
,
status
:
'Draft
'
},
{
noKontrak
:
'K-2001920'
,
namaWerehouse
:
'Branch-2'
,
petugas
:
'Dadang
Tukimin'
,
tglTerima
:
'03-03-2020'
,
status
:
'Draft'
,
brand
:
'Honda'
,
type
:
'Revo'
,
noPol
:
'B 4203 PWK
'
},
{
noKontrak
:
'K-2001921'
,
namaWerehouse
:
'Branch-1'
,
petugas
:
'Dudung
'
,
tglTerima
:
'03-03-2020'
,
status
:
'Need Approval
'
},
{
noKontrak
:
'K-2001921'
,
namaWerehouse
:
'Branch-1'
,
petugas
:
'Dudung
Tukimin'
,
tglTerima
:
'03-03-2020'
,
status
:
'Need Approval'
,
brand
:
'Honda'
,
type
:
'Beat'
,
noPol
:
'B 4203 STW
'
},
]
]
}
}
}
}
...
@@ -21,7 +21,30 @@ export default class Appraisal extends Component {
...
@@ -21,7 +21,30 @@ export default class Appraisal extends Component {
{
this
.
state
.
arrayDummy
.
map
((
item
,
index
)
=>
{
{
this
.
state
.
arrayDummy
.
map
((
item
,
index
)
=>
{
return
(
return
(
<
View
key
=
{
index
}
style
=
{{
paddingHorizontal
:
7
}}
>
<
View
key
=
{
index
}
style
=
{{
paddingHorizontal
:
7
}}
>
<
TouchableOpacity
style
=
{{
width
:
'100%'
,
backgroundColor
:
'#FFFFFF'
,
borderRadius
:
15
,
paddingHorizontal
:
10
,
shadowRadius
:
80
,
paddingVertical
:
10
,
marginTop
:
10
}}
onPress
=
{()
=>
this
.
props
.
navigation
.
navigate
(
'MenuAppraisal'
)}
>
<
TouchableOpacity
style
=
{{
marginTop
:
10
,
borderRadius
:
20
}}
onPress
=
{()
=>
this
.
props
.
navigation
.
navigate
(
'MenuAppraisal'
)}
>
<
View
style
=
{{
height
:
60
,
backgroundColor
:
'#e4b300'
,
justifyContent
:
'space-between'
,
paddingHorizontal
:
20
,
flexDirection
:
'row'
,
borderTopRightRadius
:
10
,
borderTopLeftRadius
:
10
}}
>
<
View
style
=
{{
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
color
:
'white'
,
fontSize
:
16
,
fontWeight
:
'700'
}}
>
{
item
.
noKontrak
}
<
/Text
>
<
Text
style
=
{{
color
:
'white'
,
fontSize
:
14
}}
>
{
item
.
petugas
}
<
/Text
>
<
/View
>
<
View
style
=
{{
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
color
:
'white'
,
fontSize
:
14
,
textAlign
:
'center'
}}
>
{
item
.
namaWerehouse
}
<
/Text
>
<
/View
>
<
/View
>
<
View
style
=
{{
height
:
60
,
backgroundColor
:
'#E6E6E6'
,
justifyContent
:
'space-between'
,
paddingHorizontal
:
20
,
flexDirection
:
'row'
,
borderBottomRightRadius
:
10
,
borderBottomLeftRadius
:
10
}}
>
<
View
style
=
{{
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
color
:
'black'
,
fontSize
:
14
}}
>
{
item
.
brand
}
-
{
item
.
type
}
<
/Text
>
<
Text
style
=
{{
color
:
'black'
,
fontSize
:
14
}}
>
{
item
.
noPol
}
<
/Text
>
<
/View
>
<
View
style
=
{{
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
color
:
'black'
,
fontSize
:
14
,
textAlign
:
'center'
}}
>
{
item
.
status
}
<
/Text
>
<
/View
>
<
/View
>
{
/* <View style={{ backgroundColor: '#E6E6E6', borderBottomRightRadius: 10, borderBottomLeftRadius: 10, justifyContent: 'center', paddingHorizontal: 20, paddingVertical: 10, borderTopWidth: .7, borderTopColor: 'black' }}>
</View> */
}
<
/TouchableOpacity
>
{
/* <TouchableOpacity style={{ width: '100%', backgroundColor: '#FFFFFF', borderRadius: 15, paddingHorizontal: 10, shadowRadius: 80, paddingVertical: 10, marginTop: 10 }} onPress={() => this.props.navigation.navigate('MenuAppraisal')}>
<View style={{ width: 120, height: 20, backgroundColor: 'black', marginLeft: -20, marginTop: 5, borderTopRightRadius: 5, borderBottomRightRadius: 5 }}>
<View style={{ width: 120, height: 20, backgroundColor: 'black', marginLeft: -20, marginTop: 5, borderTopRightRadius: 5, borderBottomRightRadius: 5 }}>
<Text style={{ color: 'white', textAlign: 'center' }}>{item.status}</Text>
<Text style={{ color: 'white', textAlign: 'center' }}>{item.status}</Text>
</View>
</View>
...
@@ -40,25 +63,21 @@ export default class Appraisal extends Component {
...
@@ -40,25 +63,21 @@ export default class Appraisal extends Component {
borderLeftColor: 'transparent',
borderLeftColor: 'transparent',
}} />
}} />
<View style={{ flexDirection: 'row' }}>
<View style={{ flexDirection: 'row' }}>
<
View
style
=
{{
width
:
'80%'
}}
>
<View style={{ width: '80%' }}>
{
/* <View style={{ flexDirection: 'row', width: '100%', backgroundColor: 'red' }}> */
}
<View style={{ flexDirection: 'row', justifyContent: 'space-between' }}>
<View style={{ flexDirection: 'row', justifyContent: 'space-between' }}>
<Text style={{ alignSelf: 'center', fontSize: 16, fontWeight: 'bold' }}>{item.noKontrak}</Text>
<Text style={{ alignSelf: 'center', fontSize: 16, fontWeight: 'bold' }}>{item.noKontrak}</Text>
<Text style={{ alignSelf: 'center', fontSize: 14 }}>{item.namaWerehouse}</Text>
<Text style={{ alignSelf: 'center', fontSize: 14 }}>{item.namaWerehouse}</Text>
<
/View
>
</View>
{
/* </View> */
}
{
/* <View style={{ flexDirection: 'row', justifyContent: 'space-between' }}> */
}
<View style={{ flexDirection: 'row', justifyContent: 'space-between' }}>
<View style={{ flexDirection: 'row', justifyContent: 'space-between' }}>
<Text style={{ alignSelf: 'center', fontSize: 14 }}>{item.tglTerima}</Text>
<Text style={{ alignSelf: 'center', fontSize: 14 }}>{item.tglTerima}</Text>
<Text style={{ alignSelf: 'center', fontSize: 14 }}>{item.petugas}</Text>
<Text style={{ alignSelf: 'center', fontSize: 14 }}>{item.petugas}</Text>
<
/View
>
</View>
{
/* </View> */
}
</View>
</View>
<View style={{ justifyContent: 'center', width: '20%', alignItems: 'flex-end' }}>
<View style={{ justifyContent: 'center', width: '20%', alignItems: 'flex-end' }}>
<Next name="navigate-next" size={26} />
<Next name="navigate-next" size={26} />
</View>
</View>
</View>
</View>
<
/TouchableOpacity
>
</TouchableOpacity>
*/
}
<
/View
>
<
/View
>
)
)
})}
})}
...
...
app/container/home/appraisal/sampleMenuAppraisal.js
View file @
943d3f1d
...
@@ -808,19 +808,6 @@ export default class sampleMenuAppraisal extends Component {
...
@@ -808,19 +808,6 @@ export default class sampleMenuAppraisal extends Component {
/>
/>
<
/View
>
<
/View
>
<
/View
>
<
/View
>
<
View
style
=
{{
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingVertical
:
2.5
}}
>
<
View
style
=
{{
justifyContent
:
'center'
,
width
:
'45%'
}}
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Nilai
Pembanding
Rekondisi
<
/Text
>
<
/View
>
<
View
style
=
{
styles
.
viewInputEnable
}
>
<
TextInput
onChangeText
=
{(
e
)
=>
this
.
setState
({
namaRemote
:
e
})}
style
=
{
styles
.
textInput
}
value
=
{
this
.
state
.
namaRemote
}
editable
/>
<
/View
>
<
/View
>
<
View
style
=
{{
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingVertical
:
2.5
}}
>
<
View
style
=
{{
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingVertical
:
2.5
}}
>
<
View
style
=
{{
justifyContent
:
'center'
,
width
:
'45%'
}}
>
<
View
style
=
{{
justifyContent
:
'center'
,
width
:
'45%'
}}
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Pokok
Pembiayaan
<
/Text
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Pokok
Pembiayaan
<
/Text
>
...
...
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