andi 2 lat temu
rodzic
commit
7767890bd2

+ 3 - 0
components/PT/JawabanKeberatan/ModalPermohonan.js

@@ -6,6 +6,8 @@ import { connect } from "react-redux";
 import { toast } from "react-toastify";
 import { Formik, Form, Field, ErrorMessage } from "formik";
 import * as Yup from "yup";
+import { updatePT } from "@/actions/sanksi";
+
 
 let Dropzone = null;
 class DropzoneWrapper extends Component {
@@ -109,6 +111,7 @@ export class ModalPermohonan extends Component {
 
 		const toastid = toast.loading("Please wait...");
 		const added = await addBanding(token, id, formdata);
+		await updatePT(token, query.id, { is_pengajuan_banding: true })
 
 		if (!added) {
 			toast.update(toastid, { render: "All is not good", type: "error", isLoading: false, autoClose: true, closeButton: true });

+ 1 - 1
pages/app/keberatan/index.js

@@ -19,7 +19,7 @@ class Keberatan extends Component {
 	componentDidMount = async () => {
 		const { token } = this.props;
 		await createLog(token, { aktivitas: "Mengakses halaman Keberatan", menu: "Keberatan" });
-		const sanksi = await getSanksi(token, { is_pengajuan_keberatan: true });
+		const sanksi = await getSanksi(token, { keberatan: true });
 		this.setState({ sanksi });
 	};
 

+ 1 - 1
pages/pt/jawaban-banding/index.js

@@ -16,7 +16,7 @@ class JawabanKeberatan extends Component {
 
 	componentDidMount = async () => {
 		const { token } = this.props;
-		const sanksi = await getSanksi(token, { is_pengajuan_banding: true });
+		const sanksi = await getSanksi(token, { banding: true });
 		this.setState({ sanksi });
 	};