3 Replies Latest reply on Jul 17, 2012 2:18 PM by 446032

    ADF Mobile-PieGraph not passing Series and GroupAttributes to ClickListener

      JDeveloper Version:

      We are developing ADF Mobile Apps and using the ADF trinidad DVT PIE Graph component. The custom click listener method I have in place is not able to retrieve the series or group attributes when clicked. All of the Series and group attributes are being returned as NULL. Below is the code I have in place:

      <dvtt:pieGraph id="graph1" value="#{bindings.EroProductReportGrpByView1.graphModel}"
      subType="PIE" customLayout="CL_NONE"
      threeDEffect="true" inlineStyle="width:100%"
      <dvtt:background> <dvtt:specialEffects/> </dvtt:background>
      <dvtt:legendArea automaticPlacement="AP_NEVER" position="LAP_BOTTOM" rendered="false"/>
      <dvtt:slice labelPosition="LP_OUTSIDE_WITH_FEELER"/>
      <dvtt:sliceLabel textType="LD_TEXT_PERCENT"/>
      <dvtt:pieLabel rendered="true"/>
      <dvtt:graphTitle horizontalAlignment="CENTER"
      text=" "/>

      <graph IterBinding="EroProductReportGrpByView1Iterator" id="EroProductReportGrpByView1"
      xmlns="http://xmlns.oracle.com/adfm/dvt" type="PIE">
      <graphDataMap convert="false" leafOnly="true">
      <item value="Plant" label="Plant"/>
      <item value="OrderPrefix" label="OrderPrefix"/>
      <item value="PlantId" label="${adfBundle['com.dam.DAMReportsWebBundle'].PLANT_KEY}"/>

      public void pieGraphClicked(ClickEvent clickEvent) {       
      ComponentHandle handle = clickEvent.getComponentHandle();
      if (handle instanceof DataComponentHandle)
      DataComponentHandle dhandle = (DataComponentHandle)handle;
      // Get the value displayed in the series
      System.out.println("Value: " + dhandle.getValue(DataComponentHandle.UNFORMATTED_VALUE));
      // Get the series attributes
      Attributes [] seriesInfo = dhandle.getSeriesAttributes();
      Object component = dhandle.getComponent();
      System.out.println("Component is : "+component+" Data Component Handle Name : "+dhandle.getName());
      if(seriesInfo != null)
      for(Attributes attrs: seriesInfo)
      System.out.println("Series value: " + attrs.getValue(Attributes.LABEL_VALUE) + "Series name: " + attrs.getValue(Attributes.LABEL_ATTRIBUTE)+ " Series value id: " + attrs.getValue(Attributes.ID_VALUE));
      System.out.println("Series name id: " + attrs.getValue(Attributes.ID_ATTRIBUTE));
      // Get the group attributes
      Attributes [] groupInfo = dhandle.getGroupAttributes();
      if(groupInfo != null)
      for(Attributes attrs: groupInfo)
      System.out.println("Group value: " + attrs.getValue(Attributes.LABEL_VALUE));
      System.out.println("Group name: " + attrs.getValue(Attributes.LABEL_ATTRIBUTE));

      Any one have an idea where the problem can be?

      Edited by: vp**** on Jul 12, 2012 7:49 AM

      Edited by: vp**** on Jul 12, 2012 8:59 AM
        • 1. Re: ADF Mobile-PieGraph not passing Series and GroupAttributes to ClickListener
          Frank Nimphius-Oracle

          assuming you have verified this to work in a browser environment outside of mobile phone use, please file a bug with customer support

          • 2. Re: ADF Mobile-PieGraph not passing Series and GroupAttributes to ClickListener
            Hi Frank,

            We have not yet tested on Mobile browser. Currently we are testing on IE and Safari browsers and the click listener is not able to receive the Series and Group attributes of the PIE graph.

            One more question - Does the imageFormat of the Pie Graph needs to be explicitly specified as "FLASH" for the clickListener to work correctly?

            I even tried specifying in the jspx file and it is throwing error as below:

            Error: An unreported error occurred in Appc. No errors were reported, but the tool returned a failure result code: 1.
            Warning: <Jul 13, 2012 12:11:57 PM CDT> <Error> <J2EE> <BEA-160187> <weblogic.appc failed to compile your application. Recompile with the -verbose option for more details. Please see the error message(s) below.>
            Warning: There are 1 nested errors:
            Warning: imageFormat="FLASH">
            Warning: ^----^
            Warning:      at weblogic.servlet.jsp.jspc20.runBodyInternal(jspc20.java:458)
            Warning:      at weblogic.servlet.jsp.jspc20.runJspc(jspc20.java:227)
            Warning:      at weblogic.servlet.jsp.JspcInvoker.compile(JspcInvoker.java:236)
            Warning:      at weblogic.application.compiler.AppcUtils.compileWAR(AppcUtils.java:376)
            Warning:      at weblogic.application.compiler.WARModule.compile(WARModule.java:245)
            Warning:      at weblogic.application.compiler.flow.SingleModuleCompileFlow.proecessModule(SingleModuleCompileFlow.java:18)
            Warning:      at weblogic.application.compiler.flow.SingleModuleFlow.compile(SingleModuleFlow.java:36)
            Warning:      at weblogic.application.compiler.FlowDriver$FlowStateChange.next(FlowDriver.java:69)
            Warning:      at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
            Warning:      at weblogic.application.compiler.FlowDriver.nextState(FlowDriver.java:36)
            Warning:      at weblogic.application.compiler.FlowDriver.run(FlowDriver.java:26)
            Warning:      at weblogic.application.compiler.WARCompiler.compile(WARCompiler.java:29)
            Warning:      at weblogic.application.compiler.flow.AppCompilerFlow.compileInput(AppCompilerFlow.java:112)
            Warning:      at weblogic.application.compiler.flow.AppCompilerFlow.compile(AppCompilerFlow.java:37)
            Warning:      at weblogic.application.compiler.Appc.runBody(Appc.java:203)
            Warning:      at weblogic.utils.compiler.Tool.run(Tool.java:158)
            Warning:      at weblogic.utils.compiler.Tool.run(Tool.java:115)
            Warning:      at weblogic.application.compiler.Appc.main(Appc.java:262)
            Warning:      at weblogic.appc.main(appc.java:14)


            Edited by: vp**** on Jul 13, 2012 11:11 AM
            • 3. Re: ADF Mobile-PieGraph not passing Series and GroupAttributes to ClickListener
              Does anyone have an idea on why the click listener might not be working or is not passing the Series and Group attributes to the listener method. I have pasted the code above.

              Thank you