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
d92ca86a
Commit
d92ca86a
authored
Sep 22, 2020
by
Deni Rinaldi
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'rifka' into 'master'
update See merge request
!355
parents
5340be35
89e0a0bc
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
260 additions
and
139 deletions
+260
-139
TaxPlanning.js
src/container/BudgetTahunan/TaxPlanning.js
+258
-137
CreateManagementDoc.js
src/container/DocumentManagement/CreateManagementDoc.js
+1
-1
EditManagementDoc.js
src/container/DocumentManagement/EditManagementDoc.js
+1
-1
No files found.
src/container/BudgetTahunan/TaxPlanning.js
View file @
d92ca86a
...
@@ -93,7 +93,8 @@ export default class TaxPlanning extends Component {
...
@@ -93,7 +93,8 @@ export default class TaxPlanning extends Component {
{
tbc
:
item
.
tax_planning
.
may
.
tbc
,
fcp
:
item
.
tax_planning
.
may
.
fcp
,
tbf
:
item
.
tax_planning
.
may
.
tbf
},
{
tbc
:
item
.
tax_planning
.
may
.
tbc
,
fcp
:
item
.
tax_planning
.
may
.
fcp
,
tbf
:
item
.
tax_planning
.
may
.
tbf
},
{
tbc
:
item
.
tax_planning
.
june
.
tbc
,
fcp
:
item
.
tax_planning
.
june
.
fcp
,
tbf
:
item
.
tax_planning
.
june
.
tbf
},
{
tbc
:
item
.
tax_planning
.
june
.
tbc
,
fcp
:
item
.
tax_planning
.
june
.
fcp
,
tbf
:
item
.
tax_planning
.
june
.
tbf
},
{
tbc
:
item
.
tax_planning
.
july
.
tbc
,
fcp
:
item
.
tax_planning
.
july
.
fcp
,
tbf
:
item
.
tax_planning
.
july
.
tbf
},
{
tbc
:
item
.
tax_planning
.
july
.
tbc
,
fcp
:
item
.
tax_planning
.
july
.
fcp
,
tbf
:
item
.
tax_planning
.
july
.
tbf
},
{
tbc
:
item
.
tax_planning
.
august
.
tbc
,
fcp
:
item
.
tax_planning
.
august
.
fcp
,
tbf
:
item
.
tax_planning
.
august
.
tbf
},
{
tbc
:
item
.
tax_planning
.
august
.
tbc
===
null
?
"0"
:
item
.
tax_planning
.
august
.
tbc
===
""
?
"0"
:
item
.
tax_planning
.
august
.
tbc
,
fcp
:
item
.
tax_planning
.
august
.
fcp
,
tbf
:
item
.
tax_planning
.
august
.
tbf
},
{
tbc
:
item
.
tax_planning
.
september
.
tbc
,
fcp
:
item
.
tax_planning
.
september
.
fcp
,
tbf
:
item
.
tax_planning
.
september
.
tbf
},
{
tbc
:
item
.
tax_planning
.
september
.
tbc
,
fcp
:
item
.
tax_planning
.
september
.
fcp
,
tbf
:
item
.
tax_planning
.
september
.
tbf
},
{
tbc
:
item
.
tax_planning
.
october
.
tbc
,
fcp
:
item
.
tax_planning
.
october
.
fcp
,
tbf
:
item
.
tax_planning
.
october
.
tbf
},
{
tbc
:
item
.
tax_planning
.
october
.
tbc
,
fcp
:
item
.
tax_planning
.
october
.
fcp
,
tbf
:
item
.
tax_planning
.
october
.
tbf
},
{
tbc
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
item
.
tax_planning
.
november
.
tbf
},
{
tbc
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
item
.
tax_planning
.
november
.
tbf
},
...
@@ -129,7 +130,8 @@ export default class TaxPlanning extends Component {
...
@@ -129,7 +130,8 @@ export default class TaxPlanning extends Component {
{
tbc
:
item
.
tax_planning
.
may
.
tbc
,
fcp
:
item
.
tax_planning
.
may
.
fcp
,
tbf
:
item
.
tax_planning
.
may
.
tbf
},
{
tbc
:
item
.
tax_planning
.
may
.
tbc
,
fcp
:
item
.
tax_planning
.
may
.
fcp
,
tbf
:
item
.
tax_planning
.
may
.
tbf
},
{
tbc
:
item
.
tax_planning
.
june
.
tbc
,
fcp
:
item
.
tax_planning
.
june
.
fcp
,
tbf
:
item
.
tax_planning
.
june
.
tbf
},
{
tbc
:
item
.
tax_planning
.
june
.
tbc
,
fcp
:
item
.
tax_planning
.
june
.
fcp
,
tbf
:
item
.
tax_planning
.
june
.
tbf
},
{
tbc
:
item
.
tax_planning
.
july
.
tbc
,
fcp
:
item
.
tax_planning
.
july
.
fcp
,
tbf
:
item
.
tax_planning
.
july
.
tbf
},
{
tbc
:
item
.
tax_planning
.
july
.
tbc
,
fcp
:
item
.
tax_planning
.
july
.
fcp
,
tbf
:
item
.
tax_planning
.
july
.
tbf
},
{
tbc
:
item
.
tax_planning
.
august
.
tbc
,
fcp
:
item
.
tax_planning
.
august
.
fcp
,
tbf
:
item
.
tax_planning
.
august
.
tbf
},
{
tbc
:
item
.
tax_planning
.
august
.
tbc
===
null
?
"0"
:
item
.
tax_planning
.
august
.
tbc
===
""
?
"0"
:
item
.
tax_planning
.
august
.
tbc
,
fcp
:
item
.
tax_planning
.
august
.
fcp
,
tbf
:
item
.
tax_planning
.
august
.
tbf
},
{
tbc
:
item
.
tax_planning
.
september
.
tbc
,
fcp
:
item
.
tax_planning
.
september
.
fcp
,
tbf
:
item
.
tax_planning
.
september
.
tbf
},
{
tbc
:
item
.
tax_planning
.
september
.
tbc
,
fcp
:
item
.
tax_planning
.
september
.
fcp
,
tbf
:
item
.
tax_planning
.
september
.
tbf
},
{
tbc
:
item
.
tax_planning
.
october
.
tbc
,
fcp
:
item
.
tax_planning
.
october
.
fcp
,
tbf
:
item
.
tax_planning
.
october
.
tbf
},
{
tbc
:
item
.
tax_planning
.
october
.
tbc
,
fcp
:
item
.
tax_planning
.
october
.
fcp
,
tbf
:
item
.
tax_planning
.
october
.
tbf
},
{
tbc
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
item
.
tax_planning
.
november
.
tbf
},
{
tbc
:
item
.
tax_planning
.
november
.
tbc
,
fcp
:
item
.
tax_planning
.
november
.
fcp
,
tbf
:
item
.
tax_planning
.
november
.
tbf
},
...
@@ -191,75 +193,75 @@ export default class TaxPlanning extends Component {
...
@@ -191,75 +193,75 @@ export default class TaxPlanning extends Component {
data
.
push
({
data
.
push
({
item_report_id
:
i
[
4
],
item_report_id
:
i
[
4
],
january
:
{
january
:
{
TBC
:
String
(
i
[
9
].
tbc
),
tbc
:
String
(
i
[
9
].
tbc
),
FCP
:
String
(
i
[
9
].
fcp
),
fcp
:
String
(
i
[
9
].
fcp
),
TBF
:
String
(
i
[
9
].
tbf
)
tbf
:
String
(
i
[
9
].
tbf
)
},
},
february
:
{
february
:
{
TBC
:
String
(
i
[
10
].
tbc
),
tbc
:
String
(
i
[
10
].
tbc
),
FCP
:
String
(
i
[
10
].
fcp
),
fcp
:
String
(
i
[
10
].
fcp
),
TBF
:
String
(
i
[
10
].
tbf
)
tbf
:
String
(
i
[
10
].
tbf
)
},
},
march
:
{
march
:
{
TBC
:
String
(
i
[
11
].
tbc
),
tbc
:
String
(
i
[
11
].
tbc
),
FCP
:
String
(
i
[
11
].
fcp
),
fcp
:
String
(
i
[
11
].
fcp
),
TBF
:
String
(
i
[
11
].
tbf
)
tbf
:
String
(
i
[
11
].
tbf
)
},
},
april
:
{
april
:
{
TBC
:
String
(
i
[
12
].
tbc
),
tbc
:
String
(
i
[
12
].
tbc
),
FCP
:
String
(
i
[
12
].
fcp
),
fcp
:
String
(
i
[
12
].
fcp
),
TBF
:
String
(
i
[
12
].
tbf
)
tbf
:
String
(
i
[
12
].
tbf
)
},
},
may
:
{
may
:
{
TBC
:
String
(
i
[
13
].
tbc
),
tbc
:
String
(
i
[
13
].
tbc
),
FCP
:
String
(
i
[
13
].
fcp
),
fcp
:
String
(
i
[
13
].
fcp
),
TBF
:
String
(
i
[
13
].
tbf
)
tbf
:
String
(
i
[
13
].
tbf
)
},
},
june
:
{
june
:
{
TBC
:
String
(
i
[
14
].
tbc
),
tbc
:
String
(
i
[
14
].
tbc
),
FCP
:
String
(
i
[
14
].
fcp
),
fcp
:
String
(
i
[
14
].
fcp
),
TBF
:
String
(
i
[
14
].
tbf
)
tbf
:
String
(
i
[
14
].
tbf
)
},
},
july
:
{
july
:
{
TBC
:
String
(
i
[
15
].
tbc
),
tbc
:
String
(
i
[
15
].
tbc
),
FCP
:
String
(
i
[
15
].
fcp
),
fcp
:
String
(
i
[
15
].
fcp
),
TBF
:
String
(
i
[
15
].
tbf
)
tbf
:
String
(
i
[
15
].
tbf
)
},
},
august
:
{
august
:
{
TBC
:
String
(
i
[
16
].
tbc
),
tbc
:
String
(
i
[
16
].
tbc
),
FCP
:
String
(
i
[
16
].
fcp
),
fcp
:
String
(
i
[
16
].
fcp
),
TBF
:
String
(
i
[
16
].
tbf
)
tbf
:
String
(
i
[
16
].
tbf
)
},
},
september
:
{
september
:
{
TBC
:
String
(
i
[
17
].
tbc
),
tbc
:
String
(
i
[
17
].
tbc
),
FCP
:
String
(
i
[
17
].
fcp
),
fcp
:
String
(
i
[
17
].
fcp
),
TBF
:
String
(
i
[
17
].
tbf
)
tbf
:
String
(
i
[
17
].
tbf
)
},
},
october
:
{
october
:
{
TBC
:
String
(
i
[
18
].
tbc
),
tbc
:
String
(
i
[
18
].
tbc
),
FCP
:
String
(
i
[
18
].
fcp
),
fcp
:
String
(
i
[
18
].
fcp
),
TBF
:
String
(
i
[
18
].
tbf
)
tbf
:
String
(
i
[
18
].
tbf
)
},
},
november
:
{
november
:
{
TBC
:
String
(
i
[
19
].
tbc
),
tbc
:
String
(
i
[
19
].
tbc
),
FCP
:
String
(
i
[
19
].
fcp
),
fcp
:
String
(
i
[
19
].
fcp
),
TBF
:
String
(
i
[
19
].
tbf
)
tbf
:
String
(
i
[
19
].
tbf
)
},
},
december
:
{
december
:
{
TBC
:
String
(
i
[
20
].
tbc
),
tbc
:
String
(
i
[
20
].
tbc
),
FCP
:
String
(
i
[
20
].
fcp
),
fcp
:
String
(
i
[
20
].
fcp
),
TBF
:
String
(
i
[
20
].
tbf
)
tbf
:
String
(
i
[
20
].
tbf
)
},
},
total_current_year
:
String
(
i
[
21
]),
total_current_year
:
String
(
i
[
21
]),
total_next_year
:
{
total_next_year
:
{
TBC
:
String
(
i
[
22
].
tbc
),
tbc
:
String
(
i
[
22
].
tbc
),
FCP
:
String
(
i
[
22
].
fcp
),
fcp
:
String
(
i
[
22
].
fcp
),
TBF
:
String
(
i
[
22
].
tbf
)
tbf
:
String
(
i
[
22
].
tbf
)
},
},
total_more_year
:
{
total_more_year
:
{
TBC
:
String
(
i
[
23
].
tbc
),
tbc
:
String
(
i
[
23
].
tbc
),
FCP
:
String
(
i
[
23
].
fcp
),
fcp
:
String
(
i
[
23
].
fcp
),
TBF
:
String
(
i
[
23
].
tbf
)
tbf
:
String
(
i
[
23
].
tbf
)
}
}
})
})
})
})
...
@@ -296,75 +298,75 @@ export default class TaxPlanning extends Component {
...
@@ -296,75 +298,75 @@ export default class TaxPlanning extends Component {
// item_report_name: this.state.reportName,
// item_report_name: this.state.reportName,
item_report
:
i
[
1
]
===
undefined
?
""
:
String
(
i
[
1
]).
trim
(),
item_report
:
i
[
1
]
===
undefined
?
""
:
String
(
i
[
1
]).
trim
(),
january
:
{
january
:
{
TBC
:
i
[
2
]
===
undefined
?
""
:
String
(
i
[
2
]).
trim
(),
tbc
:
i
[
2
]
===
undefined
?
""
:
String
(
i
[
2
]).
trim
(),
FCP
:
i
[
3
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
3
]))
===
false
?
"0"
:
String
(
i
[
3
]).
trim
(),
fcp
:
i
[
3
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
3
]))
===
false
?
"0"
:
String
(
i
[
3
]).
trim
(),
TBF
:
i
[
4
]
===
undefined
?
""
:
String
(
i
[
4
]).
trim
()
tbf
:
i
[
4
]
===
undefined
?
""
:
String
(
i
[
4
]).
trim
()
},
},
february
:
{
february
:
{
TBC
:
String
(
i
[
10
].
tbc
),
tbc
:
i
[
5
]
===
undefined
?
""
:
String
(
i
[
5
]).
trim
(
),
FCP
:
String
(
i
[
10
].
fcp
),
fcp
:
i
[
6
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
6
]))
===
false
?
"0"
:
String
(
i
[
6
]).
trim
(
),
TBF
:
String
(
i
[
10
].
tbf
)
tbf
:
i
[
7
]
===
undefined
?
""
:
String
(
i
[
7
]).
trim
(
)
},
},
march
:
{
march
:
{
TBC
:
String
(
i
[
11
].
tbc
),
tbc
:
i
[
8
]
===
undefined
?
""
:
String
(
i
[
8
]).
trim
(
),
FCP
:
String
(
i
[
11
].
fcp
),
fcp
:
i
[
9
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
9
]))
===
false
?
"0"
:
String
(
i
[
9
]).
trim
(
),
TBF
:
String
(
i
[
11
].
tbf
)
tbf
:
i
[
10
]
===
undefined
?
""
:
String
(
i
[
10
]).
trim
(),
},
},
april
:
{
april
:
{
TBC
:
String
(
i
[
12
].
tbc
),
tbc
:
i
[
11
]
===
undefined
?
""
:
String
(
i
[
11
]).
trim
(
),
FCP
:
String
(
i
[
12
].
fcp
),
fcp
:
i
[
12
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
12
]))
===
false
?
"0"
:
String
(
i
[
12
]).
trim
(
),
TBF
:
String
(
i
[
12
].
tbf
)
tbf
:
i
[
13
]
===
undefined
?
""
:
String
(
i
[
13
]).
trim
(
)
},
},
may
:
{
may
:
{
TBC
:
String
(
i
[
13
].
tbc
),
tbc
:
i
[
14
]
===
undefined
?
""
:
String
(
i
[
14
]).
trim
(
),
FCP
:
String
(
i
[
13
].
fcp
),
fcp
:
i
[
15
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
15
]))
===
false
?
"0"
:
String
(
i
[
15
]).
trim
(
),
TBF
:
String
(
i
[
13
].
tbf
)
tbf
:
i
[
16
]
===
undefined
?
""
:
String
(
i
[
16
]).
trim
(
)
},
},
june
:
{
june
:
{
TBC
:
String
(
i
[
14
].
tbc
),
tbc
:
i
[
17
]
===
undefined
?
""
:
String
(
i
[
17
]).
trim
(
),
FCP
:
String
(
i
[
14
].
fcp
),
fcp
:
i
[
18
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
18
]))
===
false
?
"0"
:
String
(
i
[
18
]).
trim
(
),
TBF
:
String
(
i
[
14
].
tbf
)
tbf
:
i
[
19
]
===
undefined
?
""
:
String
(
i
[
19
]).
trim
(
)
},
},
july
:
{
july
:
{
TBC
:
String
(
i
[
15
].
tbc
),
tbc
:
i
[
20
]
===
undefined
?
""
:
String
(
i
[
20
]).
trim
(
),
FCP
:
String
(
i
[
15
].
fcp
),
fcp
:
i
[
21
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
21
]))
===
false
?
"0"
:
String
(
i
[
21
]).
trim
(
),
TBF
:
String
(
i
[
15
].
tbf
)
tbf
:
i
[
22
]
===
undefined
?
""
:
String
(
i
[
22
]).
trim
(
)
},
},
august
:
{
august
:
{
TBC
:
String
(
i
[
16
].
tbc
),
tbc
:
i
[
23
]
===
undefined
?
""
:
String
(
i
[
23
]).
trim
(
),
FCP
:
String
(
i
[
16
].
fcp
),
fcp
:
i
[
24
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
24
]))
===
false
?
"0"
:
String
(
i
[
24
]).
trim
(
),
TBF
:
String
(
i
[
16
].
tbf
)
tbf
:
i
[
25
]
===
undefined
?
""
:
String
(
i
[
25
]).
trim
(
)
},
},
september
:
{
september
:
{
TBC
:
String
(
i
[
17
].
tbc
),
tbc
:
i
[
26
]
===
undefined
?
""
:
String
(
i
[
26
]).
trim
(
),
FCP
:
String
(
i
[
17
].
fcp
),
fcp
:
i
[
27
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
27
]))
===
false
?
"0"
:
String
(
i
[
27
]).
trim
(
),
TBF
:
String
(
i
[
17
].
tbf
)
tbf
:
i
[
28
]
===
undefined
?
""
:
String
(
i
[
28
]).
trim
(
)
},
},
october
:
{
october
:
{
TBC
:
String
(
i
[
18
].
tbc
),
tbc
:
i
[
29
]
===
undefined
?
""
:
String
(
i
[
29
]).
trim
(
),
FCP
:
String
(
i
[
18
].
fcp
),
fcp
:
i
[
30
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
30
]))
===
false
?
"0"
:
String
(
i
[
30
]).
trim
(
),
TBF
:
String
(
i
[
18
].
tbf
)
tbf
:
i
[
31
]
===
undefined
?
""
:
String
(
i
[
31
]).
trim
(
)
},
},
november
:
{
november
:
{
TBC
:
String
(
i
[
19
].
tbc
),
tbc
:
i
[
32
]
===
undefined
?
""
:
String
(
i
[
32
]).
trim
(
),
FCP
:
String
(
i
[
19
].
fcp
),
fcp
:
i
[
33
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
33
]))
===
false
?
"0"
:
String
(
i
[
33
]).
trim
(
),
TBF
:
String
(
i
[
19
].
tbf
)
tbf
:
i
[
34
]
===
undefined
?
""
:
String
(
i
[
34
]).
trim
(
)
},
},
december
:
{
december
:
{
TBC
:
String
(
i
[
20
].
tbc
),
tbc
:
i
[
35
]
===
undefined
?
""
:
String
(
i
[
35
]).
trim
(
),
FCP
:
String
(
i
[
20
].
fcp
),
fcp
:
i
[
36
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
36
]))
===
false
?
"0"
:
String
(
i
[
36
]).
trim
(
),
TBF
:
String
(
i
[
20
].
tbf
)
tbf
:
i
[
37
]
===
undefined
?
""
:
String
(
i
[
37
]).
trim
(
)
},
},
total_current_year
:
String
(
i
[
21
]
),
total_current_year
:
i
[
38
]
===
undefined
?
""
:
String
(
i
[
38
]).
trim
(
),
total_next_year
:
{
total_next_year
:
{
TBC
:
String
(
i
[
22
].
tbc
),
tbc
:
i
[
39
]
===
undefined
?
""
:
String
(
i
[
39
]).
trim
(
),
FCP
:
String
(
i
[
22
].
fcp
),
fcp
:
i
[
40
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
40
]))
===
false
?
"0"
:
String
(
i
[
40
]).
trim
(
),
TBF
:
String
(
i
[
22
].
tbf
)
tbf
:
i
[
41
]
===
undefined
?
""
:
String
(
i
[
41
]).
trim
(
)
},
},
total_more_year
:
{
total_more_year
:
{
TBC
:
String
(
i
[
23
].
tbc
),
tbc
:
i
[
42
]
===
undefined
?
""
:
String
(
i
[
42
]).
trim
(
),
FCP
:
String
(
i
[
23
].
fcp
),
fcp
:
i
[
43
]
===
undefined
?
"0"
:
reg
.
test
(
String
(
i
[
43
]))
===
false
?
"0"
:
String
(
i
[
43
]).
trim
(
),
TBF
:
String
(
i
[
23
].
tbf
)
tbf
:
i
[
44
]
===
undefined
?
""
:
String
(
i
[
44
]).
trim
(
)
}
}
})
})
}
}
...
@@ -373,7 +375,7 @@ export default class TaxPlanning extends Component {
...
@@ -373,7 +375,7 @@ export default class TaxPlanning extends Component {
company_id
:
this
.
props
.
company
.
company_id
,
company_id
:
this
.
props
.
company
.
company_id
,
periode
:
this
.
props
.
periode
,
periode
:
this
.
props
.
periode
,
report_id
:
this
.
props
.
report_id
,
report_id
:
this
.
props
.
report_id
,
balance_sheet
:
payload
tax_planning
:
payload
}
}
console
.
log
(
body
)
console
.
log
(
body
)
this
.
setState
({
payload
:
body
,
judul
:
resp
.
rows
[
1
][
0
],
judulColumn
:
resp
.
rows
[
2
]
})
this
.
setState
({
payload
:
body
,
judul
:
resp
.
rows
[
1
][
0
],
judulColumn
:
resp
.
rows
[
2
]
})
...
@@ -383,49 +385,154 @@ export default class TaxPlanning extends Component {
...
@@ -383,49 +385,154 @@ export default class TaxPlanning extends Component {
checkUpload
()
{
checkUpload
()
{
api
.
create
().
checkUploadMB
(
this
.
state
.
payload
).
then
(
response
=>
{
api
.
create
().
checkUploadMB
(
this
.
state
.
payload
).
then
(
response
=>
{
//
console.log(JSON.stringify(this.state.payload));
console
.
log
(
JSON
.
stringify
(
this
.
state
.
payload
));
console
.
log
(
response
)
console
.
log
(
response
)
//
if (response.data) {
if
(
response
.
data
)
{
//
if (response.data.status === 'success') {
if
(
response
.
data
.
status
===
'success'
)
{
//
this.setState({ visibleUpload: false, visibleTP: false, loading: true })
this
.
setState
({
visibleUpload
:
false
,
visibleTP
:
false
,
loading
:
true
})
//
let dataTable = response.data.data.map((item, index) => {
let
dataTable
=
response
.
data
.
data
.
map
((
item
,
index
)
=>
{
//
return [
return
[
// item.type_report_id,
// item.type_report_id,
// item.item_report_id,
0
,
// item.parent,
Number
(
item
.
type_report_id
.
tbc
),
// item.formula,
Number
(
item
.
type_report_id
.
fcp
),
// item.level,
Number
(
item
.
type_report_id
.
tbf
),
// item.item_report,
item
.
item_report_id
,
// item.total_actual_before,
item
.
parent
,
// item.january,
item
.
formula
,
// item.february,
// {tbc: item.formula.tbc, fcp: item.formula.fcp, tbf: item.formula.tbf},
// item.march,
item
.
level
,
// item.april,
item
.
item_report
,
// item.may,
{
tbc
:
item
.
january
.
tbc
,
fcp
:
item
.
january
.
fcp
,
tbf
:
item
.
january
.
tbf
},
// item.june,
{
tbc
:
item
.
february
.
tbc
,
fcp
:
item
.
february
.
fcp
,
tbf
:
item
.
february
.
tbf
},
// item.july,
{
tbc
:
item
.
march
.
tbc
,
fcp
:
item
.
march
.
fcp
,
tbf
:
item
.
march
.
tbf
},
// item.august,
{
tbc
:
item
.
april
.
tbc
,
fcp
:
item
.
april
.
fcp
,
tbf
:
item
.
april
.
tbf
},
// item.september,
{
tbc
:
item
.
may
.
tbc
,
fcp
:
item
.
may
.
fcp
,
tbf
:
item
.
may
.
tbf
},
// item.october,
{
tbc
:
item
.
june
.
tbc
,
fcp
:
item
.
june
.
fcp
,
tbf
:
item
.
june
.
tbf
},
// item.november,
{
tbc
:
item
.
july
.
tbc
,
fcp
:
item
.
july
.
fcp
,
tbf
:
item
.
july
.
tbf
},
// item.december,
{
tbc
:
item
.
august
.
tbc
,
fcp
:
item
.
august
.
fcp
,
tbf
:
item
.
august
.
tbf
},
// item.total_current_year,
{
tbc
:
item
.
september
.
tbc
,
fcp
:
item
.
september
.
fcp
,
tbf
:
item
.
september
.
tbf
},
// item.total_next_year,
{
tbc
:
item
.
october
.
tbc
,
fcp
:
item
.
october
.
fcp
,
tbf
:
item
.
october
.
tbf
},
// item.total_more_year,
{
tbc
:
item
.
november
.
tbc
,
fcp
:
item
.
november
.
fcp
,
tbf
:
item
.
november
.
tbf
},
// item.error
{
tbc
:
item
.
december
.
tbc
,
fcp
:
item
.
december
.
fcp
,
tbf
:
item
.
december
.
tbf
},
// ]
item
.
total_current_year
,
// })
{
tbc
:
item
.
total_next_year
.
tbc
,
fcp
:
item
.
total_next_year
.
fcp
,
tbf
:
item
.
total_next_year
.
tbf
},
// this.setState({ dataTable, dataLoaded: true, loading: false, buttonError: false }, () => {
{
tbc
:
item
.
total_more_year
.
tbc
,
fcp
:
item
.
total_more_year
.
fcp
,
tbf
:
item
.
total_more_year
.
tbf
},
// this.state.dataTable.map(item => {
item
.
error
// if (item[22].length > 0) {
]
// console.log('masuk')
})
// this.setState({ buttonError: true, errorPreview: true })
this
.
setState
({
dataTable
,
dataLoaded
:
true
,
loading
:
false
,
buttonError
:
false
},
()
=>
{
// }
this
.
state
.
dataTable
.
map
(
item
=>
{
// })
if
(
item
[
24
].
length
>
0
)
{
// // console.log(this.state.dataTable);
console
.
log
(
'masuk'
)
// })
this
.
setState
({
buttonError
:
true
,
errorPreview
:
true
})
// }
}
// }
})
console
.
log
(
this
.
state
.
dataTable
);
})
}
}
})
}
uploadTP
()
{
let
data
=
[]
this
.
state
.
dataTable
.
map
(
i
=>
{
data
.
push
({
item_report_id
:
i
[
4
],
january
:
{
tbc
:
String
(
i
[
9
].
tbc
),
fcp
:
String
(
i
[
9
].
fcp
),
tbf
:
String
(
i
[
9
].
tbf
)
},
february
:
{
tbc
:
String
(
i
[
10
].
tbc
),
fcp
:
String
(
i
[
10
].
fcp
),
tbf
:
String
(
i
[
10
].
tbf
)
},
march
:
{
tbc
:
String
(
i
[
11
].
tbc
),
fcp
:
String
(
i
[
11
].
fcp
),
tbf
:
String
(
i
[
11
].
tbf
)
},
april
:
{
tbc
:
String
(
i
[
12
].
tbc
),
fcp
:
String
(
i
[
12
].
fcp
),
tbf
:
String
(
i
[
12
].
tbf
)
},
may
:
{
tbc
:
String
(
i
[
13
].
tbc
),
fcp
:
String
(
i
[
13
].
fcp
),
tbf
:
String
(
i
[
13
].
tbf
)
},
june
:
{
tbc
:
String
(
i
[
14
].
tbc
),
fcp
:
String
(
i
[
14
].
fcp
),
tbf
:
String
(
i
[
14
].
tbf
)
},
july
:
{
tbc
:
String
(
i
[
15
].
tbc
),
fcp
:
String
(
i
[
15
].
fcp
),
tbf
:
String
(
i
[
15
].
tbf
)
},
august
:
{
tbc
:
String
(
i
[
16
].
tbc
),
fcp
:
String
(
i
[
16
].
fcp
),
tbf
:
String
(
i
[
16
].
tbf
)
},
september
:
{
tbc
:
String
(
i
[
17
].
tbc
),
fcp
:
String
(
i
[
17
].
fcp
),
tbf
:
String
(
i
[
17
].
tbf
)
},
october
:
{
tbc
:
String
(
i
[
18
].
tbc
),
fcp
:
String
(
i
[
18
].
fcp
),
tbf
:
String
(
i
[
18
].
tbf
)
},
november
:
{
tbc
:
String
(
i
[
19
].
tbc
),
fcp
:
String
(
i
[
19
].
fcp
),
tbf
:
String
(
i
[
19
].
tbf
)
},
december
:
{
tbc
:
String
(
i
[
20
].
tbc
),
fcp
:
String
(
i
[
20
].
fcp
),
tbf
:
String
(
i
[
20
].
tbf
)
},
total_current_year
:
String
(
i
[
21
]),
total_next_year
:
{
tbc
:
String
(
i
[
22
].
tbc
),
fcp
:
String
(
i
[
22
].
fcp
),
tbf
:
String
(
i
[
22
].
tbf
)
},
total_more_year
:
{
tbc
:
String
(
i
[
23
].
tbc
),
fcp
:
String
(
i
[
23
].
fcp
),
tbf
:
String
(
i
[
23
].
tbf
)
}
})
})
let
body
=
{
submission_id
:
this
.
props
.
submissionID
,
company_id
:
this
.
props
.
company
.
company_id
,
periode
:
this
.
props
.
periode
,
report_id
:
this
.
props
.
report_id
,
tax_planning
:
data
}
console
.
log
(
data
);
api
.
create
(
'UPLOAD'
).
uploadMasterBudget
(
body
).
then
(
response
=>
{
console
.
log
(
response
);
if
(
response
.
data
)
{
if
(
response
.
data
.
status
===
"success"
)
{
this
.
props
.
onClickClose
()
this
.
props
.
getReport
()
}
else
{
alert
(
response
.
data
.
status
)
}
}
else
{
alert
(
response
.
problem
)
}
})
})
}
}
...
@@ -476,6 +583,18 @@ export default class TaxPlanning extends Component {
...
@@ -476,6 +583,18 @@ export default class TaxPlanning extends Component {
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
].
fcp
=
Number
(
val
)
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
].
fcp
=
Number
(
val
)
}
}
}
}
const
handleTotal
=
(
tableMeta
)
=>
{
let
total
=
0
dataTable2
[
tableMeta
.
rowIndex
].
map
((
item
,
index
)
=>
{
if
(
index
>=
9
&&
index
<=
20
)
{
let
valItem
=
item
==
undefined
||
item
==
""
?
0
:
item
total
+=
Number
(
valItem
)
}
})
dataTable2
[
tableMeta
.
rowIndex
][
19
]
=
total
return
total
// console.log(total);
}
const
handleValue
=
(
data
)
=>
{
const
handleValue
=
(
data
)
=>
{
let
total
=
0
let
total
=
0
// console.log(dataTable2)
// console.log(dataTable2)
...
@@ -586,8 +705,8 @@ export default class TaxPlanning extends Component {
...
@@ -586,8 +705,8 @@ export default class TaxPlanning extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
customBodyRender
:
(
val
,
tableMeta
)
=>
{
return
(
return
(
<
div
style
=
{{
width
:
300
}}
>
<
div
style
=
{{
width
:
300
}}
>
{
tableMeta
.
rowData
[
2
2
]
?
{
tableMeta
.
rowData
[
2
4
]
?
tableMeta
.
rowData
[
2
2
].
length
>
0
?
tableMeta
.
rowData
[
2
4
].
length
>
0
?
<
div
style
=
{{
paddingLeft
:
20
*
Number
(
tableMeta
.
rowData
[
4
])
}}
>
<
div
style
=
{{
paddingLeft
:
20
*
Number
(
tableMeta
.
rowData
[
4
])
}}
>
<
LightTooltip
title
=
{
"Report Items Not Registered"
}
arrow
>
<
LightTooltip
title
=
{
"Report Items Not Registered"
}
arrow
>
<
span
style
=
{{
fontSize
:
12
,
color
:
'red'
}}
>
{
tableMeta
.
rowData
[
0
]
===
4
?
""
:
val
}
<
/span
>
<
span
style
=
{{
fontSize
:
12
,
color
:
'red'
}}
>
{
tableMeta
.
rowData
[
0
]
===
4
?
""
:
val
}
<
/span
>
...
@@ -4514,13 +4633,14 @@ export default class TaxPlanning extends Component {
...
@@ -4514,13 +4633,14 @@ export default class TaxPlanning extends Component {
<
/div
>
<
/div
>
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
(
this
.
props
.
open
===
true
?
400
:
150
)
}}
>
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
(
this
.
props
.
open
===
true
?
400
:
150
)
}}
>
{
!
this
.
state
.
loading
&&
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
{
this
.
state
.
loading
&&
loadingComponent
}
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
<
MUIDataTable
<
MUIDataTable
data
=
{
dataTable2
}
data
=
{
dataTable2
}
columns
=
{
columns
}
columns
=
{
columns
}
options
=
{
options
}
options
=
{
options
}
/
>
/
>
<
/MuiThemeProvider>
}
<
/MuiThemeProvider
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x"
style
=
{{
marginTop
:
20
}}
>
<
div
className
=
"grid grid-2x"
style
=
{{
marginTop
:
20
}}
>
...
@@ -4623,13 +4743,14 @@ export default class TaxPlanning extends Component {
...
@@ -4623,13 +4743,14 @@ export default class TaxPlanning extends Component {
<
/div
>
<
/div
>
{
this
.
state
.
dataLoaded
&&
(
{
this
.
state
.
dataLoaded
&&
(
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
(
this
.
props
.
open
===
true
?
400
:
150
)
}}
>
<
div
style
=
{{
marginTop
:
20
,
width
:
this
.
props
.
width
-
(
this
.
props
.
open
===
true
?
400
:
150
)
}}
>
{
!
this
.
state
.
loading
&&
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
{
this
.
state
.
loading
&&
loadingComponent
}
<
MuiThemeProvider
theme
=
{
getMuiTheme
()}
>
<
MUIDataTable
<
MUIDataTable
data
=
{
dataTable2
}
data
=
{
dataTable2
}
columns
=
{
columns
}
columns
=
{
columns
}
options
=
{
options
}
options
=
{
options
}
/
>
/
>
<
/MuiThemeProvider>
}
<
/MuiThemeProvider
>
<
/div
>
<
/div
>
)}
)}
<
/div
>
<
/div
>
...
@@ -4675,7 +4796,7 @@ export default class TaxPlanning extends Component {
...
@@ -4675,7 +4796,7 @@ export default class TaxPlanning extends Component {
disabled
=
{
this
.
state
.
buttonError
}
disabled
=
{
this
.
state
.
buttonError
}
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
{
onClick
=
{()
=>
this
.
setState
({
loading
:
true
},
()
=>
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
this
.
upload
BalanceSheet
()
this
.
upload
TP
()
},
100
);
},
100
);
})}
})}
>
>
...
...
src/container/DocumentManagement/CreateManagementDoc.js
View file @
d92ca86a
...
@@ -362,7 +362,7 @@ export default class CreateManagementDoc extends Component {
...
@@ -362,7 +362,7 @@ export default class CreateManagementDoc extends Component {
type
=
{
this
.
state
.
uploadStatus
}
type
=
{
this
.
state
.
uploadStatus
}
percentage
=
{
this
.
state
.
percentage
}
percentage
=
{
this
.
state
.
percentage
}
result
=
{
this
.
state
.
result
}
result
=
{
this
.
state
.
result
}
acceptedFiles
=
{[
"xls"
,
"xlsx"
,
"pdf"
,
"PDF"
]}
acceptedFiles
=
{[
"xls"
,
"xlsx"
,
"pdf"
,
"PDF"
,
"docx"
,
"doc"
,
"pptx"
,
"ppt"
,
"ods"
,
"odf"
]}
intent
=
{
"management"
}
intent
=
{
"management"
}
onHandle
=
{(
dt
)
=>
{
onHandle
=
{(
dt
)
=>
{
this
.
fileHandler
(
dt
)
this
.
fileHandler
(
dt
)
...
...
src/container/DocumentManagement/EditManagementDoc.js
View file @
d92ca86a
...
@@ -407,7 +407,7 @@ export default class EditManagementDoc extends Component {
...
@@ -407,7 +407,7 @@ export default class EditManagementDoc extends Component {
type
=
{
this
.
state
.
uploadStatus
}
type
=
{
this
.
state
.
uploadStatus
}
percentage
=
{
this
.
state
.
percentage
}
percentage
=
{
this
.
state
.
percentage
}
result
=
{
this
.
state
.
result
}
result
=
{
this
.
state
.
result
}
acceptedFiles
=
{[
"xls"
,
"xlsx"
,
"pdf"
,
"PDF"
]}
acceptedFiles
=
{[
"xls"
,
"xlsx"
,
"pdf"
,
"PDF"
,
"docx"
,
"doc"
,
"pptx"
,
"ppt"
,
"ods"
,
"odf"
]}
intent
=
{
"management"
}
intent
=
{
"management"
}
onHandle
=
{(
dt
)
=>
{
onHandle
=
{(
dt
)
=>
{
this
.
fileHandler
(
dt
)
this
.
fileHandler
(
dt
)
...
...
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