Selected_scheduled? helper added

To be used in Schedules#index
This commit is contained in:
Ana 2016-08-04 01:59:58 +02:00
parent 29b920d746
commit 33e9c86214
2 changed files with 5 additions and 1 deletions

View file

@ -366,4 +366,8 @@ module ApplicationHelper
end end
item_class item_class
end end
def selected_scheduled?(schedule)
(schedule == @selected_schedule) ? 'Yes' : 'No'
end
end end

View file

@ -18,7 +18,7 @@
Schedule Schedule
= schedule.id = schedule.id
%td %td
= (schedule == @selected_schedule) ? 'Yes' : 'No' = selected_scheduled?(schedule)
%td %td
.btn-group{role: "group"} .btn-group{role: "group"}
= link_to 'Show', admin_conference_schedule_path(@conference.short_title, schedule.id), = link_to 'Show', admin_conference_schedule_path(@conference.short_title, schedule.id),