mirror of
https://github.com/zhigang1992/ProMotion.git
synced 2026-05-24 09:13:24 +08:00
Automatically add the little magnifying glass to the top of the table index if the table is searchable.
This commit is contained in:
@@ -2,7 +2,9 @@ module ProMotion
|
||||
module Table
|
||||
module Indexable
|
||||
def table_data_index
|
||||
@promotion_table_data.filtered ? nil : @promotion_table_data.sections.collect{ |section| section[:title][0] }
|
||||
index = @promotion_table_data.filtered ? nil : @promotion_table_data.sections.collect{ |section| section[:title][0] }
|
||||
index.unshift("{search}") if self.class.get_searchable
|
||||
index
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user