Answer the question
In order to leave comments, you need to log in
How to form long query using angular for spring framework?
It is necessary: to form a long post, according to the type (address/street='Avenu'&house=5&flat=10)
Probably, I tried 10 ways.
tried like this:
$http.post("name_site/download_data", { street: "Avenu", house: 5} ).success(function (data) {
});
$http.post("name_site/download_data/" + "street=Avenu&house=5" ).success(function (data) {
});
@RequestMapping(value="/download_data", method=RequestMethod.POST)
public void downloadData(@RequestParam(value = "street") String street) throws IOException {
System.out.println(street);
}
@RequestMapping(value="/download_data/{data}", method=RequestMethod.POST)
public void downloadData(@PathVariable("street") String street) throws IOException {
System.out.println(street);
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question