Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/djk2/django-tables2-column-shifter
Simple extension for django-tables2 can dynamically show or hide columns. Using JQuery, Bootstrap 3, Bootstrap 4, Bootstrap 5 and Django >=1.9
https://github.com/djk2/django-tables2-column-shifter
bootstrap3 bootstrap4 bootstrap5 column django django-tables2
Last synced: 3 months ago
JSON representation
Simple extension for django-tables2 can dynamically show or hide columns. Using JQuery, Bootstrap 3, Bootstrap 4, Bootstrap 5 and Django >=1.9
- Host: GitHub
- URL: https://github.com/djk2/django-tables2-column-shifter
- Owner: djk2
- License: bsd-3-clause
- Created: 2016-11-21T07:57:17.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2023-05-03T09:00:44.000Z (over 1 year ago)
- Last Synced: 2024-09-30T09:01:21.239Z (3 months ago)
- Topics: bootstrap3, bootstrap4, bootstrap5, column, django, django-tables2
- Language: Python
- Homepage:
- Size: 1.24 MB
- Stars: 21
- Watchers: 3
- Forks: 8
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- Changelog: CHANGELOG.rst
- License: LICENSE
Awesome Lists containing this project
README
django-tables2-column-shifter
------------------------------.. image:: https://badge.fury.io/py/django-tables2-column-shifter.svg
:target: https://badge.fury.io/py/django-tables2-column-shifter
:alt: Latest PyPI version.. image:: https://github.com/djk2/django-tables2-column-shifter/actions/workflows/tests.yaml/badge.svg?branch=master
:target: https://github.com/djk2/django-tables2-column-shifter/actions/workflows/tests.yaml
:alt: GitHub Actions.. image:: https://requires.io/github/djk2/django-tables2-column-shifter/requirements.svg?branch=master
:target: https://requires.io/github/djk2/django-tables2-column-shifter/requirements/?branch=master
:alt: Requirements Status**About the app:**
Simple extension for django-tables2 to dynamically show or hide columns using jQuery.
Application uses web storage to store information whih columns are visible or not.
Using JQuery, Bootstrap3 or Bootstrap4 or Bootstrap5 and Django >=1.9.**Warning** : - Since version 2.0 my extension works by default with bootstrap4.
I highly recommend to inherit explicite from tables class indicate on bootstrap version.
I.e if you use in your project bootstrap in version 5.
Your `Table` classes should inherit from:
`django_tables2_column_shifter.tables.ColumnShiftTableBootstrap5`.Now you should inherit from:
* for bootstrap2 - ColumnShiftTableBootstrap2,
* for bootstrap3 - ColumnShiftTableBootstrap3,
* for bootstrap4 - ColumnShiftTableBootstrap4
* for bootstrap4 in responsive mode - ColumnShiftTableBootstrap4Responsive (only for django-tables2 >= 2.5)
* for bootstrap5 - ColumnShiftTableBootstrap5
* for bootstrap5 in responsive mode - ColumnShiftTableBootstrap5Responsive (only for django-tables2 >= 2.5.3)**Tested by tox with:**
* Python :3.6, 3.8, 3.10
* Django : 1.9, 1.10, 1.11, 2.0, 2.1, 3.0, 3.1, 3.2, 4.0, 4.2, master
* django-tables2 : 1.15, ..., 1.21, 2.0, 2.1, 2.2, 2.3, 2.5, master**Supported:**
* Django >= 1.9
* django-tables2 >= 1.15 (earlier version probably will work but wasn't tested)
* **bootstrap2** / **bootstrap3** / **bootstrap4** / **bootstrap4.1.3** / **bootstrap5 beta3**
* **JQuery****Supported locale:**
* EN - (English)
* PL - (Polish)
* EL - (Greek / Hellenic Republic)
* PT-BR - (Portuguese - Brazilian)More information about django-tables in here: https://django-tables2.readthedocs.io/
Screens:
----------.. image:: https://raw.githubusercontent.com/djk2/django-tables2-column-shifter/master/doc/static/scr1.png
:alt: screen 1.. image:: https://raw.githubusercontent.com/djk2/django-tables2-column-shifter/master/doc/static/scr2.png
:alt: screen 2How to Install:
---------------
1. Install django-tables2-column-shifter using::pip install django-tables2-column-shifter
or
pip install git+https://github.com/djk2/django-tables2-column-shifter
or
pip install django-tables2-column-shifter.zip
or
pip install django-tables2-column-shifter.tar.gz
2. Add ``django_tables2_column_shifter`` to your ``INSTALLED_APPS`` setting (after django_tables2) like this ::
INSTALLED_APPS = [
...,
'django_tables2',
'django_tables2_column_shifter',
...,
]3. Add path to js script: ``django_tables2_column_shifter.min.js`` in your base django template.
Script must be add after jquery.js and bootstrap.js and before
...
...
{# require #}
{# Popper is a dependency for bootstrap >= 4.0 #}