1 Reply Latest reply: Jun 1, 2012 5:08 AM by Steven Davelaar-Oracle RSS

    how to design pivot table from jheadstart?

    857452
      hi
      i am new in ADF And jheadstart,
      i can add pivot table in adf and it runs correctly,
      but when i create it by jheadstart it looses it's functionality,
      i create it in jheadstart by changing vm file of a command button
      is it a good way???
      as i said when i create it by vm file it runs but i cant driil down or other functions

      thanx for help

      medi
        • 1. Re: how to design pivot table from jheadstart?
          Steven Davelaar-Oracle
          Medi,

          If you drag and drop a pivot table, it also creates a binding in the page definition.
          So, to not loose the correct behavior when regenerating, you need to move the pivot table tag to a custom template AND make sure the binding is also generated.

          Here is an example custom template that generates a graph with associated binding (same idea as pivot table):


          #macro (CUSTOM_BINDING)
          <graph IterBinding="Employees4Iterator" id="EmployeesView4"
          xmlns="http://xmlns.oracle.com/adfm/dvt" type="BAR_VERT_CLUST">
          <graphDataMap leafOnly="true">
          <series>
          <data>
          <item value="Salary"/>
          </data>
          </series>
          <groups>
          <item value="LastName"/>
          </groups>
          </graphDataMap>
          </graph>
          #end
          ${JHS.pageDefGenerator.addBinding($JHS.page,"EmployeesView4","#CUSTOM_BINDING()")}
          <dvt:barGraph id="barGraph1" shortDesc="Salary graph"
          value="#{bindings.EmployeesView4.graphModel}"
          subType="BAR_VERT_CLUST"
          seriesRolloverBehavior="RB_HIGHLIGHT"
          style="Confetti"
          animationOnDisplay="auto"
          threeDEffect="true">
          <dvt:background>
          <dvt:specialEffects/>
          </dvt:background>
          <dvt:graphPlotArea/>
          <dvt:seriesSet>
          <dvt:series/>
          </dvt:seriesSet>
          <dvt:o1Axis/>
          <dvt:y1Axis/>
          <dvt:legendArea automaticPlacement="AP_NEVER"/>
          </dvt:barGraph>


          For more info, see the Jheadstart Developers Guide, section 12.7.2 Preserving Bindings Added Using a Drag-And-Drop Action.

          Steven Davelaar,
          JHeadstart Team.