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
71794974
Commit
71794974
authored
Oct 01, 2020
by
d.arizona
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://103.44.149.204/d.arizona/tia-dev
into didam
parents
d3b4a1d6
005ff046
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
110 additions
and
107 deletions
+110
-107
FixedAssetsMovement.js
src/container/BudgetTahunan/FixedAssetsMovement.js
+39
-37
ProfitLoss.js
src/container/BudgetTahunan/ProfitLoss.js
+35
-33
TaxPlanning.js
src/container/BudgetTahunan/TaxPlanning.js
+36
-37
No files found.
src/container/BudgetTahunan/FixedAssetsMovement.js
View file @
71794974
...
...
@@ -330,11 +330,11 @@ export default class FixedAssetsMovement extends Component {
item
.
error
]
})
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
},
()
=>
{
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
,
editable
:
true
},
()
=>
{
this
.
state
.
dataTable
.
map
(
item
=>
{
if
(
item
[
23
].
length
>
0
)
{
console
.
log
(
'masuk'
)
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
})
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
,
editable
:
true
})
}
})
// console.log(this.state.dataTable);
...
...
@@ -531,7 +531,7 @@ export default class FixedAssetsMovement extends Component {
"formula"
:
rilFormula
}
api
.
create
().
countingFormula
(
body
).
then
(
response
=>
{
console
.
log
(
response
);
//
console.log(response);
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
setTimeout
(()
=>
{
...
...
@@ -550,7 +550,7 @@ export default class FixedAssetsMovement extends Component {
"formula"
:
rilFormula
}
api
.
create
().
countingFormula
(
body
).
then
(
response
=>
{
console
.
log
(
response
)
//
console.log(response)
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
setTimeout
(()
=>
{
...
...
@@ -641,7 +641,6 @@ export default class FixedAssetsMovement extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
<
div
style
=
{{
width
:
300
}}
>
{
console
.
log
(
tableMeta
.
rowData
)}
{
tableMeta
.
rowData
[
23
]
?
tableMeta
.
rowData
[
23
].
length
>
0
?
<
div
style
=
{{
paddingLeft
:
20
*
Number
(
tableMeta
.
rowData
[
4
])
}}
>
...
...
@@ -2148,14 +2147,14 @@ export default class FixedAssetsMovement extends Component {
outline
:
'none'
,
marginRight
:
20
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
loading
:
true
,
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(
()
=>
{
this
.
backToMasterBudget
(
'draft'
)
},
100
);
})
}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
backToMasterBudget
(
'draft'
)
})
}
>
<
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
>
...
...
@@ -2166,16 +2165,12 @@ export default class FixedAssetsMovement extends Component {
disabled
=
{
this
.
state
.
buttonError
}
onClick
=
{()
=>
this
.
state
.
buttonError
?
this
.
setState
({
loading
:
true
},
()
=>
{
setTimeout
(()
=>
{
this
.
setState
({
alert
:
true
,
messageAlert
:
'Data is not complete !'
,
tipeAlert
:
'warning'
,
loading
:
false
})
},
100
);
})
:
this
.
setState
({
alert
:
true
,
messageAlert
:
'Data is not complete !'
,
tipeAlert
:
'warning'
})
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
loading
:
true
,
handleTekTekTek
:
1
},
()
=>
{
this
.
backToMasterBudget
(
'submitted'
)
})}
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
backToMasterBudget
(
'submitted'
)
})}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
...
...
@@ -2245,7 +2240,7 @@ export default class FixedAssetsMovement extends Component {
onClick
=
{()
=>
{
this
.
setState
({
loading
:
true
},
()
=>
{
setTimeout
(()
=>
{
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
})
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
,
editable
:
false
})
},
100
);
})
}}
...
...
@@ -2260,19 +2255,19 @@ export default class FixedAssetsMovement extends Component {
disabled
=
{
this
.
state
.
buttonError
}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
cursor
:
this
.
state
.
editable
===
true
?
'default'
:
'pointer'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
marginRight
:
20
}}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadFAM
(
'draft'
)
},
100
);
})
)}
})}
>
<
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
>
...
...
@@ -2280,15 +2275,22 @@ export default class FixedAssetsMovement extends Component {
<
/button
>
<
button
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadFAM
(
'submitted'
)
},
100
);
})
)}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default'
,
borderColor
:
'transparent'
,
outline
:
'none'
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadFAM
(
'submitted'
)
},
100
);
})
}
>
<
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
>
...
...
src/container/BudgetTahunan/ProfitLoss.js
View file @
71794974
...
...
@@ -339,11 +339,11 @@ export default class ProfitLoss extends Component {
item
.
error
]
})
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
},
()
=>
{
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
,
editable
:
true
},
()
=>
{
this
.
state
.
dataTable
.
map
(
item
=>
{
if
(
item
[
24
].
length
>
0
)
{
console
.
log
(
'masuk'
)
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
})
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
,
editable
:
true
})
}
})
// console.log(this.state.buttonError)
...
...
@@ -2270,10 +2270,10 @@ export default class ProfitLoss extends Component {
<
/button
>
<
/div
>
<
div
className
=
"col-2"
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
,
maxWidth
:
'100%'
}}
>
<
button
<
button
className
=
"button"
type
=
"button"
//
disabled={this.state.buttonError}
disabled
=
{
this
.
state
.
buttonError
}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
...
...
@@ -2284,7 +2284,7 @@ export default class ProfitLoss extends Component {
onClick
=
{()
=>
{
this
.
setState
({
loading
:
true
},
()
=>
{
setTimeout
(()
=>
{
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
})
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
,
editable
:
false
})
},
100
);
})
}}
...
...
@@ -2295,23 +2295,23 @@ export default class ProfitLoss extends Component {
<
/button
>
<
button
type
=
"button"
// disabled={this.state.buttonError}
// onClick={() => this.setState({ loading: true }, () => {
// setTimeout(() => {
// this.uploadProfitLoss('draft')
// }, 100);
// })}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadProfitLoss
(
"draft"
)
},
100
);
})
)}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
marginRight
:
20
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadProfitLoss
(
'draft'
)
},
100
);
})
}
>
<
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
>
...
...
@@ -2319,20 +2319,22 @@ export default class ProfitLoss extends Component {
<
/button
>
<
button
type
=
"button"
// disabled={this.state.buttonError}
// onClick={() => this.setState({ loading: true }, () => {
// setTimeout(() => {
// this.uploadProfitLoss('submitted')
// }, 100);
// })}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadProfitLoss
(
"submitted"
)
},
100
);
})
)}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadProfitLoss
(
'submitted'
)
},
100
);
})
}
>
<
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
>
...
...
src/container/BudgetTahunan/TaxPlanning.js
View file @
71794974
...
...
@@ -485,14 +485,15 @@ export default class TaxPlanning extends Component {
fcp
:
Number
(
item
.
type_report_id
.
fcp
)
===
3
&&
item
.
total_more_year
.
fcp
===
""
?
"0"
:
item
.
total_more_year
.
fcp
,
tbf
:
Number
(
item
.
type_report_id
.
tbf
)
===
3
&&
item
.
total_more_year
.
tbf
===
""
?
"0"
:
item
.
total_more_year
.
tbf
},
item
.
orders
,
item
.
error
]
})
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
},
()
=>
{
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
,
editable
:
true
},
()
=>
{
this
.
state
.
dataTable
.
map
(
item
=>
{
if
(
item
[
2
4
].
length
>
0
)
{
if
(
item
[
2
5
].
length
>
0
)
{
console
.
log
(
'masuk'
)
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
})
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
,
editable
:
true
})
}
})
console
.
log
(
this
.
state
.
dataTable
);
...
...
@@ -5102,11 +5103,10 @@ export default class TaxPlanning extends Component {
<
button
className
=
"button"
type
=
"button"
//
disabled={this.state.buttonError}
disabled
=
{
this
.
state
.
buttonError
}
style
=
{{
backgroundColor
:
'transparent'
,
// cursor: this.state.buttonError === true ? 'default' : 'pointer',
cursor
:
'pointer'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
marginRight
:
20
...
...
@@ -5114,7 +5114,7 @@ export default class TaxPlanning extends Component {
onClick
=
{()
=>
{
this
.
setState
({
loading
:
true
},
()
=>
{
setTimeout
(()
=>
{
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
})
this
.
setState
({
loading
:
false
,
buttonError
:
this
.
state
.
errorPreview
===
true
?
true
:
false
,
editable
:
false
})
},
100
);
})
}}
...
...
@@ -5125,28 +5125,24 @@ export default class TaxPlanning extends Component {
<
/button
>
<
button
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
// onClick={() => this.setState({ loading: true }, () => {
// setTimeout(() => {
// this.uploadTP('draft')
// }, 100);
// })}
// style={{ marginRight: 20}}
// disabled={this.state.buttonError}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer
'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default
'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
marginRight
:
20
}}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadTP
(
"draft"
)
},
100
);
})
)}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadTP
(
'draft'
)
},
100
);
})
}
>
<
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
>
...
...
@@ -5154,20 +5150,23 @@ export default class TaxPlanning extends Component {
<
/button
>
<
button
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
// onClick={() => this.setState({ loading: true }, () => {
// setTimeout(() => {
// this.uploadTP('submitted')
// }, 100);
// })}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadTP
(
"submitted"
)
},
100
);
})
)}
// disabled={this.state.buttonError}
style
=
{{
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
editable
!==
true
?
'pointer'
:
'default'
,
borderColor
:
'transparent'
,
outline
:
'none'
,
}}
onClick
=
{()
=>
this
.
state
.
editable
===
true
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
setTimeout
(()
=>
{
this
.
uploadTP
(
'submitted'
)
},
100
);
})
}
>
<
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
>
...
...
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