diff --git a/jsconfig.json b/jsconfig.json index b51472a..c136578 100644 --- a/jsconfig.json +++ b/jsconfig.json @@ -1,27 +1,27 @@ // javascript for production -{ - "compilerOptions": { - "paths": { - "@/*": ["./src/*"], - "^/*": ["./public/*"] - } - } -} - -// typescript for local development // { // "compilerOptions": { -// "jsx": "react-jsx", -// "noUnusedLocals": true, -// "noImplicitAny": false, -// "checkJs": true, -// "allowJs": true, -// "strict": true, -// "baseUrl": ".", // "paths": { // "@/*": ["./src/*"], // "^/*": ["./public/*"] // } -// }, -// "exclude": ["node_modules"] +// } // } + +// typescript for local development +{ + "compilerOptions": { + "jsx": "react-jsx", + "noUnusedLocals": true, + "noImplicitAny": false, + "checkJs": true, + "allowJs": true, + "strict": true, + "baseUrl": ".", + "paths": { + "@/*": ["./src/*"], + "^/*": ["./public/*"] + } + }, + "exclude": ["node_modules"] +} diff --git a/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmRoadSafetyForm/ConfirmRoadSafetyDialog.jsx b/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmRoadSafetyForm/ConfirmRoadSafetyDialog.jsx index 7b8e90e..862fb85 100644 --- a/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmRoadSafetyForm/ConfirmRoadSafetyDialog.jsx +++ b/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmRoadSafetyForm/ConfirmRoadSafetyDialog.jsx @@ -1,5 +1,5 @@ import DialogLoading from "@/core/components/DialogLoading"; -import { GET_REQUEST_INQUIRY_PRIVACY_ZAMIN_GOV_ASSISTANT_DETAILS } from "@/core/utils/routes"; +import { GET_REQUEST_INQUIRY_PRIVACY } from "@/core/utils/routes"; import useRequest from "@/lib/hooks/useRequest"; import { DialogContent, Typography } from "@mui/material"; import { useEffect, useState } from "react"; @@ -14,7 +14,7 @@ const ConfirmRoadSafetyDialog = ({ row, handleClose, rowId, mutate }) => { const fetchData = async () => { try { setLoading(true); - const response = await request(`${GET_REQUEST_INQUIRY_PRIVACY_ZAMIN_GOV_ASSISTANT_DETAILS}/${rowId}`); + const response = await request(`${GET_REQUEST_INQUIRY_PRIVACY}/${rowId}`); setData(response.data.data); } catch (error) { } finally { diff --git a/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmVerifyLicenseForm/ConfirmRoadSafetyDialog.jsx b/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmVerifyLicenseForm/ConfirmRoadSafetyDialog.jsx index 8305cf4..862fb85 100644 --- a/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmVerifyLicenseForm/ConfirmRoadSafetyDialog.jsx +++ b/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/ConfirmVerifyLicenseForm/ConfirmRoadSafetyDialog.jsx @@ -1,5 +1,5 @@ import DialogLoading from "@/core/components/DialogLoading"; -import { GET_REQUEST_INQUIRY_PRIVACY_ZAMIN_GOV_ASSISTANT_DETAILS } from "@/core/utils/routes"; +import { GET_REQUEST_INQUIRY_PRIVACY } from "@/core/utils/routes"; import useRequest from "@/lib/hooks/useRequest"; import { DialogContent, Typography } from "@mui/material"; import { useEffect, useState } from "react"; @@ -14,7 +14,7 @@ const ConfirmRoadSafetyDialog = ({ row, handleClose, rowId, mutate }) => { const fetchData = async () => { try { setLoading(true); - const response = await request(`${GET_REQUEST_INQUIRY_PRIVACY_ZAMIN_GOV_ASSISTANT_DETAILS}/${rowId}`); + const response = await request(`${GET_REQUEST_INQUIRY_PRIVACY}/${rowId}`); setData(response.data.data); } catch (error) { } finally { @@ -28,9 +28,8 @@ const ConfirmRoadSafetyDialog = ({ row, handleClose, rowId, mutate }) => { return ( <> {loading ? ( -
Loading...
- ) : // - data ? ( + + ) : data ? ( { const fetchData = async () => { try { setLoading(true); - const response = await request(`${GET_REQUEST_INQUIRY_PRIVACY_ZAMIN_GOV_ASSISTANT_DETAILS}/${rowId}`); + const response = await request(`${GET_REQUEST_INQUIRY_PRIVACY}/${rowId}`); setData(response.data.data); } catch (error) { } finally { @@ -28,9 +28,15 @@ const ConfirmRoadSafetyDialog = ({ row, handleClose, rowId, mutate }) => { return ( <> {loading ? ( - + ) : data ? ( - + ) : ( اطلاعات درخواست در سامانه یافت نشد @@ -38,6 +44,5 @@ const ConfirmRoadSafetyDialog = ({ row, handleClose, rowId, mutate }) => { )} ); - -} -export default ConfirmRoadSafetyDialog \ No newline at end of file +}; +export default ConfirmRoadSafetyDialog; diff --git a/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/index.jsx b/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/index.jsx index 58261f4..cb1ecf7 100644 --- a/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/index.jsx +++ b/src/components/dashboard/inquiryPrivacy/technical-deputy/RowActions/index.jsx @@ -5,18 +5,17 @@ import ConfirmVerifyLicenseForm from "./ConfirmVerifyLicenseForm"; const RowActions = ({ row, mutate }) => { return ( - <> - // - // {row.original.state_id == 3 && ( - // - // )} - // {row.original.state_id == 6 && ( - // - // )} - // {row.original.state_id == 14 && ( - // - // )} - // + + {row.original.state_id == 3 && ( + + )} + {row.original.state_id == 6 && ( + + )} + {row.original.state_id == 14 && ( + + )} + ); }; export default RowActions; diff --git a/src/core/utils/routes.js b/src/core/utils/routes.js index e9e7119..070a222 100644 --- a/src/core/utils/routes.js +++ b/src/core/utils/routes.js @@ -242,3 +242,4 @@ export const CITY_ADMIN_FEEDBACK = api + "/api/v3/harim/province_office/feedback export const GET_PRIVACY_ADMIN_LIST = api + "/api/v3/harim/harim_office"; export const PRIVACY_ADMIN_ACTION_API = api + "/api/v3/harim/harim_office"; export const GET_INQUIRY_PRIVACY_TABLE_LIST = api + "/api/v3/harim/technical_deputy"; +export const GET_REQUEST_INQUIRY_PRIVACY = api + "/api/v3/harim/technical_deputy";