drg_blog_news_forum 0.5.52.0 → 0.5.52.1

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
  SHA1:
3
- metadata.gz: 21376b47f6aebf241e6cd3053fe434b6cc1b430a
4
- data.tar.gz: f7cbc383f3882a7fa36a385b0dd311d653f1eee4
3
+ metadata.gz: bb7ee75586683204eb1f405464282a1e220b417d
4
+ data.tar.gz: 1cc753d310225e1a2ee45cead6ae072547677701
5
5
  SHA512:
6
- metadata.gz: 58171ad983f8d78c280f409be0992fef784cf64b7350fdf9e06710900fca5c8f17ce6025632c8e971f4d2162045c81cd75d2511c8ae7a60d399b6d690bf21e0e
7
- data.tar.gz: 804ccf7bb9b4dded3b05684c8cf26616b52037d55f0e392d98f791a216d472844b107c0f8f22428869d72cd454c7456e15a889f3b761b8ce0828f4aec42bac4a
6
+ metadata.gz: 6150f740cbe57a19ed9780d322e8e39170b19666c08037062f1d9c37eaf4bdf6ae7c7997c8825fa225a6d4cc84676d4620d3c702ee57c53080ab7fc9b9360ae0
7
+ data.tar.gz: e6395612293542900ac3824bc28bc189e145364a3ddc8686869e00211aa5ef8b5c3854c3fe06879855c70bc10d20a5057cfc287571cee240dc833aa81c98ce0d
data/MIT-LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright 2014+ Damjan Rems
1
+ Copyright 2014-2018 Damjan Rems
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -12,20 +12,13 @@ Add this line to your Gemfile:
12
12
 
13
13
  Usage:
14
14
 
15
- Create dc_page documents with blog, news and forum links.
15
+ Create dc_page documents with blog, news or forum links.
16
16
 
17
17
  Create related dc_design documents and use one of this lines for rendering html code.
18
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' }
19
+ <%= dc_render(:dc_blog) %>
20
+ <%= dc_render(:dc_news) %>
21
+ <%= dc_render(:dc_forum) %>
29
22
  ```
30
23
 
31
24
  Documentation
@@ -37,7 +30,7 @@ Please see the DRG CMS website for up-to-date documentation:
37
30
  License
38
31
  -------
39
32
 
40
- Copyright (c) 2014-2015 Damjan Rems
33
+ Copyright (c) 2014-2018 Damjan Rems
41
34
 
42
35
  Permission is hereby granted, free of charge, to any person obtaining
43
36
  a copy of this software and associated documentation files (the
data/Rakefile CHANGED
@@ -1,3 +1,25 @@
1
+ #--
2
+ # Copyright (c) 2014-2018 Damjan Rems
3
+ #
4
+ # Permission is hereby granted, free of charge, to any person obtaining
5
+ # a copy of this software and associated documentation files (the
6
+ # "Software"), to deal in the Software without restriction, including
7
+ # without limitation the rights to use, copy, modify, merge, publish,
8
+ # distribute, sublicense, and/or sell copies of the Software, and to
9
+ # permit persons to whom the Software is furnished to do so, subject to
10
+ # the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be
13
+ # included in all copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18
+ # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19
+ # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20
+ # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21
+ # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ #++
1
23
  begin
2
24
  require 'bundler/setup'
3
25
  rescue LoadError
@@ -67,7 +67,7 @@ def last_blogs
67
67
  .order_by(created_at: -1).limit(limit).to_a
68
68
 
69
69
  entries.inject('') do |result, document|
70
- result << @parent.link_to("/blog/#{document.link}") do
70
+ result << @parent.link_to("/blog/#{document.created_by_name}/#{document.link}") do
71
71
  %Q[
72
72
  <span class="date">#{@parent.dc_pretty_date(document.created_at)} : </span>
73
73
  <span class="title">#{document.subject}</span><br><br>
@@ -83,7 +83,6 @@ end
83
83
  ########################################################################
84
84
  def default
85
85
  document_link = @opts[:path].last
86
- p @opts[:path]
87
86
  if @opts[:path].size == 1 or document_link == 'blogers'
88
87
  list_blogers
89
88
  elsif @opts[:path].size == 2
@@ -1,4 +1,4 @@
1
- <div class="wrap">
1
+
2
2
  <div class="blog-title">
3
3
  <%= title %>
4
4
  </div>
@@ -23,4 +23,3 @@
23
23
  <% else %>
24
24
  <br><br><br>This blog has no posts. Yet ;-)
25
25
  <% end %>
26
- </div>
@@ -1,4 +1,4 @@
1
- <div class="wrap">
1
+
2
2
  <% if session[:edit_mode] > 1 %>
3
3
  <%= dc_link_for_create(controller: 'cmsedit', table: 'dc_blog', title: 'dc_blog.new_entry' ) %>
4
4
  <% end %>
@@ -11,4 +11,3 @@
11
11
  <%= link_to( bloger, { path: "blog/#{bloger}"} )%>
12
12
  </div>
13
13
  <% end %>
14
- </div>
@@ -1,3 +1,4 @@
1
+ <!-- NOT USED ANYMORE -->
1
2
  <div class="wrap">
2
3
  <div id="last-blogs">
3
4
  <h3><%= t('dc_blog.last_blogs') %></h3>
@@ -1,13 +1,11 @@
1
1
 
2
- <div class="wrap">
3
- <div id="blogs">
4
- <h3><%= t('dc_blog.blogs') %></h3>
2
+ <div id="blogs">
3
+ <h3><%= t('dc_blog.blogs') %></h3>
5
4
 
6
- <% for document in documents %>
7
- <div class="entry">
8
- <div class="date"><%= dc_pretty_date(document.created_at) %></div>
9
- <div class="title"><%= link_to( document.subject, path: "#{@page.link}/#{document.created_by_name}/#{document.link}" )%></div>
10
- </div>
11
- <% end %>
5
+ <% for document in documents %>
6
+ <div class="entry">
7
+ <div class="date"><%= dc_pretty_date(document.created_at) %></div>
8
+ <div class="title"><%= link_to( document.subject, path: "#{@page.link}/#{document.created_by_name}/#{document.link}" )%></div>
12
9
  </div>
13
- </div>
10
+ <% end %>
11
+ </div>
@@ -1,4 +1,4 @@
1
- <div class="wrap">
1
+
2
2
  <% if session[:edit_mode] > 1 %>
3
3
  <%= dc_link_for_create(controller: 'cmsedit', table: 'dc_blog', title: 'dc_blog.new_document' ) %>
4
4
  <br><br>
@@ -18,4 +18,3 @@
18
18
  </div>
19
19
 
20
20
  <iframe id="iframe_edit" name="iframe_edit" scrolling="no"></iframe>
21
- </div>
@@ -1,3 +1,3 @@
1
1
  module DrgBlogNewsForum
2
- VERSION = "0.5.52.0"
2
+ VERSION = "0.5.52.1"
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.5.52.0
4
+ version: 0.5.52.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Damjan Rems
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-08-27 00:00:00.000000000 Z
11
+ date: 2018-08-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails