Commit 5a0ab914 authored by Riri Novita's avatar Riri Novita

push

parent 5cd6900d
......@@ -311,7 +311,19 @@ export default class OperatingIndicator extends Component {
})
} else if (String(item[1]).toLocaleLowerCase().includes("monthly report")) {
console.log(item);
console.log(item[1]);
let month = String(item[1]).toLocaleLowerCase().includes('jan') ? 1 :
String(item[1]).toLocaleLowerCase().includes('feb') ? 2 :
String(item[1]).toLocaleLowerCase().includes('mar') ? 3 :
String(item[1]).toLocaleLowerCase().includes('apr') ? 4 :
String(item[1]).toLocaleLowerCase().includes('may') ? 5 :
String(item[1]).toLocaleLowerCase().includes('jun') ? 6 :
String(item[1]).toLocaleLowerCase().includes('jul') ? 7 :
String(item[1]).toLocaleLowerCase().includes('aug') ? 8 :
String(item[1]).toLocaleLowerCase().includes('sep') ? 9 :
String(item[1]).toLocaleLowerCase().includes('oct') ? 10 :
String(item[1]).toLocaleLowerCase().includes('nov') ? 11 :
String(item[1]).toLocaleLowerCase().includes('dec') ? 12 : null
this.setState({
statusDetail: String(item[2]).toLocaleLowerCase(),
dataDetail: { ...this.state.dataReport[index], periode: this.state.periode.periode, operatingIndID: this.state.operatingIndID, company: this.state.company },
......@@ -319,7 +331,7 @@ export default class OperatingIndicator extends Component {
visibleDetailOpt: false,
visibleDetailMonthly: true,
visibleDetailRolling: false,
months: id === 22 ? 1 : 23 ? 2 : 24 ? 3 : 25 ? 4 : 27 ? 5 : 28 ? 6 : 29 ? 7 : 31 ? 8 : 32 ? 9 : 33 ? 10 : 35 ? 11 : 36 ? 12 : 0
months: month
})
......
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