feedcellar-web 0.4.2 → 0.4.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +2 -2
- data/NEWS.md +12 -0
- data/lib/feedcellar/web/app.rb +5 -5
- data/lib/feedcellar/web/version.rb +1 -1
- data/lib/feedcellar/web/views/_feeds.haml +5 -5
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 72eb3c01eb4f352febe8c82c72146d27c96aa08f
|
4
|
+
data.tar.gz: c7fcc7ff4d00f820bc24dcd39bca1c972b2ff6b5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ca2a990851a6aa433390ca3bd2eee0114155f28fa157a5c90c3fe3a82cfce22cf744554da2c5cd0c48b6bf3f8ae5a3472d924ff779aebd4ea471ca7905d58106
|
7
|
+
data.tar.gz: ef8ca6f8534be71600c42915a1933c4a080c7d568ad3e1a9b2a355a8a1781673d4993200230882d1e365267cd2ee26d5ce151b260914f53c2ebaf947d0459a4d
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
feedcellar-web (0.4.
|
4
|
+
feedcellar-web (0.4.3)
|
5
5
|
feedcellar (>= 0.6.0)
|
6
6
|
haml
|
7
7
|
kaminari
|
@@ -41,7 +41,7 @@ GEM
|
|
41
41
|
backports (3.6.8)
|
42
42
|
builder (3.2.2)
|
43
43
|
erubis (2.7.0)
|
44
|
-
feedcellar (0.7.
|
44
|
+
feedcellar (0.7.1)
|
45
45
|
parallel
|
46
46
|
rroonga (>= 5.0.0)
|
47
47
|
thor
|
data/NEWS.md
CHANGED
data/lib/feedcellar/web/app.rb
CHANGED
@@ -79,11 +79,11 @@ module Feedcellar
|
|
79
79
|
@feeds = search(words, options)
|
80
80
|
page = (params[:page] || 1).to_i
|
81
81
|
size = (params[:n_per_page] || 50).to_i
|
82
|
-
@
|
83
|
-
|
84
|
-
|
85
|
-
@
|
86
|
-
@
|
82
|
+
@paginated_feeds = @feeds.paginate([["date", :desc]],
|
83
|
+
page: page,
|
84
|
+
size: size)
|
85
|
+
@paginated_feeds.extend(PaginationProxy)
|
86
|
+
@paginated_feeds
|
87
87
|
end
|
88
88
|
|
89
89
|
def search(words, options={})
|
@@ -1,10 +1,10 @@
|
|
1
|
-
- if @
|
2
|
-
= paginate(@
|
1
|
+
- if @paginated_feeds.total_pages > 1
|
2
|
+
= paginate(@paginated_feeds)
|
3
3
|
%ul
|
4
|
-
- @
|
4
|
+
- @paginated_feeds.each do |feed|
|
5
5
|
%li
|
6
6
|
%p
|
7
7
|
= feed.date.strftime("%Y-%m-%d")
|
8
8
|
= link_to("#{feed.title} - #{feed.resource.title}", feed.link)
|
9
|
-
- if @
|
10
|
-
= paginate(@
|
9
|
+
- if @paginated_feeds.total_pages > 1
|
10
|
+
= paginate(@paginated_feeds)
|