ravivarma434

Members
  • Content count

    7
  • Joined

  • Last visited

Posts posted by ravivarma434


  1. Hey,

     

    Yes, it can be done with the help of linked charts. Providing the docs link from earlier version for reference:

    http://docs.fusioncharts.com/charts/contents/Code/J2EE/JSP_Drill.html

     

    Hope this helps.

     

    Hi Swarnam,

     

    Thanks for the response. I gone through this link, which is not similar with my requirement.

    How this will best fit into the jsp code that I shared in. Please let me know.

     

    Regards,

    Varma


  2. Hi Team.

     

    We have generated two reports using JSPs. (Main & Sub report). 

     

    Both are JSP pages & report is generating perfectly. We want to link both the charts. 

    When click on pie chart in the first chart, it should navigate to second chart. Both used the web services internally with JSP useBean tags. Attached the Main JSP here for your reference. How to link the second JSP in this chart. 

     

    -------------------------------------------------------------------------------------------

    <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
    <%@ taglib uri="http://www.fusioncharts.com/jsp/core"prefix="fc"%>
    <%@page import="org.json.JSONObject"%>
    <%
    /* In this page the chart is finally displayed. */
    %>
    <c:set var="folderPath" value="../Chart/FusionCharts/" />
    <c:set var="jsPath" value="${folderPath}" scope="request" />
     
    <script src="${jsPath}fusioncharts.js"></script>
     
    <jsp:useBean id="product" class="com.aasc.model.DataBean">
    <c:set var="jsonArray" value="${product.jsonArray}"/>
    <c:set var="chartId" value="NormalCahrt"/>
    <c:set var="chartType" value="pie3d"/>
    <c:set var="caption" value="AA-Freight Audit Report"/>
    <c:set var="subCaption" value="UPS"/>
    <c:set var="paletteColors" value="#f2c500,#f45b00,#8e0000"/>
    <c:set var="width" value="500"/>
    <c:set var="height" value="300"/>
    <c:set var="exportEnabled" value="1"/>
    <c:set var="enableSmartLabels" value="0"/>
    <c:set var="showLegend" value="1"/>
    <c:set var="legendBorderAlpha" value="0"/>
    <c:set var="captionFontSize" value="20"/>
    <c:set var="subcaptionFontSize" value="16"/>
    <c:set var="useDataPlotColorForLabels" value="1"/>
     
    <%
    JSONObject chartObject = new JSONObject();
    chartObject.put("caption", pageContext.getAttribute("caption"));
    chartObject.put("subcaption", pageContext.getAttribute("subCaption"));
    chartObject.put("paletteColors", pageContext.getAttribute("paletteColors"));
    chartObject.put("exportEnabled", pageContext.getAttribute("exportEnabled"));
    chartObject.put("showLegend", pageContext.getAttribute("showLegend"));
    chartObject.put("legendBorderAlpha", pageContext.getAttribute("legendBorderAlpha"));
    chartObject.put("enableSmartLabels", pageContext.getAttribute("enableSmartLabels"));
    chartObject.put("captionFontSize", pageContext.getAttribute("captionFontSize"));
    chartObject.put("subcaptionFontSize", pageContext.getAttribute("subcaptionFontSize"));
    chartObject.put("useDataPlotColorForLabels", pageContext.getAttribute("useDataPlotColorForLabels"));
    //put all together in final JSON Object
    JSONObject jsonObject = new JSONObject();
    jsonObject.put("chart", chartObject);
    jsonObject.put("data", pageContext.getAttribute("jsonArray"));
    String json = jsonObject.toString();
    pageContext.setAttribute("json", json);
    %>
    <fc:render chartId="${chartId }" swfFilename="${chartType}" width="${width}"
    height="${height}" debugMode="false" registerWithJS="false"
    jsonData="${json}" />
    </jsp:useBean>
    <br />
    <br />
     
    -----------------------------------------------------------------

     

    Best Regards,

    Varma


  3. Hi Team,

     

    I followed the below link to generate the 2D/3D chart using Datasource with JSP. While running the jsp, getting blank screen.

     

    http://docs.fusioncharts.com/charts/contents/?Code/J2EE/JSP_BasicExample.html#_ga=1.230867802.418366346.1430721233

     

    I have removed the template tags for the rendering section. Can you please share the sample example code that works with the JDBC datasource.

    Initially tried with the Resful Webservices, but in one of the blog found that the Fusioncharts support is not available using services.

     

    Attached the JSP file & the error message while executing the JSP in the Tomcat Server.

     

    Best Regards,

    Ravi

    home-jsp.txt

    post-65908-0-58559800-1432727135_thumb.png


  4. Hi Team,

     

    I have a requirement where we want to renders the pie chart in the JSP page using Fusioncharts. The data should populate dynamically using the Restfiul webservices. The service response will come in JSON format & the database is Oracle.

     

    I have a working example, where able to show it from the json file in the html page, which is using the dummy data.

     

    Can you please share any working example with above requirement. Here am attaching the html page & json file that used in the server to render data.

    We have to fulfill the same requirement where the data should come from the service/database and populate dynamically.

     

    Regards,
    RaviauditReport_json.txt

    linkedParent.html