$scope.getProjectDetails = function(theId){
$http.get('${pageContext.request.contextPath}/api/project', {params: {theId}})
.then(function(response){
$scope.project = response.data;
});
}
этот генерирует:
GET http://localhost:8080/editor-application/api/project?theId=1 404
а весенний отдых хочет:
http://localhost:8080/editor-application/api/project/1
Контроллер:
@GetMapping("/project/{theId}")
public Project getProject(@PathVariable int theId) {
return editorService.getProject(theId);
}
как заставить их говорить друг с другом?