From 1f3cd9460195f08a4f651118a23e12c30281799b Mon Sep 17 00:00:00 2001 From: Adam Goldsmith Date: Mon, 22 Jan 2024 12:33:10 -0500 Subject: [PATCH] Add django-tables2 --- cmsmanage/settings/base.py | 4 ++++ pdm.lock | 14 +++++++++++++- pyproject.toml | 1 + 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/cmsmanage/settings/base.py b/cmsmanage/settings/base.py index 854bfca..f1ffae0 100644 --- a/cmsmanage/settings/base.py +++ b/cmsmanage/settings/base.py @@ -38,6 +38,7 @@ INSTALLED_APPS = [ "rest_framework.authtoken", "django_q", "django_nh3", + "django_tables2", "tasks.apps.TasksConfig", "rentals.apps.RentalsConfig", "membershipworks.apps.MembershipworksConfig", @@ -134,3 +135,6 @@ Q_CLUSTER = { }, }, } + +# Django-Tables2 +DJANGO_TABLES2_TEMPLATE = "django_tables2/bootstrap5-responsive.html" diff --git a/pdm.lock b/pdm.lock index a6b8951..21a0b0a 100644 --- a/pdm.lock +++ b/pdm.lock @@ -5,7 +5,7 @@ groups = ["default", "debug", "lint", "server", "typing", "dev"] strategy = ["cross_platform"] lock_version = "4.4.1" -content_hash = "sha256:73715d6c541091f09cb8dea4f2baba6b58b0972a615b44e6f85869f918fdb360" +content_hash = "sha256:b7ca762523a8ec97b04cc997ad7110cc9dcb77ffd1194d9d806a3a2784ccc62b" [[package]] name = "aiohttp" @@ -573,6 +573,18 @@ files = [ {file = "django_stubs-4.2.7-py3-none-any.whl", hash = "sha256:4cf4de258fa71adc6f2799e983091b9d46cfc67c6eebc68fe111218c9a62b3b8"}, ] +[[package]] +name = "django-tables2" +version = "2.7.0" +summary = "Table/data-grid framework for Django" +dependencies = [ + "Django>=3.2", +] +files = [ + {file = "django-tables2-2.7.0.tar.gz", hash = "sha256:4113fcc575eb438a12e83a4d4ea01452e4800d970e8bdd0e4122ac171af1900d"}, + {file = "django_tables2-2.7.0-py2.py3-none-any.whl", hash = "sha256:99e06d966ca8ac69fd74092eb45c79a280dd5ca0ccb81395d96261f62128e1af"}, +] + [[package]] name = "django-widget-tweaks" version = "1.5.0" diff --git a/pyproject.toml b/pyproject.toml index 22c5e93..16089e6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -29,6 +29,7 @@ dependencies = [ "openapi-client-udm~=1.0", "django-nh3~=0.1", "nh3~=0.2", + "django-tables2~=2.7", ] requires-python = ">=3.11"