Commit 6255b4f5 authored by Riri Novita's avatar Riri Novita

Fixing Issue FAM

parent 4f35da02
......@@ -321,10 +321,8 @@ export default class BudgetTahunan extends Component {
let indexC = String(item.current_status).toLocaleUpperCase().indexOf('C')
let status_approv = ''
if (String(item.current_status).toLocaleUpperCase().includes('CC')) {
console.log("tes 1");
status_approv = `${String(item.current_status).substr(0, indexC)}${String(item.current_status).substr(indexC + 1, String(item.current_status).length)}`
} else {
console.log("tes 2");
status_approv = String(item.current_status)
}
const handleOpbal = (item) => {
......@@ -336,9 +334,9 @@ export default class BudgetTahunan extends Component {
}
return isUpload
}
console.log(this.state.lastStatus);
console.log(this.state.isSubmit);
console.log(status_approv);
// console.log(this.state.lastStatus);
// console.log(this.state.isSubmit);
// console.log(status_approv);
return [
item.number,
item.report_name === 'CAT' ? 'Corporate Annual Target' : item.report_name,
......@@ -681,9 +679,9 @@ export default class BudgetTahunan extends Component {
}
// this.getFR(type)
api.create().checkApprover().then(response => {
console.log(this.state.btnedit)
console.log(this.state.btncreate);
console.log(response);
// console.log(this.state.btnedit)
// console.log(this.state.btncreate);
// console.log(response);
if (this.state.btncreate === true && this.state.btnedit === true) {
this.setState({ isApprover: false }, () => {
if (response.data.data.is_approver === true) {
......
......@@ -233,6 +233,7 @@ export default class FixedAssetsMovement extends Component {
}
backToMasterBudget(type) {
console.log("masuk sini");
let data = []
this.state.dataTable.map(i => {
data.push({
......@@ -408,6 +409,7 @@ export default class FixedAssetsMovement extends Component {
}
uploadFAM(type) {
console.log("masuk ga?");
let data = []
this.state.dataTable.map(i => {
data.push({
......@@ -2906,25 +2908,29 @@ export default class FixedAssetsMovement extends Component {
<Typography style={{ fontSize: '11px', color: '#354960', textAlign: 'center' }}>Calculate</Typography>
</div>
</button>
<button
className="button"
type="button"
disabled={this.state.buttonError}
// disabled={this.state.buttonError}
style={{
backgroundColor: 'transparent',
cursor: this.state.editable === true ? 'default' : 'pointer',
// cursor: this.state.editable === true ? 'default' : 'pointer',
cursor: this.state.editable !== true ? 'pointer' : 'default',
borderColor: 'transparent',
outline: 'none',
marginRight: 20
}}
onClick={() => this.state.editable === true ?
onClick={() =>
this.state.editable === true ?
null : this.setState({ loading: true }, () =>
this.state.handleDoubleClick == 1 ? null :
this.setState({ handleDoubleClick: 1 }, () => {
setTimeout(() => {
this.uploadFAM('draft')
}, 100);
}))}
}))
}
>
<div style={{ backgroundColor: '#354960', width: 105, height: 25, borderRadius: 3, justifyContent: 'center', display: 'flex', alignItems: 'center' }}>
<Typography style={{ fontSize: '11px', color: '#fff', textAlign: 'center' }}>Save as Draft</Typography>
......
......@@ -252,7 +252,6 @@ export default class ProfitLoss extends Component {
backToMasterBudget(type) {
// tambahin currency
console.log("tes");
let data = []
this.state.dataTable.map(i => {
data.push({
......@@ -3229,7 +3228,7 @@ export default class ProfitLoss extends Component {
/>
</div>
</div>
<div style={{ padding: '15px 30px 55px' }}>
<div style={{ padding: '10px 30px' }}>
<UploadFile
type={this.state.uploadStatus}
percentage={this.state.percentage}
......
......@@ -9086,8 +9086,8 @@ export default class TaxPlanning extends Component {
</div>
</button>
</div>
{/* {this.props.isApprover === true || this.state.dataTable.length == 0 ? null :
(!this.props.truelyApprover) && (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 || this.state.dataTable.length == 0 ? null :
(!this.props.truelyApprover) && (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') ?
<div className="col-2" style={{ display: 'flex', justifyContent: 'flex-end', maxWidth: '100%' }}>
<button
className="button"
......@@ -9161,8 +9161,8 @@ export default class TaxPlanning extends Component {
</div>
</button>
</div>
{/* : null
} */}
: null
}
</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