Skip to main content

HTML Grid renderer that helps generating HTML tables (or other structures) for data presentation, supports ordering, sorting columns, and is very customizable

Project description

webhelpers2_grid

HTML Grid renderer that helps generating HTML tables (or other structures) for data presentation, supports ordering, sorting columns, and is very customizable

DOCUMENTATION: https://webhelpers-grid2.readthedocs.io

DEMOS: http://ergo.github.io/webhelpers_grid2/gh-pages/ (static page)

BUG TRACKER: https://github.com/ergo/webhelpers_grid2/issues

Example Usage::

test_data = [
             {"group_name": "foo", "options": "lalala", "id":1},
             {"group_name": "foo2", "options": "lalala2", "id":2},
             {"group_name": "foo3", "options": "lalala3", "id":3},
             {"group_name": "foo4", "options": "lalala4", "id":4},
             ]

def options_td(col_num, i, item):
    u = url("/tickets/view", ticket_id=item["id"])
    a = link_to(item["options"], u)
    return HTML.td(a)

g = Grid(test_data, columns=["_numbered", "group_name", "options"])
g.labels["options"] = 'FOOBAAR'
g.column_formats["options"] = options_td
str(g)

webhelpers2_grid is BSD Licensed

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for webhelpers2_grid, version 0.9
Filename, size File type Python version Upload date Hashes
Filename, size webhelpers2_grid-0.9-py3-none-any.whl (5.5 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size webhelpers2_grid-0.9.tar.gz (5.4 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page