Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added units for pressure-sore #8755

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import { IPressureSore } from "../../../Patient/models";
import { Error } from "../../../../Utils/Notifications";
import { classNames, getValueDescription } from "../../../../Utils/utils";
import { calculatePushScore } from "./utils";
import { useTranslation } from "react-i18next";

const PressureSore = ({ log, onChange, readonly }: LogUpdateSectionProps) => {
const value = log.pressure_sore ?? [];
Expand Down Expand Up @@ -104,6 +105,8 @@ const RegionEditor = (props: RegionEditorProps) => {

const isReadOnly = !props.onSave;

const { t } = useTranslation();

return (
<PopupModal
show={props.show}
Expand All @@ -129,7 +132,7 @@ const RegionEditor = (props: RegionEditorProps) => {
<br />
<div className="grid grid-cols-2 gap-2">
<TextFormField
label="Width"
label={t("width", { unit: "cm" })}
name="width"
disabled={isReadOnly}
labelClassName="text-xs"
Expand All @@ -141,7 +144,7 @@ const RegionEditor = (props: RegionEditorProps) => {
onChange={(e) => update({ width: parseFloat(e.value) })}
/>
<TextFormField
label="Length"
label={t("length", { unit: "cm" })}
name="length"
disabled={isReadOnly}
labelClassName="text-xs"
Expand Down
4 changes: 3 additions & 1 deletion src/Locale/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -1022,5 +1022,7 @@
"date_of_result": "Covid confirmation date",
"is_vaccinated": "Whether vaccinated",
"consultation_not_filed": "You have not filed any consultation for this patient yet.",
"consultation_not_filed_description": "Please file a consultation for this patient to continue."
"consultation_not_filed_description": "Please file a consultation for this patient to continue.",
"width": "Width ({{unit}})",
"length": "Length ({{unit}})"
}
Loading