|
|
@@ -41,7 +41,7 @@ class JawabanKeberatan extends Component {
|
|
|
}
|
|
|
};
|
|
|
toPerbaikan = () => {
|
|
|
- Router.push("/pt/keberatan");
|
|
|
+ Router.push("/pt/dokumen-perbaikan");
|
|
|
}
|
|
|
|
|
|
render() {
|
|
|
@@ -71,49 +71,57 @@ class JawabanKeberatan extends Component {
|
|
|
<Card className="card-default">
|
|
|
<CardBody>
|
|
|
<Row>
|
|
|
- <Col lg={12}>
|
|
|
- <DetailSanksi data={sanksi.data} />
|
|
|
- <DetailJawaban data={sanksi.data.jawaban.keberatan} />
|
|
|
- {sanksi.data.jawaban.keberatan.status !== "Membatalkan Keputusan" &&
|
|
|
- (new Date(sanksi.data.batas_waktu.banding).getTime() > Date.now() ? (
|
|
|
- <>
|
|
|
- <p style={{ fontSize: '1vw' }}>
|
|
|
- <strong>
|
|
|
- Setelah membaca surat keputusan sanksi tersebut, Apakah Perguruan Tinggi bermaksud mengajukan permohonan banding?
|
|
|
- </strong>
|
|
|
- </p>
|
|
|
- <p style={{ fontSize: '0.8vw' }}>
|
|
|
- Pengajuan dilakukan paling lambat tanggal {moment(sanksi.data.batas_waktu.banding).locale("id").format("DD MMMM YYYY")}
|
|
|
- </p>
|
|
|
- <p className="lead">
|
|
|
- <span className="btn-radius">
|
|
|
- <Button color="" disabled={sanksi.data.pengajuan.banding || false} className="btn-labeled-notHover" onClick={this.toggleModal}>
|
|
|
- <h4 className="mt-2 mb-md-2 text-center font-color-white pl-3 pr-3">Ya</h4>
|
|
|
- </Button>
|
|
|
- </span>
|
|
|
- <span className="btn-radius">
|
|
|
- <Button disabled={sanksi.data.pengajuan.banding || false} color className="btn-labeled-3-notHover" onClick={async () => {
|
|
|
+ {sanksi.data.jawaban?.keberatan ? (
|
|
|
+ <Col lg={12}>
|
|
|
+ <DetailSanksi data={sanksi.data} />
|
|
|
+ <DetailJawaban data={sanksi.data.jawaban.keberatan} />
|
|
|
+ {sanksi.data.jawaban?.keberatan?.status !== "Membatalkan Keputusan" &&
|
|
|
+ (new Date(sanksi.data.batas_waktu.banding).getTime() > Date.now() ? (
|
|
|
+ <>
|
|
|
+ <p style={{ fontSize: '1vw' }}>
|
|
|
+ <strong>
|
|
|
+ Setelah membaca surat keputusan sanksi tersebut, Apakah Perguruan Tinggi bermaksud mengajukan permohonan banding?
|
|
|
+ </strong>
|
|
|
+ </p>
|
|
|
+ <p style={{ fontSize: '0.8vw' }}>
|
|
|
+ Pengajuan dilakukan paling lambat tanggal {moment(sanksi.data.batas_waktu.banding).locale("id").format("DD MMMM YYYY")}
|
|
|
+ </p>
|
|
|
+ <p className="lead">
|
|
|
+ <span className="btn-radius">
|
|
|
+ <Button color="" disabled={sanksi.data.pengajuan.banding || false} className="btn-labeled-notHover" onClick={this.toggleModal}>
|
|
|
+ <h4 className="mt-2 mb-md-2 text-center font-color-white pl-3 pr-3">Ya</h4>
|
|
|
+ </Button>
|
|
|
+ </span>
|
|
|
+ <span className="btn-radius">
|
|
|
+ <Button disabled={sanksi.data.pengajuan.banding || false} color className="btn-labeled-3-notHover" onClick={async () => {
|
|
|
|
|
|
- const toastid = toast.loading("Please wait...");
|
|
|
- try {
|
|
|
- const { token, query } = this.props;
|
|
|
- await updatePT(token, query.id, { is_pengajuan_keberatan: false })
|
|
|
- toast.update(toastid, { render: "All is good", type: "success", isLoading: false, autoClose: true, closeButton: true });
|
|
|
- Router.push("/pt/dokumen-perbaikan");
|
|
|
- } catch (error) {
|
|
|
- toast.update(toastid, { render: "All is not good", type: "error", isLoading: false, autoClose: true, closeButton: true });
|
|
|
+ const toastid = toast.loading("Please wait...");
|
|
|
+ try {
|
|
|
+ const { token, query } = this.props;
|
|
|
+ await updatePT(token, query.id, { is_pengajuan_keberatan: false })
|
|
|
+ toast.update(toastid, { render: "All is good", type: "success", isLoading: false, autoClose: true, closeButton: true });
|
|
|
+ Router.push("/pt/dokumen-perbaikan");
|
|
|
+ } catch (error) {
|
|
|
+ toast.update(toastid, { render: "All is not good", type: "error", isLoading: false, autoClose: true, closeButton: true });
|
|
|
+ }
|
|
|
}
|
|
|
- }
|
|
|
- }>
|
|
|
- <h4 className=" mt-1 mb-md-2 text-center">Tidak</h4>
|
|
|
- </Button>
|
|
|
- </span>
|
|
|
- </p>
|
|
|
- </>
|
|
|
- ) : (
|
|
|
- <p>Pengajuan ditutup</p>
|
|
|
- ))}
|
|
|
- </Col>
|
|
|
+ }>
|
|
|
+ <h4 className=" mt-1 mb-md-2 text-center">Tidak</h4>
|
|
|
+ </Button>
|
|
|
+ </span>
|
|
|
+ </p>
|
|
|
+ </>
|
|
|
+ ) : (
|
|
|
+ <p>Pengajuan ditutup</p>
|
|
|
+ ))}
|
|
|
+
|
|
|
+
|
|
|
+ </Col>) : (
|
|
|
+ <Col lg={12}>
|
|
|
+ <h3 className=" font-weight-bold">Menunggu Jawaban Permohonan Keberatan</h3>
|
|
|
+ <div className=" tengah"><img className=" tengah" src="/static/img/Wait-Jawaban.png" alt="gambar" /></div>
|
|
|
+ </Col>
|
|
|
+ )}
|
|
|
</Row>
|
|
|
</CardBody>
|
|
|
</Card>
|
|
|
@@ -123,9 +131,39 @@ class JawabanKeberatan extends Component {
|
|
|
)}
|
|
|
<Col xl="3">{pt && <DetailPT data={pt} />}</Col>
|
|
|
</Row>
|
|
|
+ {sanksi.data ? (
|
|
|
+
|
|
|
+ <Col xl="9">
|
|
|
+ <p className="pb-5">
|
|
|
+ <Link href={{ pathname: "/pt/keberatan/detail", query: { id: sanksi.data._id } }}>
|
|
|
+ <span className="btn-radius float-left">
|
|
|
+ <Button color="" className="btn-labeled-3-notHover" >
|
|
|
+ <h4 className=" mt-1 mb-md-2 text-center">Previous</h4>
|
|
|
+ </Button>
|
|
|
+ </span>
|
|
|
+ </Link>
|
|
|
+ {sanksi.data.pengajuan?.banding ? (
|
|
|
+ <Link href={{ pathname: "/pt/jawaban-banding/detail", query: { id: sanksi.data._id } }}>
|
|
|
+ <span className="btn-radius float-rigt">
|
|
|
+ <Button color="" className="btn-labeled-notHover" >
|
|
|
+ <h4 className="mt-2 mb-md-2 text-center font-color-white pl-3 pr-3">Next</h4>
|
|
|
+ </Button>
|
|
|
+ </span>
|
|
|
+ </Link>
|
|
|
+ ) : (
|
|
|
+ <span className="btn-radius float-rigt">
|
|
|
+ <Button color="" className="btn-labeled-notHover" disabled={true} >
|
|
|
+ <h4 className="mt-2 mb-md-2 text-center font-color-white pl-3 pr-3">Next</h4>
|
|
|
+ </Button>
|
|
|
+ </span>
|
|
|
+ )}
|
|
|
+
|
|
|
+ </p>
|
|
|
+ </Col>
|
|
|
+ ) : ("")}
|
|
|
{sanksi.data && (
|
|
|
<Row>
|
|
|
- <Col>{sanksi.data.jawaban.keberatan.status !== "Membatalkan Keputusan" && <Riwayat data={sanksi.data.pengajuan?.banding ? sanksi.data.pengajuan.banding : null} />}</Col>
|
|
|
+ <Col>{sanksi.data.jawaban?.keberatan?.status !== "Membatalkan Keputusan" && <Riwayat data={sanksi.data.pengajuan?.banding ? sanksi.data.pengajuan.banding : null} />}</Col>
|
|
|
</Row>
|
|
|
)}
|
|
|
</div>
|