The export action for the grid panel allows the user to save the attributes displayed in the grid to a number of different formats.
The formats supported by this tool are all provided by separate plugins, with HTML, CSV, Excel and Excel GeoPackage being the currently supplied plugins.
...
The following is an example of a basic export_html.css file that will change the background colours for the table.
Code Block |
---|
table { background-color: #beccdd; }
tr.even { background-color: #ffffff; }
tr.odd { background-color: #deecfd; }
|
...
name | description |
---|---|
text | The label to display to the user. |
iconCls | The id of an icon to display for the export item. |
format | The format to export the data in, this must correspond to one of the supported formats based on the installed plugins, currently 'html', 'excel', 'csv' or 'csvgpkg'. |
tooltip | This will change the tooltip display and should contain title and text properties. |
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<item action="com.cohga.client.actions.menuAction"> <text>Export</text> <iconCls>icon-database_go</iconCls> <item action="com.cohga.html.client.grid.exportAction"> <text>CSV<<text>HTML</text> <format>csv<<format>html</format> <iconCls>icon-page_white_world<code</iconCls> <tooltip> <title>CSV<<title>HTML</title> <text>Export the data to a comma separated text file<HTML page</text> </tooltip> </item> <item action="com.cohga.html.client.grid.exportAction"> <text>Excel</text> <format>excel</format> <iconCls>icon-page_white_excel</iconCls> <tooltip> <title>Excel</title> <text>Export the data to an Microsoft Excel spreadsheet</text> </tooltip> </item> <item action="com.cohga.html.client.grid.exportAction"> <text>CSV</text> <format>csv</format> <text>HTML<<iconCls>icon-page_white_wrench</iconCls> <tooltip> <title>CSV</title> <text>Export the data to a comma separated text file</text> </tooltip> </item> <item action="com.cohga.html.client.grid.exportAction"> <text>GeoPackage</text> <format>html<<format>gpkg</format> <iconCls>icon-page_white_world</iconCls> <tooltip> <title>HTML<<title>GeoPackage</title> <text>Export the data to a HTMLGeoPackage page<file</text> </tooltip> </item> </item> |
...