adva_blog 0.0.1 → 0.1.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
- SHA1:
3
- metadata.gz: eaca04c9824c2a859bd1a6702a393f9d6bd47608
4
- data.tar.gz: 9b49939cb632912f8a3a7e3718bdd7bc40ab2e2b
2
+ SHA256:
3
+ metadata.gz: be103e746dc5019a37a44afe5f2592cbdf32f49334bb0d9bad8b14d351284d3b
4
+ data.tar.gz: 96d3af6bcc8b0e4b1cc9b11aa4d40af10e52273074b90a613bc67b3f4157e1a5
5
5
  SHA512:
6
- metadata.gz: 6f1a8bf1af639cc618b2182e1f3e6c55ea5e0b40abe5270d2b3e21e70197eed4b1139858446bdb8ca80c72732d38cc2551ffd89ca69ffece4eebad7d6b6c2c7d
7
- data.tar.gz: 178fdf0d38457b057202543ad331f83c1d32a57f94372f0b7bcc846892d0202fe1ad4f675fb0a84ae149a64a78481edbc44f0cef71aba0a4f74a1443ebcbd4c2
6
+ metadata.gz: 0a01ee29afb12c403f94cb9bb541ff98c17aff2255cfdac5d90166842fa39599ba68a38d4d9b0a7da8f3898aabff7e982d4815c4cd0430a84b8311a7f24157ff
7
+ data.tar.gz: 1185830c46a1952b7cd7ac67bcef10f12ae5fa515bc50b5529ddf3f2da07f9b93321bbb5e61958de7748ff28a1aac40da973c5e67e823b5bdeb467d2c57b1ceb
@@ -1,5 +1,5 @@
1
1
  class Admin::Blog::ContentsController < Admin::Page::ContentsController
2
2
  def index
3
- redirect_to [:admin, @site, @section, :articles]
3
+ redirect_to [:admin, @section, :articles]
4
4
  end
5
5
  end
@@ -19,7 +19,7 @@ module BlogHelper
19
19
  Time.local(params[:year], params[:month]) if params[:year]
20
20
  end
21
21
 
22
- def blog_article_path section, article
22
+ def blog_article_path section, article, options={}
23
23
  if article.published_at
24
24
  super :section_permalink => section.permalink,
25
25
  :year => article.published_at.year,
@@ -31,7 +31,7 @@ module BlogHelper
31
31
  end
32
32
  end
33
33
 
34
- def blog_article_url section, article
34
+ def blog_article_url section, article, options={}
35
35
  if article.published_at
36
36
  super :section_permalink => section.permalink,
37
37
  :year => article.published_at.year,
@@ -9,19 +9,19 @@
9
9
 
10
10
  t.row do |r, content|
11
11
  r.add_class "level_#{content.level}"
12
- r.cell content_status(content) + link_to(content.title, [:edit, :admin, @site, @section, content], :class => content.state)
12
+ r.cell content_status(content) + " " + link_to(content.title, [:edit, :admin, @section, content], :class => content.state)
13
13
  r.cell content.category_titles.join(", ") if @section.categories.any?
14
14
  r.cell content.accept_comments? && content.comments.present? ? link_to(content.comments.size, admin_comments_path) : t(:"adva.common.none") if defined?(Comment)
15
15
  r.cell published_at_formatted(content)
16
- r.cell link_to("Edit", [:edit, :admin, @site, @section, content], :class => "edit content") +
17
- link_to("Delete", [:admin, @site, @section, content], :method => :delete, :class => "delete content")
16
+ r.cell link_to("Edit", [:edit, :admin, @section, content], :class => "edit content") +
17
+ link_to("Delete", [:admin, @section, content], :method => :delete, :class => "delete content")
18
18
  end
19
19
 
20
20
  t.empty :p, :class => 'empty' do
21
21
  raw params[:filters] ?
22
22
  t(:'adva.content.no_filtered_contents') :
23
23
  t(:'adva.contents.no_contents', :section => @section.title) + "\n" +
24
- link_to(t(:'adva.contents.links.create_now'), [:new, :admin, @site, @section, :article])
24
+ link_to(t(:'adva.contents.links.create_now'), [:new, :admin, @section, :article])
25
25
  end
26
26
  end
27
27
  %>
@@ -6,7 +6,7 @@
6
6
  <%= t(:'adva.blog.attribution', :author => article.author_name) %>
7
7
  <%= link_to_content_comments article if (defined?(Comment) && (article.accept_comments? || article.comments.present?)) && mode != :single %>
8
8
  <% authorized_tag :span, :update, article do -%>
9
- <%= link_to t(:'adva.common.edit'), edit_admin_article_path(@site, @section, article) %>
9
+ <%= link_to t(:'adva.common.edit'), edit_admin_article_path(@section, article) %>
10
10
  <% end -%>
11
11
  </p>
12
12
  <p>
@@ -8,7 +8,7 @@ atom_feed :url => request.url do |feed|
8
8
  feed.updated @articles.first ? @articles.first.updated_at : Time.now.utc
9
9
 
10
10
  @articles[0..12].each do |article|
11
- url = "http://#{@site.host}#{url_for([@section, article])}"
11
+ url = [request.protocol, @site.host, url_for([@section, article])].join("")
12
12
  feed.entry article, :url => url do |entry|
13
13
  entry.title article.title
14
14
  entry.content "#{absolutize_links(article.excerpt_html)} #{absolutize_links(article.body_html)}", :type => 'html'
@@ -1,3 +1,3 @@
1
- ActionDispatch::Callbacks.to_prepare do
1
+ ActiveSupport::Reloader.to_prepare do
2
2
  BaseController.class_eval { helper BlogHelper }
3
3
  end
data/config/routes.rb CHANGED
@@ -8,12 +8,10 @@ Rails.application.routes.draw do
8
8
  end
9
9
 
10
10
  namespace :admin do
11
- resources :sites do
12
- resources :blogs do
13
- scope :module => :blog do
14
- resources :contents, :articles, :categories do
15
- put "/", :action => "update_all", :on => :collection
16
- end
11
+ resources :blogs do
12
+ scope :module => :blog do
13
+ resources :contents, :articles, :categories do
14
+ put "/", :action => "update_all", :on => :collection
17
15
  end
18
16
  end
19
17
  end
@@ -1,3 +1,3 @@
1
1
  module AdvaBlog
2
- VERSION = "0.0.1"
2
+ VERSION = "0.1.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: adva_blog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Micah Geisel
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-29 00:00:00.000000000 Z
11
+ date: 2022-09-01 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Adva Blog
14
14
  email:
@@ -76,8 +76,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
76
76
  - !ruby/object:Gem::Version
77
77
  version: '0'
78
78
  requirements: []
79
- rubyforge_project:
80
- rubygems_version: 2.4.6
79
+ rubygems_version: 3.2.3
81
80
  signing_key:
82
81
  specification_version: 4
83
82
  summary: Engine for Adva CMS blog component