diff --git a/src/Components/ExternalResult/ResultList.tsx b/src/Components/ExternalResult/ResultList.tsx
index 8fddc7cadc9..9a04fcf38b6 100644
--- a/src/Components/ExternalResult/ResultList.tsx
+++ b/src/Components/ExternalResult/ResultList.tsx
@@ -16,9 +16,12 @@ import Page from "../Common/components/Page";
import routes from "../../Redux/api";
import useQuery from "../../Utils/request/useQuery";
import { parsePhoneNumber } from "../../Utils/utils";
+import useAuthUser from "../../Common/hooks/useAuthUser";
+import { NonReadOnlyUsers } from "../../Utils/AuthorizeFor";
const Loading = lazy(() => import("../Common/Loading"));
export default function ResultList() {
+ const authUser = useAuthUser();
const {
qParams,
updateQuery,
@@ -165,6 +168,10 @@ export default function ResultList() {
{
@@ -226,13 +233,18 @@ export default function ResultList() {
navigate("/external_results/upload"),
- options: {
- icon: ,
- },
- },
+ ...(authUser.user_type !== "Nurse" &&
+ authUser.user_type !== "Staff"
+ ? [
+ {
+ label: "Import Results",
+ action: () => navigate("/external_results/upload"),
+ options: {
+ icon: ,
+ },
+ },
+ ]
+ : []),
{
label: "Export Results",
action: () =>
diff --git a/src/Components/Patient/PatientRegister.tsx b/src/Components/Patient/PatientRegister.tsx
index 546d35cc487..ce63d5019de 100644
--- a/src/Components/Patient/PatientRegister.tsx
+++ b/src/Components/Patient/PatientRegister.tsx
@@ -70,6 +70,7 @@ import useConfig from "../../Common/hooks/useConfig";
import { useDispatch } from "react-redux";
import { validatePincode } from "../../Common/validation";
import { FormContextValue } from "../Form/FormContext.js";
+import useAuthUser from "../../Common/hooks/useAuthUser.js";
const Loading = lazy(() => import("../Common/Loading"));
const PageTitle = lazy(() => import("../Common/PageTitle"));
@@ -180,6 +181,7 @@ const patientFormReducer = (state = initialState, action: any) => {
};
export const PatientRegister = (props: PatientRegisterProps) => {
+ const authUser = useAuthUser();
const { goBack } = useAppHistory();
const { gov_data_api_key, enable_hcx, enable_abdm } = useConfig();
const dispatchAction: any = useDispatch();
@@ -1173,6 +1175,10 @@ export const PatientRegister = (props: PatientRegisterProps) => {
{
setShowImport({
show: true,
|