build and format2

This commit is contained in:
2025-11-26 16:27:43 +03:30
parent 9f622baca8
commit a6d1e7db29
2 changed files with 3 additions and 7 deletions

View File

@@ -31,11 +31,7 @@ const ConfirmRoadSafetyDialog = ({ handleClose, rowId, mutate }) => {
{loading ? (
<DialogLoading loadingOpen={loading} />
) : data ? (
<ConfirmRoadSafetyFormContext
rowId={rowId}
mutate={mutate}
handleClose={handleClose}
/>
<ConfirmRoadSafetyFormContext rowId={rowId} mutate={mutate} handleClose={handleClose} />
) : (
<DialogContent>
<Typography textAlign={"center"}>اطلاعات درخواست در سامانه یافت نشد</Typography>

View File

@@ -4,7 +4,7 @@ import useRequest from "@/lib/hooks/useRequest";
import { useState } from "react";
const ConfirmRoadSafetyFormContext = ({ rowId, mutate, handleClose }) => {
const requestServer = useRequest({notificationShow : true, notificationSuccess : true});
const requestServer = useRequest({ notificationShow: true, notificationSuccess: true });
const [description, setDescription] = useState("");
const [loading, setLoading] = useState(false);
const [error, setError] = useState(null);
@@ -30,7 +30,7 @@ const ConfirmRoadSafetyFormContext = ({ rowId, mutate, handleClose }) => {
setSuccess(true);
mutate();
setDescription("");
handleClose()
handleClose();
} catch (err) {
setError(err.message);
} finally {