Update journal_papers_helper.rb

This commit is contained in:
chiu 2019-11-02 11:40:47 +08:00
parent c0a5af9280
commit e9feed00ba
1 changed files with 1 additions and 1 deletions

View File

@ -3,7 +3,7 @@ module Admin::JournalPapersHelper
journal.authors.to_s.blank? ? get_member(journal).join('/') : Nokogiri::HTML(journal.authors.to_s).text journal.authors.to_s.blank? ? get_member(journal).join('/') : Nokogiri::HTML(journal.authors.to_s).text
end end
def get_authors_show(journal) def get_authors_show(journal)
journal.authors.to_s.blank? ? get_member(journal).join('/') : (journal.authors.to_s) journal.authors.to_s.blank? ? get_member(journal).collect(&:name).join('/') : (journal.authors.to_s)
end end
def get_member(journal) def get_member(journal)
Array(MemberProfile.find(Array(journal).collect(&:member_profile_id))) Array(MemberProfile.find(Array(journal).collect(&:member_profile_id)))