{t("examination.previousentries")}
diff --git a/src/components/accessories/patientVisit/patientVisit.tsx b/src/components/accessories/patientVisit/patientVisit.tsx
index de06acde9..01b672c2d 100644
--- a/src/components/accessories/patientVisit/patientVisit.tsx
+++ b/src/components/accessories/patientVisit/patientVisit.tsx
@@ -36,8 +36,6 @@ const PatientVisit: FunctionComponent = () => {
const [creationMode, setCreationMode] = useState(true);
- const [showModal, setShowModal] = useState(false);
-
const changeStatus = useAppSelector((state) => {
/*
Apart from "IDLE" create and update cannot reach "LOADING", "SUCCESS" and "FAIL"
@@ -112,10 +110,6 @@ const PatientVisit: FunctionComponent = () => {
scrollToElement(null);
};
- const addOperationCallback = () => {
- setShowModal(true);
- };
-
const onEdit: (row: VisitDTO) => void = (row) => {
setVisitToEdit(row);
setCreationMode(false);
@@ -141,7 +135,7 @@ const PatientVisit: FunctionComponent = () => {
isLoading={changeStatus === "LOADING"}
shouldResetForm={shouldResetForm}
resetFormCallback={resetFormCallback}
- addOperationCallback={addOperationCallback}
+ addOperationCallback={() => {}}
/>
{changeStatus === "FAIL" && (
diff --git a/src/components/accessories/paymentsTable/PaymentsTable.tsx b/src/components/accessories/paymentsTable/PaymentsTable.tsx
index 6e97d7aef..2d1f19de0 100644
--- a/src/components/accessories/paymentsTable/PaymentsTable.tsx
+++ b/src/components/accessories/paymentsTable/PaymentsTable.tsx
@@ -92,7 +92,7 @@ export const PaymentsTable: FC
= ({ fields }) => {
useEffect(() => {
dispatch(searchPayments(initialValues as TFilterValues));
- }, [fields]);
+ }, [dispatch, fields, initialValues]);
const { setFieldValue, handleBlur } = formik;
diff --git a/src/components/accessories/profilePicture/ProfilePicture.tsx b/src/components/accessories/profilePicture/ProfilePicture.tsx
index 843481382..1de796c80 100644
--- a/src/components/accessories/profilePicture/ProfilePicture.tsx
+++ b/src/components/accessories/profilePicture/ProfilePicture.tsx
@@ -30,10 +30,7 @@ import Webcam from "../../accessories/webcam/Webcam";
import { ProfilePictureCropper } from "../profilePictureCropper/ProfilePictureCropper";
import "./styles.scss";
import { IProps } from "./types";
-import {
- extractPictureFromSelection,
- preprocessImage
-} from "./utils";
+import { extractPictureFromSelection, preprocessImage } from "./utils";
export const ProfilePicture: FunctionComponent = ({
isEditable,
@@ -81,7 +78,7 @@ export const ProfilePicture: FunctionComponent = ({
setFromFileSystem(false);
openCropper();
}
- }, [pictureToResize]);
+ }, [fromFileSystem, pictureToResize, showModal]);
const pictureInputRef = useRef(null);
@@ -122,6 +119,7 @@ export const ProfilePicture: FunctionComponent = ({
preprocessImage(setPicture, image, setShowError);
closeModal();
},
+ // eslint-disable-next-line react-hooks/exhaustive-deps
[setPicture]
);
diff --git a/src/components/accessories/profilePicture/utils.ts b/src/components/accessories/profilePicture/utils.ts
index ef5ee634f..a88a21e64 100644
--- a/src/components/accessories/profilePicture/utils.ts
+++ b/src/components/accessories/profilePicture/utils.ts
@@ -1,7 +1,6 @@
-import { ChangeEvent, Dispatch, SetStateAction } from "react";
import imageCompression from "browser-image-compression";
+import { ChangeEvent, Dispatch, SetStateAction } from "react";
import { MAX_FILE_UPLOAD_SIZE } from "./consts";
-import { pick } from "lodash";
const createPreview = (img: HTMLImageElement) => {
const canvas = document.createElement("canvas");
diff --git a/src/components/accessories/table/Table.tsx b/src/components/accessories/table/Table.tsx
index f5bd9d6ea..324886ace 100644
--- a/src/components/accessories/table/Table.tsx
+++ b/src/components/accessories/table/Table.tsx
@@ -37,10 +37,10 @@ import {
import { TOrder } from "../../../libraries/sortUtils/types";
import Button from "../button/Button";
import ConfirmationDialog from "../confirmationDialog/ConfirmationDialog";
+import TableBodyRow from "./TableBodyRow";
import { FilterButton } from "./filter/FilterButton";
import { TFilterValues } from "./filter/types";
import "./styles.scss";
-import TableBodyRow from "./TableBodyRow";
import { IProps, TActions } from "./types";
const Table: FunctionComponent = ({
@@ -348,6 +348,7 @@ const Table: FunctionComponent = ({
if (onFilterChange && !manualFilter) {
onFilterChange(filters);
}
+ // eslint-disable-next-line react-hooks/exhaustive-deps
}, [filters]);
return (
@@ -399,7 +400,7 @@ const Table: FunctionComponent = ({
field={filterField}
onChange={(value) =>
setFilters((previous) => ({
- ...filters,
+ ...previous,
[filterField.key]: value,
}))
}
diff --git a/src/components/accessories/table/filter/FilterButton.tsx b/src/components/accessories/table/filter/FilterButton.tsx
index 7c00a6e9b..edf2d24b3 100644
--- a/src/components/accessories/table/filter/FilterButton.tsx
+++ b/src/components/accessories/table/filter/FilterButton.tsx
@@ -101,6 +101,12 @@ export const FilterButton = ({ field, onChange }: IOwnProps) => {
useEffect(() => {
formik.submitForm();
+ const submit = setTimeout(() => {
+ formik.submitForm();
+ }, 250);
+
+ return () => clearInterval(submit);
+ // eslint-disable-next-line react-hooks/exhaustive-deps
}, [formik.values]);
return (
diff --git a/src/components/accessories/tabs/RouterTabs.tsx b/src/components/accessories/tabs/RouterTabs.tsx
index c094f9c49..36bcc7ece 100644
--- a/src/components/accessories/tabs/RouterTabs.tsx
+++ b/src/components/accessories/tabs/RouterTabs.tsx
@@ -30,7 +30,7 @@ const RouterTabs: FunctionComponent = ({ config, defaultRoute }) => {
if (!mobile) {
return tabs.map((item, index) => {
const path = item.path!;
- return tabs.length == 1 ? (
+ return tabs.length === 1 ? (
<>>
) : (
{
if (item.checkPermissions) {
const checkPermissions = asArray(item.checkPermissions);
return checkPermissions.find((permission) =>
- permissions.includes(permission)
+ permissions.includes(permission as TPermission)
);
}
return true;
diff --git a/src/components/activities/adminActivity/SideMenu/SideMenu.module.scss b/src/components/activities/adminActivity/SideMenu/SideMenu.module.scss
index 7f9c69479..d002276a1 100644
--- a/src/components/activities/adminActivity/SideMenu/SideMenu.module.scss
+++ b/src/components/activities/adminActivity/SideMenu/SideMenu.module.scss
@@ -20,6 +20,14 @@
gap: 8px;
}
+.editButton {
+ color: black !important;
+ background-color: white !important;
+ &:hover {
+ background-color: gray !important;
+ }
+}
+
.item {
display: flex;
flex-direction: column;
diff --git a/src/components/activities/adminActivity/SideMenu/SideMenu.tsx b/src/components/activities/adminActivity/SideMenu/SideMenu.tsx
index a3b6e55f6..81c8b9806 100644
--- a/src/components/activities/adminActivity/SideMenu/SideMenu.tsx
+++ b/src/components/activities/adminActivity/SideMenu/SideMenu.tsx
@@ -10,10 +10,12 @@ import {
People,
SupervisedUserCircle,
} from "@mui/icons-material";
+import { PATHS } from "consts";
import React, { ReactNode, useCallback } from "react";
import { useTranslation } from "react-i18next";
import { useLocation, useNavigate } from "react-router";
import { useAppSelector } from "../../../../libraries/hooks/redux";
+import Button from "../../../accessories/button/Button";
import { MenuItem } from "../../../accessories/menuItem";
import { IAdminSection } from "../types";
import classes from "./SideMenu.module.scss";
@@ -86,6 +88,7 @@ const SideMenu = () => {
))}
{t("nav.hospital")}
}
label={t(`nav.hospitalInfo`)}
onClick={() => {}}
@@ -102,6 +105,17 @@ const SideMenu = () => {
{entry[1] ?? "---"}
))}
+
}
/>
diff --git a/src/components/activities/editPatientActivity/EditPatientActivity.tsx b/src/components/activities/editPatientActivity/EditPatientActivity.tsx
index f73ae8524..d291558e1 100644
--- a/src/components/activities/editPatientActivity/EditPatientActivity.tsx
+++ b/src/components/activities/editPatientActivity/EditPatientActivity.tsx
@@ -50,7 +50,7 @@ const EditPatientActivity = () => {
if (isEmpty(patient.data) && patient.status === "IDLE" && id) {
dispatch(getPatient(id));
}
- }, [patient, id, getPatient]);
+ }, [patient, id, dispatch]);
const breadcrumbMap = {
[t("nav.patients")]: PATHS.patients,
@@ -81,10 +81,6 @@ const EditPatientActivity = () => {
},
})
);
- else
- console.error(
- 'The Patient: PatientDTO object must have a "code" property.'
- );
};
const [activityTransitionState, setActivityTransitionState] =
@@ -96,10 +92,9 @@ const EditPatientActivity = () => {
if (isEmpty(patient.data) && patient.status === "IDLE") {
getPatient(id!);
}
- }, [patient, id, getPatient]);
+ }, [patient, id]);
useEffect(() => {
- console.log(activityTransitionState);
if (activityTransitionState === "TO_PATIENT") {
getPatient(id!);
updatePatientReset();
@@ -108,7 +103,7 @@ const EditPatientActivity = () => {
setOpenConfirmationMessage(false);
setActivityTransitionState("IDLE");
}
- }, [activityTransitionState, updatePatientReset, getPatient, id]);
+ }, [activityTransitionState, id]);
useEffect(() => {
setOpenConfirmationMessage(hasSucceeded);
diff --git a/src/components/activities/laboratoryActivity/LaboratoryActivity.tsx b/src/components/activities/laboratoryActivity/LaboratoryActivity.tsx
index 9f5a69e92..a028f0d0d 100644
--- a/src/components/activities/laboratoryActivity/LaboratoryActivity.tsx
+++ b/src/components/activities/laboratoryActivity/LaboratoryActivity.tsx
@@ -27,7 +27,7 @@ const LaboratoryActivity: FC = () => {
return {
[t("nav.laboratory")]: PATHS.laboratory,
};
- }, [location]);
+ }, [location.pathname, t]);
const userCredentials = useAppSelector(
(state) => state.main.authentication.data
diff --git a/src/components/activities/newPatientActivity/NewPatientActivity.tsx b/src/components/activities/newPatientActivity/NewPatientActivity.tsx
index 72b298d56..6542af7c5 100644
--- a/src/components/activities/newPatientActivity/NewPatientActivity.tsx
+++ b/src/components/activities/newPatientActivity/NewPatientActivity.tsx
@@ -60,7 +60,7 @@ const NewPatientActivity: FunctionComponent
= ({
useEffect(() => {
dispatch(getPatientReset());
- }, []);
+ }, [dispatch]);
useEffect(() => {
if (
@@ -68,16 +68,16 @@ const NewPatientActivity: FunctionComponent = ({
activityTransitionState === "TO_DASHBOARD" ||
activityTransitionState === "TO_PATIENT_DASHBOARD"
) {
+ const code = patient?.code;
dispatch(createPatientReset());
setShouldResetForm(true);
+ if (activityTransitionState === "TO_PATIENT_DASHBOARD" && !!code) {
+ navigate(`${PATHS.patients_details}/${code}`, {
+ replace: true,
+ });
+ }
}
- }, [activityTransitionState, createPatientReset]);
-
- useEffect(() => {
- if (activityTransitionState === "TO_PATIENT_DASHBOARD" && patient?.code) {
- navigate(`/patients/details/${patient?.code}`, { replace: true });
- }
- }, [patient, activityTransitionState, createPatientReset]);
+ }, [activityTransitionState, dispatch, navigate, patient?.code]);
const infoBoxRef = useRef(null);
useEffect(() => {
@@ -97,8 +97,6 @@ const NewPatientActivity: FunctionComponent = ({
switch (activityTransitionState) {
case "TO_DASHBOARD":
return ;
- case "TO_PATIENT_DASHBOARD":
- return ;
default:
return (
diff --git a/src/components/activities/newPatientActivity/types.ts b/src/components/activities/newPatientActivity/types.ts
index c682e0979..3fa083d29 100644
--- a/src/components/activities/newPatientActivity/types.ts
+++ b/src/components/activities/newPatientActivity/types.ts
@@ -1,4 +1,3 @@
-import { PatientDTO } from "../../../generated";
import { TUserCredentials } from "../../../state/main/types";
export interface IOwnProps {
diff --git a/src/components/activities/patientDetailsActivity/InPatientDashboardMenu.tsx b/src/components/activities/patientDetailsActivity/InPatientDashboardMenu.tsx
index 3d121c567..1fbcd0042 100644
--- a/src/components/activities/patientDetailsActivity/InPatientDashboardMenu.tsx
+++ b/src/components/activities/patientDetailsActivity/InPatientDashboardMenu.tsx
@@ -10,7 +10,7 @@ import {
} from "@mui/icons-material";
import React, { FunctionComponent, useCallback } from "react";
import { useTranslation } from "react-i18next";
-import { useLocation, useNavigate } from "react-router";
+import { useNavigate } from "react-router";
import Arrow from "../../../assets/arrow-w.svg";
import { Permission } from "../../../libraries/permissionUtils/Permission";
import "./styles.scss";
@@ -27,7 +27,6 @@ const InPatientDashboardMenu: FunctionComponent
= ({
}) => {
const { t } = useTranslation();
- const { pathname } = useLocation();
const navigate = useNavigate();
const isActive = (value: string) => {
diff --git a/src/components/activities/patientDetailsActivity/OutPatientDashboardMenu.tsx b/src/components/activities/patientDetailsActivity/OutPatientDashboardMenu.tsx
index bfa339129..3e4de4957 100644
--- a/src/components/activities/patientDetailsActivity/OutPatientDashboardMenu.tsx
+++ b/src/components/activities/patientDetailsActivity/OutPatientDashboardMenu.tsx
@@ -8,7 +8,7 @@ import {
} from "@mui/icons-material";
import React, { FunctionComponent, useCallback } from "react";
import { useTranslation } from "react-i18next";
-import { useLocation, useNavigate } from "react-router";
+import { useNavigate } from "react-router";
import Arrow from "../../../assets/arrow-w.svg";
import "./styles.scss";
import { IUserSection } from "./types";
@@ -28,7 +28,6 @@ const OutPatientDashboardMenu: FunctionComponent = ({
return value === userSection ? "active" : "default";
};
- const { pathname } = useLocation();
const navigate = useNavigate();
const changeUserSection = useCallback(
@@ -36,7 +35,7 @@ const OutPatientDashboardMenu: FunctionComponent = ({
setUserSection(section);
navigate(`${section}`, { replace: true });
},
- [navigate, pathname, setUserSection]
+ [navigate, setUserSection]
);
return (
diff --git a/src/components/activities/patientDetailsActivity/PatientDetailsActivity.tsx b/src/components/activities/patientDetailsActivity/PatientDetailsActivity.tsx
index 0b3507712..9401185de 100644
--- a/src/components/activities/patientDetailsActivity/PatientDetailsActivity.tsx
+++ b/src/components/activities/patientDetailsActivity/PatientDetailsActivity.tsx
@@ -17,7 +17,7 @@ import { PatientDTOStatusEnum } from "../../../generated";
import { renderDate } from "../../../libraries/formatUtils/dataFormatting";
import { Permission } from "../../../libraries/permissionUtils/Permission";
import { scrollToElement } from "../../../libraries/uiUtils/scrollToElement";
-import { getPatient } from "../../../state/patients";
+import { getPatient, getPatientReset } from "../../../state/patients";
import {
Accordion,
AccordionDetails,
@@ -57,6 +57,12 @@ const PatientDetailsActivity = () => {
}
}, [patient, id, dispatch]);
+ useEffect(() => {
+ return () => {
+ dispatch(getPatientReset());
+ };
+ }, [dispatch]);
+
const breadcrumbMap = {
[t("nav.patients")]: PATHS.patients,
[t("nav.searchpatient")]: PATHS.patients_search,
diff --git a/src/components/activities/searchPatientActivity/PatientSearchItem.tsx b/src/components/activities/searchPatientActivity/PatientSearchItem.tsx
index 55379330c..cf3581e98 100644
--- a/src/components/activities/searchPatientActivity/PatientSearchItem.tsx
+++ b/src/components/activities/searchPatientActivity/PatientSearchItem.tsx
@@ -24,7 +24,7 @@ const PatientSearchItem: FunctionComponent = ({
navigate(`/patients/details/${patient.code}`);
}
}
- }, [activityTransitionState, getPatientSuccessCallback, patient]);
+ }, [activityTransitionState, getPatientSuccessCallback, navigate, patient]);
const patientDate = renderDate(patient.birthDate ?? "");
diff --git a/src/components/activities/searchPatientActivity/types.ts b/src/components/activities/searchPatientActivity/types.ts
index c35e85394..b695e9020 100644
--- a/src/components/activities/searchPatientActivity/types.ts
+++ b/src/components/activities/searchPatientActivity/types.ts
@@ -1,6 +1,6 @@
import { PatientDTO } from "../../../generated";
import { TUserCredentials } from "../../../state/main/types";
-import { IAction, TAPIResponseStatus } from "../../../state/types";
+import { TAPIResponseStatus } from "../../../state/types";
export interface IStateProps {
userCredentials: TUserCredentials;
diff --git a/src/consts.ts b/src/consts.ts
index 1974a2ef9..e895d8c37 100644
--- a/src/consts.ts
+++ b/src/consts.ts
@@ -73,4 +73,5 @@ export const PATHS = {
admin_admissions_types: "/admin/types/admissions",
admin_admissions_types_new: "/admin/types/admissions/new",
admin_admissions_types_edit: "/admin/types/admissions/:code/edit",
+ admin_hospital_edit: "/admin/hospital/edit",
};
diff --git a/src/generated/.openapi-generator/FILES b/src/generated/.openapi-generator/FILES
index 057f67774..e64020890 100644
--- a/src/generated/.openapi-generator/FILES
+++ b/src/generated/.openapi-generator/FILES
@@ -35,6 +35,8 @@ apis\SMSApi.ts
apis\StockMovementsApi.ts
apis\SuppliersApi.ts
apis\TherapiesApi.ts
+apis\UserGroupsApi.ts
+apis\UserSettingsApi.ts
apis\UsersApi.ts
apis\VaccineTypeApi.ts
apis\VaccinesApi.ts
@@ -62,7 +64,6 @@ models\FullBillDTO.ts
models\HospitalDTO.ts
models\LabWithRowsDTO.ts
models\LaboratoryDTO.ts
-models\LitePermissionDTO.ts
models\LoginRequest.ts
models\LoginResponse.ts
models\LotDTO.ts
@@ -116,6 +117,7 @@ models\SupplierDTO.ts
models\TherapyDTO.ts
models\TherapyRow.ts
models\TherapyRowDTO.ts
+models\TokenRefreshRequest.ts
models\UserDTO.ts
models\UserGroupDTO.ts
models\UserProfileDTO.ts
diff --git a/src/generated/apis/AdmissionTypesApi.ts b/src/generated/apis/AdmissionTypesApi.ts
index 7cd200d75..d17cf02ed 100644
--- a/src/generated/apis/AdmissionTypesApi.ts
+++ b/src/generated/apis/AdmissionTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/AdmissionsApi.ts b/src/generated/apis/AdmissionsApi.ts
index 9d21017b7..21fc6e4fa 100644
--- a/src/generated/apis/AdmissionsApi.ts
+++ b/src/generated/apis/AdmissionsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/AgeTypesApi.ts b/src/generated/apis/AgeTypesApi.ts
index 3c4f6039b..6129e939b 100644
--- a/src/generated/apis/AgeTypesApi.ts
+++ b/src/generated/apis/AgeTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/BillsApi.ts b/src/generated/apis/BillsApi.ts
index 99f8dbc49..530dd2604 100644
--- a/src/generated/apis/BillsApi.ts
+++ b/src/generated/apis/BillsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/DeliveryResultTypeApi.ts b/src/generated/apis/DeliveryResultTypeApi.ts
index 2fb981be8..2e8c0007a 100644
--- a/src/generated/apis/DeliveryResultTypeApi.ts
+++ b/src/generated/apis/DeliveryResultTypeApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/DeliveryTypeApi.ts b/src/generated/apis/DeliveryTypeApi.ts
index c790848b3..cd5beab74 100644
--- a/src/generated/apis/DeliveryTypeApi.ts
+++ b/src/generated/apis/DeliveryTypeApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/DischargeTypeApi.ts b/src/generated/apis/DischargeTypeApi.ts
index 24f642ae5..2fb9743d1 100644
--- a/src/generated/apis/DischargeTypeApi.ts
+++ b/src/generated/apis/DischargeTypeApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/DiseaseTypesApi.ts b/src/generated/apis/DiseaseTypesApi.ts
index eab00a017..9f0a757ce 100644
--- a/src/generated/apis/DiseaseTypesApi.ts
+++ b/src/generated/apis/DiseaseTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/DiseasesApi.ts b/src/generated/apis/DiseasesApi.ts
index 4bc6c1876..0e11a4134 100644
--- a/src/generated/apis/DiseasesApi.ts
+++ b/src/generated/apis/DiseasesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/ExamRowsApi.ts b/src/generated/apis/ExamRowsApi.ts
index 174efbd62..4a4fccea1 100644
--- a/src/generated/apis/ExamRowsApi.ts
+++ b/src/generated/apis/ExamRowsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/ExamTypesApi.ts b/src/generated/apis/ExamTypesApi.ts
index b2e99376d..7c6aa04bd 100644
--- a/src/generated/apis/ExamTypesApi.ts
+++ b/src/generated/apis/ExamTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/ExaminationsApi.ts b/src/generated/apis/ExaminationsApi.ts
index 1a4770aea..919c777d4 100644
--- a/src/generated/apis/ExaminationsApi.ts
+++ b/src/generated/apis/ExaminationsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/ExamsApi.ts b/src/generated/apis/ExamsApi.ts
index 40af44a78..28e37b638 100644
--- a/src/generated/apis/ExamsApi.ts
+++ b/src/generated/apis/ExamsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/HospitalsApi.ts b/src/generated/apis/HospitalsApi.ts
index 10db836f2..3013d624d 100644
--- a/src/generated/apis/HospitalsApi.ts
+++ b/src/generated/apis/HospitalsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/LaboratoriesApi.ts b/src/generated/apis/LaboratoriesApi.ts
index 92569326e..c82b7ebf3 100644
--- a/src/generated/apis/LaboratoriesApi.ts
+++ b/src/generated/apis/LaboratoriesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/LoginApi.ts b/src/generated/apis/LoginApi.ts
index 6e58d3efa..47ead5458 100644
--- a/src/generated/apis/LoginApi.ts
+++ b/src/generated/apis/LoginApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -16,12 +16,17 @@ import { BaseAPI, HttpHeaders, throwIfNullOrUndefined, OperationOpts, RawAjaxRes
import {
LoginRequest,
LoginResponse,
+ TokenRefreshRequest,
} from '../models';
export interface AuthenticateUserRequest {
loginRequest: LoginRequest;
}
+export interface RefreshTokenRequest {
+ tokenRefreshRequest: TokenRefreshRequest;
+}
+
/**
* no description
*/
@@ -64,4 +69,24 @@ export class LoginApi extends BaseAPI {
}, opts?.responseOpts);
};
+ /**
+ */
+ refreshToken({ tokenRefreshRequest }: RefreshTokenRequest): Observable
+ refreshToken({ tokenRefreshRequest }: RefreshTokenRequest, opts?: OperationOpts): Observable>
+ refreshToken({ tokenRefreshRequest }: RefreshTokenRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(tokenRefreshRequest, 'tokenRefreshRequest', 'refreshToken');
+
+ const headers: HttpHeaders = {
+ 'Content-Type': 'application/json',
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/auth/refresh-token',
+ method: 'POST',
+ headers,
+ body: tokenRefreshRequest,
+ }, opts?.responseOpts);
+ };
+
}
diff --git a/src/generated/apis/MalnutritionsApi.ts b/src/generated/apis/MalnutritionsApi.ts
index 8a2f3b77e..e8d207ecb 100644
--- a/src/generated/apis/MalnutritionsApi.ts
+++ b/src/generated/apis/MalnutritionsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/MedicalStockMovementTypeApi.ts b/src/generated/apis/MedicalStockMovementTypeApi.ts
index 66c327c64..1540eac5b 100644
--- a/src/generated/apis/MedicalStockMovementTypeApi.ts
+++ b/src/generated/apis/MedicalStockMovementTypeApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/MedicalStockWardApi.ts b/src/generated/apis/MedicalStockWardApi.ts
index 27c2a4923..fa566992a 100644
--- a/src/generated/apis/MedicalStockWardApi.ts
+++ b/src/generated/apis/MedicalStockWardApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/MedicalTypesApi.ts b/src/generated/apis/MedicalTypesApi.ts
index cc2df1619..4b376c2fc 100644
--- a/src/generated/apis/MedicalTypesApi.ts
+++ b/src/generated/apis/MedicalTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/MedicalsApi.ts b/src/generated/apis/MedicalsApi.ts
index 15cfc919c..0769ae0ba 100644
--- a/src/generated/apis/MedicalsApi.ts
+++ b/src/generated/apis/MedicalsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/OpdsApi.ts b/src/generated/apis/OpdsApi.ts
index 12b356051..cea986161 100644
--- a/src/generated/apis/OpdsApi.ts
+++ b/src/generated/apis/OpdsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/OperationsApi.ts b/src/generated/apis/OperationsApi.ts
index 2deac60fd..608e6e2af 100644
--- a/src/generated/apis/OperationsApi.ts
+++ b/src/generated/apis/OperationsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/OperationsTypesApi.ts b/src/generated/apis/OperationsTypesApi.ts
index d8bf85f20..066bd16f9 100644
--- a/src/generated/apis/OperationsTypesApi.ts
+++ b/src/generated/apis/OperationsTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/OthersPriceApi.ts b/src/generated/apis/OthersPriceApi.ts
index c98a161a7..cf2c878fe 100644
--- a/src/generated/apis/OthersPriceApi.ts
+++ b/src/generated/apis/OthersPriceApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/PatientConsensusApi.ts b/src/generated/apis/PatientConsensusApi.ts
index 9e08c936d..d6c5020d8 100644
--- a/src/generated/apis/PatientConsensusApi.ts
+++ b/src/generated/apis/PatientConsensusApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/PatientVaccinesApi.ts b/src/generated/apis/PatientVaccinesApi.ts
index 789d35790..8a8126561 100644
--- a/src/generated/apis/PatientVaccinesApi.ts
+++ b/src/generated/apis/PatientVaccinesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/PatientsApi.ts b/src/generated/apis/PatientsApi.ts
index f1b8676c4..93fc140b8 100644
--- a/src/generated/apis/PatientsApi.ts
+++ b/src/generated/apis/PatientsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/PermissionsApi.ts b/src/generated/apis/PermissionsApi.ts
index e7b733a45..18e60e094 100644
--- a/src/generated/apis/PermissionsApi.ts
+++ b/src/generated/apis/PermissionsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -17,14 +17,6 @@ import {
PermissionDTO,
} from '../models';
-export interface DeletePermissionRequest {
- id: number;
-}
-
-export interface InsertPermissionRequest {
- permissionDTO: PermissionDTO;
-}
-
export interface RetrievePermissionByIdRequest {
id: number;
}
@@ -33,58 +25,15 @@ export interface RetrievePermissionByNameRequest {
name: string;
}
-export interface RetrievePermissionsByUserGroupcodeRequest {
+export interface RetrievePermissionsByUserGroupCodeRequest {
userGroupCode: string;
}
-export interface UpdatePermissionRequest {
- id: number;
- permissionDTO: PermissionDTO;
-}
-
/**
* no description
*/
export class PermissionsApi extends BaseAPI {
- /**
- */
- deletePermission({ id }: DeletePermissionRequest): Observable
- deletePermission({ id }: DeletePermissionRequest, opts?: OperationOpts): Observable>
- deletePermission({ id }: DeletePermissionRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(id, 'id', 'deletePermission');
-
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/permissions/{id}'.replace('{id}', encodeURI(id)),
- method: 'DELETE',
- headers,
- }, opts?.responseOpts);
- };
-
- /**
- */
- insertPermission({ permissionDTO }: InsertPermissionRequest): Observable
- insertPermission({ permissionDTO }: InsertPermissionRequest, opts?: OperationOpts): Observable>
- insertPermission({ permissionDTO }: InsertPermissionRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(permissionDTO, 'permissionDTO', 'insertPermission');
-
- const headers: HttpHeaders = {
- 'Content-Type': 'application/json',
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/permissions',
- method: 'POST',
- headers,
- body: permissionDTO,
- }, opts?.responseOpts);
- };
-
/**
*/
retrieveAllPermissions(): Observable>
@@ -139,10 +88,10 @@ export class PermissionsApi extends BaseAPI {
/**
*/
- retrievePermissionsByUserGroupcode({ userGroupCode }: RetrievePermissionsByUserGroupcodeRequest): Observable>
- retrievePermissionsByUserGroupcode({ userGroupCode }: RetrievePermissionsByUserGroupcodeRequest, opts?: OperationOpts): Observable>>
- retrievePermissionsByUserGroupcode({ userGroupCode }: RetrievePermissionsByUserGroupcodeRequest, opts?: OperationOpts): Observable | RawAjaxResponse>> {
- throwIfNullOrUndefined(userGroupCode, 'userGroupCode', 'retrievePermissionsByUserGroupcode');
+ retrievePermissionsByUserGroupCode({ userGroupCode }: RetrievePermissionsByUserGroupCodeRequest): Observable>
+ retrievePermissionsByUserGroupCode({ userGroupCode }: RetrievePermissionsByUserGroupCodeRequest, opts?: OperationOpts): Observable>>
+ retrievePermissionsByUserGroupCode({ userGroupCode }: RetrievePermissionsByUserGroupCodeRequest, opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ throwIfNullOrUndefined(userGroupCode, 'userGroupCode', 'retrievePermissionsByUserGroupCode');
const headers: HttpHeaders = {
...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
@@ -155,25 +104,4 @@ export class PermissionsApi extends BaseAPI {
}, opts?.responseOpts);
};
- /**
- */
- updatePermission({ id, permissionDTO }: UpdatePermissionRequest): Observable
- updatePermission({ id, permissionDTO }: UpdatePermissionRequest, opts?: OperationOpts): Observable>
- updatePermission({ id, permissionDTO }: UpdatePermissionRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(id, 'id', 'updatePermission');
- throwIfNullOrUndefined(permissionDTO, 'permissionDTO', 'updatePermission');
-
- const headers: HttpHeaders = {
- 'Content-Type': 'application/json',
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/permissions/{id}'.replace('{id}', encodeURI(id)),
- method: 'PUT',
- headers,
- body: permissionDTO,
- }, opts?.responseOpts);
- };
-
}
diff --git a/src/generated/apis/PregnantTreatmentTypesApi.ts b/src/generated/apis/PregnantTreatmentTypesApi.ts
index 09474df30..8e7ad3018 100644
--- a/src/generated/apis/PregnantTreatmentTypesApi.ts
+++ b/src/generated/apis/PregnantTreatmentTypesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/PriceListsApi.ts b/src/generated/apis/PriceListsApi.ts
index d0618035c..969f8c3df 100644
--- a/src/generated/apis/PriceListsApi.ts
+++ b/src/generated/apis/PriceListsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/ReportsApi.ts b/src/generated/apis/ReportsApi.ts
index c13cf2f00..858692616 100644
--- a/src/generated/apis/ReportsApi.ts
+++ b/src/generated/apis/ReportsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/SMSApi.ts b/src/generated/apis/SMSApi.ts
index 5df572a84..81f523242 100644
--- a/src/generated/apis/SMSApi.ts
+++ b/src/generated/apis/SMSApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/StockMovementsApi.ts b/src/generated/apis/StockMovementsApi.ts
index e12592d16..c3691b134 100644
--- a/src/generated/apis/StockMovementsApi.ts
+++ b/src/generated/apis/StockMovementsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -23,10 +23,19 @@ export interface AlertCriticalQuantityRequest {
qty: number;
}
+export interface AlertCriticalQuantity1Request {
+ medCode: number;
+ qty: number;
+}
+
export interface GetLotByMedicalRequest {
medCode: number;
}
+export interface GetLotByMedical1Request {
+ medCode: number;
+}
+
export interface GetMovements1Request {
ref: string;
}
@@ -50,16 +59,49 @@ export interface GetMovements3Request {
to: string;
}
+export interface GetMovements5Request {
+ ref: string;
+}
+
+export interface GetMovements6Request {
+ medCode?: number;
+ medType?: string;
+ wardId?: string;
+ movType?: string;
+ movFrom?: string;
+ movTo?: string;
+ lotPrepFrom?: string;
+ lotPrepTo?: string;
+ lotDueFrom?: string;
+ lotDueTo?: string;
+}
+
+export interface GetMovements7Request {
+ wardId: string;
+ from: string;
+ to: string;
+}
+
export interface NewMultipleChargingMovementsRequest {
ref: string;
movementDTO: Array;
}
+export interface NewMultipleChargingMovements1Request {
+ ref: string;
+ movementDTO: Array;
+}
+
export interface NewMultipleDischargingMovementsRequest {
ref: string;
movementDTO: Array;
}
+export interface NewMultipleDischargingMovements1Request {
+ ref: string;
+ movementDTO: Array;
+}
+
/**
* no description
*/
@@ -82,6 +124,31 @@ export class StockMovementsApi extends BaseAPI {
'qty': qty,
};
+ return this.request({
+ url: '/stockmovements/critical/check',
+ method: 'GET',
+ headers,
+ query,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ alertCriticalQuantity1({ medCode, qty }: AlertCriticalQuantity1Request): Observable
+ alertCriticalQuantity1({ medCode, qty }: AlertCriticalQuantity1Request, opts?: OperationOpts): Observable>
+ alertCriticalQuantity1({ medCode, qty }: AlertCriticalQuantity1Request, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(medCode, 'medCode', 'alertCriticalQuantity1');
+ throwIfNullOrUndefined(qty, 'qty', 'alertCriticalQuantity1');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ const query: HttpQuery = { // required parameters are used directly since they are already checked by throwIfNullOrUndefined
+ 'med_code': medCode,
+ 'qty': qty,
+ };
+
return this.request({
url: '/medicalstockmovements/critical/check',
method: 'GET',
@@ -101,6 +168,24 @@ export class StockMovementsApi extends BaseAPI {
...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
};
+ return this.request>({
+ url: '/stockmovements/lot/{med_code}'.replace('{med_code}', encodeURI(medCode)),
+ method: 'GET',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getLotByMedical1({ medCode }: GetLotByMedical1Request): Observable>
+ getLotByMedical1({ medCode }: GetLotByMedical1Request, opts?: OperationOpts): Observable>>
+ getLotByMedical1({ medCode }: GetLotByMedical1Request, opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ throwIfNullOrUndefined(medCode, 'medCode', 'getLotByMedical1');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
return this.request>({
url: '/medicalstockmovements/lot/{med_code}'.replace('{med_code}', encodeURI(medCode)),
method: 'GET',
@@ -118,7 +203,7 @@ export class StockMovementsApi extends BaseAPI {
};
return this.request>({
- url: '/medicalstockmovements',
+ url: '/stockmovements',
method: 'GET',
headers,
}, opts?.responseOpts);
@@ -136,7 +221,7 @@ export class StockMovementsApi extends BaseAPI {
};
return this.request>({
- url: '/medicalstockmovements/{ref}'.replace('{ref}', encodeURI(ref)),
+ url: '/stockmovements/{ref}'.replace('{ref}', encodeURI(ref)),
method: 'GET',
headers,
}, opts?.responseOpts);
@@ -166,7 +251,7 @@ export class StockMovementsApi extends BaseAPI {
if (lotDueTo != null) { query['lot_due_to'] = (lotDueTo as any).toISOString(); }
return this.request>({
- url: '/medicalstockmovements/filter/v2',
+ url: '/stockmovements/filter/v2',
method: 'GET',
headers,
query,
@@ -192,6 +277,98 @@ export class StockMovementsApi extends BaseAPI {
'to': (to as any).toISOString(),
};
+ return this.request>({
+ url: '/stockmovements/filter/v1',
+ method: 'GET',
+ headers,
+ query,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getMovements4(): Observable>
+ getMovements4(opts?: OperationOpts): Observable>>
+ getMovements4(opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request>({
+ url: '/medicalstockmovements',
+ method: 'GET',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getMovements5({ ref }: GetMovements5Request): Observable>
+ getMovements5({ ref }: GetMovements5Request, opts?: OperationOpts): Observable>>
+ getMovements5({ ref }: GetMovements5Request, opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ throwIfNullOrUndefined(ref, 'ref', 'getMovements5');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request>({
+ url: '/medicalstockmovements/{ref}'.replace('{ref}', encodeURI(ref)),
+ method: 'GET',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getMovements6({ medCode, medType, wardId, movType, movFrom, movTo, lotPrepFrom, lotPrepTo, lotDueFrom, lotDueTo }: GetMovements6Request): Observable>
+ getMovements6({ medCode, medType, wardId, movType, movFrom, movTo, lotPrepFrom, lotPrepTo, lotDueFrom, lotDueTo }: GetMovements6Request, opts?: OperationOpts): Observable>>
+ getMovements6({ medCode, medType, wardId, movType, movFrom, movTo, lotPrepFrom, lotPrepTo, lotDueFrom, lotDueTo }: GetMovements6Request, opts?: OperationOpts): Observable | RawAjaxResponse>> {
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ const query: HttpQuery = {};
+
+ if (medCode != null) { query['med_code'] = medCode; }
+ if (medType != null) { query['med_type'] = medType; }
+ if (wardId != null) { query['ward_id'] = wardId; }
+ if (movType != null) { query['mov_type'] = movType; }
+ if (movFrom != null) { query['mov_from'] = (movFrom as any).toISOString(); }
+ if (movTo != null) { query['mov_to'] = (movTo as any).toISOString(); }
+ if (lotPrepFrom != null) { query['lot_prep_from'] = (lotPrepFrom as any).toISOString(); }
+ if (lotPrepTo != null) { query['lot_prep_to'] = (lotPrepTo as any).toISOString(); }
+ if (lotDueFrom != null) { query['lot_due_from'] = (lotDueFrom as any).toISOString(); }
+ if (lotDueTo != null) { query['lot_due_to'] = (lotDueTo as any).toISOString(); }
+
+ return this.request>({
+ url: '/medicalstockmovements/filter/v2',
+ method: 'GET',
+ headers,
+ query,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getMovements7({ wardId, from, to }: GetMovements7Request): Observable>
+ getMovements7({ wardId, from, to }: GetMovements7Request, opts?: OperationOpts): Observable>>
+ getMovements7({ wardId, from, to }: GetMovements7Request, opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ throwIfNullOrUndefined(wardId, 'wardId', 'getMovements7');
+ throwIfNullOrUndefined(from, 'from', 'getMovements7');
+ throwIfNullOrUndefined(to, 'to', 'getMovements7');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ const query: HttpQuery = { // required parameters are used directly since they are already checked by throwIfNullOrUndefined
+ 'ward_id': wardId,
+ 'from': (from as any).toISOString(),
+ 'to': (to as any).toISOString(),
+ };
+
return this.request>({
url: '/medicalstockmovements/filter/v1',
method: 'GET',
@@ -217,6 +394,32 @@ export class StockMovementsApi extends BaseAPI {
'ref': ref,
};
+ return this.request({
+ url: '/stockmovements/charge',
+ method: 'POST',
+ headers,
+ query,
+ body: movementDTO,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ newMultipleChargingMovements1({ ref, movementDTO }: NewMultipleChargingMovements1Request): Observable
+ newMultipleChargingMovements1({ ref, movementDTO }: NewMultipleChargingMovements1Request, opts?: OperationOpts): Observable>
+ newMultipleChargingMovements1({ ref, movementDTO }: NewMultipleChargingMovements1Request, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(ref, 'ref', 'newMultipleChargingMovements1');
+ throwIfNullOrUndefined(movementDTO, 'movementDTO', 'newMultipleChargingMovements1');
+
+ const headers: HttpHeaders = {
+ 'Content-Type': 'application/json',
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ const query: HttpQuery = { // required parameters are used directly since they are already checked by throwIfNullOrUndefined
+ 'ref': ref,
+ };
+
return this.request({
url: '/medicalstockmovements/charge',
method: 'POST',
@@ -243,6 +446,32 @@ export class StockMovementsApi extends BaseAPI {
'ref': ref,
};
+ return this.request({
+ url: '/stockmovements/discharge',
+ method: 'POST',
+ headers,
+ query,
+ body: movementDTO,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ newMultipleDischargingMovements1({ ref, movementDTO }: NewMultipleDischargingMovements1Request): Observable
+ newMultipleDischargingMovements1({ ref, movementDTO }: NewMultipleDischargingMovements1Request, opts?: OperationOpts): Observable>
+ newMultipleDischargingMovements1({ ref, movementDTO }: NewMultipleDischargingMovements1Request, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(ref, 'ref', 'newMultipleDischargingMovements1');
+ throwIfNullOrUndefined(movementDTO, 'movementDTO', 'newMultipleDischargingMovements1');
+
+ const headers: HttpHeaders = {
+ 'Content-Type': 'application/json',
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ const query: HttpQuery = { // required parameters are used directly since they are already checked by throwIfNullOrUndefined
+ 'ref': ref,
+ };
+
return this.request({
url: '/medicalstockmovements/discharge',
method: 'POST',
diff --git a/src/generated/apis/SuppliersApi.ts b/src/generated/apis/SuppliersApi.ts
index e878f2549..ea55d6a80 100644
--- a/src/generated/apis/SuppliersApi.ts
+++ b/src/generated/apis/SuppliersApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/TherapiesApi.ts b/src/generated/apis/TherapiesApi.ts
index b99d96e89..6d43e8b46 100644
--- a/src/generated/apis/TherapiesApi.ts
+++ b/src/generated/apis/TherapiesApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
diff --git a/src/generated/apis/UserGroupsApi.ts b/src/generated/apis/UserGroupsApi.ts
new file mode 100644
index 000000000..3c4f33694
--- /dev/null
+++ b/src/generated/apis/UserGroupsApi.ts
@@ -0,0 +1,183 @@
+// tslint:disable
+/**
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
+ *
+ * The version of the OpenAPI document: 0.1.0
+ *
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+import { Observable } from 'rxjs';
+import { BaseAPI, HttpHeaders, throwIfNullOrUndefined, encodeURI, OperationOpts, RawAjaxResponse } from '../runtime';
+import {
+ UserGroupDTO,
+} from '../models';
+
+export interface AssignPermissionRequest {
+ groupCode: string;
+ id: number;
+}
+
+export interface DeleteGroupRequest {
+ groupCode: string;
+}
+
+export interface GetUserGroupRequest {
+ groupCode: string;
+}
+
+export interface NewUserGroupRequest {
+ userGroupDTO: UserGroupDTO;
+}
+
+export interface RevokePermissionRequest {
+ groupCode: string;
+ id: number;
+}
+
+export interface UpdateUserGroupRequest {
+ groupCode: string;
+ userGroupDTO: UserGroupDTO;
+}
+
+/**
+ * no description
+ */
+export class UserGroupsApi extends BaseAPI {
+
+ /**
+ */
+ assignPermission({ groupCode, id }: AssignPermissionRequest): Observable
+ assignPermission({ groupCode, id }: AssignPermissionRequest, opts?: OperationOpts): Observable>
+ assignPermission({ groupCode, id }: AssignPermissionRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(groupCode, 'groupCode', 'assignPermission');
+ throwIfNullOrUndefined(id, 'id', 'assignPermission');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usergroups/{group_code}/permissions/{id}'.replace('{group_code}', encodeURI(groupCode)).replace('{id}', encodeURI(id)),
+ method: 'POST',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ deleteGroup({ groupCode }: DeleteGroupRequest): Observable
+ deleteGroup({ groupCode }: DeleteGroupRequest, opts?: OperationOpts): Observable>
+ deleteGroup({ groupCode }: DeleteGroupRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(groupCode, 'groupCode', 'deleteGroup');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usergroups/{group_code}'.replace('{group_code}', encodeURI(groupCode)),
+ method: 'DELETE',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getUserGroup({ groupCode }: GetUserGroupRequest): Observable
+ getUserGroup({ groupCode }: GetUserGroupRequest, opts?: OperationOpts): Observable>
+ getUserGroup({ groupCode }: GetUserGroupRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(groupCode, 'groupCode', 'getUserGroup');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usergroups/{group_code}'.replace('{group_code}', encodeURI(groupCode)),
+ method: 'GET',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getUserGroups(): Observable>
+ getUserGroups(opts?: OperationOpts): Observable>>
+ getUserGroups(opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request>({
+ url: '/usergroups',
+ method: 'GET',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ newUserGroup({ userGroupDTO }: NewUserGroupRequest): Observable
+ newUserGroup({ userGroupDTO }: NewUserGroupRequest, opts?: OperationOpts): Observable>
+ newUserGroup({ userGroupDTO }: NewUserGroupRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(userGroupDTO, 'userGroupDTO', 'newUserGroup');
+
+ const headers: HttpHeaders = {
+ 'Content-Type': 'application/json',
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usergroups',
+ method: 'POST',
+ headers,
+ body: userGroupDTO,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ revokePermission({ groupCode, id }: RevokePermissionRequest): Observable
+ revokePermission({ groupCode, id }: RevokePermissionRequest, opts?: OperationOpts): Observable>
+ revokePermission({ groupCode, id }: RevokePermissionRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(groupCode, 'groupCode', 'revokePermission');
+ throwIfNullOrUndefined(id, 'id', 'revokePermission');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usergroups/{group_code}/permissions/{id}'.replace('{group_code}', encodeURI(groupCode)).replace('{id}', encodeURI(id)),
+ method: 'DELETE',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ updateUserGroup({ groupCode, userGroupDTO }: UpdateUserGroupRequest): Observable
+ updateUserGroup({ groupCode, userGroupDTO }: UpdateUserGroupRequest, opts?: OperationOpts): Observable>
+ updateUserGroup({ groupCode, userGroupDTO }: UpdateUserGroupRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(groupCode, 'groupCode', 'updateUserGroup');
+ throwIfNullOrUndefined(userGroupDTO, 'userGroupDTO', 'updateUserGroup');
+
+ const headers: HttpHeaders = {
+ 'Content-Type': 'application/json',
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usergroups/{group_code}'.replace('{group_code}', encodeURI(groupCode)),
+ method: 'PUT',
+ headers,
+ body: userGroupDTO,
+ }, opts?.responseOpts);
+ };
+
+}
diff --git a/src/generated/apis/UserSettingsApi.ts b/src/generated/apis/UserSettingsApi.ts
index 2b676e0d4..50478299e 100644
--- a/src/generated/apis/UserSettingsApi.ts
+++ b/src/generated/apis/UserSettingsApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -12,12 +12,25 @@
*/
import { Observable } from 'rxjs';
-import { BaseAPI, HttpHeaders, throwIfNullOrUndefined, OperationOpts, RawAjaxResponse } from '../runtime';
+import { BaseAPI, HttpHeaders, throwIfNullOrUndefined, encodeURI, OperationOpts, RawAjaxResponse } from '../runtime';
import {
UserSettingDTO,
} from '../models';
-export interface NewUserSettingRequest {
+export interface DeleteUserSettingRequest {
+ id: number;
+}
+
+export interface GetUserSettingByUserRequest {
+ configName: string;
+}
+
+export interface NewUserSettingsRequest {
+ userSettingDTO: UserSettingDTO;
+}
+
+export interface UpdateUserSettingsRequest {
+ id: number;
userSettingDTO: UserSettingDTO;
}
@@ -28,15 +41,35 @@ export class UserSettingsApi extends BaseAPI {
/**
*/
- getUserSettingDashboard(): Observable
- getUserSettingDashboard(opts?: OperationOpts): Observable>
- getUserSettingDashboard(opts?: OperationOpts): Observable> {
+ deleteUserSetting({ id }: DeleteUserSettingRequest): Observable
+ deleteUserSetting({ id }: DeleteUserSettingRequest, opts?: OperationOpts): Observable>
+ deleteUserSetting({ id }: DeleteUserSettingRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(id, 'id', 'deleteUserSetting');
+
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usersettings/{id}'.replace('{id}', encodeURI(id)),
+ method: 'DELETE',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ getUserSettingByUser({ configName }: GetUserSettingByUserRequest): Observable
+ getUserSettingByUser({ configName }: GetUserSettingByUserRequest, opts?: OperationOpts): Observable>
+ getUserSettingByUser({ configName }: GetUserSettingByUserRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(configName, 'configName', 'getUserSettingByUser');
+
const headers: HttpHeaders = {
...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
};
return this.request({
- url: '/usersettings/dashboard',
+ url: '/usersettings/{configName}'.replace('{configName}', encodeURI(configName)),
method: 'GET',
headers,
}, opts?.responseOpts);
@@ -44,10 +77,26 @@ export class UserSettingsApi extends BaseAPI {
/**
*/
- newUserSetting({ userSettingDTO }: NewUserSettingRequest): Observable
- newUserSetting({ userSettingDTO }: NewUserSettingRequest, opts?: OperationOpts): Observable>
- newUserSetting({ userSettingDTO }: NewUserSettingRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(userSettingDTO, 'userSettingDTO', 'newUserSetting');
+ getUserSettings(): Observable>
+ getUserSettings(opts?: OperationOpts): Observable>>
+ getUserSettings(opts?: OperationOpts): Observable | RawAjaxResponse>> {
+ const headers: HttpHeaders = {
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request>({
+ url: '/usersettings',
+ method: 'GET',
+ headers,
+ }, opts?.responseOpts);
+ };
+
+ /**
+ */
+ newUserSettings({ userSettingDTO }: NewUserSettingsRequest): Observable
+ newUserSettings({ userSettingDTO }: NewUserSettingsRequest, opts?: OperationOpts): Observable>
+ newUserSettings({ userSettingDTO }: NewUserSettingsRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(userSettingDTO, 'userSettingDTO', 'newUserSettings');
const headers: HttpHeaders = {
'Content-Type': 'application/json',
@@ -62,4 +111,25 @@ export class UserSettingsApi extends BaseAPI {
}, opts?.responseOpts);
};
+ /**
+ */
+ updateUserSettings({ id, userSettingDTO }: UpdateUserSettingsRequest): Observable
+ updateUserSettings({ id, userSettingDTO }: UpdateUserSettingsRequest, opts?: OperationOpts): Observable>
+ updateUserSettings({ id, userSettingDTO }: UpdateUserSettingsRequest, opts?: OperationOpts): Observable> {
+ throwIfNullOrUndefined(id, 'id', 'updateUserSettings');
+ throwIfNullOrUndefined(userSettingDTO, 'userSettingDTO', 'updateUserSettings');
+
+ const headers: HttpHeaders = {
+ 'Content-Type': 'application/json',
+ ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
+ };
+
+ return this.request({
+ url: '/usersettings/{id}'.replace('{id}', encodeURI(id)),
+ method: 'PUT',
+ headers,
+ body: userSettingDTO,
+ }, opts?.responseOpts);
+ };
+
}
diff --git a/src/generated/apis/UsersApi.ts b/src/generated/apis/UsersApi.ts
index cf2c58f9c..17bf554cc 100644
--- a/src/generated/apis/UsersApi.ts
+++ b/src/generated/apis/UsersApi.ts
@@ -1,9 +1,9 @@
// tslint:disable
/**
- * OH 2.0 Api Documentation
- * OH 2.0 Api Documentation
+ * Open Hospital API Documentation
+ * Open Hospital API Documentation
*
- * The version of the OpenAPI document: 1.0
+ * The version of the OpenAPI document: 0.1.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -14,25 +14,15 @@
import { Observable } from 'rxjs';
import { BaseAPI, HttpHeaders, HttpQuery, throwIfNullOrUndefined, encodeURI, OperationOpts, RawAjaxResponse } from '../runtime';
import {
- LitePermissionDTO,
+ PermissionDTO,
UserDTO,
- UserGroupDTO,
UserProfileDTO,
- UserSettingDTO,
} from '../models';
-export interface DeleteGroupRequest {
- groupCode: string;
-}
-
export interface DeleteUserRequest {
username: string;
}
-export interface DeleteUserSettingRequest {
- id: number;
-}
-
export interface GetUserRequest {
groupId?: string;
}
@@ -41,43 +31,21 @@ export interface GetUserByNameRequest {
username: string;
}
-export interface GetUserSettingByIdRequest {
- id: number;
-}
-
-export interface GetUserSettingByUserRequest {
- userName: string;
- configName: string;
-}
-
export interface NewUserRequest {
userDTO: UserDTO;
}
-export interface NewUserGroupRequest {
- userGroupDTO: UserGroupDTO;
-}
-
-export interface NewUserSettingsRequest {
- userSettingDTO: UserSettingDTO;
-}
-
export interface RetrievePermissionsByUsernameRequest {
username: string;
}
-export interface UpdateUserRequest {
+export interface UpdateProfileRequest {
userDTO: UserDTO;
- password?: boolean;
-}
-
-export interface UpdateUserGroupRequest {
- userGroupDTO: UserGroupDTO;
}
-export interface UpdateUserSettingsRequest {
- id: number;
- userSettingDTO: UserSettingDTO;
+export interface UpdateUserRequest {
+ username: string;
+ userDTO: UserDTO;
}
/**
@@ -87,58 +55,22 @@ export class UsersApi extends BaseAPI {
/**
*/
- deleteGroup({ groupCode }: DeleteGroupRequest): Observable
- deleteGroup({ groupCode }: DeleteGroupRequest, opts?: OperationOpts): Observable>
- deleteGroup({ groupCode }: DeleteGroupRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(groupCode, 'groupCode', 'deleteGroup');
-
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/users/groups/{group_code}'.replace('{group_code}', encodeURI(groupCode)),
- method: 'DELETE',
- headers,
- }, opts?.responseOpts);
- };
-
- /**
- */
- deleteUser({ username }: DeleteUserRequest): Observable
- deleteUser({ username }: DeleteUserRequest, opts?: OperationOpts): Observable>
- deleteUser({ username }: DeleteUserRequest, opts?: OperationOpts): Observable> {
+ deleteUser({ username }: DeleteUserRequest): Observable
+ deleteUser({ username }: DeleteUserRequest, opts?: OperationOpts): Observable>
+ deleteUser({ username }: DeleteUserRequest, opts?: OperationOpts): Observable> {
throwIfNullOrUndefined(username, 'username', 'deleteUser');
const headers: HttpHeaders = {
...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
};
- return this.request({
+ return this.request({
url: '/users/{username}'.replace('{username}', encodeURI(username)),
method: 'DELETE',
headers,
}, opts?.responseOpts);
};
- /**
- */
- deleteUserSetting({ id }: DeleteUserSettingRequest): Observable
- deleteUserSetting({ id }: DeleteUserSettingRequest, opts?: OperationOpts): Observable>
- deleteUserSetting({ id }: DeleteUserSettingRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(id, 'id', 'deleteUserSetting');
-
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/users/settings/{id}'.replace('{id}', encodeURI(id)),
- method: 'DELETE',
- headers,
- }, opts?.responseOpts);
- };
-
/**
*/
getUser({ groupId }: GetUserRequest): Observable>
@@ -181,78 +113,9 @@ export class UsersApi extends BaseAPI {
/**
*/
- getUserGroup(): Observable>
- getUserGroup(opts?: OperationOpts): Observable>>
- getUserGroup(opts?: OperationOpts): Observable | RawAjaxResponse>> {
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request>({
- url: '/users/groups',
- method: 'GET',
- headers,
- }, opts?.responseOpts);
- };
-
- /**
- */
- getUserSettingById({ id }: GetUserSettingByIdRequest): Observable
- getUserSettingById({ id }: GetUserSettingByIdRequest, opts?: OperationOpts): Observable>
- getUserSettingById({ id }: GetUserSettingByIdRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(id, 'id', 'getUserSettingById');
-
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/users/settings/{id}'.replace('{id}', encodeURI(id)),
- method: 'GET',
- headers,
- }, opts?.responseOpts);
- };
-
- /**
- */
- getUserSettingByUser({ userName, configName }: GetUserSettingByUserRequest): Observable
- getUserSettingByUser({ userName, configName }: GetUserSettingByUserRequest, opts?: OperationOpts): Observable>
- getUserSettingByUser({ userName, configName }: GetUserSettingByUserRequest, opts?: OperationOpts): Observable> {
- throwIfNullOrUndefined(userName, 'userName', 'getUserSettingByUser');
- throwIfNullOrUndefined(configName, 'configName', 'getUserSettingByUser');
-
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request({
- url: '/users/{userName}/settings/{configName}'.replace('{userName}', encodeURI(userName)).replace('{configName}', encodeURI(configName)),
- method: 'GET',
- headers,
- }, opts?.responseOpts);
- };
-
- /**
- */
- getUserSettings(): Observable>
- getUserSettings(opts?: OperationOpts): Observable>>
- getUserSettings(opts?: OperationOpts): Observable | RawAjaxResponse>> {
- const headers: HttpHeaders = {
- ...(this.configuration.username != null && this.configuration.password != null ? { Authorization: `Basic ${btoa(this.configuration.username + ':' + this.configuration.password)}` } : undefined),
- };
-
- return this.request>({
- url: '/users/settings',
- method: 'GET',
- headers,
- }, opts?.responseOpts);
- };
-
- /**
- */
- newUser({ userDTO }: NewUserRequest): Observable
- newUser({ userDTO }: NewUserRequest, opts?: OperationOpts): Observable>
- newUser({ userDTO }: NewUserRequest, opts?: OperationOpts): Observable> {
+ newUser({ userDTO }: NewUserRequest): Observable
+ newUser({ userDTO }: NewUserRequest, opts?: OperationOpts): Observable