=== modified file 'src/docbkx/en/dhis2_user_man_web_api.xml' --- src/docbkx/en/dhis2_user_man_web_api.xml 2013-12-30 18:02:58 +0000 +++ src/docbkx/en/dhis2_user_man_web_api.xml 2013-12-31 00:25:11 +0000 @@ -1460,11 +1460,11 @@ success: setLinks }); }); - Now let us have a look at the various options for the Pivot table plug-in. Two properies are required: el and url (please refer to the table below). Now, if you want to refer to pre-defined tables already made inside DHIS it is sufficient to provide the additional id parameter. If you instead want to configure a pivot table dynamically you shoud omit the id parameter and provide data dimensions inside a columns array (chart series), a rows array (chart categories) and optionally a filters array instead. + Now let us have a look at the various options for the Pivot table plug-in. Two properies are required: el and url (please refer to the table below). Now, if you want to refer to pre-defined tables already made inside DHIS it is sufficient to provide the additional id parameter. If you instead want to configure a pivot table dynamically you shoud omit the id parameter and provide data dimensions inside a columns array, a rows array and optionally a filters array instead. A data dimension is defined as an object with a text property called dimension. This property accepts the following values: in (indicator), de (data element), ds (data set), dc (data element operand), pe (period), ou (organisation unit) or the id of any organisation unit group set or data element group set (can be found in the web api). The data dimension also has an array property called items which accepts objects with an id property. - To sum up, if you want to have e.g. "ANC 1 Coverage", "ANC 2 Coverage" and "ANC 3 Coverage" on the columns in your chart you can make the following columns config: + To sum up, if you want to have e.g. "ANC 1 Coverage", "ANC 2 Coverage" and "ANC 3 Coverage" on the columns in your table you can make the following columns config: columns: [{ dimension: "in", // "in", "de", "ds", "dc", "pe", "ou" or any dimension id @@ -1503,7 +1503,7 @@ string Yes - Identifier of the HTML element to render the chart in your web page + Identifier of the HTML element to render the table in your web page url @@ -1517,28 +1517,28 @@ string No - Identifier of a pre-defined chart (favorite) in DHIS + Identifier of a pre-defined table (favorite) in DHIS columns array Yes (if no id provided) - Data dimensions to include in chart as series + Data dimensions to include in table as columns rows array Yes (if no id provided) - Data dimensions to include in chart as category + Data dimensions to include in table as rows filter array No - Data dimensions to include in chart as filters + Data dimensions to include in table as filters showTotals @@ -1601,11 +1601,11 @@ We continue by adding one pre-defined and one dynamic pivot table to our HTML document. You can browse the list of available pivot tables using the Web API here: . function setLinks() { - PT.plugin.getTable({ url: base, el: 'chartA1', id: 'R0DVGvXDUNP' }); + PT.plugin.getTable({ url: base, el: 'tableA1', id: 'R0DVGvXDUNP' }); PT.plugin.getTable({ url: base, - el: 'chartB1', + el: 'tableB1', type: 'stackedBar', columns: [ {dimension: 'de', items: [{id: 'YtbsuPPo010'}, {id: 'l6byfWFUGaP'}]} @@ -1627,8 +1627,8 @@ }); }; Finally we include some div elements in the body section of the HTML document with the identifiers referred to in the plug-in Javascript. - <div id="tableA1" class="chart"></div> -<div id="tableB1" class="chart"></div> + <div id="tableA1"></div> +<div id="tableB1"></div> To see a complete working example please visit .
@@ -1854,8 +1854,8 @@ }); }; Finally we include some div elements in the body section of the HTML document with the identifiers referred to in the plug-in Javascript. - <div id="chartA1" class="chart"></div> -<div id="chartB1" class="chart"></div> + <div id="chartA1"></div> +<div id="chartB1"></div> To see a complete working example please visit .
@@ -1884,7 +1884,7 @@ success: setLinks }); });
- Now let us have a look at the various options for the GIS plug-in. Two properies are required: el and url (please refer to the table below). Now, if you want to refer to pre-defined charts already made inside DHIS it is sufficient to provide the additional id parameter. If you instead want to configure a chart dynamically you shoud omit the id parameter and provide mapViews (layers) instead. They should be configured with data dimensions inside a columns array (chart series), a rows array (chart categories) and optionally a filters array instead. + Now let us have a look at the various options for the GIS plug-in. Two properies are required: el and url (please refer to the table below). Now, if you want to refer to pre-defined maps already made in the DHIS 2 GIS it is sufficient to provide the additional id parameter. If you instead want to configure a map dynamically you shoud omit the id parameter and provide mapViews (layers) instead. They should be configured with data dimensions inside a columns array, a rows array and optionally a filters array instead. A data dimension is defined as an object with a text property called dimension. This property accepts the following values: in (indicator), de (data element), ds (data set), dc (data element operand), pe (period), ou (organisation unit) or the id of any organisation unit group set or data element group set (can be found in the web api). The data dimension also has an array property called items which accepts objects with an id property. @@ -1896,7 +1896,7 @@ }] - Visualizer chart plug-in configuration + GIS map plug-in configuration @@ -1923,7 +1923,7 @@ string Yes - Identifier of the HTML element to render the chart in your web page + Identifier of the HTML element to render the map in your web page url @@ -1937,7 +1937,7 @@ string No - Identifier of a pre-defined chart (favorite) in DHIS + Identifier of a pre-defined map (favorite) in DHIS baseLayer @@ -2106,8 +2106,8 @@ }); }; Finally we include some div elements in the body section of the HTML document with the identifiers referred to in the plug-in Javascript. - <div id="mapA1" class="chart"></div> -<div id="mapB1" class="chart"></div> + <div id="mapA1"></div> +<div id="mapB1"></div> To see a complete working example please visit . @@ -2137,10 +2137,10 @@ The first argument in the configuration is the id of the div element in which you want to render the carousel. The autoPlay configuration option refers to whether we want the carousel to start when the user loads the Web page. The interval option defines how many seconds each chart should be displayed. The showPlayButton defines whether we want to render a button for the user to start and stop the carousel. Finally we need to insert the div elements in the body of the HTML document: <div id="chartCarousel"> -<div id="chartA1" class="chart"></div> -<div id="chartA2" class="chart"></div> -<div id="chartA3" class="chart"></div> -<div id="chartA4" class="chart"></div> +<div id="chartA1"></div> +<div id="chartA2"></div> +<div id="chartA3"></div> +<div id="chartA4"></div> To see a complete working example please visit .