Commit ed408605 authored by syadziy's avatar syadziy

update fixing UAT

parent 1281c5dc
......@@ -19,10 +19,13 @@ export default class CreateCarfmDoc extends Component {
super(props)
this.state = {
perusahaan: null,
perusahaanData: null,
getPerusahaan: null,
errorPerusahaan: false,
msgErrorPerusahaan: '',
document: null,
documentData: null,
getDocument: null,
errorDocument: false,
msgErrorDocument: '',
listPeriode: null,
......@@ -43,8 +46,7 @@ export default class CreateCarfmDoc extends Component {
fileType: '',
docId: '',
sizeUpload: "1",
saveDisable: false,
submitVal: 0
isClickSave: 0
}
}
......@@ -234,6 +236,7 @@ export default class CreateCarfmDoc extends Component {
else if (R.isNil(this.state.file)) {
this.setState({ alert: true, messageAlert: 'File Cannot be Empty', tipeAlert: 'warning', saveDisable: false })
} else {
console.log(this.state.isClickSave + " ===> di luar");
const formData = new FormData();
formData.append("file", this.state.file);
formData.append("companyId", this.state.getPerusahaan.company_id);
......@@ -430,21 +433,10 @@ export default class CreateCarfmDoc extends Component {
disabled={this.state.saveDisable}
type="button"
onClick={() =>
{
this.props.handleLoading(1);
this.setState({
saveDisable: true,
submitVal : this.state.submitVal + 1
}, console.log());
setTimeout(() => {
this.state.isClickSave == 1 ? null :
this.setState({ isClickSave: 1 }, () => {
this.validasi()
console.log("vlidasi " + this.validasi());
}, 100)
this.props.handleLoading(0);
}
})
}
>
<div style={{ width: 102, height: 30, backgroundColor: '#354960', borderRadius: 5, alignItems: 'center', display: 'flex', justifyContent: 'center' }}>
......
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