Skip to content

Commit

Permalink
Merge pull request #172 from La-Fresca/systemlog
Browse files Browse the repository at this point in the history
update
  • Loading branch information
Ravindu-Hasanka authored Jan 29, 2025
2 parents 2f632c5 + 47c464a commit 13bcd0a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ public class BranchRequestDTO {
@NotNull(message = "Contact Number cannot be null")
private String ContactNo;

@NotNull(message = "Longitude cannot be null")
// @NotNull(message = "Longitude cannot be null")
private Double Longitude;

@NotNull(message = "Longitude cannot be null")
// @NotNull(message = "Longitude cannot be null")
private Double Latitude;

@NotEmpty(message = "Branch Manager cannot be empty")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ public BranchRequestDTO addNewBranch(@Valid BranchRequestDTO branch) {
newBranch.setName(branch.getName());
newBranch.setStatus(BranchStatus.CLOSED);

newBranch.setLatitude(1.221);
newBranch.setLongitude(1.221);

User branchManager = userRepository.findById(branch.getBranchManager()).orElseThrow(() -> new ResourceNotFoundException("Branch manager not found with id " + branch.getBranchManager()));

newBranch.setDeleted(0);
Expand Down

0 comments on commit 13bcd0a

Please sign in to comment.