aboutsummaryrefslogtreecommitdiffstats
path: root/app/helpers/table_builder_helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/helpers/table_builder_helper.rb')
-rw-r--r--app/helpers/table_builder_helper.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/helpers/table_builder_helper.rb b/app/helpers/table_builder_helper.rb
index e2aa2e9ea..8c73cb33c 100644
--- a/app/helpers/table_builder_helper.rb
+++ b/app/helpers/table_builder_helper.rb
@@ -153,7 +153,7 @@ module TableBuilderHelper
i = columns.index(column)
if overhead[i].blank?
- if (i > 0) && (overhead[i - 1][:width] > 1)
+ if (i > 0) && overhead[i - 1][:width] && (overhead[i - 1][:width] > 1)
clsArrayH = overhead[i - 1][:cls].split
hcont << content_tag(:th, build_column_header(
@@ -225,7 +225,7 @@ module TableBuilderHelper
if column.linkable?
path = column.link_to(item)
- link = value.present? && path.present? ? link_to(value, path) : ""
+ link = value.present? && path.present? ? link_to(value, path) : value
if overhead.empty?
bcont << content_tag(:td, link, title: 'Voir', class: extra_class)
@@ -234,7 +234,7 @@ module TableBuilderHelper
i = columns.index(column)
if overhead[i].blank?
- if (i > 0) && (overhead[i - 1][:width] > 1)
+ if (i > 0) && overhead[i - 1][:width] && (overhead[i - 1][:width] > 1)
clsArrayAlt = overhead[i - 1][:cls].split
bcont << content_tag(:td, link, title: 'Voir', class: td_cls(clsArrayAlt, extra_class))