diff options
author | David <bimmer44@users.noreply.github.com> | 2019-01-28 14:23:38 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-28 14:23:38 +0300 |
commit | 12ef17b881bf2236bbbc11e9d4daf9c5cb6df663 (patch) | |
tree | ba6fab81688281ebfde7502e73dc8459598eee3b | |
parent | 9250deaf6a64949451b44b376d546ed11b9a1684 (diff) | |
parent | 5a751b964e7f324fad872a16df8b2738632cd890 (diff) |
Merge pull request #5 from veeraya/master
Added support for pagination.
-rw-r--r-- | layouts/_default/list.html | 6 | ||||
-rw-r--r-- | layouts/index.html | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 536ada3..461fef5 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -9,7 +9,7 @@ </div> <div class="col-sm-7 col-sm-offset-4 col-md-6 col-md-offset-3 col-lg-5 col-lg-offset-3 content"> - {{ range first 10 .Data.Pages }} + {{ range .Paginator.Pages }} <div class="post"> <div class="post-heading"> @@ -22,6 +22,10 @@ </div> {{ end }} + <div class="text-center"> + {{ template "_internal/pagination.html" . }} + </div> + </div> <div class="col-sm-1 col-md-3 col-md-4"> </div> diff --git a/layouts/index.html b/layouts/index.html index 536ada3..461fef5 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -9,7 +9,7 @@ </div> <div class="col-sm-7 col-sm-offset-4 col-md-6 col-md-offset-3 col-lg-5 col-lg-offset-3 content"> - {{ range first 10 .Data.Pages }} + {{ range .Paginator.Pages }} <div class="post"> <div class="post-heading"> @@ -22,6 +22,10 @@ </div> {{ end }} + <div class="text-center"> + {{ template "_internal/pagination.html" . }} + </div> + </div> <div class="col-sm-1 col-md-3 col-md-4"> </div> |