From 52a9790a114c1dcce2e83d8e4d10b772c61517a0 Mon Sep 17 00:00:00 2001 From: SilverD3 Date: Thu, 17 Oct 2024 10:05:59 +0100 Subject: [PATCH 1/2] chore:update operation DTO --- api/oh.yaml | 303 +++++++++++++++++---------- src/generated/models/OperationDTO.ts | 17 ++ 2 files changed, 215 insertions(+), 105 deletions(-) diff --git a/api/oh.yaml b/api/oh.yaml index dced99431..487f209d5 100644 --- a/api/oh.yaml +++ b/api/oh.yaml @@ -398,6 +398,61 @@ paths: description: No Content security: - bearerAuth: [] + /usergroups/{group_code}/permissions: + put: + tags: + - User Groups + operationId: updateGroupPermissions + parameters: + - name: group_code + in: path + required: true + schema: + type: string + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPermissionsDTO' + required: true + responses: + "200": + description: OK + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/PermissionDTO' + security: + - bearerAuth: [] + patch: + tags: + - User Groups + operationId: replaceGroupPermissions + parameters: + - name: group_code + in: path + required: true + schema: + type: string + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupPermissionsDTO' + required: true + responses: + "200": + description: OK + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/PermissionDTO' + security: + - bearerAuth: [] /suppliers: get: tags: @@ -451,8 +506,8 @@ paths: $ref: '#/components/schemas/SupplierDTO' required: true responses: - "200": - description: OK + "201": + description: Created content: application/json: schema: @@ -3511,6 +3566,22 @@ paths: $ref: '#/components/schemas/SupplierDTO' security: - bearerAuth: [] + delete: + tags: + - Suppliers + operationId: deleteSupplier + parameters: + - name: id + in: path + required: true + schema: + type: integer + format: int32 + responses: + "204": + description: No Content + security: + - bearerAuth: [] /stockmovements: get: tags: @@ -6164,11 +6235,11 @@ components: description: lock format: int32 example: 0 - female: + opd: type: boolean male: type: boolean - opd: + female: type: boolean pharmacy: type: boolean @@ -6515,6 +6586,19 @@ components: type: string userGroup: $ref: '#/components/schemas/UserGroupDTO' + GroupPermissionsDTO: + type: object + properties: + permissions: + type: array + description: List of permissions' ids + example: + - 48 + - 24 + items: + type: integer + description: List of permissions' ids + format: int32 SupplierDTO: required: - supId @@ -6711,6 +6795,7 @@ components: - code - description - major + - opeFor - type type: object properties: @@ -6724,6 +6809,14 @@ components: description: The operation description type: $ref: '#/components/schemas/OperationTypeDTO' + opeFor: + type: string + description: The operation context + example: opd_admission + enum: + - opd_admission + - admission + - opd major: type: integer description: The operation major @@ -6835,11 +6928,11 @@ components: type: string description: "Flag record deleted, values are 'Y' OR 'N' " example: "N" + fhu: + type: string yprog: type: integer format: int32 - fhu: - type: string description: The admission AdmissionTypeDTO: required: @@ -7850,10 +7943,10 @@ components: $ref: '#/components/schemas/PatientProfilePhoto' patientConsensus: $ref: '#/components/schemas/PatientConsensus' - informations: - type: string searchString: type: string + informations: + type: string PatientConsensus: type: object properties: @@ -7949,6 +8042,8 @@ components: type: object family: type: string + plain: + type: boolean fontName: type: string transform: @@ -8003,8 +8098,6 @@ components: format: float transformed: type: boolean - plain: - type: boolean psname: type: string size2D: @@ -8034,6 +8127,8 @@ components: type: object family: type: string + plain: + type: boolean fontName: type: string transform: @@ -8088,8 +8183,6 @@ components: format: float transformed: type: boolean - plain: - type: boolean psname: type: string size2D: @@ -8099,6 +8192,9 @@ components: type: array items: type: object + height: + type: integer + format: int32 ascent: type: integer format: int32 @@ -8108,9 +8204,6 @@ components: leading: type: integer format: int32 - height: - type: integer - format: int32 maxDescent: type: integer format: int32 @@ -8220,34 +8313,34 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double rect: @@ -8255,53 +8348,53 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double writeOnly: true - maxX: + minX: type: number format: double - maxY: + minY: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double xormode: @@ -8380,34 +8473,34 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double rect: @@ -8415,53 +8508,53 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double writeOnly: true - maxX: + minX: type: number format: double - maxY: + minY: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double bounds2D: @@ -8469,34 +8562,34 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double clipRect: @@ -8539,34 +8632,34 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double rect: @@ -8574,53 +8667,53 @@ components: properties: empty: type: boolean - width: + "y": type: number format: double - height: + x: type: number format: double - "y": + minX: type: number format: double - x: + minY: type: number format: double - maxX: + height: type: number format: double - maxY: + width: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double writeOnly: true - maxX: + minX: type: number format: double - maxY: + minY: type: number format: double - centerX: + maxX: type: number format: double - centerY: + maxY: type: number format: double - minX: + centerX: type: number format: double - minY: + centerY: type: number format: double deprecated: true @@ -8685,10 +8778,10 @@ components: smsInt: type: integer format: int32 - sms: - type: boolean notify: type: boolean + sms: + type: boolean medical: type: integer format: int32 diff --git a/src/generated/models/OperationDTO.ts b/src/generated/models/OperationDTO.ts index 97492e784..2ca18514a 100644 --- a/src/generated/models/OperationDTO.ts +++ b/src/generated/models/OperationDTO.ts @@ -37,6 +37,12 @@ export interface OperationDTO { * @memberof OperationDTO */ type: OperationTypeDTO; + /** + * The operation context + * @type {string} + * @memberof OperationDTO + */ + opeFor: OperationDTOOpeForEnum; /** * The operation major * @type {number} @@ -50,3 +56,14 @@ export interface OperationDTO { */ lock?: number; } + +/** + * @export + * @enum {string} + */ +export enum OperationDTOOpeForEnum { + OpdAdmission = 'opd_admission', + Admission = 'admission', + Opd = 'opd' +} + From 8555a5d74e2aefa77713e3f7d072e540e3cec114 Mon Sep 17 00:00:00 2001 From: SilverD3 Date: Thu, 17 Oct 2024 11:09:09 +0100 Subject: [PATCH 2/2] chore:OH2-390 | add context in operation --- .../operationForm/OperationForm.tsx | 57 ++- .../admin/operations/operationForm/consts.ts | 8 +- .../operations/operationForm/styles.scss | 4 +- .../admin/operations/operationForm/types.ts | 7 +- .../operationTable/OperationTable.tsx | 24 +- .../accessories/autocompleteField/styles.scss | 2 +- src/generated/runtime.ts | 337 ++++++++---------- src/resources/i18n/en.json | 8 +- 8 files changed, 224 insertions(+), 223 deletions(-) diff --git a/src/components/accessories/admin/operations/operationForm/OperationForm.tsx b/src/components/accessories/admin/operations/operationForm/OperationForm.tsx index c25b3c694..c132eeac9 100644 --- a/src/components/accessories/admin/operations/operationForm/OperationForm.tsx +++ b/src/components/accessories/admin/operations/operationForm/OperationForm.tsx @@ -1,4 +1,5 @@ import { useFormik } from "formik"; +import { OperationDTOOpeForEnum } from "generated"; import { useAppDispatch, useAppSelector } from "libraries/hooks/redux"; import { get, has } from "lodash"; import React, { @@ -63,6 +64,15 @@ const OperationForm: FC = ({ [operationsTypeState.data] ); + const operationContextOptions = () => { + return Object.values(OperationDTOOpeForEnum).map((type) => { + return { + label: t(`operation.contextOptions.${type}`), + value: type, + }; + }); + }; + const errorMessage = useMemo( () => (creationMode @@ -150,19 +160,6 @@ const OperationForm: FC = ({
-
- -
= ({ />
+ +
+
+ +
+
= ({ disabled={isLoading} />
-
- -
-
+
+ +
+
= ({ })) ?? [] ); - const header = ["code", "type", "description", "class"]; + const operationContextOptions = () => { + return Object.values(OperationDTOOpeForEnum).map((type) => { + return { + label: t(`operation.contextOptions.${type}`), + value: type, + }; + }); + }; + + const header = ["code", "type", "description", "class", "opeFor"]; const label = { code: t("operation.code"), type: t("operation.type"), description: t("operation.description"), class: t("operation.class"), + opeFor: t("operation.opeFor"), }; - const order = ["code", "type", "description", "class"]; + + const order = ["code", "type", "description", "class", "opeFor"]; const filters: TFilterField[] = [ { key: "description", label: t("operation.description"), type: "text" }, { @@ -61,6 +72,12 @@ export const OperationTable: FunctionComponent = ({ { label: t("operation.classes.major"), value: "1" }, ], }, + { + key: "opeFor", + label: t("operation.opeFor"), + type: "select", + options: operationContextOptions(), + }, ]; const { data, status, error } = useAppSelector( @@ -89,6 +106,7 @@ export const OperationTable: FunctionComponent = ({ code: item.code ?? "", type: item.type?.description ?? "", description: item.description ?? "", + opeFor: t(`operation.contextOptions.${item.opeFor}`), class: item.major === 0 ? t("operation.classes.minor") diff --git a/src/components/accessories/autocompleteField/styles.scss b/src/components/accessories/autocompleteField/styles.scss index 13eb48326..69441e220 100644 --- a/src/components/accessories/autocompleteField/styles.scss +++ b/src/components/accessories/autocompleteField/styles.scss @@ -18,7 +18,7 @@ } .MuiAutocomplete-inputRoot[class*="MuiOutlinedInput-root"] { - padding: 10px !important; + padding: 12px !important; } } diff --git a/src/generated/runtime.ts b/src/generated/runtime.ts index 3dbdfa869..e3fee4f86 100644 --- a/src/generated/runtime.ts +++ b/src/generated/runtime.ts @@ -1,161 +1,134 @@ // tslint:disable /** - * OH 2.0 Api Documentation - * OH 2.0 Api Documentation - * - * The version of the OpenAPI document: 1.0 + * 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, of, Subscriber } from "rxjs"; -import { ajax, AjaxRequest, AjaxResponse } from "rxjs/ajax"; -import { map, concatMap } from "rxjs/operators"; +import { Observable, of, Subscriber } from 'rxjs'; +import { ajax, AjaxRequest, AjaxResponse } from 'rxjs/ajax'; +import { map, concatMap } from 'rxjs/operators'; -export const BASE_PATH = "https://oh2.open-hospital.org".replace(/\/+$/, ""); +export const BASE_PATH = 'http://localhost:8080'.replace(/\/+$/, ''); export interface ConfigurationParameters { - basePath?: string; // override base path - middleware?: Middleware[]; // middleware to apply before/after rxjs requests - username?: string; // parameter for basic security - password?: string; // parameter for basic security - apiKey?: string | ((name: string) => string); // parameter for apiKey security - accessToken?: string | ((name?: string, scopes?: string[]) => string); // parameter for oauth2 security + basePath?: string; // override base path + middleware?: Middleware[]; // middleware to apply before/after rxjs requests + username?: string; // parameter for basic security + password?: string; // parameter for basic security + apiKey?: string | ((name: string) => string); // parameter for apiKey security + accessToken?: string | ((name?: string, scopes?: string[]) => string); // parameter for oauth2 security } export class Configuration { - constructor(private configuration: ConfigurationParameters = {}) {} - - get basePath(): string { - return this.configuration.basePath ?? BASE_PATH; - } - - get middleware(): Middleware[] { - return this.configuration.middleware ?? []; - } - - get username(): string | undefined { - return this.configuration.username; - } - - get password(): string | undefined { - return this.configuration.password; - } - - get apiKey(): ((name: string) => string) | undefined { - const { apiKey } = this.configuration; - return apiKey - ? typeof apiKey === "string" - ? () => apiKey - : apiKey - : undefined; - } - - get accessToken(): ((name: string, scopes?: string[]) => string) | undefined { - const { accessToken } = this.configuration; - return accessToken - ? typeof accessToken === "string" - ? () => accessToken - : accessToken - : undefined; - } + constructor(private configuration: ConfigurationParameters = {}) {} + + get basePath(): string { + return this.configuration.basePath ?? BASE_PATH; + } + + get middleware(): Middleware[] { + return this.configuration.middleware ?? []; + } + + get username(): string | undefined { + return this.configuration.username; + } + + get password(): string | undefined { + return this.configuration.password; + } + + get apiKey(): ((name: string) => string) | undefined { + const { apiKey } = this.configuration; + return apiKey ? (typeof apiKey === 'string' ? () => apiKey : apiKey) : undefined; + } + + get accessToken(): ((name: string, scopes?: string[]) => string) | undefined { + const { accessToken } = this.configuration; + return accessToken ? (typeof accessToken === 'string' ? () => accessToken : accessToken) : undefined; + } } /** * This is the base class for all generated API classes. */ export class BaseAPI { - private middleware: Middleware[] = []; - - constructor(protected configuration = new Configuration()) { - this.middleware = configuration.middleware; - } - - withMiddleware = (middlewares: Middleware[]): this => { - const next = this.clone(); - next.middleware = next.middleware.concat(middlewares); - return next; - }; - - withPreMiddleware = (preMiddlewares: Array) => - this.withMiddleware(preMiddlewares.map((pre) => ({ pre }))); - - withPostMiddleware = (postMiddlewares: Array) => - this.withMiddleware(postMiddlewares.map((post) => ({ post }))); - - protected request(requestOpts: RequestOpts): Observable; - protected request( - requestOpts: RequestOpts, - responseOpts?: ResponseOpts - ): Observable>; - protected request( - requestOpts: RequestOpts, - responseOpts?: ResponseOpts - ): Observable> { - return this.rxjsRequest(this.createRequestArgs(requestOpts)).pipe( - map((res) => { - const { status, response } = res; - if (status >= 200 && status < 300) { - return responseOpts?.respone === "raw" ? res : response; - } - throw res; - }) - ); - } - - private createRequestArgs = ({ - url: baseUrl, - query, - method, - headers, - body, - responseType, - }: RequestOpts): RequestArgs => { - // only add the queryString to the URL if there are query parameters. - // this is done to avoid urls ending with a '?' character which buggy webservers - // do not handle correctly sometimes. - const url = `${this.configuration.basePath}${baseUrl}${ - query && Object.keys(query).length ? `?${queryString(query)}` : "" - }`; - - return { - url, - method, - headers, - body: body instanceof FormData ? body : JSON.stringify(body), - responseType: responseType ?? "json", + private middleware: Middleware[] = []; + + constructor(protected configuration = new Configuration()) { + this.middleware = configuration.middleware; + } + + withMiddleware = (middlewares: Middleware[]): this => { + const next = this.clone(); + next.middleware = next.middleware.concat(middlewares); + return next; }; - }; - - private rxjsRequest = (params: RequestArgs): Observable => - of(params).pipe( - map((request) => { - this.middleware - .filter((item) => item.pre) - .forEach((mw) => (request = mw.pre!(request))); - return request; - }), - concatMap((args) => - ajax(args).pipe( - map((response) => { - this.middleware - .filter((item) => item.post) - .forEach((mw) => (response = mw.post!(response))); - return response; - }) - ) - ) - ); - - /** - * Create a shallow clone of `this` by constructing a new instance - * and then shallow cloning data members. - */ - private clone = (): this => - Object.assign(Object.create(Object.getPrototypeOf(this)), this); + + withPreMiddleware = (preMiddlewares: Array) => + this.withMiddleware(preMiddlewares.map((pre) => ({ pre }))); + + withPostMiddleware = (postMiddlewares: Array) => + this.withMiddleware(postMiddlewares.map((post) => ({ post }))); + + protected request(requestOpts: RequestOpts): Observable + protected request(requestOpts: RequestOpts, responseOpts?: ResponseOpts): Observable> + protected request(requestOpts: RequestOpts, responseOpts?: ResponseOpts): Observable> { + return this.rxjsRequest(this.createRequestArgs(requestOpts)).pipe( + map((res) => { + const { status, response } = res; + if (status >= 200 && status < 300) { + return responseOpts?.respone === 'raw' ? res : response; + } + throw res; + }) + ); + } + + private createRequestArgs = ({ url: baseUrl, query, method, headers, body, responseType }: RequestOpts): RequestArgs => { + // only add the queryString to the URL if there are query parameters. + // this is done to avoid urls ending with a '?' character which buggy webservers + // do not handle correctly sometimes. + const url = `${this.configuration.basePath}${baseUrl}${query && Object.keys(query).length ? `?${queryString(query)}`: ''}`; + + return { + url, + method, + headers, + body: body instanceof FormData ? body : JSON.stringify(body), + responseType: responseType ?? 'json', + }; + } + + private rxjsRequest = (params: RequestArgs): Observable => + of(params).pipe( + map((request) => { + this.middleware.filter((item) => item.pre).forEach((mw) => (request = mw.pre!(request))); + return request; + }), + concatMap((args) => + ajax(args).pipe( + map((response) => { + this.middleware.filter((item) => item.post).forEach((mw) => (response = mw.post!(response))); + return response; + }) + ) + ) + ); + + /** + * Create a shallow clone of `this` by constructing a new instance + * and then shallow cloning data members. + */ + private clone = (): this => + Object.assign(Object.create(Object.getPrototypeOf(this)), this); } /** @@ -163,68 +136,52 @@ export class BaseAPI { * export for not being a breaking change */ export class RequiredError extends Error { - name: "RequiredError" = "RequiredError"; + name: 'RequiredError' = 'RequiredError'; } export const COLLECTION_FORMATS = { - csv: ",", - ssv: " ", - tsv: "\t", - pipes: "|", + csv: ',', + ssv: ' ', + tsv: '\t', + pipes: '|', }; export type Json = any; -export type HttpMethod = - | "GET" - | "POST" - | "PUT" - | "PATCH" - | "DELETE" - | "OPTIONS" - | "HEAD"; +export type HttpMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD'; export type HttpHeaders = { [key: string]: string }; -export type HttpQuery = Partial<{ - [key: string]: - | string - | number - | null - | boolean - | Array; -}>; // partial is needed for strict mode +export type HttpQuery = Partial<{ [key: string]: string | number | null | boolean | Array }>; // partial is needed for strict mode export type HttpBody = Json | FormData; export interface RequestOpts extends AjaxRequest { - query?: HttpQuery; // additional prop - // the following props have improved types over AjaxRequest - method: HttpMethod; - headers?: HttpHeaders; - body?: HttpBody; - responseType?: "json" | "blob" | "arraybuffer" | "text"; + query?: HttpQuery; // additional prop + // the following props have improved types over AjaxRequest + method: HttpMethod; + headers?: HttpHeaders; + body?: HttpBody; + responseType?: 'json' | 'blob' | 'arraybuffer' | 'text'; } export interface ResponseOpts { - respone?: "raw"; + respone?: 'raw'; } export interface OperationOpts { - responseOpts?: ResponseOpts; + responseOpts?: ResponseOpts; } -// AjaxResponse with typed response +// AjaxResponse with typed response export interface RawAjaxResponse extends AjaxResponse { - response: T; + response: T; } export const encodeURI = (value: any) => encodeURIComponent(`${value}`); -const queryString = (params: HttpQuery): string => - Object.entries(params) - .map(([key, value]) => - value instanceof Array - ? value.map((val) => `${encodeURI(key)}=${encodeURI(val)}`).join("&") +const queryString = (params: HttpQuery): string => Object.entries(params) + .map(([key, value]) => value instanceof Array + ? value.map((val) => `${encodeURI(key)}=${encodeURI(val)}`).join('&') : `${encodeURI(key)}=${encodeURI(value)}` ) - .join("&"); + .join('&'); // alias fallback for not being a breaking change export const querystring = queryString; @@ -232,28 +189,16 @@ export const querystring = queryString; /** * @deprecated */ -export const throwIfRequired = ( - params: { [key: string]: any }, - key: string, - nickname: string -) => { - if (!params || params[key] == null) { - throw new RequiredError( - `Required parameter ${key} was null or undefined when calling ${nickname}.` - ); - } +export const throwIfRequired = (params: {[key: string]: any}, key: string, nickname: string) => { + if (!params || params[key] == null) { + throw new RequiredError(`Required parameter ${key} was null or undefined when calling ${nickname}.`); + } }; -export const throwIfNullOrUndefined = ( - value: any, - paramName: string, - nickname: string -) => { - if (value == null) { - throw new Error( - `Parameter "${paramName}" was null or undefined when calling "${nickname}".` - ); - } +export const throwIfNullOrUndefined = (value: any, paramName: string, nickname: string) => { + if (value == null) { + throw new Error(`Parameter "${paramName}" was null or undefined when calling "${nickname}".`); + } }; // alias for easier importing @@ -261,6 +206,6 @@ export interface RequestArgs extends AjaxRequest {} export interface ResponseArgs extends AjaxResponse {} export interface Middleware { - pre?(request: RequestArgs): RequestArgs; - post?(response: ResponseArgs): ResponseArgs; -} \ No newline at end of file + pre?(request: RequestArgs): RequestArgs; + post?(response: ResponseArgs): ResponseArgs; +} diff --git a/src/resources/i18n/en.json b/src/resources/i18n/en.json index f743ad2aa..e15c36beb 100644 --- a/src/resources/i18n/en.json +++ b/src/resources/i18n/en.json @@ -443,7 +443,13 @@ "saveOperation": "Save Operation", "createSuccess": "Operation has been created successfully!", "updateSuccess": "Operation {{code}} has been updated successfully!", - "deleteSuccess": "Operation {{code}} has been deleted successfully!" + "deleteSuccess": "Operation {{code}} has been deleted successfully!", + "opeFor": "Context", + "contextOptions": { + "opd_admission": "OPD/Admission", + "admission": "Admission", + "opd": "OPD" + } }, "common": { "ok": "OK",