comfy_archive 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 73980cbf5c9dfe489601266553d0ab4a16b369758e8f379d60861ea7f0e9cbdf
|
4
|
+
data.tar.gz: 6f6b3c14ba6754b8cb01f50a3eabf2149fcad1427c960f63e9db66d4a03797a5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c635e6a7f305a8b9b4915c7f7051fe2c2ef3883ee0d66ec09c13761eb265da3fe33a89d95757796c8b0e3ba26f85886c713c2356543f973a9f7463a169e642a6
|
7
|
+
data.tar.gz: 3a691a6cf2f79254787dd0dcf3284fd1d4ac2ef52285ea5b5660d96712d096175a45b6b8df9772e7cedd9684c2527b5e2f5de6b852328a884edc6eaef1feab9c
|
data/README.md
CHANGED
@@ -2,6 +2,8 @@
|
|
2
2
|
|
3
3
|
ComfyArchive is a management engine for chronologically & categorically archived sections for [Comfortable Mexican Sofa](https://github.com/comfy/comfortable-mexican-sofa) 2.x. You can select one or more Comfortable Mexican Sofa pages to act as an index for child pages, which will then be organized both cronologically, by year and month, and by category.
|
4
4
|
|
5
|
+
[![Gem Version](https://badge.fury.io/rb/comfy_archive.svg)](https://badge.fury.io/rb/comfy_archive)
|
6
|
+
|
5
7
|
## Dependencies
|
6
8
|
|
7
9
|
Make sure that you have [ComfortableMexicanSofa](https://github.com/comfy/comfortable-mexican-sofa) installed first.
|
@@ -10,7 +12,7 @@ Make sure that you have [ComfortableMexicanSofa](https://github.com/comfy/comfor
|
|
10
12
|
|
11
13
|
1) Add gem definition to your Gemfile:
|
12
14
|
|
13
|
-
gem "comfy_archive", "~> 0.
|
15
|
+
gem "comfy_archive", "~> 0.2.0"
|
14
16
|
|
15
17
|
2) From your Rails project's root run:
|
16
18
|
|
@@ -10,7 +10,7 @@ class Comfy::Archive::IndexController < Comfy::Cms::ContentController
|
|
10
10
|
only: :index
|
11
11
|
|
12
12
|
def index
|
13
|
-
|
13
|
+
if ! @cms_index || @cms_index.page != @cms_page
|
14
14
|
show
|
15
15
|
else
|
16
16
|
scope = @cms_index.children(true).chronologically(@cms_index.datetime_fragment)
|
@@ -27,7 +27,11 @@ class Comfy::Archive::IndexController < Comfy::Cms::ContentController
|
|
27
27
|
end
|
28
28
|
|
29
29
|
@archive_pages = comfy_paginate(scope, per_page: ComfyArchive.config.posts_per_page)
|
30
|
-
|
30
|
+
if @cms_index.force_render_page
|
31
|
+
show
|
32
|
+
else
|
33
|
+
render layout: app_layout
|
34
|
+
end
|
31
35
|
end
|
32
36
|
end
|
33
37
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: comfy_archive
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Morgan Aldridge
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-12-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: comfortable_mexican_sofa
|