I now have a problem with JSReport .. It was assumed that I already have an API ... Now I want to associate it with my client side, which uses AngularJS.
If I use Postman, it will return the pdf file I want. But my problem is how to show that this is my page when I submit it using angularjs ..
I have a code like this:
controller
$scope.Print = function () { authService.print().then(function(result){ var _result = result; }); };
Service
var _print = function () { var data = { "template": { "shortid": "byQtwHLPQ" } }; return $http.post("http://192.168.8.87/api/report", data).then(function (result) { return result; }); }; authServiceFactory.print = _print;
Now I have this code and it does not work ... I assumed that it has no return, so I delete the return and just publish, but still it does not work, and even the PDF download did not work.
Anyone can help please ...
source share