Skip to content

Commit

Permalink
OH2-310 Add missing supDeleted field in SupplierDto (#449)
Browse files Browse the repository at this point in the history
* Add missing field supDeleted

* Update openapi spec

* Fix import order
  • Loading branch information
mwithi committed Jun 6, 2024
1 parent 0dab980 commit 8c6327b
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
5 changes: 5 additions & 0 deletions openapi/oh.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6239,6 +6239,7 @@ components:
description: The value of the user
SupplierDTO:
required:
- supDeleted
- supId
- supName
type: object
Expand Down Expand Up @@ -6282,6 +6283,10 @@ components:
maxLength: 200
type: string
description: The supplier's notes
supDeleted:
type: string
description: "Flag record deleted, values are 'Y' OR 'N' "
example: 'N'
PricesOthersDTO:
required:
- code
Expand Down
16 changes: 14 additions & 2 deletions src/main/java/org/isf/supplier/dto/SupplierDTO.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
public class SupplierDTO {

@NotNull(message = "supplier's ID is required")
@Schema(description = "The supplier's ID", example = "111")
private Integer supId;

@NotNull(message = "supplier's name is required")
Expand All @@ -53,11 +52,15 @@ public class SupplierDTO {
@Schema(description = "The supplier's notes", example = "", maxLength = 200)
private String supNote;

@NotNull
@Schema(description = "Flag record deleted, values are 'Y' OR 'N' ", example = "N")
private String supDeleted;

public SupplierDTO() {
}

public SupplierDTO(Integer supId, String supName, String supAddress, String supTaxcode, String supPhone,
String supFax, String supEmail, String supNote) {
String supFax, String supEmail, String supNote) {
this.supId = supId;
this.supName = supName;
this.supAddress = supAddress;
Expand All @@ -66,6 +69,7 @@ public SupplierDTO(Integer supId, String supName, String supAddress, String supT
this.supFax = supFax;
this.supEmail = supEmail;
this.supNote = supNote;
this.supDeleted = "N";
}

public Integer getSupId() {
Expand Down Expand Up @@ -131,4 +135,12 @@ public void setSupEmail(String supEmail) {
public void setSupNote(String supNote) {
this.supNote = supNote;
}

public String getSupDeleted() {
return supDeleted;
}

public void setSupDeleted(String supDeleted) {
this.supDeleted = supDeleted;
}
}

0 comments on commit 8c6327b

Please sign in to comment.