Table List

We’ll look at four separate components of a module to build a lookup table of records.

About the application

In this application, we are mainly looking into four components of our lookupList.py component module. These four components will help us display tables using the SQL data from our databases.

  • First, we have the ItemCell component, which returns a TableCell component with a Box component in it.

  • The ItemRowVu component then further wraps the ItemCell up inside the TableRow component.

  • Then, the ItemRows component checks if there are records to show. If any records need to be shown, ItemRows will also loop through the list of records and create an ItemRowVu component for each existing record.

  • Lastly, the ItemsList component will wrap and return the whole table along with the table header.

This is what the application looks like:

Note: To login use the username admin and password 123.

Get hands-on with 1400+ tech skills courses.