Fix link.

This commit is contained in:
BoHung Chiu 2022-12-15 17:43:55 +08:00
parent 2fa9d31762
commit 0fae8917d2
1 changed files with 4 additions and 1 deletions

View File

@ -76,7 +76,10 @@ class Research
pd_data = []
fields_to_show.collect do |t|
if t == "research_title"
pd_data << { "data_title" => "<a href=\"#{OrbitHelper.url_to_plugin_show(p.to_param,'personal_research')}\" title=\"#{p.send(t)}\">#{p.send(t)}</a>" }
link = OrbitHelper.url_to_plugin_show(p.to_param,'personal_research')
url_to_plugin_show_blank = OrbitHelper.instance_variable_get(:@url_to_plugin_show_blank)
tmp_title = p.research_title
pd_data << { "data_title" => (url_to_plugin_show_blank ? tmp_title : "<a title=\"#{tmp_title}\" href=\"#{link}\" target=\"_blank\">#{tmp_title}") }
elsif t == "research_category"
pd_data << {"data_title" => (p.research_category.title rescue "")}
else