Skip to content


Folders and files

Last commit message
Last commit date

Latest commit



6 Commits

Repository files navigation

Datatables example

This is an examples of a datatables implementation for a django project.


  • django 2.1.2
  • django-braces 1.13.0
  • django-filter 2.0.0
  • djangorestframework 3.9.0

Getting Started

First thing is to clone the project into the folder you want to work from. git clone

Then we need to create a virtual environment to install the dependencies. virtualenv env

Activate the virtual environment. For windows run: ./env/Scripts/activate

For linux: source env/bin/activate


Install the requirements. pip install -r requirements.txt

Setting up Django

CD into the myproject folder. cd myproject

Run migrate to set up the database. python migrate

Create a superuser so we can add rows to the database. python createsuperuser

Run the app. python runserver

Adding the datatables editor trial css and js files

Download the trial css and js files for Datatables Editor. You will select the option that says JS+CSS. Place the js/dataTables.editor.js and js/dataTables.editor.min.js files in the following folder. datatables_example/myproject/static/Editor-2018-01-03-1.7.0

The trial is good for 15 days. After that you will need to pay to use the editor funtionality. I added a .gitignore file inside myproject/static/Editor-2018-01-03-1.7.0. You will want to remove this when you add your files.

Using the app

Go into the admin to create a table so we have something to view.

Add a record to the invoices table under the DATATABLES_EXAMPLE app.

Now you can navigate to to view the table.

You can also view the record from the api.


This is an example I used to get datatables and datatables editor working with django 2.0






No releases published


No packages published