<docbook><section><title>OATDOCpivot</title><para> </para>
<title> pivot.js</title> pivot.js
<para>Advanced interactive Pivot table.</para>
<bridgehead class="http://www.w3.org/1999/xhtml:h2"> Objects</bridgehead>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> OAT.Pivot(div, chartDiv, filterDiv, headerRow, dataRows, headerRowIndexes, headerColIndexes, filterIndexes, dataColumnIndex, options)</bridgehead>
<para>Creates Pivot table.
 Arguments are explained below:</para>
<itemizedlist mark="bullet" spacing="compact"><listitem><computeroutput> <emphasis>div</emphasis></computeroutput> - the pivot table will be created as a child of this element (dom element) </listitem>
<listitem><computeroutput> <emphasis>chartDiv</emphasis></computeroutput> - pivot chart will be created as a child of this element (dom element) </listitem>
<listitem><computeroutput> <emphasis>filterDiv</emphasis></computeroutput> - &#39;paging&#39; selects will go here (dom element) </listitem>
<listitem><computeroutput> <emphasis>headerRow</emphasis></computeroutput> - array of headings for data <computeroutput>Rows</computeroutput> (array) </listitem>
<listitem><computeroutput> <emphasis>dataRows</emphasis></computeroutput> - array of rows.
 Every row (array) must have the same number of elements as <computeroutput>headerRow</computeroutput> (array of arrays) </listitem>
<listitem><computeroutput> <emphasis>headerRowIndexes</emphasis></computeroutput> - array, containing indexes of columns which should be drawn as vertical aggregate columns (array) </listitem>
<listitem><computeroutput> <emphasis>headerColIndexes</emphasis></computeroutput> - array, containing indexes of columns which should be drawn as horizontal aggregate columns (array) </listitem>
<listitem><computeroutput> <emphasis>filterIndexes</emphasis></computeroutput> - array, containing indexes of columns which should be drawn as paging aggregate columns (array) </listitem>
<listitem><computeroutput> <emphasis>dataColumnIndex</emphasis></computeroutput> - index of data column (number) </listitem>
<listitem><computeroutput> <emphasis>optObj</emphasis></computeroutput> - object containing following: </listitem>
<listitem><computeroutput> <emphasis>headingBefore</emphasis></computeroutput> - should we create headings before data? (bool) </listitem>
<listitem><computeroutput> <emphasis>headingAfter</emphasis></computeroutput> - should we create headings after data? (bool) </listitem>
<listitem><computeroutput> <emphasis>agg</emphasis></computeroutput> - constant, specifying appropriate aggregating function index (number) </listitem>
<listitem><computeroutput> <emphasis>aggTotals</emphasis> </computeroutput>- constant, specifying appropriate aggregating function index for sub-totals and totals (number) </listitem>
<listitem><computeroutput> <emphasis>showChart</emphasis></computeroutput> - show chart? (bool) </listitem>
<listitem><computeroutput> <emphasis>showRowChart</emphasis></computeroutput> - show row totals chart? (bool) </listitem>
<listitem><computeroutput> <emphasis>showColChart</emphasis></computeroutput> - show column totals chart? (bool) </listitem>
<listitem><computeroutput> <emphasis>type</emphasis></computeroutput> - one of <computeroutput>TYPE</computeroutput> _constants for number formatting (OAT.PivotData) </listitem>
<listitem><computeroutput> <emphasis>customType</emphasis></computeroutput> - formatting function for TYPE_CUSTOM </listitem>
<listitem><computeroutput> <emphasis>showEmpty</emphasis></computeroutput> - show columns &amp; rows with null values? (bool) </listitem>
<listitem><computeroutput> <emphasis>subtotals</emphasis></computeroutput> - show subtotals? (bool) </listitem>
<listitem><computeroutput> <emphasis>totals</emphasis></computeroutput> - show totals? (bool) </listitem>
<listitem><computeroutput> <emphasis>currencySymbol</emphasis></computeroutput> - when using <computeroutput>OAT.PivotData.TYPE_CURRENCY</computeroutput> as <computeroutput>customType</computeroutput> option.
 Default is $.</listitem>
</itemizedlist><bridgehead class="http://www.w3.org/1999/xhtml:h2"> Constants</bridgehead>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> OAT.PivotData.TYPE_</bridgehead>
<itemizedlist mark="bullet" spacing="compact"><listitem><computeroutput><emphasis>OAT.PivotData.TYPE_BASIC</emphasis></computeroutput> - 1234.56 </listitem>
<listitem><computeroutput><emphasis>OAT.PivotData.TYPE_PERCENT</emphasis></computeroutput> - 1234.56% </listitem>
<listitem><computeroutput><emphasis>OAT.PivotData.TYPE_SCI</emphasis></computeroutput>- 1234E+02 </listitem>
<listitem><computeroutput><emphasis>OAT.PivotData.TYPE_SPACE</emphasis></computeroutput>- 1 234.56 </listitem>
<listitem><computeroutput><emphasis>OAT.PivotData.TYPE_CUSTOM</emphasis></computeroutput> - function in <computeroutput>options.custom</computeroutput> Type </listitem>
<listitem><computeroutput><emphasis>OAT.PivotData.TYPE_COMMA</emphasis></computeroutput> - 1,234.56 </listitem>
<listitem><computeroutput><emphasis>OAT.PivotData.TYPE_CURRENCY</emphasis></computeroutput> (currency symbol in <computeroutput>options.currencySymbol.$</computeroutput> is default)</listitem>
</itemizedlist><bridgehead class="http://www.w3.org/1999/xhtml:h2"> CSS classes</bridgehead>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .pivot_table</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .h1</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .h2</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .odd</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .even</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .subtotal</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .total</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .gtotal</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .pivot_chart</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .pivot row_chart</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h3"> .pivot col_chart</bridgehead>
<para><ulink url="ToBeDone">ToBeDone</ulink></para>
<bridgehead class="http://www.w3.org/1999/xhtml:h2"> Example</bridgehead>
<programlisting>var pivot = new OAT.Pivot(div, chartDiv, filterDiv, headerRow, dataRows, 
                          headerRowIndexes, headerColIndexes, 
                          filterIndexes, dataColumnIndex, {}) 
</programlisting><para> <ulink url="CategoryDocumentation">CategoryDocumentation</ulink> <ulink url="CategoryOAT">CategoryOAT</ulink> <ulink url="CategoryOpenSource">CategoryOpenSource</ulink> <ulink url="CategoryToBeDone">CategoryToBeDone</ulink></para>
</section></docbook>