         @collection.fetch data: @data
         return @
 
+    # Refresh the pagination div at the bottom
+    refreshPagination: =>
+        from = (@data.page - 1) * @data.size + 1
+        to   = from + @collection.size() - 1
+        max  = @collection.count || -1
+        if max < 0
+            maxPage  = 1
+            pageFrom = @data.page
+            pageTo   = @data.page
+            max = ""
+        else
+            maxPage  = Math.ceil max / @data.size
+            pageFrom = @data.page
+            pageTo   = @data.page
+            max = " of " + max + " entries"
+        pages = ({number: i, active: (i == @data.page && "active") || ""} for i in _.range pageFrom, pageTo + 1)
+        $("#pagination-main", @$el).html @paginationTemplate
+            from: from
+            to: to
+            total: max
+            prevDisabled: if @data.page == 1 then "disabled" else ""
+            nextDisabled: if to == @collection.size then "disabled" else ""
+            pages: pages
+        return @
+
     # Render the collection in the tbody section of the table
     renderData: =>
         $("tbody", @$el).html @dataTemplate
             collection: @collection
             columns:    @columns
             empty:      @empty or "No records to show"
-        return @
+        @refreshPagination()
 
     # Go to the previous page in the collection
     prevPage: =>

            title:      @applyTemplate @titleTemplate,      @title
            search:     @applyTemplate @searchTemplate,     @search
            columns:    @applyTemplate @columnsTemplate,    @columns
            pagination: @applyTemplate @paginationTemplate, @pagination

        @filters = _.map(@filters, (filter, name) => @createFilter(name, filter))
        filtersDiv = $(".filters", @$el)

        <input type="text" class="search-query pull-right" placeholder="<%= model.detail || model %>" value="<%= data[model.query || "q"] || "" %>"></input>
    """
    paginationTemplate: _.template """
        <div class="row">
            <div class="span6">
                <div id="info">Showing <%= from %> to <%= to %><%= total %></div>
            </div>
            <div class="span6">
                <div class="pagination">
                    <ul>
                        <li class="pager-prev <%= prevDisabled %>"><a href="javascript:void(0)">← Previous</a></li>
                        <% _.each(pages, function (page) { %>
                            <li class="<%= page.active %>"><a href="javascript:void(0)"><%= page.number %></a></li>
                        <% }) %>
                        <li class="pager-next <%= nextDisabled %>"><a href="javascript:void(0)">Next → </a></li>
                    </ul>
                </div>
            </div>
        </div>
    """
    dataTemplate: _.template """
        <% _.each(collection.models, function (row) { %>
