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
32074f66
Commit
32074f66
authored
Mar 08, 2021
by
rifkaki
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://103.44.149.204/d.arizona/tia-dev
into rifka
parents
43aa73ba
307e1e92
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
2269 additions
and
10 deletions
+2269
-10
CashFlowMR.js
src/container/MonthlyReport/CashFlowMR.js
+3
-1
CorporateAnnualTargetMR.js
src/container/MonthlyReport/CorporateAnnualTargetMR.js
+4
-4
OperatingIndicator.js
src/container/OprIndicator/OperatingIndicator.js
+38
-0
RollingOutlook.js
src/container/RollingOutlook.js
+1
-1
OperatingIndicatorRO.js
src/container/RollingOutlook/OperatingIndicatorRO.js
+2162
-0
ProfitLossRO.js
src/container/RollingOutlook/ProfitLossRO.js
+61
-4
No files found.
src/container/MonthlyReport/CashFlowMR.js
View file @
32074f66
...
@@ -76,11 +76,13 @@ export default class CashFlowMR extends Component {
...
@@ -76,11 +76,13 @@ export default class CashFlowMR extends Component {
checkPrevRev
=
false
checkPrevRev
=
false
}
}
if
(
this
.
props
.
status
===
'revision'
||
this
.
props
.
status
===
'not-yet'
||
this
.
props
.
status
===
'drat'
||
this
.
props
.
status
===
'submitted'
)
{
if
(
this
.
props
.
status
===
'revision'
||
this
.
props
.
status
===
'not-yet'
||
this
.
props
.
status
===
'dra
f
t'
||
this
.
props
.
status
===
'submitted'
)
{
checkStatus
=
true
checkStatus
=
true
}
else
{
}
else
{
checkStatus
=
false
checkStatus
=
false
}
}
// console.log(this.props.status)
// console.log(this.props.lastStatus)
// console.log(checkStatus)
// console.log(checkStatus)
// console.log(checkLastStatus)
// console.log(checkLastStatus)
// console.log(checkApprover)
// console.log(checkApprover)
...
...
src/container/MonthlyReport/CorporateAnnualTargetMR.js
View file @
32074f66
...
@@ -684,7 +684,7 @@ export default class CorporateAnnualTargetMR extends Component {
...
@@ -684,7 +684,7 @@ export default class CorporateAnnualTargetMR extends Component {
}
}
}
else
if
(
target
==
0
)
{
}
else
if
(
target
==
0
)
{
if
(
target
>=
actual
)
{
if
(
target
>=
actual
)
{
totalAch
=
1.2
5
totalAch
=
1.2
6
}
else
{
}
else
{
totalAch
=
0
totalAch
=
0
}
}
...
@@ -711,7 +711,7 @@ export default class CorporateAnnualTargetMR extends Component {
...
@@ -711,7 +711,7 @@ export default class CorporateAnnualTargetMR extends Component {
}
}
}
else
if
(
target
==
0
)
{
}
else
if
(
target
==
0
)
{
if
(
target
<=
actual
)
{
if
(
target
<=
actual
)
{
totalAch
=
1.2
5
totalAch
=
1.2
6
}
else
{
}
else
{
totalAch
=
0
totalAch
=
0
}
}
...
@@ -1281,7 +1281,7 @@ export default class CorporateAnnualTargetMR extends Component {
...
@@ -1281,7 +1281,7 @@ export default class CorporateAnnualTargetMR extends Component {
}
}
}
else
if
(
target
==
0
)
{
}
else
if
(
target
==
0
)
{
if
(
target
>=
actual
)
{
if
(
target
>=
actual
)
{
total
=
1.2
5
total
=
1.2
6
}
else
{
}
else
{
total
=
0
total
=
0
}
}
...
@@ -1303,7 +1303,7 @@ export default class CorporateAnnualTargetMR extends Component {
...
@@ -1303,7 +1303,7 @@ export default class CorporateAnnualTargetMR extends Component {
}
}
}
else
if
(
target
==
0
)
{
}
else
if
(
target
==
0
)
{
if
(
target
<=
actual
)
{
if
(
target
<=
actual
)
{
total
=
1.2
5
total
=
1.2
6
}
else
{
}
else
{
total
=
0
total
=
0
}
}
...
...
src/container/OprIndicator/OperatingIndicator.js
View file @
32074f66
...
@@ -12,6 +12,7 @@ import UploadFile from "../../library/Upload";
...
@@ -12,6 +12,7 @@ import UploadFile from "../../library/Upload";
import
{
format
}
from
'date-fns'
;
import
{
format
}
from
'date-fns'
;
import
Constant
from
'../../library/Constant'
;
import
Constant
from
'../../library/Constant'
;
import
OperatingIndicatorMR
from
'../MonthlyReport/OperatingIndicatorMR'
;
import
OperatingIndicatorMR
from
'../MonthlyReport/OperatingIndicatorMR'
;
import
OperatingIndicatorRO
from
'../RollingOutlook/OperatingIndicatorRO'
;
var
ct
=
require
(
"../../library/CustomTable"
);
var
ct
=
require
(
"../../library/CustomTable"
);
const
getMuiTheme
=
()
=>
createMuiTheme
(
ct
.
customTable
());
const
getMuiTheme
=
()
=>
createMuiTheme
(
ct
.
customTable
());
...
@@ -341,6 +342,16 @@ export default class OperatingIndicator extends Component {
...
@@ -341,6 +342,16 @@ export default class OperatingIndicator extends Component {
})
})
}
else
if
(
String
(
item
[
1
]).
toLocaleLowerCase
().
includes
(
"rolling outlook"
))
{
this
.
setState
({
statusDetail
:
String
(
item
[
2
]).
toLocaleLowerCase
(),
dataDetail
:
{
...
this
.
state
.
dataReport
[
index
],
periode
:
this
.
state
.
periode
.
periode
,
operatingIndID
:
this
.
state
.
operatingIndID
,
company
:
this
.
state
.
company
},
visibleOperatingIndicator
:
false
,
visibleDetailOpt
:
false
,
visibleDetailMonthly
:
false
,
visibleDetailRolling
:
true
})
}
else
{
}
else
{
this
.
setState
({
this
.
setState
({
statusDetail
:
String
(
item
[
2
]).
toLocaleLowerCase
(),
statusDetail
:
String
(
item
[
2
]).
toLocaleLowerCase
(),
...
@@ -409,6 +420,14 @@ export default class OperatingIndicator extends Component {
...
@@ -409,6 +420,14 @@ export default class OperatingIndicator extends Component {
})
})
}
}
saveRollingOI
(
payload
)
{
api
.
create
().
createMonthlyReportOI
(
payload
).
then
((
response
)
=>
{
console
.
log
(
response
);
this
.
getReport
()
this
.
getOperatingID
()
})
}
render
()
{
render
()
{
const
columns
=
[
"#"
,
"Report Type"
,
const
columns
=
[
"#"
,
"Report Type"
,
// {
// {
...
@@ -644,6 +663,25 @@ export default class OperatingIndicator extends Component {
...
@@ -644,6 +663,25 @@ export default class OperatingIndicator extends Component {
/
>
/
>
}
}
{
this
.
state
.
visibleDetailRolling
&&
<
OperatingIndicatorRO
open
=
{
this
.
props
.
open
}
data
=
{
this
.
state
.
dataDetail
}
height
=
{
this
.
props
.
height
}
width
=
{
this
.
props
.
width
}
months
=
{
this
.
state
.
months
}
company
=
{
this
.
state
.
company
}
onClickClose
=
{()
=>
this
.
setState
({
visibleDetailRolling
:
false
,
visibleOperatingIndicator
:
true
},
()
=>
{
this
.
getOperatingID
()
this
.
forceUpdate
()
})}
getReport
=
{()
=>
this
.
getOperatingID
()}
saveRollingOI
=
{
this
.
saveRollingOI
.
bind
(
this
)}
isSubmit
=
{
this
.
state
.
statusDetail
==
'closed'
?
false
:
this
.
state
.
isSubmit
}
permission
=
{{
create
:
this
.
state
.
buttonCreate
,
edit
:
this
.
state
.
buttonEdit
,
delete
:
this
.
state
.
buttonDelete
}}
/
>
}
{
this
.
state
.
visibleUpload
&&
(
{
this
.
state
.
visibleUpload
&&
(
<
div
className
=
"test app-popup-show"
>
<
div
className
=
"test app-popup-show"
>
<
div
className
=
"popup-content background-white border-radius"
style
=
{{
borderRadius
:
8
}}
>
<
div
className
=
"popup-content background-white border-radius"
style
=
{{
borderRadius
:
8
}}
>
...
...
src/container/RollingOutlook.js
View file @
32074f66
...
@@ -559,7 +559,7 @@ export default class RollingOutlook extends Component {
...
@@ -559,7 +559,7 @@ export default class RollingOutlook extends Component {
this
.
setState
({
alert
:
false
})
this
.
setState
({
alert
:
false
})
}
}
saveTo
MasterBudget
(
data
)
{
saveTo
RollingOutlook
(
data
)
{
this
.
setState
({
loading
:
true
})
this
.
setState
({
loading
:
true
})
// console.log(JSON.stringify(data));
// console.log(JSON.stringify(data));
api
.
create
(
'UPLOAD'
).
createSubmitReport
(
data
).
then
(
response
=>
{
api
.
create
(
'UPLOAD'
).
createSubmitReport
(
data
).
then
(
response
=>
{
...
...
src/container/RollingOutlook/OperatingIndicatorRO.js
0 → 100644
View file @
32074f66
This source diff could not be displayed because it is too large. You can
view the blob
instead.
src/container/RollingOutlook/ProfitLossRO.js
View file @
32074f66
...
@@ -142,7 +142,7 @@ export default class ProfitLossRO extends Component {
...
@@ -142,7 +142,7 @@ export default class ProfitLossRO extends Component {
item
.
formula
,
item
.
formula
,
item
.
level
,
item
.
level
,
item
.
description
,
item
.
description
,
item
.
profit_loss
.
notes
===
undefined
?
""
:
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
last_year_total
===
""
?
"0"
:
item
.
profit_loss
.
last_year_total
,
item
.
profit_loss
.
last_year_total
===
""
?
"0"
:
item
.
profit_loss
.
last_year_total
,
item
.
profit_loss
.
january
===
""
?
"0"
:
item
.
profit_loss
.
january
,
item
.
profit_loss
.
january
===
""
?
"0"
:
item
.
profit_loss
.
january
,
item
.
profit_loss
.
february
===
""
?
"0"
:
item
.
profit_loss
.
february
,
item
.
profit_loss
.
february
===
""
?
"0"
:
item
.
profit_loss
.
february
,
...
@@ -179,7 +179,7 @@ export default class ProfitLossRO extends Component {
...
@@ -179,7 +179,7 @@ export default class ProfitLossRO extends Component {
item
.
formula
,
item
.
formula
,
item
.
level
,
item
.
level
,
item
.
description
,
item
.
description
,
item
.
profit_loss
.
notes
===
undefined
?
""
:
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
notes
,
item
.
profit_loss
.
last_year_total
===
""
?
"0"
:
item
.
profit_loss
.
last_year_total
,
item
.
profit_loss
.
last_year_total
===
""
?
"0"
:
item
.
profit_loss
.
last_year_total
,
item
.
profit_loss
.
january
===
""
?
"0"
:
item
.
profit_loss
.
january
,
item
.
profit_loss
.
january
===
""
?
"0"
:
item
.
profit_loss
.
january
,
item
.
profit_loss
.
february
===
""
?
"0"
:
item
.
profit_loss
.
february
,
item
.
profit_loss
.
february
===
""
?
"0"
:
item
.
profit_loss
.
february
,
...
@@ -303,6 +303,63 @@ export default class ProfitLossRO extends Component {
...
@@ -303,6 +303,63 @@ export default class ProfitLossRO extends Component {
// })
// })
}
}
backToRollingOutlook
(
type
)
{
this
.
setState
({
loading
:
true
})
let
data
=
[]
this
.
state
.
dataTable
.
map
(
i
=>
{
data
.
push
({
"item_report_id"
:
i
[
1
],
"total_december_last_year"
:
String
(
Number
(
i
[
6
]).
toFixed
(
1
)),
"january"
:
String
(
Number
(
i
[
7
]).
toFixed
(
1
)),
"february"
:
String
(
Number
(
i
[
8
]).
toFixed
(
1
)),
"march"
:
String
(
Number
(
i
[
9
]).
toFixed
(
1
)),
"april"
:
String
(
Number
(
i
[
10
]).
toFixed
(
1
)),
"may"
:
String
(
Number
(
i
[
11
]).
toFixed
(
1
)),
"june"
:
String
(
Number
(
i
[
12
]).
toFixed
(
1
)),
"july"
:
String
(
Number
(
i
[
13
]).
toFixed
(
1
)),
"august"
:
String
(
Number
(
i
[
14
]).
toFixed
(
1
)),
"september"
:
String
(
Number
(
i
[
15
]).
toFixed
(
1
)),
"october"
:
String
(
Number
(
i
[
16
]).
toFixed
(
1
)),
"november"
:
String
(
Number
(
i
[
17
]).
toFixed
(
1
)),
"december"
:
String
(
Number
(
i
[
18
]).
toFixed
(
1
)),
"total_december_year"
:
String
(
Number
(
i
[
19
]).
toFixed
(
1
))
})
})
let
payload
=
{
"rolling_outlook_id"
:
this
.
props
.
rollingOutlookID
,
"company_id"
:
this
.
props
.
company
.
company_id
,
"periode"
:
this
.
props
.
periode
,
"report_id"
:
this
.
props
.
report_id
,
// "months": this.props.month.month_id,
"months"
:
0
,
"status"
:
type
,
"balance_sheet"
:
data
}
api
.
create
(
'UPLOAD'
).
createRollingOutlookBS
(
payload
).
then
(
response
=>
{
console
.
log
(
payload
);
console
.
log
(
response
);
// console.log(JSON.stringify(payload))
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
if
(
type
==
'submitted'
)
{
// this.props.saveToMonthlyReport('BS')
this
.
props
.
onClickClose
()
}
else
{
// this.props.saveToMonthlyReport()
this
.
props
.
onClickClose
()
}
}
else
{
this
.
setState
({
loading
:
false
,
handleTekTekTek
:
0
},
()
=>
{
// this.props.saveToMonthlyReport()
this
.
props
.
onClickClose
()
})
}
}
else
{
this
.
setState
({
loading
:
false
,
handleTekTekTek
:
0
})
}
})
}
closeAlert
()
{
closeAlert
()
{
this
.
setState
({
alert
:
false
})
this
.
setState
({
alert
:
false
})
}
}
...
@@ -2121,7 +2178,7 @@ export default class ProfitLossRO extends Component {
...
@@ -2121,7 +2178,7 @@ export default class ProfitLossRO extends Component {
:
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
,
loading
:
true
},
()
=>
{
this
.
setState
({
handleTekTekTek
:
1
,
loading
:
true
},
()
=>
{
this
.
backTo
MonthlyReport
(
'draft'
)
this
.
backTo
RollingOutlook
(
'draft'
)
})
})
}
}
>
>
...
@@ -2138,7 +2195,7 @@ export default class ProfitLossRO extends Component {
...
@@ -2138,7 +2195,7 @@ export default class ProfitLossRO extends Component {
:
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
state
.
handleTekTekTek
==
1
?
null
:
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
setState
({
handleTekTekTek
:
1
},
()
=>
{
this
.
backTo
MonthlyReport
(
'submitted'
)
this
.
backTo
RollingOutlook
(
'submitted'
)
})}
})}
style
=
{{
style
=
{{
backgroundColor
:
'transparent'
,
backgroundColor
:
'transparent'
,
...
...
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