fix error
This commit is contained in:
parent
755d395902
commit
8c412dc167
|
@ -144,7 +144,7 @@ class PersonalJournalsController < ApplicationController
|
||||||
|
|
||||||
def index_by_author(journal_papers)
|
def index_by_author(journal_papers)
|
||||||
journal_papers_total_pages = journal_papers.total_pages
|
journal_papers_total_pages = journal_papers.total_pages
|
||||||
journal_papers_list = journal_papers.group_by{|jp| jp.member_profile.name rescue jp.authors}.collect do |name, jps|
|
journal_papers_list = journal_papers.group_by{|jp| jp.member_profiles.collect{|v| v.name}.join(', ') rescue jp.authors}.collect do |name, jps|
|
||||||
jps_data = jps.collect do |jp|
|
jps_data = jps.collect do |jp|
|
||||||
{'title' => jp.create_link_tag_for_title}
|
{'title' => jp.create_link_tag_for_title}
|
||||||
end
|
end
|
||||||
|
|
|
@ -211,6 +211,19 @@ class JournalPaper
|
||||||
plugin_datas
|
plugin_datas
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def member_profile(only_one=true)
|
||||||
|
tmp = super()
|
||||||
|
only_one ? tmp.first : tmp
|
||||||
|
end
|
||||||
|
|
||||||
|
def member_profiles
|
||||||
|
member_profile(false)
|
||||||
|
end
|
||||||
|
|
||||||
|
def member_profile=(mp)
|
||||||
|
super(mp.class != MemberProfile ? mp : [mp])
|
||||||
|
end
|
||||||
|
|
||||||
def get_plugin_field_data(field)
|
def get_plugin_field_data(field)
|
||||||
case field
|
case field
|
||||||
when "level_type"
|
when "level_type"
|
||||||
|
|
Loading…
Reference in New Issue