dry18813 2015-06-05 09:12
浏览 78
已采纳

Jasper报告 - 未找到资源

I am developing a jasper report in PHP I have tried embedded jasper library 0.9d -- PhpJasperLibrary-master After fixing part of the code in the library, It works normally but it cannot display table format which is very important for me to develop Jasper report so I give up in this method and build up an jasper server.

I have installed the PHP Client(v2.0) by composer and using the sample code in the following link

http://community.jaspersoft.com/wiki/php-client-sample-code http://community.jaspersoft.com/project/php-client/releases

I am not sure why there is a lot of bugs in the sample code like getjob(s) function and passing variable to class client.

Anyway, I fixed it and the server info can be called. In the last stage, I cannot run the report and the error message shown that the resource of my report not found.

Jaspersoft\Exception\RESTRequestException

Resource /20150604 not found. 

I could like you to help me and I hope I can release a prefect version after all parts done.Thanks

And the below is my report information.

I have put my report under the folder /reports and it can run in the jasper server

I have checked the URL that calling the report is like below

localhost:9090/jasperserver/rest_v2/reports/20150604.html

I have concern about the URL but I cant find any reference to it. So please support me to fix the problem. Thanks

additional: here is the code I call the report

$report = $c->reportService()->runReport('/20150604', 'html');
  • 写回答

1条回答 默认 最新

  • dreamy1992 2015-06-05 17:17
    关注

    Hmm the rest endpoint to "run" a report is js/rest_v2/?path to report?.html

    Unless your report is in the root of your organization, then you need a path.

    Check out this (line 20): https://github.com/jasonhuber/Jaspersoft_InputControlsFromCSV/blob/master/index.html#L20

    and check in the web services guide page 71...

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥30 求一段fortran代码用IVF编译运行的结果
  • ¥15 深度学习根据CNN网络模型,搭建BP模型并训练MNIST数据集
  • ¥15 lammps拉伸应力应变曲线分析
  • ¥15 C++ 头文件/宏冲突问题解决
  • ¥15 用comsol模拟大气湍流通过底部加热(温度不同)的腔体
  • ¥50 安卓adb backup备份子用户应用数据失败
  • ¥20 有人能用聚类分析帮我分析一下文本内容嘛
  • ¥15 请问Lammps做复合材料拉伸模拟,应力应变曲线问题
  • ¥30 python代码,帮调试,帮帮忙吧
  • ¥15 #MATLAB仿真#车辆换道路径规划