Commit 1fec0e2c authored by Riri Novita's avatar Riri Novita

tambahin

parent 3aeca67e
...@@ -810,47 +810,47 @@ export default class OperatingIndicatorRO extends Component { ...@@ -810,47 +810,47 @@ export default class OperatingIndicatorRO extends Component {
value={Number(value).toFixed(1)} value={Number(value).toFixed(1)}
/> />
: :
tableMeta.rowData[0] == 2 ? // tableMeta.rowData[0] == 2 ?
<div style={{ flex: 1 }}> // <div style={{ flex: 1 }}>
<FormControlLabel // <FormControlLabel
style={{ margin: 0 }} // style={{ margin: 0 }}
value={value} // value={value}
control={ // control={
<NumberFormat // <NumberFormat
thousandSeparator={true} // thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} // style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" // type="text"
placeholder="" // placeholder=""
value={Number(handleParent(tableMeta)).toFixed(1)} // value={Number(handleParent(tableMeta)).toFixed(1)}
disabled={true} // disabled={true}
decimalScale={1} // decimalScale={1}
/> // />
} // }
/> // />
</div> // </div>
: // :
(tableMeta.rowData[0] == 5 || tableMeta.rowData[0] == 6 ? // (tableMeta.rowData[0] == 5 || tableMeta.rowData[0] == 6 ?
<div style={{ flex: 1 }}> // <div style={{ flex: 1 }}>
<FormControlLabel // <FormControlLabel
style={{ margin: 0 }} // style={{ margin: 0 }}
value={value} // value={value}
control={ // control={
<NumberFormat // <NumberFormat
thousandSeparator={true} // thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} // style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" // type="text"
placeholder="" // placeholder=""
value={Number(handleFormula(tableMeta)).toFixed(1)} // value={Number(handleFormula(tableMeta)).toFixed(1)}
disabled={true} // disabled={true}
decimalScale={1} // decimalScale={1}
onBlur={(event) => { // onBlur={(event) => {
handleChange(event.target.value, tableMeta) // handleChange(event.target.value, tableMeta)
}} // }}
/> // />
} // }
/> // />
</div> // </div>
: // :
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
...@@ -861,7 +861,8 @@ export default class OperatingIndicatorRO extends Component { ...@@ -861,7 +861,8 @@ export default class OperatingIndicatorRO extends Component {
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
placeholder="" placeholder=""
value={Number(value).toFixed(1)} // value={Number(value).toFixed(1)}
value={value === "0" ? "" : Number(value).toFixed(1)}
decimalScale={1} decimalScale={1}
disabled={true} disabled={true}
// disabled={!this.props.permission.create || !this.props.permission.edit || !this.props.isSubmit} // disabled={!this.props.permission.create || !this.props.permission.edit || !this.props.isSubmit}
...@@ -871,7 +872,8 @@ export default class OperatingIndicatorRO extends Component { ...@@ -871,7 +872,8 @@ export default class OperatingIndicatorRO extends Component {
/> />
} }
/> />
</div>) </div>
// )
} }
</div> </div>
) )
...@@ -904,47 +906,47 @@ export default class OperatingIndicatorRO extends Component { ...@@ -904,47 +906,47 @@ export default class OperatingIndicatorRO extends Component {
value={Number(value).toFixed(1)} value={Number(value).toFixed(1)}
/> />
: :
tableMeta.rowData[0] == 2 ? // tableMeta.rowData[0] == 2 ?
<div style={{ flex: 1 }}> // <div style={{ flex: 1 }}>
<FormControlLabel // <FormControlLabel
style={{ margin: 0 }} // style={{ margin: 0 }}
value={value} // value={value}
control={ // control={
<NumberFormat // <NumberFormat
thousandSeparator={true} // thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} // style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" // type="text"
placeholder="" // placeholder=""
value={Number(handleParent(tableMeta)).toFixed(1)} // value={Number(handleParent(tableMeta)).toFixed(1)}
disabled={true} // disabled={true}
decimalScale={1} // decimalScale={1}
/> // />
} // }
/> // />
</div> // </div>
: // :
(tableMeta.rowData[0] == 5 || tableMeta.rowData[0] == 6 ? // (tableMeta.rowData[0] == 5 || tableMeta.rowData[0] == 6 ?
<div style={{ flex: 1 }}> // <div style={{ flex: 1 }}>
<FormControlLabel // <FormControlLabel
style={{ margin: 0 }} // style={{ margin: 0 }}
value={value} // value={value}
control={ // control={
<NumberFormat // <NumberFormat
thousandSeparator={true} // thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} // style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" // type="text"
placeholder="" // placeholder=""
value={Number(handleFormula(tableMeta)).toFixed(1)} // value={Number(handleFormula(tableMeta)).toFixed(1)}
disabled={true} // disabled={true}
decimalScale={1} // decimalScale={1}
onBlur={(event) => { // onBlur={(event) => {
handleChange(event.target.value, tableMeta) // handleChange(event.target.value, tableMeta)
}} // }}
/> // />
} // }
/> // />
</div> // </div>
: // :
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
...@@ -955,7 +957,8 @@ export default class OperatingIndicatorRO extends Component { ...@@ -955,7 +957,8 @@ export default class OperatingIndicatorRO extends Component {
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
placeholder="" placeholder=""
value={Number(value).toFixed(1)} // value={Number(value).toFixed(1)}
value={value === "0" ? "" : Number(value).toFixed(1)}
decimalScale={1} decimalScale={1}
disabled={true} disabled={true}
// disabled={!this.props.permission.create || !this.props.permission.edit || !this.props.isSubmit} // disabled={!this.props.permission.create || !this.props.permission.edit || !this.props.isSubmit}
...@@ -965,7 +968,8 @@ export default class OperatingIndicatorRO extends Component { ...@@ -965,7 +968,8 @@ export default class OperatingIndicatorRO extends Component {
/> />
} }
/> />
</div>) </div>
// )
} }
</div> </div>
) )
...@@ -997,47 +1001,47 @@ export default class OperatingIndicatorRO extends Component { ...@@ -997,47 +1001,47 @@ export default class OperatingIndicatorRO extends Component {
value={Number(value).toFixed(1)} value={Number(value).toFixed(1)}
/> />
: :
tableMeta.rowData[0] == 2 ? // tableMeta.rowData[0] == 2 ?
<div style={{ flex: 1 }}> // <div style={{ flex: 1 }}>
<FormControlLabel // <FormControlLabel
style={{ margin: 0 }} // style={{ margin: 0 }}
value={value} // value={value}
control={ // control={
<NumberFormat // <NumberFormat
thousandSeparator={true} // thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} // style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" // type="text"
placeholder="" // placeholder=""
value={Number(handleParent(tableMeta)).toFixed(1)} // value={Number(handleParent(tableMeta)).toFixed(1)}
disabled={true} // disabled={true}
decimalScale={1} // decimalScale={1}
/> // />
} // }
/> // />
</div> // </div>
: // :
(tableMeta.rowData[0] == 5 || tableMeta.rowData[0] == 6 ? // (tableMeta.rowData[0] == 5 || tableMeta.rowData[0] == 6 ?
<div style={{ flex: 1 }}> // <div style={{ flex: 1 }}>
<FormControlLabel // <FormControlLabel
style={{ margin: 0 }} // style={{ margin: 0 }}
value={value} // value={value}
control={ // control={
<NumberFormat // <NumberFormat
thousandSeparator={true} // thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} // style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" // type="text"
placeholder="" // placeholder=""
value={Number(handleFormula(tableMeta)).toFixed(1)} // value={Number(handleFormula(tableMeta)).toFixed(1)}
disabled={true} // disabled={true}
decimalScale={1} // decimalScale={1}
onBlur={(event) => { // onBlur={(event) => {
handleChange(event.target.value, tableMeta) // handleChange(event.target.value, tableMeta)
}} // }}
/> // />
} // }
/> // />
</div> // </div>
: // :
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
...@@ -1048,7 +1052,8 @@ export default class OperatingIndicatorRO extends Component { ...@@ -1048,7 +1052,8 @@ export default class OperatingIndicatorRO extends Component {
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }} style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text" type="text"
placeholder="" placeholder=""
value={Number(value).toFixed(1)} value={value === "0" ? "" : Number(value).toFixed(1)}
// value={Number(value).toFixed(1)}
decimalScale={1} decimalScale={1}
disabled={true} disabled={true}
// disabled={!this.props.permission.create || !this.props.permission.edit || !this.props.isSubmit} // disabled={!this.props.permission.create || !this.props.permission.edit || !this.props.isSubmit}
...@@ -1058,7 +1063,8 @@ export default class OperatingIndicatorRO extends Component { ...@@ -1058,7 +1063,8 @@ export default class OperatingIndicatorRO extends Component {
/> />
} }
/> />
</div>) </div>
// )
} }
</div> </div>
) )
...@@ -2052,7 +2058,11 @@ export default class OperatingIndicatorRO extends Component { ...@@ -2052,7 +2058,11 @@ export default class OperatingIndicatorRO extends Component {
borderColor: 'transparent', borderColor: 'transparent',
margin: 5 margin: 5
}} }}
onClick={() => this.downloadTemplate()} onClick={() => {
// this.setState({loading: true}, () => {
this.downloadTemplate()
// })
}}
> >
<img src={Images.template} /> <img src={Images.template} />
</button> </button>
......
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