diff --git a/cypress/pageobject/Asset/AssetFilters.ts b/cypress/pageobject/Asset/AssetFilters.ts
index 33363f2d161..ac83ca97c0b 100644
--- a/cypress/pageobject/Asset/AssetFilters.ts
+++ b/cypress/pageobject/Asset/AssetFilters.ts
@@ -3,7 +3,7 @@ export class AssetFilters {
facilityName: string,
assetStatus: string,
assetClass: string,
- assetLocation: string
+ assetLocation: string,
) {
cy.contains("Advanced Filters").click();
cy.get("input[name='Facilities']")
diff --git a/cypress/pageobject/Asset/AssetSearch.ts b/cypress/pageobject/Asset/AssetSearch.ts
index b1ccb2f71c9..653c7bdd89c 100644
--- a/cypress/pageobject/Asset/AssetSearch.ts
+++ b/cypress/pageobject/Asset/AssetSearch.ts
@@ -17,7 +17,7 @@ export class AssetSearchPage {
verifyBadgeContent(expectedText: string) {
cy.get("[data-testid='Name/Serial No./QR ID']").should(
"contain",
- expectedText
+ expectedText,
);
}
@@ -54,7 +54,7 @@ export class AssetSearchPage {
verifyAssetListContains(dummyCameraText: string) {
cy.get("[data-testid='created-asset-list']").should(
"contain",
- dummyCameraText
+ dummyCameraText,
);
}
}
diff --git a/cypress/pageobject/Patient/PatientInsurance.ts b/cypress/pageobject/Patient/PatientInsurance.ts
index be4c25c5535..60eaefffa44 100644
--- a/cypress/pageobject/Patient/PatientInsurance.ts
+++ b/cypress/pageobject/Patient/PatientInsurance.ts
@@ -2,7 +2,7 @@ class PatientInsurance {
typePatientInsuranceDetail(
containerId: string,
fieldId: string,
- value: string
+ value: string,
) {
cy.get(`#${containerId}`).within(() => {
cy.get(`#${fieldId}`).click().type(value);
diff --git a/cypress/pageobject/Patient/PatientMedicalHistory.ts b/cypress/pageobject/Patient/PatientMedicalHistory.ts
index 1c9b733f3ba..a0dbdd0131a 100644
--- a/cypress/pageobject/Patient/PatientMedicalHistory.ts
+++ b/cypress/pageobject/Patient/PatientMedicalHistory.ts
@@ -31,7 +31,7 @@ class PatientMedicalHistory {
patientSymptoms4,
patientSymptoms5,
patientSymptoms6,
- patientSymptoms7
+ patientSymptoms7,
) {
cy.get("[data-testid=patient-details]").then(($dashboard) => {
cy.url().should("include", "/facility/");
@@ -51,7 +51,7 @@ class PatientMedicalHistory {
verifyNoSymptosPresent(patientSymptoms1: string) {
cy.get("[data-testid=patient-details]").should(
"not.contain",
- patientSymptoms1
+ patientSymptoms1,
);
}
}
diff --git a/scripts/generate-build-version.js b/scripts/generate-build-version.js
index 36e7ea1162a..84b8e0e5928 100644
--- a/scripts/generate-build-version.js
+++ b/scripts/generate-build-version.js
@@ -20,5 +20,5 @@ fs.writeFile(
return console.log(err);
}
return null;
- }
+ },
);
diff --git a/src/Components/Facility/Investigations/InvestigationTable.tsx b/src/Components/Facility/Investigations/InvestigationTable.tsx
index 6984b0baedb..18c64108b6f 100644
--- a/src/Components/Facility/Investigations/InvestigationTable.tsx
+++ b/src/Components/Facility/Investigations/InvestigationTable.tsx
@@ -4,6 +4,7 @@ import { SelectFormField } from "../../Form/FormFields/SelectFormField";
import TextFormField from "../../Form/FormFields/TextFormField";
import { classNames } from "../../../Utils/utils";
import { useState } from "react";
+import { useTranslation } from "react-i18next";
const TestRow = ({ data, i, onChange, showForm, value, isChanged }: any) => {
return (
@@ -70,6 +71,7 @@ export const InvestigationTable = ({
handleUpdateCancel,
handleSave,
}: any) => {
+ const { t } = useTranslation();
const [searchFilter, setSearchFilter] = useState("");
const [showForm, setShowForm] = useState(false);
const filterTests = Object.values(data).filter((i: any) => {
@@ -84,16 +86,10 @@ export const InvestigationTable = ({
return (
- {title &&
{title}
}
-
-
window.print()}
- className="my-2 mr-2"
- disabled={showForm}
- >
- Print Report
-
+ {title && (
+
{title}
+ )}
+
setSearchFilter(e.value)}
/>
-
-
-
-
+
+
+
+
{["Name", "Value", "Unit", "Min", "Max", "Ideal"].map(
(heading) => (
{heading}
|
@@ -143,7 +140,7 @@ export const InvestigationTable = ({
)}
-
+
{filterTests.length > 0 ? (
filterTests.map((t: any, i) => {
const value =
@@ -173,12 +170,13 @@ export const InvestigationTable = ({
};
handleValueChange(value, target);
}}
+ className="print:text-black"
/>
);
})
) : (
-
- No tests taken
+
+ {t("no_tests_taken")} |
)}
diff --git a/src/Components/Facility/Investigations/ShowInvestigation.tsx b/src/Components/Facility/Investigations/ShowInvestigation.tsx
index a7f74b98fde..7477c64f899 100644
--- a/src/Components/Facility/Investigations/ShowInvestigation.tsx
+++ b/src/Components/Facility/Investigations/ShowInvestigation.tsx
@@ -1,14 +1,13 @@
import _, { set } from "lodash-es";
import { navigate } from "raviger";
import { lazy, useCallback, useReducer } from "react";
-import { useTranslation } from "react-i18next";
import routes from "../../../Redux/api";
import * as Notification from "../../../Utils/Notifications.js";
import request from "../../../Utils/request/request";
import useQuery from "../../../Utils/request/useQuery";
-import PageTitle from "../../Common/PageTitle";
import InvestigationTable from "./InvestigationTable";
-
+import PrintPreview from "../../../CAREUI/misc/PrintPreview";
+import { useTranslation } from "react-i18next";
const Loading = lazy(() => import("../../Common/Loading"));
const initialState = {
@@ -35,10 +34,15 @@ const updateFormReducer = (state = initialState, action: any) => {
}
};
-export default function ShowInvestigation(props: any) {
+interface ShowInvestigationProps {
+ consultationId: string;
+ patientId: string;
+ sessionId: string;
+ facilityId: string;
+}
+export default function ShowInvestigation(props: ShowInvestigationProps) {
+ const { consultationId, patientId, sessionId } = props;
const { t } = useTranslation();
- const { consultationId, patientId, facilityId, sessionId } = props;
-
const [state, dispatch] = useReducer(updateFormReducer, initialState);
const { loading: investigationLoading } = useQuery(routes.getInvestigation, {
pathParams: {
@@ -141,20 +145,16 @@ export default function ShowInvestigation(props: any) {
if (patientLoading || investigationLoading) {
return ;
}
-
return (
-
+
);
}
diff --git a/src/Components/Facility/TreatmentSummary.tsx b/src/Components/Facility/TreatmentSummary.tsx
index e719e859a4b..610e7dc189d 100644
--- a/src/Components/Facility/TreatmentSummary.tsx
+++ b/src/Components/Facility/TreatmentSummary.tsx
@@ -4,10 +4,8 @@ import {
formatDateTime,
formatPatientAge,
} from "../../Utils/utils";
-import useAppHistory from "../../Common/hooks/useAppHistory";
import routes from "../../Redux/api";
import useQuery from "../../Utils/request/useQuery";
-import CareIcon from "../../CAREUI/icons/CareIcon";
import { ConsultationModel } from "./models";
import { useMemo } from "react";
import {
@@ -18,6 +16,8 @@ import PageHeadTitle from "../Common/PageHeadTitle";
import { useTranslation } from "react-i18next";
import { PatientModel } from "../Patient/models";
import MedicineRoutes from "../Medicine/routes";
+import PrintPreview from "../../CAREUI/misc/PrintPreview";
+import careConfig from "@careConfig";
export interface ITreatmentSummaryProps {
consultationId: string;
@@ -28,12 +28,9 @@ export interface ITreatmentSummaryProps {
export default function TreatmentSummary({
consultationId,
patientId,
- facilityId,
}: ITreatmentSummaryProps) {
const { t } = useTranslation();
const date = new Date();
- const { goBack } = useAppHistory();
- const url = `/facility/${facilityId}/patient/${patientId}/consultation/${consultationId}`;
const { data: patientData } = useQuery(routes.getPatient, {
pathParams: { id: patientId },
@@ -49,50 +46,42 @@ export default function TreatmentSummary({
-
-
-
-
-
-
-
- {consultationData?.facility_name ?? ""}
-
+
+
+
+
{consultationData?.facility_name}
+
+
+
+ {t("treatment_summary__heading")}
+
-
- {t("treatment_summary__heading")}
-
+
{formatDate(date)}
-
{formatDate(date)}
+
+
-
-
+
-
+
-
+
-
+
-
+
-
-
-
+
+
-
+
);
diff --git a/src/Locale/en/Consultation.json b/src/Locale/en/Consultation.json
index 8282656b560..3d101bcb2bd 100644
--- a/src/Locale/en/Consultation.json
+++ b/src/Locale/en/Consultation.json
@@ -22,9 +22,12 @@
"investigations": "Investigations",
"search_investigation_placeholder": "Search Investigation & Groups",
"save_investigation": "Save Investigation",
+ "investigation_report_for_{{name}}": "Investigation Report for {{name}}",
+ "investigation_report_of_{{name}}":"Investigation Report of : {{name}}",
"investigation_reports": "Investigation Reports",
"no_investigation": "No investigation Reports found",
"investigations_suggested": "Investigations Suggested",
+ "no_tests_taken":"No tests taken",
"to_be_conducted": "To be conducted",
"log_report": "Log Report",
"no_investigation_suggestions": "No Investigation Suggestions",
diff --git a/src/style/index.css b/src/style/index.css
index 327cc03d047..254bf4e9b6e 100644
--- a/src/style/index.css
+++ b/src/style/index.css
@@ -435,7 +435,6 @@ button:disabled,
background-size: 1000px 100%;
}
-
@media print {
body * {
visibility: hidden;
@@ -450,7 +449,7 @@ button:disabled,
left: 0;
top: 0;
}
-}
+}
.header-section .appBar {
z-index: 1201;