diff --git a/app/controllers/journals_controller.rb b/app/controllers/journals_controller.rb
index 27dfda0..eb29622 100644
--- a/app/controllers/journals_controller.rb
+++ b/app/controllers/journals_controller.rb
@@ -78,7 +78,8 @@ class JournalsController < ApplicationController
page: node.page,
text: node.text,
link_to_show: OrbitHelper.url_to_show("#{node.to_param}?list=chapter"),
- file: node.file.url
+ file: (node.file.present? ? node.file.url : ''),
+ file_class: (node.file.present? ? '' : 'hidden')
}
end
{
diff --git a/app/models/journal.rb b/app/models/journal.rb
index c173a1b..224de24 100644
--- a/app/models/journal.rb
+++ b/app/models/journal.rb
@@ -10,6 +10,7 @@ class Journal
field :pub_date, type: DateTime
field :author, type: String, localize: true
field :author_description, type: String, localize: true
+ field :pub_information, localize: true
mount_uploader :cover, ImageUploader
diff --git a/app/views/admin/chapters/_form.html.erb b/app/views/admin/chapters/_form.html.erb
index efa9973..d140575 100644
--- a/app/views/admin/chapters/_form.html.erb
+++ b/app/views/admin/chapters/_form.html.erb
@@ -45,8 +45,6 @@
<% @site_in_use_locales.each_with_index do |locale, i| %>
">
<%= render partial: 'form_text_locale', locals: {f: f, node: :title, locale: locale, style: 'long'}%>
- <%= render partial: 'form_text_locale', locals: {f: f, node: :author, locale: locale, style: 'long'}%>
- <%= render partial: 'form_text_locale', locals: {f: f, node: :author_description, locale: locale, style: 'long'}%>
<% end %>
@@ -54,6 +52,8 @@
<% @site_in_use_locales.each_with_index do |locale, i| %>
">
+ <%= render partial: 'form_text_locale', locals: {f: f, node: :author, locale: locale, style: 'long'}%>
+ <%= render partial: 'form_text_area', locals: {f: f, node: :author_description, locale: locale} %>
<%= render partial: 'form_text_area', locals: {f: f, node: :text, locale: locale} %>
<% end %>
diff --git a/app/views/admin/journals/_form.html.erb b/app/views/admin/journals/_form.html.erb
index bcfacb2..58a79d0 100644
--- a/app/views/admin/journals/_form.html.erb
+++ b/app/views/admin/journals/_form.html.erb
@@ -59,6 +59,7 @@
<% @site_in_use_locales.each_with_index do |locale, i| %>
">
<%= render partial: 'form_text_locale', locals: {f: f, node: :author, locale: locale, style: nil} %>
+ <%= render partial: 'form_text_area', locals: {f: f, node: :pub_information, locale: locale} %>
<% end %>
diff --git a/app/views/admin/journals/_form_text_area.html.erb b/app/views/admin/journals/_form_text_area.html.erb
new file mode 100644
index 0000000..3d7c2a2
--- /dev/null
+++ b/app/views/admin/journals/_form_text_area.html.erb
@@ -0,0 +1,10 @@
+
diff --git a/journals.gemspec b/journals.gemspec
index 4908659..ecd8394 100644
--- a/journals.gemspec
+++ b/journals.gemspec
@@ -9,7 +9,7 @@ Gem::Specification.new do |s|
s.version = Journals::VERSION
s.authors = ["Archer Lin"]
s.email = ["twbcs@yahoo.com.tw"]
- s.homepage = "no"
+ s.homepage = "https://github.com/twbcs"
s.summary = "Journals."
s.description = "Description of Journals."
s.license = "MIT"