Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

OH2-389 | Provide operation context #477

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

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 43 additions & 34 deletions openapi/oh.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6219,14 +6219,14 @@ components:
description: lock
format: int32
example: 0
opd:
male:
type: boolean
female:
type: boolean
male:
type: boolean
pharmacy:
type: boolean
opd:
type: boolean
PatientDTO:
required:
- age
Expand Down Expand Up @@ -6779,6 +6779,7 @@ components:
- code
- description
- major
- opeFor
- type
type: object
properties:
Expand All @@ -6792,6 +6793,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
Expand Down Expand Up @@ -8306,16 +8315,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
rect:
Expand All @@ -8341,16 +8350,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
writeOnly: true
Expand Down Expand Up @@ -8466,16 +8475,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
rect:
Expand All @@ -8501,16 +8510,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
writeOnly: true
Expand Down Expand Up @@ -8555,16 +8564,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
clipRect:
Expand Down Expand Up @@ -8625,16 +8634,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
rect:
Expand All @@ -8660,16 +8669,16 @@ components:
height:
type: number
format: double
minX:
x:
type: number
format: double
minY:
"y":
type: number
format: double
x:
minX:
type: number
format: double
"y":
minY:
type: number
format: double
writeOnly: true
Expand Down Expand Up @@ -8753,13 +8762,13 @@ components:
smsInt:
type: integer
format: int32
medical:
type: integer
format: int32
sms:
type: boolean
notify:
type: boolean
medical:
type: integer
format: int32
TherapyDTO:
type: object
properties:
Expand Down
35 changes: 20 additions & 15 deletions src/main/java/org/isf/operation/dto/OperationDTO.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@

import jakarta.validation.constraints.NotNull;

import org.isf.operation.enums.OperationTarget;
import org.isf.opetype.dto.OperationTypeDTO;

import io.swagger.v3.oas.annotations.media.Schema;
Expand All @@ -41,6 +42,10 @@ public class OperationDTO {
@Schema(description = "The operation type")
private OperationTypeDTO type;

@NotNull
@Schema(description = "The operation context", example = "opd_admission")
private OperationTarget opeFor;

@NotNull
@Schema(description = "The operation major")
private Integer major;
Expand All @@ -59,33 +64,33 @@ public void setLock(int lock) {
public String getCode() {
return this.code;
}

public void setCode(String code) {
this.code = code;
}
public String getDescription() {
return this.description;
}

public void setDescription(String description) {
this.description = description;
}
public OperationTypeDTO getType() {
return this.type;
}

public void setType(OperationTypeDTO type) {
this.type = type;
}
public Integer getMajor() {
return this.major;
}

public void setCode(String code) {
this.code = code;
}

public void setDescription(String description) {
this.description = description;
public void setMajor(Integer major) {
this.major = major;
}

public void setType(OperationTypeDTO type) {
this.type = type;
public OperationTarget getOpeFor() {
return this.opeFor;
}

public void setMajor(Integer major) {
this.major = major;
public void setOpeFor(OperationTarget opeFor) {
this.opeFor = opeFor;
}

}
Loading