Commit 62a65736 authored by ririnovita's avatar ririnovita

Fix Progress Report

parent 9dd6074b
...@@ -175,7 +175,8 @@ class ReportProgress extends Component { ...@@ -175,7 +175,8 @@ class ReportProgress extends Component {
let data = response.data.data let data = response.data.data
data.map((item,index) => { data.map((item,index) => {
let report = [] let report = []
let statusSubmission = String(item.submission_status).toLocaleUpperCase() let statusSubmissionCAT = String(item.submission_status_cat).toLocaleUpperCase()
let statusSubmissionFinance = String(item.submission_status_finance).toLocaleUpperCase()
let statusOI = String(item.operating_indicator).toLocaleUpperCase() let statusOI = String(item.operating_indicator).toLocaleUpperCase()
item.report.map((items,index) => { item.report.map((items,index) => {
let statusReport = String(items.status_report).toLocaleUpperCase() let statusReport = String(items.status_report).toLocaleUpperCase()
...@@ -183,8 +184,8 @@ class ReportProgress extends Component { ...@@ -183,8 +184,8 @@ class ReportProgress extends Component {
}) })
report.push( report.push(
{report_name: 'Operating Indicator', status_report: statusOI}, {report_name: 'Operating Indicator', status_report: statusOI},
{report_name: 'Report Finance Status', status_report: (statusSubmission == 'APPROVED' || statusSubmission == 'REVISION' || statusSubmission == 'COMPLETED') ? (statusSubmission + ' - ' + item.submissionStatusDate) : statusSubmission}, {report_name: 'Report Finance Status', status_report: (statusSubmissionFinance == 'APPROVED' || statusSubmissionFinance == 'REVISION' || statusSubmissionFinance == 'COMPLETED') ? (statusSubmissionFinance + ' - ' + item.submissionStatusDate) : statusSubmissionFinance},
{report_name: 'Report CAT Status', status_report: (statusSubmission == 'APPROVED' || statusSubmission == 'REVISION' || statusSubmission == 'COMPLETED') ? (statusSubmission + ' - ' + item.submissionStatusDate) : statusSubmission} {report_name: 'Report CAT Status', status_report: (statusSubmissionCAT == 'APPROVED' || statusSubmissionCAT == 'REVISION' || statusSubmissionCAT == 'COMPLETED') ? (statusSubmissionCAT + ' - ' + item.submissionStatusDate) : statusSubmissionCAT}
) )
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
...@@ -243,8 +244,8 @@ class ReportProgress extends Component { ...@@ -243,8 +244,8 @@ class ReportProgress extends Component {
let report = item.report let report = item.report
report.push( report.push(
{report_name: 'Operating Indicator', status_report: item.operating_indicator}, {report_name: 'Operating Indicator', status_report: item.operating_indicator},
{report_name: 'Report Finance Status', status_report: item.monthly_status}, {report_name: 'Report Finance Status', status_report: item.monthly_status_finance},
{report_name: 'Report CAT Status', status_report: item.monthly_status} {report_name: 'Report CAT Status', status_report: item.monthly_status_cat}
) )
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
...@@ -285,8 +286,8 @@ class ReportProgress extends Component { ...@@ -285,8 +286,8 @@ class ReportProgress extends Component {
let report = item.report let report = item.report
report.push( report.push(
{report_name: 'Operating Indicator', status_report: item.operating_indicator}, {report_name: 'Operating Indicator', status_report: item.operating_indicator},
{report_name: 'Report Finance Status', status_report: item.rolling_status}, {report_name: 'Report Finance Status', status_report: item.rolling_status_finance},
{report_name: 'Report CAT Status', status_report: item.rolling_status} {report_name: 'Report CAT Status', status_report: item.rolling_status_cat}
) )
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
...@@ -325,7 +326,8 @@ class ReportProgress extends Component { ...@@ -325,7 +326,8 @@ class ReportProgress extends Component {
let data = response.data.data let data = response.data.data
data.map((item,index) => { data.map((item,index) => {
let report = [] let report = []
let statusSubmission = String(item.outlook_status).toLocaleUpperCase() let statusSubmissionFinance = String(item.outlook_status_finance).toLocaleUpperCase()
let statusSubmissionCAT = String(item.outlook_status_cat).toLocaleUpperCase()
let statusOI = String(item.operating_indicator).toLocaleUpperCase() let statusOI = String(item.operating_indicator).toLocaleUpperCase()
item.report.map((items,index) => { item.report.map((items,index) => {
let statusReport = String(items.status_report).toLocaleUpperCase() let statusReport = String(items.status_report).toLocaleUpperCase()
...@@ -333,8 +335,8 @@ class ReportProgress extends Component { ...@@ -333,8 +335,8 @@ class ReportProgress extends Component {
}) })
report.push( report.push(
{report_name: 'Operating Indicator', status_report: statusOI}, {report_name: 'Operating Indicator', status_report: statusOI},
{report_name: 'Report Finance Status', status_report: (statusSubmission == 'APPROVED' || statusSubmission == 'REVISION' || statusSubmission == 'COMPLETED') ? (statusSubmission + ' - ' + item.submissionStatusDate) : statusSubmission}, {report_name: 'Report Finance Status', status_report: (statusSubmissionFinance == 'APPROVED' || statusSubmissionFinance == 'REVISION' || statusSubmissionFinance == 'COMPLETED') ? (statusSubmissionFinance + ' - ' + item.submissionStatusDate) : statusSubmissionFinance},
{report_name: 'Report CAT Status', status_report: (statusSubmission == 'APPROVED' || statusSubmission == 'REVISION' || statusSubmission == 'COMPLETED') ? (statusSubmission + ' - ' + item.submissionStatusDate) : statusSubmission} {report_name: 'Report CAT Status', status_report: (statusSubmissionCAT == 'APPROVED' || statusSubmissionCAT == 'REVISION' || statusSubmissionCAT == 'COMPLETED') ? (statusSubmissionCAT + ' - ' + item.submissionStatusDate) : statusSubmissionCAT}
) )
dataTable.push([ dataTable.push([
item.company_name, item.company_name,
......
...@@ -407,17 +407,17 @@ export default class TableProgressReport extends Component { ...@@ -407,17 +407,17 @@ export default class TableProgressReport extends Component {
<div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Cash Flow')}</div> <div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Cash Flow')}</div>
</div> </div>
</div> </div>
<div className="column-3 grid grid-3x" style={{ ...style2, fontSize: 12, position: "sticky" }}> <div className="column-3 grid grid-4x" style={{ ...style2, fontSize: 12, position: "sticky" }}>
<div className="column-1" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}> <div className="column-1" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}>
<div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'CAT')}</div> <div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'CAT')}</div>
</div> </div>
<div className="column-2" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}> <div className="column-2" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}>
<div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Report Finance Status')}</div> <div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Report Finance Status')}</div>
</div> </div>
<div className="column-2" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}> <div className="column-3" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}>
<div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Report CAT Status')}</div> <div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Report CAT Status')}</div>
</div> </div>
<div className="column-3" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}> <div className="column-4" style={{ placeSelf: 'center', textAlign: 'center', padding: 5, width: 143 }}>
<div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Operating Indicator')}</div> <div style={{ textAlign: 'center' }}>{handleValue(tableMeta, 'Operating Indicator')}</div>
</div> </div>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment