Skip to content
Snippets Groups Projects
Commit 90c5d2d0 authored by Arnaud Levy's avatar Arnaud Levy
Browse files

After commit to allow creation for newly updated files

parent 457cd276
No related branches found
No related tags found
No related merge requests found
...@@ -37,7 +37,7 @@ class Research::Journal::Article < ApplicationRecord ...@@ -37,7 +37,7 @@ class Research::Journal::Article < ApplicationRecord
belongs_to :updated_by, class_name: 'User' belongs_to :updated_by, class_name: 'User'
has_and_belongs_to_many :researchers, class_name: 'Research::Researcher' has_and_belongs_to_many :researchers, class_name: 'Research::Researcher'
after_save :publish_to_github after_commit :publish_to_github
has_one_attached :pdf has_one_attached :pdf
......
...@@ -28,7 +28,7 @@ class Research::Journal::Volume < ApplicationRecord ...@@ -28,7 +28,7 @@ class Research::Journal::Volume < ApplicationRecord
belongs_to :journal, foreign_key: :research_journal_id belongs_to :journal, foreign_key: :research_journal_id
has_many :articles, foreign_key: :research_journal_volume_id has_many :articles, foreign_key: :research_journal_volume_id
after_save :publish_to_github after_commit :publish_to_github
has_one_attached :cover has_one_attached :cover
......
...@@ -26,12 +26,12 @@ ...@@ -26,12 +26,12 @@
<h5 class="card-title mb-0">Metadata</h5> <h5 class="card-title mb-0">Metadata</h5>
</div> </div>
<div class="card-body"> <div class="card-body">
<h3 class="h5"><%= Research::Journal::Article.human_attribute_name('published_at') %></h3> <h3 class="h5"><%= Research::Journal::Article.human_attribute_name('volume') %></h3>
<%= link_to @article.volume, [:admin, @article.volume] if @article.volume %>
<h3 class="h5 mt-4"><%= Research::Journal::Article.human_attribute_name('published_at') %></h3>
<p><%= @article.published_at&.to_date %></p> <p><%= @article.published_at&.to_date %></p>
<% if @article.volume %> <h3 class="h5 mt-4"><%= Research::Journal::Article.human_attribute_name('keywords') %></h3>
<h3 class="h5 mt-4"><%= Research::Journal::Article.human_attribute_name('researchers') %></h3> <p><%= @article.keywords %></p>
<%= link_to @article.volume, [:admin, @article.volume] %>
<% end %>
<h3 class="h5 mt-4"><%= Research::Journal::Article.human_attribute_name('researchers') %></h3> <h3 class="h5 mt-4"><%= Research::Journal::Article.human_attribute_name('researchers') %></h3>
<ul class="list-unstyled"> <ul class="list-unstyled">
<% @article.researchers.each do |researcher| %> <% @article.researchers.each do |researcher| %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment