|
|
@@ -8,7 +8,7 @@ import DetailPT from "@/components/Main/DetailPT";
|
|
|
import DetailSanksi from "@/components/Main/DetailSanksi";
|
|
|
import Riwayat from "@/components/PT/DocPerbaikan/Riwayat";
|
|
|
import ContentWrapper from "@/components/Layout/ContentWrapper";
|
|
|
-import { Row, Col, Card, CardBody, FormGroup, Button, Input } from "reactstrap";
|
|
|
+import { Row, Col, Card, CardBody, FormGroup, Button, Input, Modal, ModalBody, ModalFooter } from "reactstrap";
|
|
|
import { connect } from "react-redux";
|
|
|
import { notifDocPerbaikan } from "@/actions/notifikasi";
|
|
|
import Loader from "@/components/Common/Loader";
|
|
|
@@ -67,6 +67,7 @@ class DetailPerbaikanDoc extends Component {
|
|
|
keterangan: "",
|
|
|
pt: null,
|
|
|
selectedFile: {},
|
|
|
+ modalTidak: false,
|
|
|
};
|
|
|
}
|
|
|
|
|
|
@@ -140,6 +141,11 @@ class DetailPerbaikanDoc extends Component {
|
|
|
});
|
|
|
}
|
|
|
};
|
|
|
+ setModal = () => {
|
|
|
+ this.setState({
|
|
|
+ modal: !this.state.modal
|
|
|
+ })
|
|
|
+ }
|
|
|
|
|
|
render() {
|
|
|
const { files, sanksi, pt } = this.state;
|
|
|
@@ -150,9 +156,21 @@ class DetailPerbaikanDoc extends Component {
|
|
|
<span className="text-left">{index + 1}.{file.name}</span>
|
|
|
</div>
|
|
|
));
|
|
|
-
|
|
|
+ console.log(sanksi.data)
|
|
|
return (
|
|
|
<ContentWrapper unwrap>
|
|
|
+ <Modal isOpen={this.state.modal} >
|
|
|
+ <ModalBody>jika klik Ya maka tidak bisa upload dokumen perbaikan lagi dan segera dilakukan permohonan pencabutan sanksi</ModalBody>
|
|
|
+ <ModalFooter>
|
|
|
+
|
|
|
+ <Button color className="btn-login" >
|
|
|
+ <span className="font-color-white">Ya</span>
|
|
|
+ </Button>
|
|
|
+ <Button color className="btn-v2" onClick={this.setModal}>
|
|
|
+ Tidak
|
|
|
+ </Button>
|
|
|
+ </ModalFooter>
|
|
|
+ </Modal>
|
|
|
{pt && <Header data={pt} />}
|
|
|
<div className="p-3">
|
|
|
<div className="content-heading">
|
|
|
@@ -241,11 +259,17 @@ class DetailPerbaikanDoc extends Component {
|
|
|
</div>
|
|
|
</FormGroup>
|
|
|
<FormGroup row>
|
|
|
- <div className="col-xl-10">
|
|
|
+ <div className="ml-3 mr-3">
|
|
|
<Button color className="color-3e3a8e" type="submit" disabled={isSubmitting}>
|
|
|
- <span className="font-color-white">Kirim</span>
|
|
|
+ <span className="font-color-white">Upload</span>
|
|
|
</Button>
|
|
|
</div>
|
|
|
+ <div className=" inline float-right ml-auto mr-3">
|
|
|
+ <Button color="success" className=" float-right" onClick={this.setModal} disabled={!sanksi.data?.perbaikan.length}>
|
|
|
+ <span className="font-color-white">Finalisasi upload dokumen perbaikan</span>
|
|
|
+ </Button>
|
|
|
+ </div>
|
|
|
+
|
|
|
</FormGroup>
|
|
|
</Form>
|
|
|
)}
|