drg_blog_news_forum 0.0.7 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 559f79314aca5006d0e1a4d9d69e36bc7348f9f4
4
- data.tar.gz: 0580df1d75a613069ffdefcec44cb25e5d0945c2
3
+ metadata.gz: afef89dcf18f7a648d88de37f755472efc07ae25
4
+ data.tar.gz: 5104629d5d3598dd6617e6d976649f4b8921fef4
5
5
  SHA512:
6
- metadata.gz: 5b5672ea31510550a15b5429d866ff8b9bcfaaa1d7082850502f8ce66c692e20a3cf848b1b4fdacf05a95d15420d5586cae3fb64e9785f73e4c9852136d2112b
7
- data.tar.gz: 2057a2828b65a6da3c82ce3caf2d00e927a55083f431b94ba7c4e078c6a315cc3b17244ead5efa20ce4a20543def2ab3a246b3ba3aa822b32f8acf9752f2f83c
6
+ metadata.gz: b224d51e1f70a1df09ba3379bc45d038d80c9980e7329fcce6b27796a77ccffecff51a8534013423a027377325f46ff591b4be6bdb72d9361eda8ea2e4185fde
7
+ data.tar.gz: 8e2fedc717ca5124dc5fd63ef32c09b07252a61327ec87a848eb9daa2ef286e90b52cc8ae25d0fbc9187661c627f25336dcee0cbaddb0732c25aee3e2b59cc54
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # DrgBlogNewsForum
2
2
 
3
- DRG CMS DrgBlogNewsForum plugin implements basic funcionality for enabling blog, news or forum on DRG CMS enabled web site.
3
+ DRG CMS DrgBlogNewsForum plugin implements code for blog, news or forum on DRG CMS enabled web site.
4
4
 
5
5
  Configuration
6
6
  ----------------
@@ -10,11 +10,22 @@ Add this line to your Gemfile:
10
10
  gem 'drg_blog_news_forum'
11
11
  ```
12
12
 
13
- Usage: Add this line to design.
14
- div id="dc-blog"><%= dc_render(:dc_blog) %></div>
13
+ Usage:
15
14
 
16
- Optional configuration in Site document:
17
- ```yaml
15
+ Create dc_page documents with blog, news and forum links.
16
+
17
+ Create related dc_design documents and use one of this lines for rendering html code.
18
+ ```irb
19
+ <div id="dc-blog"><%= dc_render(:dc_blog) %></div>
20
+ <div id="dc-news"><%= dc_render(:dc_news) %></div>
21
+ <div id="dc-forum"><%= dc_render(:dc_forum) %></div>
22
+ ```
23
+
24
+ Add this lines to routes.rb.
25
+ ```ruby
26
+ get '/blog/:name/:link' => 'dc_main#page', :defaults => { path: 'blog' }
27
+ get '/blog/:name' => 'dc_main#page', :defaults => { path: 'blog', link: 'all' }
28
+ get '/news/:link' => 'dc_main#page', :defaults => { path: 'news' }
18
29
  ```
19
30
 
20
31
  Documentation
@@ -26,7 +37,7 @@ Please see the DRG CMS website for up-to-date documentation:
26
37
  License
27
38
  -------
28
39
 
29
- Copyright (c) 2012-2015 Damjan Rems
40
+ Copyright (c) 2014-2015 Damjan Rems
30
41
 
31
42
  Permission is hereby granted, free of charge, to any person obtaining
32
43
  a copy of this software and associated documentation files (the
@@ -50,4 +61,4 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
50
61
  Credits
51
62
  -------
52
63
 
53
- Damjan Rems: damjan dot rems at gmail dot com
64
+ Damjan Rems: damjan dot rems at gmail dot com
@@ -105,9 +105,9 @@ height: 1px;
105
105
  }
106
106
 
107
107
  .dc-forum-quote {
108
- border-left: 2px solid #01b;
108
+ border-left: 2px solid #666;
109
109
  padding-left: 4px;
110
- color: #01b;
110
+ color: #666;
111
111
  }
112
112
 
113
113
  #dc-forum-menu {
@@ -130,14 +130,15 @@ border-radius: 2px;
130
130
  }
131
131
 
132
132
  /******* dc_blog *******/
133
-
134
133
  .blog-subject {
135
134
  font-size: 1.4em;
136
135
  font-weight: bold;
136
+ margin-top: 20px;
137
137
  }
138
138
  .blog-date {
139
139
  font-size: 1em;
140
140
  color: #aaa;
141
+ margin-bottom: 20px;
141
142
  }
142
143
  .blog-body {
143
144
  }
@@ -151,6 +152,11 @@ background-color: #fff;
151
152
  padding:5px;
152
153
  background-color: #eee;
153
154
  }
155
+
156
+ .reply-body-even p, .reply-body-odd p {
157
+ margin-top: 0em;
158
+ margin-bottom: 0em;
159
+ }
154
160
  .blog-entry {
155
161
  margin-top: 10px;
156
162
  }
@@ -1,6 +1,9 @@
1
1
  <div class="news-title">
2
2
  <h1><%= t('dc_news.news') %></h1>
3
3
  </div>
4
+ <%= if session[:edit_mode] > 1
5
+ dc_link_for_create(controller: 'cmsedit', table: 'dc_news', title: 'dc_blog.new_entry' )
6
+ end %>
4
7
  <% for entry in entries %>
5
8
 
6
9
  <div class="news-entry">
@@ -1,3 +1,3 @@
1
1
  module DrgBlogNewsForum
2
- VERSION = "0.0.7"
2
+ VERSION = "0.5.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: drg_blog_news_forum
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.7
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Damjan Rems
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-28 00:00:00.000000000 Z
11
+ date: 2015-05-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -74,7 +74,6 @@ files:
74
74
  - app/models/dc_news.rb
75
75
  - app/models/dc_reply.rb
76
76
  - app/models/dc_reply_concern.rb
77
- - app/views/dc_blog/_blog.html.erb
78
77
  - app/views/dc_blog/_blogers.html.erb
79
78
  - app/views/dc_blog/_entries.html.erb
80
79
  - app/views/dc_blog/_entry.html.erb
@@ -83,7 +82,6 @@ files:
83
82
  - app/views/dc_forum/_topics.html.erb
84
83
  - app/views/dc_news/_entries.html.erb
85
84
  - app/views/dc_news/_entry.html.erb
86
- - app/views/dc_news/_news.html.erb
87
85
  - app/views/dc_replay/_reply.html.erb
88
86
  - config/locales/dc_forum_en.yml
89
87
  - config/locales/dc_forum_sl.yml
@@ -1,24 +0,0 @@
1
- <div class="blog-title">
2
- <%= title %>
3
- </div>
4
-
5
- <%= if opts[:edit_mode] > 1
6
- dc_link_for_create(controller: 'cmsedit', table: 'dc_blog', title: 'dc_blog.new_entry' )
7
- end %>
8
-
9
- <% if blog %>
10
- <div class="blog-date"><%= dc_pretty_date(blog.created_at) %></div>
11
- <div class="blog-subject"><%= blog.subject %></div>
12
- <div style="clear:both;"></div>
13
-
14
- <div class="blog-body"><%= blog.body %></div>
15
-
16
- <div class="blog-replies">
17
- <%= render partial: 'dc_reply/reply', formats: [:html],
18
- locals: { replies: replies, parent_id: blog.id } %>
19
- </div>
20
-
21
- <iframe id="iframe_edit" name="iframe_edit" scrolling="no"></iframe>
22
- <% else %>
23
- <br><br><br>This blog has no posts. Yet ;-)
24
- <% end %>
@@ -1,24 +0,0 @@
1
- <div class="news-title">
2
- <%= title %>
3
- </div>
4
-
5
- <%= if session[:edit_mode] > 1
6
- dc_link_for_create(controller: 'cmsedit', table: 'dc_news', title: 'dc_blog.new_entry' )
7
- end %>
8
-
9
- <% if news %>
10
- <div class="news-date"><%= dc_pretty_date(news.created_at) %></div>
11
- <div class="news-subject"><%= news.subject %></div>
12
- <div style="clear:both;"></div>
13
-
14
- <div class="news-body"><%= news.body%></div>
15
-
16
- <div class="news-replies">
17
- <%= render partial: 'dc_reply/reply', formats: [:html],
18
- locals: { replies: replies, parent_id: news.id } %>
19
- </div>
20
-
21
- <iframe id="iframe_edit" name="iframe_edit" scrolling="no"></iframe>
22
- <% else %>
23
- <br><br><br>Sorry no news. Yet ;-)
24
- <% end %>