aboutsummaryrefslogtreecommitdiffstats
path: root/app/views/autocomplete_time_tables/index.rabl
blob: b17411684166ed34f06c8f44eecf7a93953a9ad8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
collection @time_tables, :object_root => false

node do |time_table|
  {
    :id => time_table.id,
    :comment => time_table.comment,
    :objectid => time_table.objectid,
    :time_table_bounding => time_table.presenter.time_table_bounding,
    :composition_info => time_table.presenter.composition_info,
    :tags => time_table.tags.join(','),
    :color => time_table.color,
    :day_types => time_table.display_day_types,
    :short_id => time_table.get_objectid.short_id,
    :text => "<strong><span class='fa fa-circle' style='color:" + (time_table.color ? time_table.color : '#4b4b4b') + "'></span> " + time_table.comment + " - " + time_table.get_objectid.short_id + "</strong><br/><small>" + time_table.display_day_types + "</small>"
  }
end