1
0
-1

Hi, 

 

I have a question, how can i retrieve image or file that already upload into server joget to use to display into jasper report.

    CommentAdd your comment...

    2 answers

    1.  
      2
      1
      0

      Hello, the first thing is that in the form through which you uploaded the image, verify the permissions, since, eventually, the person who consults the report may not be authenticated.

      On the other hand, for Jasper an image resource is usually a URL, so from the query that you have as data source you must assemble the URL of the image you want to show. In my case, in the query select I must add a field with this definition:

      http://localhost:8080/jw/web/client/app/lider_gestion/5/form/download/espec_bordado/' || id || '/' || c_image_field || '.' as URL1


      Where c_image_field is the name of the image field in the form. For some reason, besides the character '.' at the end of the result it is necessary to assemble the URL of the image.

      In the XML of the report, something like:

      <image>
      <reportElement x="0" y="20" width="360" height="150" uuid="10434016-fea6-494f-a4a0-e1943826f1fa"/>
      <imageExpression><![CDATA[$F{url1}]]></imageExpression>
      </image>
        CommentAdd your comment...
      1.  
        1
        0
        -1

        hello, hi, the url, how can i get the url?

          CommentAdd your comment...