Skip to content

Convert projects and builds pages to ToasterTable

Elliot Smith yocto-toaster 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest23 patches 1 replyIn review
  2. v122 patches 0 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/23toaster: toastergui: use ToasterTable for projects pagebitbake/lib/toaster/toastergui/tables.py bitbake/lib/toaster/toastergui/templates/projects-toastertable.html bitbake/lib/toaster/toastergui/urls.py+265 -30 replies
2/23toaster: move image file suffix list to modelbitbake/lib/toaster/orm/models.py bitbake/lib/toaster/toastergui/views.py+10 -60 replies
3/23toaster: check inferred file suffixes against list of known typesbitbake/lib/toaster/orm/models.py bitbake/lib/toaster/toastergui/tables.py bitbake/lib/toaster/toastergui/views.py+73 -410 replies
4/23toaster: toastergui: switch projects/ view to ToasterTablebitbake/lib/toaster/toastergui/tables.py bitbake/lib/toaster/toastergui/urls.py bitbake/lib/toaster/toastergui/views.py+23 -120 replies
5/23toaster: toastergui: use event delegates for hover help elementsbitbake/lib/toaster/toastergui/static/js/libtoaster.js+4 -20 replies
6/23toaster: toastergui: convert all builds page to ToasterTablebitbake/lib/toaster/orm/models.py bitbake/lib/toaster/toastergui/querysetfilter.py bitbake/lib/toaster/toastergui/tables.py +4 more+434 -800 replies
7/23toaster: toastergui: refactor ToasterTable filteringbitbake/lib/toaster/toastergui/querysetfilter.py bitbake/lib/toaster/toastergui/static/js/table.js bitbake/lib/toaster/toastergui/tablefilter.py +2 more+310 -1180 replies
8/23toaster: toastergui: switch off filter highlights when inactivebitbake/lib/toaster/toastergui/static/js/table.js+7 -10 replies
9/23toaster: toastergui: show recent builds on all builds pagebitbake/lib/toaster/toastergui/tables.py bitbake/lib/toaster/toastergui/templates/builds-toastertable.html bitbake/lib/toaster/toastergui/templates/mrb_section.html+23 -70 replies
10/23toaster: toastergui: implement date range filters for buildsbitbake/lib/toaster/toastergui/querysetfilter.py bitbake/lib/toaster/toastergui/static/js/table.js bitbake/lib/toaster/toastergui/tablefilter.py +3 more+330 -840 replies
11/23toaster: toastergui: implement "today" and "yesterday" filtersbitbake/lib/toaster/toastergui/querysetfilter.py bitbake/lib/toaster/toastergui/static/js/table.js bitbake/lib/toaster/toastergui/tablefilter.py +3 more+212 -840 replies
12/23toaster: toastergui: convert project builds page to ToasterTablebitbake/lib/toaster/toastergui/static/js/projecttopbar.js bitbake/lib/toaster/toastergui/static/js/table.js bitbake/lib/toaster/toastergui/tables.py +6 more+239 -490 replies
13/23toaster: toastergui: don't hide all elements with .col classbitbake/lib/toaster/toastergui/static/js/table.js+4 -40 replies
14/23toaster: toastergui: ensure filter_value updatesbitbake/lib/toaster/toastergui/static/js/table.js+18 -140 replies
15/23toaster: toastergui: streamline construction of filter objectsbitbake/lib/toaster/toastergui/querysetfilter.py bitbake/lib/toaster/toastergui/tablefilter.py bitbake/lib/toaster/toastergui/tables.py +1 more+32 -660 replies
16/23toaster: toastergui: serialise decimals correctlybitbake/lib/toaster/toastergui/views.py+3 -00 replies
17/23toaster: toastergui: set default visible and hideable columnsbitbake/lib/toaster/toastergui/tables.py bitbake/lib/toaster/toastergui/widgets.py+38 -30 replies
18/23toaster: toastergui: mute label for filter actions with no recordsbitbake/lib/toaster/toastergui/static/js/table.js+5 -20 replies
19/23toaster: toastergui: make "Apply" button state depend on filter rangebitbake/lib/toaster/toastergui/static/js/table.js bitbake/lib/toaster/toastergui/templates/toastertable-filter.html+59 -220 replies
20/23toaster: toastergui: fix error and warning counts for buildsbitbake/lib/toaster/contrib/django-aggregate-if-master/.gitignore bitbake/lib/toaster/contrib/django-aggregate-if-master/.travis.yml bitbake/lib/toaster/contrib/django-aggregate-if-master/LICENSE +7 more+27 -7020 replies
21/23toaster: toastergui: remove unused views and template codebitbake/lib/toaster/toastergui/templates/builds.html bitbake/lib/toaster/toastergui/templates/projects.html bitbake/lib/toaster/toastergui/views.py+0 -6470 replies
22/23toaster: tests: fix Django tests for new ToasterTable pagesbitbake/lib/toaster/toastergui/tests.py+180 -850 replies
23/23toaster: toastergui: code formatting and clean-upbitbake/lib/toaster/orm/models.py bitbake/lib/toaster/toastergui/tables.py bitbake/lib/toaster/toastergui/views.py+8 -130 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [review-request][PATCH 00/23][V2] Convert projects and builds pages to ToasterTable

V2:

Minor code formatting and fixes in line with code review by Ed Bartosh.

V1:

Many of the tables displayed by Toaster are backed by ToasterTable, but some of the key ones (like "projects", "all builds", and "project builds") aren't.

This makes it difficult to keep styling consistent between tables, as some are styled by making changes to ToasterTable, while others are styled by modifying Django templates.

Improve the consistency and maintainability of these tables by converting them to use ToasterTable.

Note that this patchset also reworks the ToasterTable API so that we can easily support different column filter types.

To test:

1. Open the "projects", "all builds" and "project builds" pages in Toaster.
2. Check that the column filtering and sorting works correctly, and projects/builds display correctly.

Changes since ea666f6 (toaster-next) are in
git://git.yoctoproject.org/poky-contrib, elliot/toaster/tables-8738
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=elliot/toaster/tables-8738

Related bug: https://bugzilla.yoctoproject.org/show_bug.cgi?id=8738

Elliot Smith (23):
toaster: toastergui: use ToasterTable for projects page
toaster: move image file suffix list to model
toaster: check inferred file suffixes against list of known types
toaster: toastergui: switch projects/ view to ToasterTable
toaster: toastergui: use event delegates for hover help elements
toaster: toastergui: convert all builds page to ToasterTable
toaster: toastergui: refactor ToasterTable filtering
toaster: toastergui: switch off filter highlights when inactive
toaster: toastergui: show recent builds on all builds page
toaster: toastergui: implement date range filters for builds
toaster: toastergui: implement "today" and "yesterday" filters
toaster: toastergui: convert project builds page to ToasterTable
toaster: toastergui: don't hide all elements with .col class
toaster: toastergui: ensure filter_value updates
toaster: toastergui: streamline construction of filter objects
toaster: toastergui: serialise decimals correctly
toaster: toastergui: set default visible and hideable columns
toaster: toastergui: mute label for filter actions with no records
toaster: toastergui: make "Apply" button state depend on filter range
toaster: toastergui: fix error and warning counts for builds
toaster: toastergui: remove unused views and template code
toaster: tests: fix Django tests for new ToasterTable pages
toaster: toastergui: code formatting and clean-up

 .../contrib/django-aggregate-if-master/.gitignore  |  10 -
 .../contrib/django-aggregate-if-master/.travis.yml |  50 --
 .../contrib/django-aggregate-if-master/LICENSE     |  21 -
 .../contrib/django-aggregate-if-master/README.rst  | 156 ----
 .../django-aggregate-if-master/aggregate_if.py     | 164 ----
 .../contrib/django-aggregate-if-master/runtests.py |  48 --
 .../contrib/django-aggregate-if-master/setup.py    |  33 -
 .../contrib/django-aggregate-if-master/tox.ini     | 198 -----
 bitbake/lib/toaster/orm/models.py                  | 103 ++-
 .../lib/toaster/toastergui/static/js/libtoaster.js |   6 +-
 .../toaster/toastergui/static/js/projecttopbar.js  |   9 +
 bitbake/lib/toaster/toastergui/static/js/table.js  | 325 ++++++--
 bitbake/lib/toaster/toastergui/tablefilter.py      | 292 +++++++
 bitbake/lib/toaster/toastergui/tables.py           | 858 +++++++++++++++++++--
 .../toastergui/templates/baseprojectpage.html      |   1 +
 .../toastergui/templates/builds-toastertable.html  |  48 ++
 .../lib/toaster/toastergui/templates/builds.html   | 125 ---
 .../toaster/toastergui/templates/mrb_section.html  |   4 +-
 .../templates/projectbuilds-toastertable.html      |  56 ++
 .../templates/projects-toastertable.html           |  36 +
 .../lib/toaster/toastergui/templates/projects.html |  92 ---
 .../toastergui/templates/toastertable-filter.html  |   4 +-
 .../toaster/toastergui/templates/toastertable.html |   7 +-
 bitbake/lib/toaster/toastergui/tests.py            | 265 +++++--
 bitbake/lib/toaster/toastergui/urls.py             |  14 +-
 bitbake/lib/toaster/toastergui/views.py            | 491 +-----------
 bitbake/lib/toaster/toastergui/widgets.py          | 112 +--
 bitbake/lib/toaster/toastermain/settings.py        |   9 -
 28 files changed, 1898 insertions(+), 1639 deletions(-)
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/.gitignore
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/.travis.yml
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/LICENSE
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/README.rst
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/aggregate_if.py
 delete mode 100755 bitbake/lib/toaster/contrib/django-aggregate-if-master/runtests.py
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/setup.py
 delete mode 100644 bitbake/lib/toaster/contrib/django-aggregate-if-master/tox.ini
 create mode 100644 bitbake/lib/toaster/toastergui/tablefilter.py
 create mode 100644 bitbake/lib/toaster/toastergui/templates/builds-toastertable.html
 delete mode 100644 bitbake/lib/toaster/toastergui/templates/builds.html
 create mode 100644 bitbake/lib/toaster/toastergui/templates/projectbuilds-toastertable.html
 create mode 100644 bitbake/lib/toaster/toastergui/templates/projects-toastertable.html
 delete mode 100644 bitbake/lib/toaster/toastergui/templates/projects.html

--
Elliot Smith
Software Engineer
Intel OTC

---------------------------------------------------------------------
Intel Corporation (UK) Limited
Registered No. 1134945 (England)
Registered Office: Pipers Way, Swindon SN3 1RJ
VAT No: 860 2173 47

This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.