Skip to content

Commit

Permalink
fix: naming
Browse files Browse the repository at this point in the history
  • Loading branch information
Angular2Guy committed Nov 19, 2023
1 parent 549d0f5 commit 821c78e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ public ResponseEntity<DocumentDto> getDocument(@PathVariable("id") Long id) {
.map(myDocument -> this.documentMapper.toDto(myDocument)).findFirst().orElse(null));
}

@GetMapping("/pdf/{id}")
public ResponseEntity<byte[]> getDocumentPdf(@PathVariable("id") Long id) {
@GetMapping("/content/{id}")
public ResponseEntity<byte[]> getDocumentContent(@PathVariable("id") Long id) {
var resultOpt = this.documentService.getDocumentById(id).stream()
.map(myDocument -> this.documentMapper.toDto(myDocument)).findFirst();
ResponseEntity<byte[]> result = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
<ul>
<li i18n="@@docSearchResultDocument">Result Document:</li>
<ul>
<li i18n="@@link">Link: <a mat-button href="/rest/document/pdf/{{!!searchResult && searchResult.documents[arrayIndex].id}}" target="_blank">{{!!searchResult && searchResult.documents[arrayIndex].documentName}}</a></li>
<li i18n="@@link">Link: <a mat-button href="/rest/document/content/{{!!searchResult && searchResult.documents[arrayIndex].id}}" target="_blank">{{!!searchResult && searchResult.documents[arrayIndex].documentName}}</a></li>
<li>{{searchResultStr}}</li>
</ul>
</ul>
Expand Down

0 comments on commit 821c78e

Please sign in to comment.