Commit a29e02aa authored by Riri Novita's avatar Riri Novita

issue reminder

parent 8dae6a34
...@@ -42,6 +42,7 @@ class ReportProgress extends Component { ...@@ -42,6 +42,7 @@ class ReportProgress extends Component {
alert: false, alert: false,
tipeAlert: '', tipeAlert: '',
messageAlert: '', messageAlert: '',
company: null
} }
} }
...@@ -575,7 +576,7 @@ class ReportProgress extends Component { ...@@ -575,7 +576,7 @@ class ReportProgress extends Component {
periode={this.state.periode ? this.state.periode.periode : null} periode={this.state.periode ? this.state.periode.periode : null}
quarter={this.state.quarter.name} quarter={this.state.quarter.name}
month={this.state.month.month_id} month={this.state.month.month_id}
company={this.state.company} company={this.state.company_id}
typeReport={String(this.state.reportType.name).toLocaleUpperCase()} typeReport={String(this.state.reportType.name).toLocaleUpperCase()}
year={this.state.periodeMB.value} year={this.state.periodeMB.value}
getMonitoringMB={this.getMonitoringMB.bind(this)} getMonitoringMB={this.getMonitoringMB.bind(this)}
......
...@@ -65,7 +65,6 @@ export default class TableProgressReport extends Component { ...@@ -65,7 +65,6 @@ export default class TableProgressReport extends Component {
"quarter": data.quarter === "Q1" ? "q1" : data.quarter === "Q2" ? "q2" : data.quarter === "Q3" ? "q3" : null "quarter": data.quarter === "Q1" ? "q1" : data.quarter === "Q2" ? "q2" : data.quarter === "Q3" ? "q3" : null
} }
console.log(payloadGetData);
api.create().sendEmail(payload).then(response => { api.create().sendEmail(payload).then(response => {
console.log(response); console.log(response);
if (response.data) { if (response.data) {
...@@ -98,7 +97,7 @@ export default class TableProgressReport extends Component { ...@@ -98,7 +97,7 @@ export default class TableProgressReport extends Component {
// }) // })
// this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'success' }) // this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'success' })
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => { this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'warning', 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)
...@@ -108,10 +107,10 @@ export default class TableProgressReport extends Component { ...@@ -108,10 +107,10 @@ export default class TableProgressReport extends Component {
}) })
} }
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false }) this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false })
} }
} else { } else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false }) this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false })
} }
}) })
} }
...@@ -241,7 +240,7 @@ export default class TableProgressReport extends Component { ...@@ -241,7 +240,7 @@ export default class TableProgressReport extends Component {
<button <button
type="button" type="button"
style={{ background: 'white' }} style={{ background: 'white' }}
onClick={() => this.handleShowPopup(tableMeta.rowData[5], tableMeta.rowData)} onClick={() => this.handleShowPopup(tableMeta.rowData[7], tableMeta.rowData)}
> >
<div style={{ width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}> <div style={{ width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}>
<span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span> <span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span>
...@@ -280,6 +279,18 @@ export default class TableProgressReport extends Component { ...@@ -280,6 +279,18 @@ export default class TableProgressReport extends Component {
display: false display: false
} }
}, },
{
name: "",
options: {
display: false
}
},
{
name: "",
options: {
display: false
}
},
{ {
name: "", name: "",
options: { options: {
...@@ -408,7 +419,7 @@ export default class TableProgressReport extends Component { ...@@ -408,7 +419,7 @@ export default class TableProgressReport extends Component {
<button <button
type="button" type="button"
style={{ background: 'white' }} style={{ background: 'white' }}
onClick={() => this.handleShowPopup(tableMeta.rowData[5], tableMeta.rowData)} onClick={() => this.handleShowPopup(tableMeta.rowData[7], tableMeta.rowData)}
> >
<div style={{ position: 'relative', width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}> <div style={{ position: 'relative', width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}>
<span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span> <span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span>
...@@ -447,6 +458,18 @@ export default class TableProgressReport extends Component { ...@@ -447,6 +458,18 @@ export default class TableProgressReport extends Component {
display: false display: false
} }
}, },
{
name: "",
options: {
display: false
}
},
{
name: "",
options: {
display: false
}
},
{ {
name: "", name: "",
options: { options: {
...@@ -559,7 +582,7 @@ export default class TableProgressReport extends Component { ...@@ -559,7 +582,7 @@ export default class TableProgressReport extends Component {
<button <button
type="button" type="button"
style={{ background: 'white' }} style={{ background: 'white' }}
onClick={() => this.handleShowPopup(tableMeta.rowData[5], tableMeta.rowData)} onClick={() => this.handleShowPopup(tableMeta.rowData[7], tableMeta.rowData)}
> >
<div style={{ width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}> <div style={{ width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}>
<span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span> <span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span>
...@@ -598,6 +621,18 @@ export default class TableProgressReport extends Component { ...@@ -598,6 +621,18 @@ export default class TableProgressReport extends Component {
display: false display: false
} }
}, },
{
name: "",
options: {
display: false
}
},
{
name: "",
options: {
display: false
}
},
{ {
name: "", name: "",
options: { options: {
...@@ -710,7 +745,7 @@ export default class TableProgressReport extends Component { ...@@ -710,7 +745,7 @@ export default class TableProgressReport extends Component {
<button <button
type="button" type="button"
style={{ background: 'white' }} style={{ background: 'white' }}
onClick={() => this.handleShowPopup(tableMeta.rowData[5], tableMeta.rowData)} onClick={() => this.handleShowPopup(tableMeta.rowData[7], tableMeta.rowData)}
> >
<div style={{ width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}> <div style={{ width: 85, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}>
<span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span> <span style={{ color: '#fff', fontSize: 11 }}>{tableMeta.rowData[3] === null || tableMeta.rowData[3] === 0 ? "Send Email" : "Sent"}</span>
...@@ -749,6 +784,18 @@ export default class TableProgressReport extends Component { ...@@ -749,6 +784,18 @@ export default class TableProgressReport extends Component {
display: false display: false
} }
}, },
{
name: "",
options: {
display: false
}
},
{
name: "",
options: {
display: false
}
},
{ {
name: "", name: "",
options: { options: {
......
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