Jump to content
Changes to the Jaspersoft community edition download ×

jasper server REST_V2/reportExecutions attachmentsPrefix


rafkacz1

Recommended Posts

Hi,

I've a problem with html output export using rest_v2 service. 

In reportExecutionRequest structure i try to set attachmentsPrefix but with no result. 

Generated output html file still uses default attachment location :

<img src="/jasperserver/rest_v2/reportExecutions/105352832_1406503405410_76/exports/html/attachments/img_0_9_0" style="height: 300px" alt="" title="Meter Chart"/>

It makes viewing report output in offline mode impossible... 

Is there any way to change it? 

 

Regards 

Rafał

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

I use Jasper Server v 5.5.0. 

This is the JSON structure send with POST data to reportExecutions serive

{

  "$id": "1",

  "reportUnitUri": "/reports/test/testReport",

  "async": true,

  "freshData": true,

  "saveDataSnapshot": false,

  "outputFormat": "html",

  "interactive": false,

  "ignorePagination": false,

  "pages": null,

  "parameters": null,

  "attachmentsPrefix": "attachments2"

}

 

The additional "id" field is generated automatically by json serializer - but i think it is not a problem. 

 

Link to comment
Share on other sites

  • 3 months later...

Hi,

I have the same problem. When I set any value for the parameter attachmentsPrefix so server still returns the HTML attachments with the default path. The server response is below.

<reportExecution>   <exports>      <export>         <id>html;attachmentsPrefix=download?attachment=</id>         <status>ready</status>         <outputResource>            <contentType>text/html</contentType>         </outputResource>         <attachments>            <attachment>               <fileName>Times New Roman-cs_CZ</fileName>            </attachment>            <attachment>               <fileName>Times New Roman-cs_CZ.ttf</fileName>            </attachment>            <attachment>               <fileName>Times New Roman tučné-Bold-cs_CZ</fileName>            </attachment>            <attachment>               <fileName>Times New Roman tučné kurzíva-Bold-Italic-cs_CZ</fileName>            </attachment>            <attachment>               <contentType>image/jpeg</contentType>               <fileName>img_0_0_42</fileName>            </attachment>            <attachment>               <fileName>Times New Roman tučné-Bold-cs_CZ.ttf</fileName>            </attachment>            <attachment>               <fileName>Times New Roman tučné kurzíva-Bold-Italic-cs_CZ.ttf</fileName>            </attachment>            <attachment>               <fileName>Times New Roman kurzíva-Italic-cs_CZ.ttf</fileName>            </attachment>            <attachment>               <fileName>Times New Roman kurzíva-Italic-cs_CZ</fileName>            </attachment>         </attachments>      </export>   </exports>   <reportURI>/BBM/11_13/Default/Reports/RJ_EKODFA</reportURI>   <requestId>990192798_1415090568558_9</requestId>   <status>ready</status>   <totalPages>2</totalPages></reportExecution>[/code]

Do you have any idea? It looks like a bug.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...