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
da2ba108
Commit
da2ba108
authored
May 23, 2023
by
Riri Novita
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev/riri' into 'ENV-DEV'
Update Bug UI Report Items See merge request
!1799
parents
cab2c395
db8da809
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
444 additions
and
324 deletions
+444
-324
Images.js
src/assets/Images.js
+1
-0
BudgetTahunan.js
src/container/BudgetTahunan/BudgetTahunan.js
+17
-10
ProfitLoss.js
src/container/BudgetTahunan/ProfitLoss.js
+59
-13
CreateParameter.js
src/container/MasterData/Parameter/CreateParameter.js
+363
-298
ReportItems.js
src/container/MasterData/ReportItems/ReportItems.js
+4
-3
No files found.
src/assets/Images.js
View file @
da2ba108
...
@@ -56,6 +56,7 @@ const Images = {
...
@@ -56,6 +56,7 @@ const Images = {
dotOverdue
:
require
(
'./dot-overdue.svg'
),
dotOverdue
:
require
(
'./dot-overdue.svg'
),
dotOpen
:
require
(
'./dot-open.svg'
),
dotOpen
:
require
(
'./dot-open.svg'
),
zip
:
require
(
'./zip.png'
),
zip
:
require
(
'./zip.png'
),
warning
:
require
(
'./warning.png'
),
}
}
export
default
Images
export
default
Images
\ No newline at end of file
src/container/BudgetTahunan/BudgetTahunan.js
View file @
da2ba108
...
@@ -312,7 +312,6 @@ export default class BudgetTahunan extends Component {
...
@@ -312,7 +312,6 @@ export default class BudgetTahunan extends Component {
"report_type"
:
"Master Budget"
,
"report_type"
:
"Master Budget"
,
"currency_id"
:
this
.
state
.
defaultCurrency
.
id
"currency_id"
:
this
.
state
.
defaultCurrency
.
id
}
}
// console.log(payload);
api
.
create
().
getReportTypeBody
(
payload
).
then
(
response
=>
{
api
.
create
().
getReportTypeBody
(
payload
).
then
(
response
=>
{
// console.log(response);
// console.log(response);
if
(
response
.
data
)
{
if
(
response
.
data
)
{
...
@@ -2316,7 +2315,7 @@ export default class BudgetTahunan extends Component {
...
@@ -2316,7 +2315,7 @@ export default class BudgetTahunan extends Component {
// console.log(data);
// console.log(data);
// // // console.log(JSON.stringify(data));
// // // console.log(JSON.stringify(data));
api
.
create
(
'UPLOAD'
).
createSubmitReport
(
data
).
then
(
response
=>
{
api
.
create
(
'UPLOAD'
).
createSubmitReport
(
data
).
then
(
response
=>
{
//
console.log(response);
console
.
log
(
response
);
if
(
response
.
data
)
{
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
if
(
response
.
ok
)
{
if
(
response
.
data
.
status
===
'success'
)
{
if
(
response
.
data
.
status
===
'success'
)
{
...
@@ -2518,7 +2517,7 @@ export default class BudgetTahunan extends Component {
...
@@ -2518,7 +2517,7 @@ export default class BudgetTahunan extends Component {
// }
// }
async
handleGenerateReport
(
data
)
{
async
handleGenerateReport
(
data
)
{
let
{
selectReport
,
submissionID
,
company
,
periode
,
month
,
downloadedFileReportId
}
=
this
.
state
let
{
selectReport
,
submissionID
,
company
,
periode
,
month
,
downloadedFileReportId
,
defaultCurrency
}
=
this
.
state
if
(
selectReport
.
length
>
0
)
{
if
(
selectReport
.
length
>
0
)
{
let
result
=
[]
let
result
=
[]
// console.log('mulai hit')
// console.log('mulai hit')
...
@@ -2526,8 +2525,8 @@ export default class BudgetTahunan extends Component {
...
@@ -2526,8 +2525,8 @@ export default class BudgetTahunan extends Component {
let
datas
=
data
.
findIndex
((
val
)
=>
val
[
4
]
==
items
)
let
datas
=
data
.
findIndex
((
val
)
=>
val
[
4
]
==
items
)
let
report
=
data
[
datas
]
let
report
=
data
[
datas
]
if
(
items
===
6
)
{
if
(
items
===
6
)
{
let
resReal
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/cash_flow/master_budget/export_master_budget?submission_id=
${
submissionID
}
&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&report_id=
${
report
[
4
]}
&download_file_report_id=
${
downloadedFileReportId
}
`
let
resReal
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/cash_flow/master_budget/export_master_budget?submission_id=
${
submissionID
}
&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&report_id=
${
report
[
4
]}
&download_file_report_id=
${
downloadedFileReportId
}
¤cy_id=
${
defaultCurrency
.
id
}
`
let
resNull
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/cash_flow/master_budget/export_master_budget?submission_id=&&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&report_id=
${
report
[
4
]}
&download_file_report_id=
${
downloadedFileReportId
}
`
let
resNull
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/cash_flow/master_budget/export_master_budget?submission_id=&&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&report_id=
${
report
[
4
]}
&download_file_report_id=
${
downloadedFileReportId
}
¤cy_id=
${
defaultCurrency
.
id
}
`
let
res
=
await
fetch
(
let
res
=
await
fetch
(
submissionID
==
null
?
resNull
:
resReal
submissionID
==
null
?
resNull
:
resReal
...
@@ -2541,8 +2540,8 @@ export default class BudgetTahunan extends Component {
...
@@ -2541,8 +2540,8 @@ export default class BudgetTahunan extends Component {
result
=
[...
result
,
res
];
result
=
[...
result
,
res
];
}
}
}
else
{
}
else
{
let
resReal
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/master_budget/export_master_budget?submission_id=
${
submissionID
}
&report_id=
${
report
[
4
]}
&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&download_file_report_id=
${
downloadedFileReportId
}
`
let
resReal
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/master_budget/export_master_budget?submission_id=
${
submissionID
}
&report_id=
${
report
[
4
]}
&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&download_file_report_id=
${
downloadedFileReportId
}
¤cy_id=
${
defaultCurrency
.
id
}
`
let
resNull
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/master_budget/export_master_budget?submission_id=&report_id=
${
report
[
4
]}
&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&download_file_report_id=
${
downloadedFileReportId
}
`
let
resNull
=
`
${
process
.
env
.
REACT_APP_URL_MAIN_BE
}
/public/transaction/master_budget/export_master_budget?submission_id=&report_id=
${
report
[
4
]}
&company_id=
${
company
.
company_id
}
&year=
${
periode
.
periode
}
&revision=
${
report
[
2
]}
&download_file_report_id=
${
downloadedFileReportId
}
¤cy_id=
${
defaultCurrency
.
id
}
`
let
res
=
await
fetch
(
let
res
=
await
fetch
(
submissionID
==
null
?
resNull
:
resReal
submissionID
==
null
?
resNull
:
resReal
...
@@ -2604,7 +2603,7 @@ export default class BudgetTahunan extends Component {
...
@@ -2604,7 +2603,7 @@ export default class BudgetTahunan extends Component {
async
handleZip
()
{
async
handleZip
()
{
// console.log('mulai zip')
// console.log('mulai zip')
api
.
create
().
createZipReport
(
this
.
state
.
downloadedFileReportId
).
then
((
response
)
=>
{
api
.
create
().
createZipReport
(
this
.
state
.
downloadedFileReportId
).
then
((
response
)
=>
{
//
console.log(response)
console
.
log
(
response
)
if
(
response
.
data
)
{
if
(
response
.
data
)
{
if
(
response
.
ok
)
{
if
(
response
.
ok
)
{
if
(
response
.
data
.
status
===
'success'
)
{
if
(
response
.
data
.
status
===
'success'
)
{
...
@@ -2968,12 +2967,15 @@ export default class BudgetTahunan extends Component {
...
@@ -2968,12 +2967,15 @@ export default class BudgetTahunan extends Component {
options
=
{
this
.
state
.
currency
}
options
=
{
this
.
state
.
currency
}
getOptionLabel
=
{(
option
)
=>
option
.
value
}
getOptionLabel
=
{(
option
)
=>
option
.
value
}
value
=
{
this
.
state
.
defaultCurrency
}
value
=
{
this
.
state
.
defaultCurrency
}
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
defaultCurrency
:
newInputValue
})}
// onChange={(event, newInputValue) => this.setState({ defaultCurrency: newInputValue })}
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
defaultCurrency
:
newInputValue
},
()
=>
{
this
.
getRevision
()
})}
renderInput
=
{(
params
)
=>
renderInput
=
{(
params
)
=>
<
TextField
<
TextField
{...
params
}
{...
params
}
variant
=
"standard"
variant
=
"standard"
label
=
"
Default
Currency"
label
=
"Currency"
margin
=
"normal"
margin
=
"normal"
style
=
{{
marginTop
:
6
}}
style
=
{{
marginTop
:
6
}}
// InputProps={{ ...params.InputProps, style: { fontSize: 11 } }}
// InputProps={{ ...params.InputProps, style: { fontSize: 11 } }}
...
@@ -3387,6 +3389,7 @@ export default class BudgetTahunan extends Component {
...
@@ -3387,6 +3389,7 @@ export default class BudgetTahunan extends Component {
width
=
{
this
.
props
.
width
}
width
=
{
this
.
props
.
width
}
company
=
{
this
.
state
.
company
}
company
=
{
this
.
state
.
company
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
currency
=
{
this
.
state
.
currency
}
revision
=
{
this
.
state
.
revisionTable
}
revision
=
{
this
.
state
.
revisionTable
}
periode
=
{
this
.
state
.
periode
.
periode
}
periode
=
{
this
.
state
.
periode
.
periode
}
submissionID
=
{
this
.
state
.
submissionID
}
submissionID
=
{
this
.
state
.
submissionID
}
...
@@ -3434,6 +3437,7 @@ export default class BudgetTahunan extends Component {
...
@@ -3434,6 +3437,7 @@ export default class BudgetTahunan extends Component {
width
=
{
this
.
props
.
width
}
width
=
{
this
.
props
.
width
}
company
=
{
this
.
state
.
company
}
company
=
{
this
.
state
.
company
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
currency
=
{
this
.
state
.
currency
}
revision
=
{
this
.
state
.
revisionTable
}
revision
=
{
this
.
state
.
revisionTable
}
periode
=
{
this
.
state
.
periode
.
periode
}
periode
=
{
this
.
state
.
periode
.
periode
}
submissionID
=
{
this
.
state
.
submissionID
}
submissionID
=
{
this
.
state
.
submissionID
}
...
@@ -3457,6 +3461,7 @@ export default class BudgetTahunan extends Component {
...
@@ -3457,6 +3461,7 @@ export default class BudgetTahunan extends Component {
width
=
{
this
.
props
.
width
}
width
=
{
this
.
props
.
width
}
company
=
{
this
.
state
.
company
}
company
=
{
this
.
state
.
company
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
currency
=
{
this
.
state
.
currency
}
revision
=
{
this
.
state
.
revisionTable
}
revision
=
{
this
.
state
.
revisionTable
}
periode
=
{
this
.
state
.
periode
.
periode
}
periode
=
{
this
.
state
.
periode
.
periode
}
submissionID
=
{
this
.
state
.
submissionID
}
submissionID
=
{
this
.
state
.
submissionID
}
...
@@ -3480,6 +3485,7 @@ export default class BudgetTahunan extends Component {
...
@@ -3480,6 +3485,7 @@ export default class BudgetTahunan extends Component {
width
=
{
this
.
props
.
width
}
width
=
{
this
.
props
.
width
}
company
=
{
this
.
state
.
company
}
company
=
{
this
.
state
.
company
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
currency
=
{
this
.
state
.
currency
}
revision
=
{
this
.
state
.
revisionTable
}
revision
=
{
this
.
state
.
revisionTable
}
periode
=
{
this
.
state
.
periode
.
periode
}
periode
=
{
this
.
state
.
periode
.
periode
}
submissionID
=
{
this
.
state
.
submissionID
}
submissionID
=
{
this
.
state
.
submissionID
}
...
@@ -3506,6 +3512,7 @@ export default class BudgetTahunan extends Component {
...
@@ -3506,6 +3512,7 @@ export default class BudgetTahunan extends Component {
width
=
{
this
.
props
.
width
}
width
=
{
this
.
props
.
width
}
company
=
{
this
.
state
.
company
}
company
=
{
this
.
state
.
company
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
defaultCurrency
=
{
this
.
state
.
defaultCurrency
}
currency
=
{
this
.
state
.
currency
}
revision
=
{
this
.
state
.
revisionTable
}
revision
=
{
this
.
state
.
revisionTable
}
periode
=
{
this
.
state
.
periode
.
periode
}
periode
=
{
this
.
state
.
periode
.
periode
}
submissionID
=
{
this
.
state
.
submissionID
}
submissionID
=
{
this
.
state
.
submissionID
}
...
...
src/container/BudgetTahunan/ProfitLoss.js
View file @
da2ba108
...
@@ -64,7 +64,8 @@ export default class ProfitLoss extends Component {
...
@@ -64,7 +64,8 @@ export default class ProfitLoss extends Component {
buttonDraft
:
true
,
buttonDraft
:
true
,
handleDoubleClick
:
0
,
handleDoubleClick
:
0
,
fromUpload
:
false
,
fromUpload
:
false
,
defaultCurrencyUpload
:
this
.
props
.
defaultCurrency
defaultCurrencyUpload
:
this
.
props
.
defaultCurrency
,
visibleAlertSave
:
false
}
}
this
.
handleValue
=
this
.
handleValue
.
bind
(
this
)
this
.
handleValue
=
this
.
handleValue
.
bind
(
this
)
this
.
fileHandler
=
this
.
fileHandler
.
bind
(
this
);
this
.
fileHandler
=
this
.
fileHandler
.
bind
(
this
);
...
@@ -250,6 +251,7 @@ export default class ProfitLoss extends Component {
...
@@ -250,6 +251,7 @@ export default class ProfitLoss extends Component {
}
}
backToMasterBudget
(
type
)
{
backToMasterBudget
(
type
)
{
// tambahin currency
let
data
=
[]
let
data
=
[]
this
.
state
.
dataTable
.
map
(
i
=>
{
this
.
state
.
dataTable
.
map
(
i
=>
{
data
.
push
({
data
.
push
({
...
@@ -278,10 +280,11 @@ export default class ProfitLoss extends Component {
...
@@ -278,10 +280,11 @@ export default class ProfitLoss 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
,
"currency_id"
:
this
.
props
.
defaultCurrency
.
id
,
"status"
:
type
,
"status"
:
type
,
"profit_loss"
:
data
"profit_loss"
:
data
}
}
// console.log(data
);
console
.
log
(
payload
);
this
.
setState
({
loading
:
false
})
this
.
setState
({
loading
:
false
})
if
(
type
==
'submitted'
)
{
if
(
type
==
'submitted'
)
{
this
.
props
.
saveToMasterBudget
(
payload
,
'PL'
)
this
.
props
.
saveToMasterBudget
(
payload
,
'PL'
)
...
@@ -359,10 +362,10 @@ export default class ProfitLoss extends Component {
...
@@ -359,10 +362,10 @@ export default class ProfitLoss extends Component {
checkUpload
()
{
checkUpload
()
{
let
payload
=
{
let
payload
=
{
...
this
.
state
.
payload
,
...
this
.
state
.
payload
,
currency_id
:
this
.
state
.
defaultCurrencyUpload
?.
id
currency_id
:
this
.
state
.
defaultCurrencyUpload
?.
id
}
}
api
.
create
().
checkUploadMB
(
payload
).
then
(
response
=>
{
api
.
create
().
checkUploadMB
(
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'
)
{
...
@@ -407,7 +410,7 @@ export default class ProfitLoss extends Component {
...
@@ -407,7 +410,7 @@ export default class ProfitLoss extends Component {
})
})
}
else
{
}
else
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
,
loading
:
false
},
()
=>
{
this
.
setState
({
alert
:
true
,
messageAlert
:
response
.
data
.
message
,
tipeAlert
:
'warning'
,
visibleAlertSave
:
true
,
loading
:
false
},
()
=>
{
if
(
response
.
data
.
message
.
includes
(
"Someone Logged In"
)
||
response
.
data
.
message
.
includes
(
"Token Expired"
))
{
if
(
response
.
data
.
message
.
includes
(
"Someone Logged In"
)
||
response
.
data
.
message
.
includes
(
"Token Expired"
))
{
setTimeout
(()
=>
{
setTimeout
(()
=>
{
localStorage
.
removeItem
(
Constant
.
TOKEN
)
localStorage
.
removeItem
(
Constant
.
TOKEN
)
...
@@ -449,6 +452,7 @@ export default class ProfitLoss extends Component {
...
@@ -449,6 +452,7 @@ export default class ProfitLoss 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
,
currency_id
:
this
.
state
.
defaultCurrencyUpload
?.
id
,
profit_loss
:
data
,
profit_loss
:
data
,
status
:
type
status
:
type
}
}
...
@@ -533,6 +537,7 @@ export default class ProfitLoss extends Component {
...
@@ -533,6 +537,7 @@ export default class ProfitLoss 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
,
"currency_id"
:
this
.
props
.
defaultCurrency
.
id
,
"profit_loss"
:
data
,
"profit_loss"
:
data
,
"status"
:
"submitted"
"status"
:
"submitted"
}
}
...
@@ -554,7 +559,7 @@ export default class ProfitLoss extends Component {
...
@@ -554,7 +559,7 @@ export default class ProfitLoss extends Component {
render
()
{
render
()
{
let
dataTable2
=
this
.
state
.
dataTable
let
dataTable2
=
this
.
state
.
dataTable
const
handleChange
=
(
value
,
tableMeta
,
type
)
=>
{
const
handleChange
=
(
value
,
tableMeta
,
type
)
=>
{
console
.
log
(
dataTable2
);
//
console.log(dataTable2);
let
val
=
String
(
value
).
split
(
","
).
join
(
""
)
let
val
=
String
(
value
).
split
(
","
).
join
(
""
)
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
]
=
Number
(
val
)
dataTable2
[
tableMeta
.
rowIndex
][
tableMeta
.
columnIndex
]
=
Number
(
val
)
}
}
...
@@ -3027,6 +3032,7 @@ export default class ProfitLoss extends Component {
...
@@ -3027,6 +3032,7 @@ export default class ProfitLoss extends Component {
this
.
backToMasterBudget
(
'draft'
)
this
.
backToMasterBudget
(
'draft'
)
})
})
}
}
>
>
<
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
>
...
@@ -3035,13 +3041,16 @@ export default class ProfitLoss extends Component {
...
@@ -3035,13 +3041,16 @@ export default class ProfitLoss extends Component {
<
button
<
button
type
=
"button"
type
=
"button"
disabled
=
{
this
.
state
.
buttonError
}
disabled
=
{
this
.
state
.
buttonError
}
onClick
=
{()
=>
this
.
state
.
buttonError
?
onClick
=
{()
=>
this
.
setState
({
alert
:
true
,
messageAlert
:
'Data is not complete !'
,
tipeAlert
:
'warning'
})
this
.
setState
({
visibleAlertSave
:
true
})
:
}
this
.
state
.
handleDoubleClick
==
1
?
null
:
// onClick={() => this.state.buttonError ?
this
.
setState
({
handleDoubleClick
:
1
},
()
=>
{
// this.setState({ alert: true, messageAlert: 'Data is not complete !', tipeAlert: 'warning' })
this
.
backToMasterBudget
(
'submitted'
)
// :
})}
// this.state.handleDoubleClick == 1 ? null :
// this.setState({ handleDoubleClick: 1 }, () => {
// this.backToMasterBudget('submitted')
// })}
style
=
{{
style
=
{{
backgroundColor
:
'transparent'
,
backgroundColor
:
'transparent'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
cursor
:
this
.
state
.
buttonError
===
true
?
'default'
:
'pointer'
,
...
@@ -3243,6 +3252,43 @@ export default class ProfitLoss extends Component {
...
@@ -3243,6 +3252,43 @@ export default class ProfitLoss extends Component {
<
/div
>
<
/div
>
<
/div
>
<
/div
>
)}
)}
{
this
.
state
.
visibleAlertSave
&&
(
<
div
className
=
"test app-popup-show"
>
<
div
className
=
"popup-content border-radius"
style
=
{{
background
:
'#FFF27D'
,
borderRadius
:
10
,
width
:
715
,
height
:
238
}}
>
<
div
style
=
{{
margin
:
30
}}
>
<
div
style
=
{{
display
:
'flex'
,
marginTop
:
76
,
marginBottom
:
43
}}
>
<
div
style
=
{{
alignSelf
:
'center'
,
marginRight
:
25
}}
>
<
img
src
=
{
Images
.
warning
}
/
>
<
/div
>
<
div
style
=
{{
justifyContent
:
'center'
,
fontSize
:
20
,
color
:
'#1D2995'
,
marginTop
:
10
}}
>
<
b
>
Rate
Currency
USD
<
/b> pada periode yang dipilih <b>belum</
b
>
diatur
.
<
br
/>
Silahkan
menghubungi
Superadmin
<
/div
>
<
/div
>
<
div
style
=
{{
display
:
'flex'
,
justifyContent
:
'flex-end'
}}
>
<
button
className
=
"button"
type
=
"button"
style
=
{{
background
:
'#F6F7F9'
,
cursor
:
'pointer'
,
border
:
'1px solid #3549609e'
,
outline
:
'none'
,
marginRight
:
20
,
borderRadius
:
9
}}
onClick
=
{()
=>
this
.
setState
({
popupDownload
:
false
})}
>
<
div
style
=
{{
backgroundColor
:
'#fff'
,
width
:
105
,
height
:
30
,
borderRadius
:
9
,
justifyContent
:
'center'
,
display
:
'flex'
,
alignItems
:
'center'
,
border
:
'solid 1px #3549609e'
}}
>
<
Typography
style
=
{{
fontSize
:
'15px'
,
color
:
'#354960'
,
textAlign
:
'center'
}}
>
Close
<
/Typography
>
<
/div
>
<
/button
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
)}
<
/div
>
<
/div
>
);
);
}
}
...
...
src/container/MasterData/Parameter/CreateParameter.js
View file @
da2ba108
...
@@ -667,7 +667,7 @@ export default class CreateParameter extends Component {
...
@@ -667,7 +667,7 @@ export default class CreateParameter extends Component {
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
20
}}
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'20px 20px 0px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
"column-1"
>
<
div
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
div
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
...
@@ -689,7 +689,30 @@ export default class CreateParameter extends Component {
...
@@ -689,7 +689,30 @@ export default class CreateParameter extends Component {
}}
}}
/
>
/
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
types
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getTypes
:
newInputValue
},
()
=>
newInputValue
===
null
?
this
.
setState
({
enableParameter
:
false
,
enableReportName
:
false
,
getParameter
:
null
,
getReportName
:
null
},
()
=>
this
.
clearMessage
())
:
this
.
getParameterByGroup
(
newInputValue
.
setting_group_id
,
newInputValue
.
setting_group_name
),
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
error
=
{
this
.
state
.
errorGroup
}
helperText
=
{
this
.
state
.
msgErrorGroup
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Group"
/>
}
value
=
{
this
.
state
.
getTypes
}
/
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
<
Autocomplete
{...
this
.
state
.
parameter
}
{...
this
.
state
.
parameter
}
debug
debug
...
@@ -707,7 +730,29 @@ export default class CreateParameter extends Component {
...
@@ -707,7 +730,29 @@ export default class CreateParameter extends Component {
value
=
{
this
.
state
.
getParameter
}
value
=
{
this
.
state
.
getParameter
}
/
>
/
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
perusahaan
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getPerusahaan
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
error
=
{
this
.
state
.
errorPerusahaan
}
helperText
=
{
this
.
state
.
msgErrorPerusahaan
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Company Name"
/>
}
value
=
{
this
.
state
.
getPerusahaan
}
/
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"description"
id
=
"description"
...
@@ -731,12 +776,14 @@ export default class CreateParameter extends Component {
...
@@ -731,12 +776,14 @@ export default class CreateParameter extends Component {
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"
value
"
id
=
"
order
"
label
=
"
Value
"
label
=
"
Order
"
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
value
}
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
order
}
inputProps
=
{{
inputProps
=
{{
min
:
0
,
min
:
0
,
style
:
{
style
:
{
...
@@ -749,29 +796,34 @@ export default class CreateParameter extends Component {
...
@@ -749,29 +796,34 @@ export default class CreateParameter extends Component {
color
:
'#7e8085'
color
:
'#7e8085'
}
}
}}
}}
name
=
"
value
"
name
=
"
order
"
onChange
=
{(
e
)
=>
{
onChange
=
{(
e
)
=>
{
let
coba
=
String
(
e
.
target
.
value
).
replace
(
/
[^\d]
/g
,
''
);
this
.
setState
({
this
.
setState
({
tempData
:
{
tempData
:
{
...
this
.
state
.
tempData
,
...
this
.
state
.
tempData
,
value
:
e
.
target
.
value
order
:
coba
}
}
})
})
this
.
clearMessage
()
this
.
clearMessage
()
}
}
// this.handleChange(coba, 'value')}
// this.handleChange(coba, 'value')}
}
}
error
=
{
this
.
state
.
errorValue
}
// error={this.state.errorOrder
}
helperText
=
{
this
.
state
.
msgErrorValue
}
// helperText={this.state.msgErrorOrder
}
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"
min_
value"
id
=
"value"
label
=
"
Min
Value"
label
=
"Value"
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
min_
value
}
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
value
}
inputProps
=
{{
inputProps
=
{{
min
:
0
,
min
:
0
,
style
:
{
style
:
{
...
@@ -784,115 +836,55 @@ export default class CreateParameter extends Component {
...
@@ -784,115 +836,55 @@ export default class CreateParameter extends Component {
color
:
'#7e8085'
color
:
'#7e8085'
}
}
}}
}}
name
=
"
min_
value"
name
=
"value"
onChange
=
{(
e
)
=>
{
onChange
=
{(
e
)
=>
{
// let coba = String(e.target.value).replace(/[^\d]/g, '');
this
.
setState
({
this
.
setState
({
tempData
:
{
tempData
:
{
...
this
.
state
.
tempData
,
...
this
.
state
.
tempData
,
min_
value
:
e
.
target
.
value
value
:
e
.
target
.
value
}
}
})
})
this
.
clearMessage
()
this
.
clearMessage
()
}
}
// this.handleChange(coba, 'value')}
// this.handleChange(coba, 'value')}
}
}
error
=
{
this
.
state
.
error
Min
Value
}
error
=
{
this
.
state
.
errorValue
}
helperText
=
{
this
.
state
.
msgError
Min
Value
}
helperText
=
{
this
.
state
.
msgErrorValue
}
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
DatePicker
margin
=
"normal"
id
=
"start_date"
label
=
"Valid From"
format
=
"dd-MM-yyyy"
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
start_date
}
error
=
{
this
.
state
.
errorStartDate
}
helperText
=
{
this
.
state
.
msgErrorStartDate
}
onChange
=
{(
e
)
=>
this
.
handleChange
(
e
,
'start_date'
)}
KeyboardButtonProps
=
{{
'aria-label'
:
'change date'
,
}}
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
style
=
{{
padding
:
0
,
margin
:
0
,
width
:
'100%'
}}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
style
=
{{
width
:
'100%'
}}
id
=
"status"
label
=
"Status"
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
status
}
disabled
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
/
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
"column-2"
>
{
this
.
state
.
enableReportName
==
true
?
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
reportName
}
debug
id
=
"report"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getReportName
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Report Name"
// error={this.state.errorPerusahaan}
// helperText={this.state.msgErrorPerusahaan}
/>
}
value
=
{
this
.
state
.
getReportName
}
/
>
<
/div> : nul
l
}
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
types
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getTypes
:
newInputValue
},
()
=>
newInputValue
===
null
?
this
.
setState
({
enableParameter
:
false
,
enableReportName
:
false
,
getParameter
:
null
,
getReportName
:
null
},
()
=>
this
.
clearMessage
())
:
this
.
getParameterByGroup
(
newInputValue
.
setting_group_id
,
newInputValue
.
setting_group_name
),
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
error
=
{
this
.
state
.
errorGroup
}
helperText
=
{
this
.
state
.
msgErrorGroup
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Group"
/>
}
value
=
{
this
.
state
.
getTypes
}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
perusahaan
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getPerusahaan
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
error
=
{
this
.
state
.
errorPerusahaan
}
helperText
=
{
this
.
state
.
msgErrorPerusahaan
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Company Name"
/>
}
value
=
{
this
.
state
.
getPerusahaan
}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"
order
"
id
=
"
min_value
"
label
=
"
Order
"
label
=
"
Min Value
"
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
order
}
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
min_value
}
inputProps
=
{{
inputProps
=
{{
min
:
0
,
min
:
0
,
style
:
{
style
:
{
...
@@ -905,47 +897,27 @@ export default class CreateParameter extends Component {
...
@@ -905,47 +897,27 @@ export default class CreateParameter extends Component {
color
:
'#7e8085'
color
:
'#7e8085'
}
}
}}
}}
name
=
"
order
"
name
=
"
min_value
"
onChange
=
{(
e
)
=>
{
onChange
=
{(
e
)
=>
{
let
coba
=
String
(
e
.
target
.
value
).
replace
(
/
[^\d]
/g
,
''
);
//
let coba = String(e.target.value).replace(/[^\d]/g, '');
this
.
setState
({
this
.
setState
({
tempData
:
{
tempData
:
{
...
this
.
state
.
tempData
,
...
this
.
state
.
tempData
,
order
:
coba
min_value
:
e
.
target
.
value
}
}
})
})
this
.
clearMessage
()
this
.
clearMessage
()
}
}
// this.handleChange(coba, 'value')}
// this.handleChange(coba, 'value')}
}
}
// error={this.state.errorOrder
}
error
=
{
this
.
state
.
errorMinValue
}
// helperText={this.state.msgErrorOrder
}
helperText
=
{
this
.
state
.
msgErrorMinValue
}
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
/div
>
{
this
.
state
.
enableReportName
&&
<
div
className
=
"column-2"
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
div
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
reportName
}
debug
id
=
"report"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getReportName
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Report Name"
// error={this.state.errorPerusahaan}
// helperText={this.state.msgErrorPerusahaan}
/>
}
value
=
{
this
.
state
.
getReportName
}
/
>
<
/div
>
}
<
div
style
=
{{
marginTop
:
'80px'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"max_value"
id
=
"max_value"
...
@@ -981,17 +953,20 @@ export default class CreateParameter extends Component {
...
@@ -981,17 +953,20 @@ export default class CreateParameter extends Component {
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
DatePicker
<
DatePicker
margin
=
"normal"
margin
=
"normal"
id
=
"
end
_date"
id
=
"
start
_date"
label
=
"Valid
To
"
label
=
"Valid
From
"
format
=
"dd-MM-yyyy"
format
=
"dd-MM-yyyy"
error
=
{
this
.
state
.
errorEndDate
}
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
start_date
}
helperText
=
{
this
.
state
.
msgErrorEndDate
}
error
=
{
this
.
state
.
errorStartDate
}
minDate
=
{
this
.
state
.
tempData
===
null
?
null
:
this
.
state
.
tempData
.
start_date
}
helperText
=
{
this
.
state
.
msgErrorStartDate
}
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
end_date
}
onChange
=
{(
e
)
=>
this
.
handleChange
(
e
,
'start_date'
)}
onChange
=
{(
e
)
=>
this
.
handleChange
(
e
,
'end_date'
)}
KeyboardButtonProps
=
{{
KeyboardButtonProps
=
{{
'aria-label'
:
'change date'
,
'aria-label'
:
'change date'
,
}}
}}
...
@@ -1011,17 +986,75 @@ export default class CreateParameter extends Component {
...
@@ -1011,17 +986,75 @@ export default class CreateParameter extends Component {
/
>
/
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
div
className
=
"border-bottom margin-top-10px"
style
=
{{
padding
:
'0px 20px 20px 20px'
,
borderRadius
:
5
}}
>
<
DatePicker
<
div
style
=
{{
display
:
'flex'
}}
>
margin
=
"normal"
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'12%'
}}
>
Created
By
<
/Typography
>
id
=
"end_date"
<
Typography
style
=
{{
fontSize
:
11
}}
>
:
{
this
.
state
.
tempData
===
null
?
""
:
this
.
state
.
tempData
.
created
}
<
/Typography
>
label
=
"Valid To"
<
/div
>
format
=
"dd-MM-yyyy"
<
div
style
=
{{
display
:
'flex'
}}
>
error
=
{
this
.
state
.
errorEndDate
}
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'12%'
}}
>
Updated
By
<
/Typography
>
helperText
=
{
this
.
state
.
msgErrorEndDate
}
<
Typography
style
=
{{
fontSize
:
11
}}
>
:
{
this
.
state
.
tempData
===
null
?
""
:
this
.
state
.
tempData
.
updated
===
null
?
""
:
this
.
state
.
tempData
.
updated
}
<
/Typography
>
minDate
=
{
this
.
state
.
tempData
===
null
?
null
:
this
.
state
.
tempData
.
start_date
}
<
/div
>
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
end_date
}
onChange
=
{(
e
)
=>
this
.
handleChange
(
e
,
'end_date'
)}
KeyboardButtonProps
=
{{
'aria-label'
:
'change date'
,
}}
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
style
=
{{
padding
:
0
,
margin
:
0
,
width
:
'100%'
}}
/
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
style
=
{{
width
:
'100%'
}}
id
=
"status"
label
=
"Status"
value
=
{
this
.
state
.
tempData
===
null
?
''
:
this
.
state
.
tempData
.
status
}
disabled
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
/
>
<
/div
>
<
/div
>
<
div
className
=
"column-2"
>
<
/div
>
<
/div
>
<
div
className
=
"border-bottom margin-top-10px"
style
=
{{
padding
:
'0px 20px 20px 20px'
,
borderRadius
:
5
}}
>
<
div
style
=
{{
display
:
'flex'
}}
>
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'12%'
}}
>
Created
By
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
11
}}
>
:
{
this
.
state
.
tempData
===
null
?
""
:
this
.
state
.
tempData
.
created
}
<
/Typography
>
<
/div
>
<
div
style
=
{{
display
:
'flex'
}}
>
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'12%'
}}
>
Updated
By
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
11
}}
>
:
{
this
.
state
.
tempData
===
null
?
""
:
this
.
state
.
tempData
.
updated
===
null
?
""
:
this
.
state
.
tempData
.
updated
}
<
/Typography
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"border-top grid grid-2x"
style
=
{{
height
:
56
,
backgroundColor
:
'#f5f5f5'
,
paddingLeft
:
20
,
paddingRight
:
20
}}
>
<
div
className
=
"border-top grid grid-2x"
style
=
{{
height
:
56
,
backgroundColor
:
'#f5f5f5'
,
paddingLeft
:
20
,
paddingRight
:
20
}}
>
...
@@ -1072,8 +1105,7 @@ export default class CreateParameter extends Component {
...
@@ -1072,8 +1105,7 @@ export default class CreateParameter extends Component {
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'20px 20px 0px'
}}
>
<
div
className
=
"border-bottom grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
20
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
"column-1"
>
<
div
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
div
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
...
@@ -1095,7 +1127,31 @@ export default class CreateParameter extends Component {
...
@@ -1095,7 +1127,31 @@ export default class CreateParameter extends Component {
}}
}}
/
>
/
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
types
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getTypes
:
newInputValue
},
()
=>
newInputValue
===
null
?
this
.
setState
({
enableParameter
:
false
,
enableReportName
:
false
,
getParameter
:
null
,
getReportName
:
null
},
()
=>
this
.
clearMessage
())
:
this
.
getParameterByGroup
(
newInputValue
.
setting_group_id
,
newInputValue
.
setting_group_name
),
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Group"
error
=
{
this
.
state
.
errorGroup
}
helperText
=
{
this
.
state
.
msgErrorGroup
}
/>
}
value
=
{
this
.
state
.
getTypes
}
/
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
<
Autocomplete
{...
this
.
state
.
parameter
}
{...
this
.
state
.
parameter
}
debug
debug
...
@@ -1114,7 +1170,31 @@ export default class CreateParameter extends Component {
...
@@ -1114,7 +1170,31 @@ export default class CreateParameter extends Component {
value
=
{
this
.
state
.
getParameter
}
value
=
{
this
.
state
.
getParameter
}
/
>
/
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
perusahaan
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getPerusahaan
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Company Name"
error
=
{
this
.
state
.
errorPerusahaan
}
helperText
=
{
this
.
state
.
msgErrorPerusahaan
}
/>
}
value
=
{
this
.
state
.
getPerusahaan
}
/
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"description"
id
=
"description"
...
@@ -1136,171 +1216,110 @@ export default class CreateParameter extends Component {
...
@@ -1136,171 +1216,110 @@ export default class CreateParameter extends Component {
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"
value
"
id
=
"
order
"
label
=
"
Value
"
label
=
"
Order
"
value
=
{
this
.
state
.
value
}
value
=
{
this
.
state
.
order
===
null
?
''
:
this
.
state
.
order
}
inputProps
=
{{
inputProps
=
{{
min
:
0
,
min
:
0
,
style
:
{
style
:
{
fontSize
:
11
fontSize
:
11
}
}
}}
}}
InputLabelProps
=
{{
InputLabelProps
=
{{
style
:
{
style
:
{
fontSize
:
11
,
fontSize
:
11
,
color
:
'#7e8085'
color
:
'#7e8085'
}
}
}}
}}
name
=
"
value
"
name
=
"
order
"
onChange
=
{(
e
)
=>
{
onChange
=
{(
e
)
=>
{
let
coba
=
String
(
e
.
target
.
value
).
replace
(
/
[^\d]
/g
,
''
);
this
.
setState
({
this
.
setState
({
value
:
e
.
target
.
value
order
:
coba
})
})
this
.
clearMessage
()
this
.
clearMessage
()
}
}
// this.handleChange(coba, 'value')}
// this.handleChange(coba, 'value')}
}
}
error
=
{
this
.
state
.
errorValue
}
// error={this.state.errorOrder
}
helperText
=
{
this
.
state
.
msgErrorValue
}
// helperText={this.state.msgErrorOrder
}
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"
min_
value"
id
=
"value"
label
=
"
Min
Value"
label
=
"Value"
value
=
{
this
.
state
.
minV
alue
}
value
=
{
this
.
state
.
v
alue
}
inputProps
=
{{
inputProps
=
{{
min
:
0
,
min
:
0
,
style
:
{
style
:
{
fontSize
:
11
fontSize
:
11
}
}
}}
}}
InputLabelProps
=
{{
InputLabelProps
=
{{
style
:
{
style
:
{
fontSize
:
11
,
fontSize
:
11
,
color
:
'#7e8085'
color
:
'#7e8085'
}
}
}}
}}
name
=
"
minV
alue"
name
=
"
v
alue"
onChange
=
{(
e
)
=>
{
onChange
=
{(
e
)
=>
{
// let coba = String(e.target.value).replace(/[^\d]/g, '');
this
.
setState
({
this
.
setState
({
minV
alue
:
e
.
target
.
value
v
alue
:
e
.
target
.
value
})
})
this
.
clearMessage
()
this
.
clearMessage
()
}
}
// this.handleChange(coba, 'value')}
// this.handleChange(coba, 'value')}
}
}
error
=
{
this
.
state
.
error
Min
Value
}
error
=
{
this
.
state
.
errorValue
}
helperText
=
{
this
.
state
.
msgError
Min
Value
}
helperText
=
{
this
.
state
.
msgErrorValue
}
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
DatePicker
margin
=
"normal"
id
=
"startDate"
label
=
"Valid From"
format
=
"dd-MM-yyyy"
error
=
{
this
.
state
.
errorStartDate
}
helperText
=
{
this
.
state
.
msgErrorStartDate
}
value
=
{
this
.
state
.
startDate
==
""
?
null
:
this
.
state
.
startDate
}
onChange
=
{(
e
)
=>
this
.
handleChangeCreate
(
e
,
'start_date'
)}
KeyboardButtonProps
=
{{
'aria-label'
:
'change date'
,
}}
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
style
=
{{
padding
:
0
,
margin
:
0
,
width
:
'100%'
}}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
style
=
{{
width
:
'100%'
}}
defaultValue
=
{
"Active"
}
id
=
"status"
label
=
"Status"
disabled
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'25%'
}}
>
Created
By
:
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'25%'
}}
>
Updated
By
:
<
/Typography
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
"column-2"
>
{
this
.
state
.
enableReportName
&&
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
reportName
}
debug
id
=
"report"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getReportName
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Report Name"
error
=
{
this
.
state
.
errorReportName
}
helperText
=
{
this
.
state
.
msgErrorReportName
}
/>
}
value
=
{
this
.
state
.
getReportName
}
/
>
<
/div
>
}
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
types
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getTypes
:
newInputValue
},
()
=>
newInputValue
===
null
?
this
.
setState
({
enableParameter
:
false
,
enableReportName
:
false
,
getParameter
:
null
,
getReportName
:
null
},
()
=>
this
.
clearMessage
())
:
this
.
getParameterByGroup
(
newInputValue
.
setting_group_id
,
newInputValue
.
setting_group_name
),
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Group"
error
=
{
this
.
state
.
errorGroup
}
helperText
=
{
this
.
state
.
msgErrorGroup
}
/>
}
value
=
{
this
.
state
.
getTypes
}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
perusahaan
}
debug
id
=
"tipe"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getPerusahaan
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Company Name"
error
=
{
this
.
state
.
errorPerusahaan
}
helperText
=
{
this
.
state
.
msgErrorPerusahaan
}
/>
}
value
=
{
this
.
state
.
getPerusahaan
}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"
order
"
id
=
"
min_value
"
label
=
"
Order
"
label
=
"
Min Value
"
value
=
{
this
.
state
.
order
===
null
?
''
:
this
.
state
.
order
}
value
=
{
this
.
state
.
minValue
}
inputProps
=
{{
inputProps
=
{{
min
:
0
,
min
:
0
,
style
:
{
style
:
{
...
@@ -1313,44 +1332,24 @@ export default class CreateParameter extends Component {
...
@@ -1313,44 +1332,24 @@ export default class CreateParameter extends Component {
color
:
'#7e8085'
color
:
'#7e8085'
}
}
}}
}}
name
=
"
order
"
name
=
"
minValue
"
onChange
=
{(
e
)
=>
{
onChange
=
{(
e
)
=>
{
let
coba
=
String
(
e
.
target
.
value
).
replace
(
/
[^\d]
/g
,
''
);
//
let coba = String(e.target.value).replace(/[^\d]/g, '');
this
.
setState
({
this
.
setState
({
order
:
coba
minValue
:
e
.
target
.
value
})
})
this
.
clearMessage
()
this
.
clearMessage
()
}
}
// this.handleChange(coba, 'value')}
// this.handleChange(coba, 'value')}
}
}
// error={this.state.errorOrder
}
error
=
{
this
.
state
.
errorMinValue
}
// helperText={this.state.msgErrorOrder
}
helperText
=
{
this
.
state
.
msgErrorMinValue
}
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
/div
>
{
this
.
state
.
enableReportName
&&
<
div
className
=
"column-2"
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Autocomplete
{...
this
.
state
.
reportName
}
debug
id
=
"report"
onChange
=
{(
event
,
newInputValue
)
=>
this
.
setState
({
getReportName
:
newInputValue
},
()
=>
this
.
clearMessage
())}
renderInput
=
{(
params
)
=>
<
TextField
{...
params
}
InputProps
=
{{
...
params
.
InputProps
,
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
label
=
"Report Name"
error
=
{
this
.
state
.
errorReportName
}
helperText
=
{
this
.
state
.
msgErrorReportName
}
/>
}
value
=
{
this
.
state
.
getReportName
}
/
>
<
/div
>
}
<
div
style
=
{{
marginTop
:
'80px'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
<
TextField
style
=
{{
width
:
'100%'
}}
style
=
{{
width
:
'100%'
}}
id
=
"max_value"
id
=
"max_value"
...
@@ -1383,7 +1382,41 @@ export default class CreateParameter extends Component {
...
@@ -1383,7 +1382,41 @@ export default class CreateParameter extends Component {
>
>
<
/TextField
>
<
/TextField
>
<
/div
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
DatePicker
margin
=
"normal"
id
=
"startDate"
label
=
"Valid From"
format
=
"dd-MM-yyyy"
error
=
{
this
.
state
.
errorStartDate
}
helperText
=
{
this
.
state
.
msgErrorStartDate
}
value
=
{
this
.
state
.
startDate
==
""
?
null
:
this
.
state
.
startDate
}
onChange
=
{(
e
)
=>
this
.
handleChangeCreate
(
e
,
'start_date'
)}
KeyboardButtonProps
=
{{
'aria-label'
:
'change date'
,
}}
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
style
=
{{
padding
:
0
,
margin
:
0
,
width
:
'100%'
}}
/
>
<
/div
>
<
/div
>
<
div
className
=
"column-2"
>
<
div
className
=
""
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
DatePicker
<
DatePicker
margin
=
"normal"
margin
=
"normal"
id
=
"endDate"
id
=
"endDate"
...
@@ -1414,6 +1447,38 @@ export default class CreateParameter extends Component {
...
@@ -1414,6 +1447,38 @@ export default class CreateParameter extends Component {
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
/div
>
<
div
className
=
"grid grid-2x grid-mobile-none gap-15px"
style
=
{{
padding
:
'5px 20px'
}}
>
<
div
className
=
"column-1"
>
<
div
className
=
""
style
=
{{
backgroundColor
:
'#e8e8e8'
,
padding
:
10
,
borderRadius
:
5
}}
>
<
TextField
style
=
{{
width
:
'100%'
}}
defaultValue
=
{
"Active"
}
id
=
"status"
label
=
"Status"
disabled
inputProps
=
{{
style
:
{
fontSize
:
11
}
}}
InputLabelProps
=
{{
style
:
{
fontSize
:
11
,
color
:
'#7e8085'
}
}}
/
>
<
/div
>
<
div
className
=
"margin-top-10px"
style
=
{{
padding
:
10
,
borderRadius
:
5
}}
>
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'25%'
}}
>
Created
By
:
<
/Typography
>
<
Typography
style
=
{{
fontSize
:
11
,
width
:
'25%'
}}
>
Updated
By
:
<
/Typography
>
<
/div
>
<
/div
>
<
div
className
=
"column-2"
>
<
/div
>
<
/div
>
<
div
className
=
"border-top grid grid-2x"
style
=
{{
height
:
56
,
backgroundColor
:
'#f5f5f5'
,
paddingLeft
:
20
,
paddingRight
:
20
}}
>
<
div
className
=
"border-top grid grid-2x"
style
=
{{
height
:
56
,
backgroundColor
:
'#f5f5f5'
,
paddingLeft
:
20
,
paddingRight
:
20
}}
>
<
div
className
=
"column-1"
style
=
{{
alignSelf
:
'center'
}}
>
<
div
className
=
"column-1"
style
=
{{
alignSelf
:
'center'
}}
>
...
...
src/container/MasterData/ReportItems/ReportItems.js
View file @
da2ba108
...
@@ -97,10 +97,11 @@ export default class ReportItems extends Component {
...
@@ -97,10 +97,11 @@ export default class ReportItems extends Component {
formula_ytd
:
item
[
13
]
===
undefined
?
""
:
item
[
13
],
formula_ytd
:
item
[
13
]
===
undefined
?
""
:
item
[
13
],
start_date
:
item
[
14
]
===
undefined
?
""
:
item
[
14
],
start_date
:
item
[
14
]
===
undefined
?
""
:
item
[
14
],
end_date
:
item
[
15
]
===
undefined
?
""
:
item
[
15
],
end_date
:
item
[
15
]
===
undefined
?
""
:
item
[
15
],
is_can_convert_value
:
item
[
16
]
===
undefined
?
""
:
item
[
16
],
is_can_convert_value
:
item
[
16
]
===
undefined
?
""
:
item
[
16
]
===
"Yes"
||
item
[
16
]
===
"yes"
?
1
:
0
,
})
})
}
}
})
})
console
.
log
(
payload
);
let
body
=
{
let
body
=
{
item_report
:
payload
item_report
:
payload
}
}
...
@@ -142,7 +143,7 @@ export default class ReportItems extends Component {
...
@@ -142,7 +143,7 @@ export default class ReportItems extends Component {
item
.
formula_ytd
,
item
.
formula_ytd
,
item
.
start_date
,
item
.
start_date
,
item
.
end_date
,
item
.
end_date
,
item
.
is_can_convert_value
,
item
.
is_can_convert_value
==
1
?
"Yes"
:
"No"
,
item
.
error
,
item
.
error
,
]
]
})
})
...
@@ -537,7 +538,7 @@ export default class ReportItems extends Component {
...
@@ -537,7 +538,7 @@ export default class ReportItems extends Component {
customBodyRender
:
(
val
,
tableMeta
)
=>
{
customBodyRender
:
(
val
,
tableMeta
)
=>
{
let
check
=
null
let
check
=
null
if
(
tableMeta
.
rowData
[
17
]
!=
null
)
{
if
(
tableMeta
.
rowData
[
17
]
!=
null
)
{
check
=
tableMeta
.
rowData
[
17
].
findIndex
((
val
)
=>
val
.
field
.
includes
(
'
company
'
))
check
=
tableMeta
.
rowData
[
17
].
findIndex
((
val
)
=>
val
.
field
.
includes
(
'
is_can_convert_value
'
))
if
(
check
>
-
1
)
{
if
(
check
>
-
1
)
{
this
.
setState
({
buttonError
:
true
})
this
.
setState
({
buttonError
:
true
})
}
}
...
...
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