• Home
  • Get started
  • Documentation
  • Source
  • License
  • About
reahl

reahl

Power tools for Python development

Gallery

  • Navigation
  • Form
  • Table
  • Chart
  • Payment
  • Other

Table Demo

  • ←First
  • «Prev
  • 6
  • 7
  • 8
  • 9
  • 10
  • »Next
  • →Last
My table caption
NameEmail
Friend (60)[email protected]
Friend (02)[email protected]
Friend (33)[email protected]
Friend (29)[email protected]
Friend (41)[email protected]
Friend (91)[email protected]
Friend (62)[email protected]
Friend (83)[email protected]
Friend (15)[email protected]
Friend (39)[email protected]
def create_table(self, view):

    # Each item in create_row_data() has a .name and .email_address, hence columns:

    columns = [StaticColumn(Field(label='Name'), 'name', sort_key=lambda i: i.name),
               StaticColumn(EmailField(label='Email'), 'email_address', sort_key=lambda i: i.email_address)]

    table_layout = TableLayout(striped=True, dark=True, border='cells', responsive=True, highlight_hovered=True)

    return DataTable(view,
                        columns,
                        self.create_row_data(),
                        caption_text='My table caption',
                        summary='Summary for screen reader',
                        table_layout=table_layout,
                        css_id='address_data')

Copyright © 2006-2025 Reahl Software Services (Pty) Ltd

Running on Reahl