Commit 10a30efc authored by r.kurnia's avatar r.kurnia

ketinggalan push tp olpa

parent 88bcedf7
......@@ -66,6 +66,8 @@ export default class TaxPlanningOLPA extends Component {
this.getSettingControl()
this.lastUpdate()
this.handleViewOnly()
console.log(this.props)
console.log(this.state.viewOnly)
}
handleViewOnly() {
......@@ -98,7 +100,7 @@ export default class TaxPlanningOLPA extends Component {
checkStatus = false
}
// this.setState({viewOnly: !checkApprover && checkLastStatus && checkStatus && checkPrevRev})
this.setState({viewOnly: !checkApprover && checkLastStatus && checkStatus && checkPrevRev})
}
handleGetFor(type) {
......@@ -3047,13 +3049,12 @@ export default class TaxPlanningOLPA extends Component {
</div>
</button>
</div>
{this.props.isApprover === true || this.state.dataTable.length == 0 ? null :
(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') ?
// {this.props.isApprover === true ?
// <div className="col-2">
// </div> :
{this.props.isApprover === true ?
<div className="col-2">
</div> :
<div className="col-2" style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%' }}>
{this.state.get_for == 'view' && this.state.viewOnly && <button
{this.state.get_for == 'view' && this.state.viewOnly &&
<button
className="button"
type="button"
style={{
......@@ -3072,7 +3073,8 @@ export default class TaxPlanningOLPA extends Component {
<div style={{ backgroundColor: '#fff', width: 105, height: 25, borderRadius: 3, justifyContent: 'center', display: 'flex', alignItems: 'center', border: 'solid 1px #354960' }}>
<Typography style={{ fontSize: '11px', color: '#354960', textAlign: 'center' }}>Edit</Typography>
</div>
</button>}
</button>
}
{this.state.get_for == 'edit' &&
<button
className="button"
......@@ -3150,7 +3152,7 @@ export default class TaxPlanningOLPA extends Component {
<Typography style={{ fontSize: '11px', color: '#fff', textAlign: 'center' }}>Save & Complete</Typography>
</div>
</button>}
</div> : null
</div>
}
</div>
</Paper>
......
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