From 51e02f2aa63bc479f37ecdb18dd1d90f4da4213a Mon Sep 17 00:00:00 2001 From: AmirHossein Mahmoodi Date: Tue, 3 Jun 2025 10:20:51 +0330 Subject: [PATCH 1/3] remove field province --- .../complaintList/RowActions/Refer/ReferContent.jsx | 12 ++++++------ .../complaintList/RowActions/Refer/index.jsx | 5 +++-- .../fastReact/complaintList/RowActions/index.jsx | 2 +- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx b/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx index 705fabf..ef74d91 100644 --- a/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx +++ b/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx @@ -7,7 +7,7 @@ import * as Yup from "yup"; import EdarateShahriField from "./EdarateShahriField"; import ProvinceField from "./ProvinceField"; -const ReferContent = ({ rowId, mutate, setOpenReferDialog }) => { +const ReferContent = ({ row, mutate, setOpenReferDialog }) => { const requestServer = useRequest({ notificationSuccess: true }); const validationSchema = Yup.object().shape({ @@ -23,7 +23,7 @@ const ReferContent = ({ rowId, mutate, setOpenReferDialog }) => { formState: { errors, isSubmitting }, } = useForm({ defaultValues: { - province_id: "", + province_id: row.original.province_id, edarat_shahri_id: "", description: "", }, @@ -36,7 +36,7 @@ const ReferContent = ({ rowId, mutate, setOpenReferDialog }) => { formData.append("province_id", data.province_id); formData.append("edarate_shahri_id", data.edarat_shahri_id); formData.append("refer_description", data.description); - await requestServer(`${REFER_FAST_REACT}/${rowId}`, "post", { + await requestServer(`${REFER_FAST_REACT}/${row.original.id}`, "post", { data: formData, hasSidebarUpdate: true, }) @@ -44,20 +44,20 @@ const ReferContent = ({ rowId, mutate, setOpenReferDialog }) => { mutate(); setOpenReferDialog(false); }) - .catch(() => {}); + .catch(() => { }); }; return ( <> - { return ; }} - /> + /> */} { +const Refer = ({ row, mutate }) => { const [openReferDialog, setOpenReferDialog] = useState(false); + return ( <> @@ -24,7 +25,7 @@ const Refer = ({ rowId, mutate }) => { > ارجاع {openReferDialog && ( - + )} diff --git a/src/components/dashboard/fastReact/complaintList/RowActions/index.jsx b/src/components/dashboard/fastReact/complaintList/RowActions/index.jsx index 081a536..f272407 100644 --- a/src/components/dashboard/fastReact/complaintList/RowActions/index.jsx +++ b/src/components/dashboard/fastReact/complaintList/RowActions/index.jsx @@ -16,7 +16,7 @@ const RowActions = ({ row, mutate, mutateParentTable }) => { rowId={row.getValue("road_observeds__id")} /> )} - + ); From a812049cfe6e693ec6c7d0138b1757a520c59de0 Mon Sep 17 00:00:00 2001 From: AmirHossein Mahmoodi Date: Tue, 3 Jun 2025 10:22:00 +0330 Subject: [PATCH 2/3] formatting --- .../fastReact/complaintList/RowActions/Refer/ReferContent.jsx | 2 +- .../fastReact/complaintList/RowActions/Refer/index.jsx | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx b/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx index ef74d91..43f249c 100644 --- a/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx +++ b/src/components/dashboard/fastReact/complaintList/RowActions/Refer/ReferContent.jsx @@ -44,7 +44,7 @@ const ReferContent = ({ row, mutate, setOpenReferDialog }) => { mutate(); setOpenReferDialog(false); }) - .catch(() => { }); + .catch(() => {}); }; return ( diff --git a/src/components/dashboard/fastReact/complaintList/RowActions/Refer/index.jsx b/src/components/dashboard/fastReact/complaintList/RowActions/Refer/index.jsx index 63431a0..31c1cd5 100644 --- a/src/components/dashboard/fastReact/complaintList/RowActions/Refer/index.jsx +++ b/src/components/dashboard/fastReact/complaintList/RowActions/Refer/index.jsx @@ -24,9 +24,7 @@ const Refer = ({ row, mutate }) => { }} > ارجاع - {openReferDialog && ( - - )} + {openReferDialog && } ); From c1286a146ecfd2ae25e04195a4b5fdd826064d15 Mon Sep 17 00:00:00 2001 From: AmirHossein Mahmoodi Date: Tue, 3 Jun 2025 10:23:04 +0330 Subject: [PATCH 3/3] change version to 1.3.8 --- .env.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 39796b8..5df7bca 100644 --- a/.env.example +++ b/.env.example @@ -1,4 +1,4 @@ HOST="rms.witel.ir" -NEXT_PUBLIC_VERSION="1.3.8" +NEXT_PUBLIC_VERSION="1.3.9" NEXT_PUBLIC_API_URL="https://rms.witel.ir" NEXT_PUBLIC_MAPTILE_ENDPOINT="https://rmsmap.rmto.ir/141map" \ No newline at end of file