Django + Tastypie + Backbone.js = TastyBackbonePie

Plugin jQuery para criar tabelas de dados ajax usando um backend de api django-tastypie. Inclui uma maneira de paginar, classificar e filtrar tabelas facilmente.

Cenário

https://github.com/sspross/tastybackbonepie

var book_table_settings = {
uid
: 'book_table',
root_url
: '/api/v1/book/',
fields
: [
{
'key': 'id',
'label': '#',
},
{
'key': 'name',
'label': 'Name',
'order_by': 'name',
},
{
'key': 'added',
'label': 'Added at',
'order_by': 'added',
},
{
'key': 'read',
'label': 'Read',
'template': '<% if (entry.get(\'read\') == true) { %>x<% } %>',
'order_by': 'read',
},
],
additional_html_fields
: [
'<a class="btn btn-mini" href="#" data-id="<%= entry.get(\'id\') %>"><i class="icon-trash"></i></a>',
]
};

var book_table = $('#book-table').renderTastyBackbonePieTable(book_table_settings);