Skip to content

Commit

Permalink
shifted to lodash
Browse files Browse the repository at this point in the history
  • Loading branch information
shivankacker committed May 10, 2024
1 parent 4dfd089 commit 864d5e6
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/Components/Patient/PatientRegister.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ import routes from "../../Redux/api.js";
import request from "../../Utils/request/request.js";
import SelectMenuV2 from "../Form/SelectMenuV2.js";
import Checkbox from "../Common/components/CheckBox.js";
import _ from "lodash";

const Loading = lazy(() => import("../Common/Loading"));
const PageTitle = lazy(() => import("../Common/PageTitle"));
Expand Down Expand Up @@ -800,10 +801,7 @@ export const PatientRegister = (props: PatientRegisterProps) => {
: null
: null,
test_type: formData.test_type,
name: formData.name
.split(" ")
.map((i: string) => i.charAt(0).toUpperCase() + i.slice(1))
.join(" "),
name: _.startCase(_.toLower(formData.name)),
pincode: formData.pincode ? formData.pincode : undefined,
gender: Number(formData.gender),
nationality: formData.nationality,
Expand Down

0 comments on commit 864d5e6

Please sign in to comment.