diff --git a/app/models/experience.rb b/app/models/experience.rb index 06c01ec..f24185f 100644 --- a/app/models/experience.rb +++ b/app/models/experience.rb @@ -75,9 +75,11 @@ class Experience pd_data = [] fields_to_show.collect do |t| if t == "organizationt_title" - pd_data << { "data_title" => "#{p.send(t)}" } + link = OrbitHelper.url_to_plugin_show(p.to_param,'personal_experience') + url_to_plugin_show_blank = OrbitHelper.instance_variable_get(:@url_to_plugin_show_blank) + tmp_title = p.organizationt_title + pd_data << { "data_title" => (url_to_plugin_show_blank ? tmp_title : "#{tmp_title}") } elsif t == "duration" - if !p.send('start_date').nil? or !p.send('end_date').nil? start_date = ((p.send('start_date').blank?) ? "" : p.send('start_date').strftime('%Y.%m')) rescue "" end_date = ((p.send('end_date').blank? || p.send('end_date').to_s == "0000-01-01" ) ? I18n.t('personal_experience.up_to_today') : p.send('end_date').strftime('%Y.%m')) rescue I18n.t('personal_experience.up_to_today')