Having trouble retrieving data from request.JSON passed through an Angular 2 HTTP POST method.
The Grails action is being triggered, but the request.JSON is consistently empty {} even when data is passed.
ANGULAR2: HTTP POST Method:
return this.http.post('http://localhost:8080/test/saveStatus', { status: 'Test' })
.map((response: Response) => response.json());
Grails Action:
class TestController {
def saveStatus() {
def request = request.JSON
/*
other codes...
*/
}
}