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
6b1962f4
Commit
6b1962f4
authored
Mar 09, 2020
by
didam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
didam
parent
b5d200fd
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
121 additions
and
70 deletions
+121
-70
history.js
app/container/history/history.js
+5
-1
sampleMenuApproval2.js
app/container/home/approval/sampleMenuApproval2.js
+33
-47
sampleMenuApproval3.js
app/container/home/approval/sampleMenuApproval3.js
+58
-15
penerimaan.js
app/container/home/penerimaan/penerimaan.js
+4
-1
sampleMenuPenerimaan2.js
app/container/home/penerimaan/sampleMenuPenerimaan2.js
+2
-2
sampleMenuPenerimaan3.js
app/container/home/penerimaan/sampleMenuPenerimaan3.js
+12
-1
profile.js
app/container/profile/profile.js
+7
-3
No files found.
app/container/history/history.js
View file @
6b1962f4
...
@@ -10,6 +10,7 @@ import fonts from '../../library/fonts';
...
@@ -10,6 +10,7 @@ import fonts from '../../library/fonts';
import
api
from
'../../service/api'
;
import
api
from
'../../service/api'
;
import
reactotron
from
'reactotron-react-native'
;
import
reactotron
from
'reactotron-react-native'
;
import
moment
from
'moment'
;
import
moment
from
'moment'
;
import
{
NavigationEvents
}
from
'react-navigation'
;
const
dateNow
=
M
().
format
(
'DD-MM-YYYY'
)
const
dateNow
=
M
().
format
(
'DD-MM-YYYY'
)
...
@@ -121,7 +122,10 @@ class History extends Component {
...
@@ -121,7 +122,10 @@ class History extends Component {
onLayout
=
{(
event
)
=>
this
.
setState
({
onLayout
=
{(
event
)
=>
this
.
setState
({
Width_Layout
:
event
.
nativeEvent
.
layout
.
width
,
Width_Layout
:
event
.
nativeEvent
.
layout
.
width
,
Height_Layout
:
event
.
nativeEvent
.
layout
.
height
Height_Layout
:
event
.
nativeEvent
.
layout
.
height
},
()
=>
this
.
DetectOrientation
())}
>
},
()
=>
this
.
DetectOrientation
())}
>
<
NavigationEvents
onDidFocus
=
{()
=>
this
.
getHistory
()}
/>
<
View
style
=
{
this
.
state
.
OrientationStatus
==
'Landscape'
?
{
width
:
'100%'
,
backgroundColor
:
'#e4b300'
,
zIndex
:
1
,
height
:
80
}
:
{
width
:
'100%'
,
backgroundColor
:
'#e4b300'
,
zIndex
:
1
,
height
:
'10%'
}}
>
<
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
>
...
...
app/container/home/approval/sampleMenuApproval2.js
View file @
6b1962f4
...
@@ -10,6 +10,7 @@ import AwesomeButton from "react-native-really-awesome-button";
...
@@ -10,6 +10,7 @@ import AwesomeButton from "react-native-really-awesome-button";
import
DocumentPicker
from
'react-native-document-picker'
import
DocumentPicker
from
'react-native-document-picker'
import
RNFetchBlob
from
'rn-fetch-blob'
import
RNFetchBlob
from
'rn-fetch-blob'
import
Colors
from
'../../../library/colors'
;
import
Colors
from
'../../../library/colors'
;
import
reactotron
from
'reactotron-react-native'
;
export
default
class
sampleMenuPenerimaan3
extends
Component
{
export
default
class
sampleMenuPenerimaan3
extends
Component
{
constructor
(
props
)
{
constructor
(
props
)
{
...
@@ -27,7 +28,7 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -27,7 +28,7 @@ export default class sampleMenuPenerimaan3 extends Component {
}
}
componentDidMount
()
{
componentDidMount
()
{
// alert(JSON.stringify(this.state.data)
)
reactotron
.
log
(
this
.
state
.
data
.
photo_unit
)
}
}
async
requestCameraPermission
(
type
)
{
async
requestCameraPermission
(
type
)
{
...
@@ -145,7 +146,7 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -145,7 +146,7 @@ export default class sampleMenuPenerimaan3 extends Component {
<
View
style
=
{{
height
:
30
,
justifyContent
:
'center'
}}
>
<
View
style
=
{{
height
:
30
,
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Foto
No
Rangka
<
/Text
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Foto
No
Rangka
<
/Text
>
<
/View
>
<
/View
>
<
TouchableOpacity
style
=
{
styles
.
viewRangka
}
onPress
=
{()
=>
this
.
requestCameraPermission
(
'rangka'
)
}
>
<
TouchableOpacity
style
=
{
styles
.
viewRangka
}
onPress
=
{()
=>
null
}
>
<
View
<
View
style
=
{{
style
=
{{
width
:
'100%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
width
:
'100%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
...
@@ -156,7 +157,7 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -156,7 +157,7 @@ export default class sampleMenuPenerimaan3 extends Component {
<
Text
style
=
{{
color
:
'rgba(237, 57, 99, .5)'
,
textAlign
:
'center'
,
fontSize
:
40
}}
>+<
/Text
>
<
Text
style
=
{{
color
:
'rgba(237, 57, 99, .5)'
,
textAlign
:
'center'
,
fontSize
:
40
}}
>+<
/Text
>
<
/View>
:
<
/View>
:
<
Image
<
Image
style
=
{{
width
:
'100%'
,
height
:
'100%'
,
resizeMode
:
'cover'
}}
style
=
{{
width
:
'100%'
,
height
:
'100%'
,
resizeMode
:
'cover'
,
borderRadius
:
5
}}
source
=
{{
uri
:
data
.
chassis_number_photo
}}
source
=
{{
uri
:
data
.
chassis_number_photo
}}
/
>
/
>
}
}
...
@@ -168,7 +169,7 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -168,7 +169,7 @@ export default class sampleMenuPenerimaan3 extends Component {
<
View
style
=
{{
height
:
30
,
justifyContent
:
'center'
}}
>
<
View
style
=
{{
height
:
30
,
justifyContent
:
'center'
}}
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Foto
No
Mesin
<
/Text
>
<
Text
style
=
{{
fontSize
:
13
}}
>
Foto
No
Mesin
<
/Text
>
<
/View
>
<
/View
>
<
TouchableOpacity
style
=
{
styles
.
viewRangka
}
onPress
=
{()
=>
{
this
.
state
.
imageMesin
!=
''
?
this
.
setState
({
viewerMesin
:
true
})
:
this
.
requestCameraPermission
(
'mesin'
)
}}
>
<
TouchableOpacity
style
=
{
styles
.
viewRangka
}
onPress
=
{()
=>
{
null
}}
>
<
View
<
View
style
=
{{
style
=
{{
width
:
'100%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
width
:
'100%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
...
@@ -179,7 +180,7 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -179,7 +180,7 @@ export default class sampleMenuPenerimaan3 extends Component {
<
Text
style
=
{{
color
:
'rgba(237, 57, 99, .5)'
,
textAlign
:
'center'
,
fontSize
:
40
}}
>+<
/Text
>
<
Text
style
=
{{
color
:
'rgba(237, 57, 99, .5)'
,
textAlign
:
'center'
,
fontSize
:
40
}}
>+<
/Text
>
<
/View>
:
<
/View>
:
<
Image
<
Image
style
=
{{
width
:
'100%'
,
height
:
'100%'
,
resizeMode
:
'stretch'
}}
style
=
{{
width
:
'100%'
,
height
:
'100%'
,
resizeMode
:
'stretch'
,
borderRadius
:
5
}}
source
=
{{
uri
:
data
.
engine_number_photo
}}
source
=
{{
uri
:
data
.
engine_number_photo
}}
/
>
/
>
}
}
...
@@ -193,51 +194,36 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -193,51 +194,36 @@ export default class sampleMenuPenerimaan3 extends Component {
<
/View
>
<
/View
>
<
View
style
=
{
styles
.
viewFotoUnit
}
>
<
View
style
=
{
styles
.
viewFotoUnit
}
>
<
View
style
=
{{
flexDirection
:
'row'
,
height
:
'45%'
,
justifyContent
:
'space-between'
}}
>
<
View
style
=
{{
flexDirection
:
'row'
,
height
:
'45%'
,
justifyContent
:
'space-between'
}}
>
<
View
{
this
.
state
.
data
.
photo_unit
.
map
((
item
,
index
)
=>
{
style
=
{{
if
(
index
<
3
)
{
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
return
(
}}
<
View
>
style
=
{{
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
<
/View
>
}}
<
View
>
style
=
{{
<
Image
source
=
{{
uri
:
item
}}
resizeMode
=
{
'stretch'
}
style
=
{{
height
:
'100%'
,
width
:
'100%'
,
borderRadius
:
20
}}
/
>
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
<
/View>
}}
)
>
}
})}
<
/View
>
<
View
style
=
{{
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
}}
>
<
/View
>
<
/View
>
<
/View
>
<
View
style
=
{{
flexDirection
:
'row'
,
height
:
'45%'
,
justifyContent
:
'space-between'
}}
>
<
View
style
=
{{
flexDirection
:
'row'
,
height
:
'45%'
,
justifyContent
:
'space-between'
}}
>
<
View
{
this
.
state
.
data
.
photo_unit
.
map
((
item
,
index
)
=>
{
style
=
{{
reactotron
.
log
(
item
)
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
if
(
index
>
2
)
{
}}
return
(
>
<
View
style
=
{{
<
/View
>
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
<
View
}}
style
=
{{
>
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
<
Image
source
=
{{
uri
:
item
}}
resizeMode
=
{
'stretch'
}
style
=
{{
height
:
'100%'
,
width
:
'100%'
,
borderRadius
:
20
}}
/
>
}}
<
/View>
>
)
}
<
/View
>
})}
<
View
style
=
{{
width
:
'30%'
,
height
:
'100%'
,
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderStyle
:
'dotted'
,
borderWidth
:
2
,
borderRadius
:
5
}}
>
<
/View
>
<
/View
>
<
/View
>
<
/View
>
<
/View
>
...
...
app/container/home/approval/sampleMenuApproval3.js
View file @
6b1962f4
This diff is collapsed.
Click to expand it.
app/container/home/penerimaan/penerimaan.js
View file @
6b1962f4
...
@@ -4,6 +4,7 @@ import { Container, Fab, Icon } from 'native-base'
...
@@ -4,6 +4,7 @@ import { Container, Fab, Icon } from 'native-base'
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
api
from
'../../../service/api'
import
api
from
'../../../service/api'
import
{
NavigationEvents
}
from
'react-navigation'
export
default
class
Penerimaan
extends
Component
{
export
default
class
Penerimaan
extends
Component
{
...
@@ -44,8 +45,10 @@ export default class Penerimaan extends Component {
...
@@ -44,8 +45,10 @@ export default class Penerimaan extends Component {
render
()
{
render
()
{
return
(
return
(
<
Container
style
=
{{
flex
:
1
}}
>
<
Container
style
=
{{
flex
:
1
}}
>
<
NavigationEvents
onDidFocus
=
{()
=>
this
.
getListData
()}
/
>
<
ScrollView
style
=
{{
paddingHorizontal
:
20
,
backgroundColor
:
'#F5F5F5'
,
paddingTop
:
10
}}
showsVerticalScrollIndicator
=
{
false
}
>
<
ScrollView
style
=
{{
paddingHorizontal
:
20
,
backgroundColor
:
'#F5F5F5'
,
paddingTop
:
10
}}
showsVerticalScrollIndicator
=
{
false
}
>
{
this
.
state
.
listClar
.
map
((
item
,
index
)
=>
{
{
this
.
state
.
listClar
.
map
((
item
,
index
)
=>
{
return
(
return
(
<
View
key
=
{
index
}
style
=
{{
paddingHorizontal
:
7
}}
>
<
View
key
=
{
index
}
style
=
{{
paddingHorizontal
:
7
}}
>
...
...
app/container/home/penerimaan/sampleMenuPenerimaan2.js
View file @
6b1962f4
...
@@ -73,7 +73,7 @@ export default class sampleMenuPenerimaan2 extends Component {
...
@@ -73,7 +73,7 @@ export default class sampleMenuPenerimaan2 extends Component {
<
View
style
=
{{
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderWidth
:
.
8
,
justifyContent
:
'center'
,
borderRadius
:
5
,
width
:
'60%'
}}
>
<
View
style
=
{{
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderWidth
:
.
8
,
justifyContent
:
'center'
,
borderRadius
:
5
,
width
:
'60%'
}}
>
<
TextInput
<
TextInput
style
=
{{
paddingHorizontal
:
10
,
paddingVertical
:
0
,
color
:
'#999999'
}}
style
=
{{
paddingHorizontal
:
10
,
paddingVertical
:
0
,
color
:
'#999999'
}}
value
=
{
'Test'
}
value
=
{
data
.
model
}
/
>
/
>
<
/View
>
<
/View
>
<
View
style
=
{{
width
:
'40%'
,
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingHorizontal
:
5
}}
>
<
View
style
=
{{
width
:
'40%'
,
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingHorizontal
:
5
}}
>
...
@@ -104,7 +104,7 @@ export default class sampleMenuPenerimaan2 extends Component {
...
@@ -104,7 +104,7 @@ export default class sampleMenuPenerimaan2 extends Component {
<
View
style
=
{{
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderWidth
:
.
8
,
justifyContent
:
'center'
,
borderRadius
:
5
,
width
:
'60%'
}}
>
<
View
style
=
{{
borderColor
:
'rgba(237, 57, 99, .5)'
,
borderWidth
:
.
8
,
justifyContent
:
'center'
,
borderRadius
:
5
,
width
:
'60%'
}}
>
<
TextInput
<
TextInput
style
=
{{
paddingHorizontal
:
10
,
paddingVertical
:
0
,
color
:
'#999999'
}}
style
=
{{
paddingHorizontal
:
10
,
paddingVertical
:
0
,
color
:
'#999999'
}}
value
=
{
this
.
state
.
data
==
""
?
""
:
`
${
data
.
brand
}
-
${
data
.
model
}
`
}
value
=
{
this
.
state
.
data
==
""
?
""
:
`
${
data
.
brand
}
`
}
/
>
/
>
<
/View
>
<
/View
>
<
View
style
=
{{
width
:
'40%'
,
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingHorizontal
:
5
}}
>
<
View
style
=
{{
width
:
'40%'
,
flexDirection
:
'row'
,
justifyContent
:
'space-between'
,
paddingHorizontal
:
5
}}
>
...
...
app/container/home/penerimaan/sampleMenuPenerimaan3.js
View file @
6b1962f4
...
@@ -10,6 +10,8 @@ import AwesomeButton from "react-native-really-awesome-button";
...
@@ -10,6 +10,8 @@ import AwesomeButton from "react-native-really-awesome-button";
import
DocumentPicker
from
'react-native-document-picker'
import
DocumentPicker
from
'react-native-document-picker'
import
RNFetchBlob
from
'rn-fetch-blob'
import
RNFetchBlob
from
'rn-fetch-blob'
import
Colors
from
'../../../library/colors'
;
import
Colors
from
'../../../library/colors'
;
import
api
from
'../../../service/api'
;
import
reactotron
from
'reactotron-react-native'
;
export
default
class
sampleMenuPenerimaan3
extends
Component
{
export
default
class
sampleMenuPenerimaan3
extends
Component
{
constructor
(
props
)
{
constructor
(
props
)
{
...
@@ -90,6 +92,15 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -90,6 +92,15 @@ export default class sampleMenuPenerimaan3 extends Component {
}
}
}
}
handlePenerimaan
()
{
api
.
create
().
postPenerimaan
({
contract_id
:
this
.
state
.
data
.
contract_id
}).
then
((
Response
)
=>
{
reactotron
.
log
(
Response
)
})
this
.
props
.
navigation
.
navigate
(
'Penerimaan'
)
}
render
()
{
render
()
{
let
{
data
}
=
this
.
state
let
{
data
}
=
this
.
state
return
(
return
(
...
@@ -259,7 +270,7 @@ export default class sampleMenuPenerimaan3 extends Component {
...
@@ -259,7 +270,7 @@ export default class sampleMenuPenerimaan3 extends Component {
progress
=
{
!
this
.
state
.
progress
}
progress
=
{
!
this
.
state
.
progress
}
onPress
=
{
next
=>
{
onPress
=
{
next
=>
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
this
.
props
.
navigation
.
navigate
(
'Penerimaan'
)
this
.
handlePenerimaan
(
)
next
()
next
()
},
300
);
},
300
);
}}
}}
...
...
app/container/profile/profile.js
View file @
6b1962f4
...
@@ -97,10 +97,14 @@ class Profile extends Component {
...
@@ -97,10 +97,14 @@ class Profile extends Component {
<
AwesomeButton
<
AwesomeButton
width
=
{
'100%'
}
raiseLevel
=
{
3
}
springRelease
=
{
true
}
type
=
"primary"
width
=
{
'100%'
}
raiseLevel
=
{
3
}
springRelease
=
{
true
}
type
=
"primary"
progress
progress
backgroundDarker
=
{
'#e3b91f'
}
backgroundColor
=
{
Colors
.
yellowBasic
}
backgroundShadow
=
{
'#e3c143'
}
backgroundShadow
=
{
'#DBDBDB'
}
backgroundPlaceholder
=
{
null
}
backgroundDarker
=
{
'#FFED75'
}
// backgroundDarker={'#e3b91f'}
// backgroundShadow={'#e3c143'}
height
=
{
50
}
height
=
{
50
}
borderColor
=
{
Colors
.
blackBasic
}
//
borderColor={Colors.blackBasic}
backgroundColor
=
{
'#e4b300'
}
backgroundColor
=
{
'#e4b300'
}
backgroundProgress
=
{
'#ffef85'
}
backgroundProgress
=
{
'#ffef85'
}
progressLoadingTime
=
{
300
}
progressLoadingTime
=
{
300
}
...
...
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