Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
Tia-dev
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
Tia-dev
Commits
c7d908bf
Commit
c7d908bf
authored
Dec 15, 2021
by
r.kurnia
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
belum ada handle control should be nil di upload BS OLPA
parent
f6fa444c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
33 deletions
+29
-33
BalanceSheetOLPA.js
src/container/OutlookPA/BalanceSheetOLPA.js
+29
-33
No files found.
src/container/OutlookPA/BalanceSheetOLPA.js
View file @
c7d908bf
...
@@ -560,6 +560,7 @@ export default class BalanceSheetOLPA extends Component {
...
@@ -560,6 +560,7 @@ export default class BalanceSheetOLPA extends Component {
dataTable
.
map
((
i
,
index
)
=>
{
dataTable
.
map
((
i
,
index
)
=>
{
if
(
String
(
i
[
5
])
==
"Control (should be nil)"
)
{
if
(
String
(
i
[
5
])
==
"Control (should be nil)"
)
{
if
(
Number
(
i
[
17
].
value
)
<
this
.
state
.
minValue
||
Number
(
i
[
17
].
value
)
>
this
.
state
.
maxValue
)
{
if
(
Number
(
i
[
17
].
value
)
<
this
.
state
.
minValue
||
Number
(
i
[
17
].
value
)
>
this
.
state
.
maxValue
)
{
console
.
log
(
"masuk selisih control"
)
err
=
true
err
=
true
}
else
if
(
Number
(
i
[
18
].
value
)
<
this
.
state
.
minValue
||
Number
(
i
[
18
].
value
)
>
this
.
state
.
maxValue
)
{
}
else
if
(
Number
(
i
[
18
].
value
)
<
this
.
state
.
minValue
||
Number
(
i
[
18
].
value
)
>
this
.
state
.
maxValue
)
{
err
=
true
err
=
true
...
@@ -2045,7 +2046,8 @@ export default class BalanceSheetOLPA extends Component {
...
@@ -2045,7 +2046,8 @@ export default class BalanceSheetOLPA extends Component {
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
as
Draft
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
as
Draft
<
/Typography
>
<
/div
>
<
/div
>
<
/button>
}
<
/button>
}
{
this
.
state
.
get_for
==
'edit'
&&
<
button
{
this
.
state
.
get_for
==
'edit'
&&
<
button
type
=
"button"
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
disabled
=
{
this
.
state
.
buttonError
}
onClick
=
{()
=>
this
.
state
.
buttonError
?
onClick
=
{()
=>
this
.
state
.
buttonError
?
...
@@ -2110,21 +2112,20 @@ export default class BalanceSheetOLPA extends Component {
...
@@ -2110,21 +2112,20 @@ export default class BalanceSheetOLPA extends Component {
<
/button
>
<
/button
>
<
/div
>
<
/div
>
<
div
className
=
"col-2"
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
,
maxWidth
:
'100%'
}}
>
<
div
className
=
"col-2"
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
,
maxWidth
:
'100%'
}}
>
<
button
{
this
.
state
.
get_for
==
'edit'
&&
<
button
className
=
"button"
className
=
"button"
type
=
"button"
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
style
=
{{
style
=
{{
backgroundColor
:
'transparent'
,
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
cursor
:
'pointer'
,
borderColor
:
'transparent'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
outline
:
'none'
,
marginRight
:
20
marginRight
:
20
}}
}}
onClick
=
{()
=>
{
onClick
=
{()
=>
{
this
.
setState
({
loading
:
true
},
()
=>
{
this
.
setState
({
loading
:
true
,
dataTable
:
dataTable2
},
()
=>
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
,
editable
:
false
}
)
this
.
handleValidate
(
)
},
100
);
},
100
);
})
})
}}
}}
...
@@ -2132,8 +2133,9 @@ export default class BalanceSheetOLPA extends Component {
...
@@ -2132,8 +2133,9 @@ export default class BalanceSheetOLPA extends Component {
<
div
style
=
{{
backgroundColor
:
'#fff'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
,
border
:
'solid 1px #354960'
}}
>
<
div
style
=
{{
backgroundColor
:
'#fff'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
,
border
:
'solid 1px #354960'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#354960'
,
textAlign
:
'center'
}}
>
Calculate
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#354960'
,
textAlign
:
'center'
}}
>
Calculate
<
/Typography
>
<
/div
>
<
/div
>
<
/button
>
<
/button>
}
<
button
{
this
.
state
.
get_for
==
'edit'
&&
<
button
className
=
"button"
type
=
"button"
type
=
"button"
style
=
{{
style
=
{{
backgroundColor
:
'transparent'
,
backgroundColor
:
'transparent'
,
...
@@ -2143,47 +2145,41 @@ export default class BalanceSheetOLPA extends Component {
...
@@ -2143,47 +2145,41 @@ export default class BalanceSheetOLPA extends Component {
marginRight
:
20
marginRight
:
20
}}
}}
onClick
=
{()
=>
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
this
.
state
.
saveDraft
?
null
:
this
.
setState
({
alert
:
true
,
messageAlert
:
'Data Incomplete !'
,
tipeAlert
:
'error'
})
this
.
setState
({
loading
:
true
},
()
=>
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
setState
({
handleTekTekTek
:
1
,
loading
:
true
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadBalanceSheet
(
'draft'
)
this
.
uploadBalanceSheet
(
'draft'
)
},
100
);
})
})
)
}
}
>
>
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
as
Draft
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
as
Draft
<
/Typography
>
<
/div
>
<
/div
>
<
/button
>
<
/button>
}
{
this
.
state
.
get_for
==
'edit'
&&
<
button
<
button
type
=
"button"
type
=
"button"
// disabled={this.state.buttonError}
onClick
=
{()
=>
this
.
state
.
buttonError
?
this
.
setState
({
alert
:
true
,
messageAlert
:
'Data is not complete !'
,
tipeAlert
:
'warning'
})
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
uploadBalanceSheet
(
'submitted'
)
})}
style
=
{{
style
=
{{
backgroundColor
:
'transparent'
,
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default
'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer
'
,
borderColor
:
'transparent'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
outline
:
'none'
,
}}
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadBalanceSheet
(
'submitted'
)
},
100
);
})
)
}
>
>
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
div
style
=
{{
backgroundColor
:
'#354960'
,
width
:
105
,
height
:
25
,
borderRadius
:
3
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
}}
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
&
Complete
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
'11px'
,
color
:
'#fff'
,
textAlign
:
'center'
}}
>
Save
&
Complete
<
/Typography
>
<
/div
>
<
/div
>
<
/button
>
<
/button>
}
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
...
...
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