Commit c16941be authored by EKSAD's avatar EKSAD

PLMR

parent 1f3367de
import { createMuiTheme, MuiThemeProvider, Paper, TableCell, Typography, Tooltip, withStyles } from '@material-ui/core' import { createMuiTheme, MuiThemeProvider, Paper, TableCell, Typography, Tooltip, withStyles, Input, FormControlLabel } from '@material-ui/core'
import MUIDataTable from 'mui-datatables'; import MUIDataTable from 'mui-datatables';
import React, { Component } from 'react' import React, { Component } from 'react'
import ReactTooltip from 'react-tooltip'; import ReactTooltip from 'react-tooltip';
import Images from '../../assets/Images'; import Images from '../../assets/Images';
import NumberFormat from 'react-number-format';
const LightTooltip = withStyles((theme) => ({ const LightTooltip = withStyles((theme) => ({
tooltip: { tooltip: {
...@@ -70,7 +71,23 @@ export default class ProfitLossMR extends Component { ...@@ -70,7 +71,23 @@ export default class ProfitLossMR extends Component {
customBodyRender: (val, tableMeta) => { customBodyRender: (val, tableMeta) => {
return ( return (
<div style={{ textAlign: 'right' }}> <div style={{ textAlign: 'right' }}>
{val} <div style={{ flex: 1 }}>
<FormControlLabel
style={{ margin: 0 }}
// value={value}
control={
<Input
disableUnderline={true}
style={{ color: "#5198ea", fontSize: 12, textAlign: 'left', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
// disabled={this.props.isApprover ? true : ((this.props.lastStatus == 'SUBMIT' || this.props.lastStatus == 'REVISION') && this.props.prevRevision === false && (this.props.status === 'revision' || this.props.status === 'not-yet' || this.props.status === 'draft' || this.props.status === 'submitted') ? false : true)}
defaultValue=""
/>
}
/>
</div>
</div> </div>
) )
} }
...@@ -133,7 +150,26 @@ export default class ProfitLossMR extends Component { ...@@ -133,7 +150,26 @@ export default class ProfitLossMR extends Component {
</div> </div>
<div className="col-3"> <div className="col-3">
<div style={{ textAlign: 'right', width: 90 }}> <div style={{ textAlign: 'right', width: 90 }}>
{val.c} <div style={{ flex: 1 }}>
<FormControlLabel
style={{ margin: 0 }}
// value={value}
control={
<NumberFormat
thousandSeparator={true}
style={{ color: "#5198ea", fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
// disabled={this.props.isApprover ? true : ((this.props.lastStatus == 'SUBMIT' || this.props.lastStatus == 'REVISION') && this.props.prevRevision === false && (this.props.status === 'revision' || this.props.status === 'not-yet' || this.props.status === 'draft' || this.props.status === 'submitted') ? false : true)}
// value={Number(value).toFixed(1)}
// onBlur={(event) => {
// handleChange(event.target.value, tableMeta)
// // console.log(dataTable2)
// }}
/>
}
/>
</div>
</div> </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