Skip to content

Commit

Permalink
Refactor : pathvariable name 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
Kim-Dong-Jun99 committed Jan 18, 2024
1 parent f867270 commit c85e07d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions .http/Trip.http
Original file line number Diff line number Diff line change
Expand Up @@ -140,3 +140,12 @@ Content-Type: application/json
}
}

### test
POST https://ws.weplanplans.site/trips/3
Content-Type: application/json

{
"tourItemId": "1",
"visitDate": "2024-01-07"
}

Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public class TripController {

@PostMapping("/trips/{tripId}")
public ResponseEntity<TripItemAddResponse> addTripItemFromMainPage(
@PathVariable Long tripId,
@PathVariable(name = "tripId") Long tripId,
@RequestBody TripItemAddRequest tripItemAddRequest) {
return ResponseEntity.ok(tripService.addTripItemFromMainPage(tripId, tripItemAddRequest));
}
Expand Down

0 comments on commit c85e07d

Please sign in to comment.