2018-11-08 17:13:48 +01:00
|
|
|
:ruby
|
2019-08-06 11:02:54 +02:00
|
|
|
url = if field.resource.class.name == 'Instructeur'
|
|
|
|
enable_feature_manager_instructeur_path(field.resource.id)
|
2018-11-08 17:13:48 +01:00
|
|
|
else
|
|
|
|
enable_feature_manager_administrateur_path(field.resource.id)
|
|
|
|
end
|
|
|
|
|
2018-04-26 14:40:03 +02:00
|
|
|
%table#features
|
2018-11-12 12:28:18 +01:00
|
|
|
- admin_features = Flipflop.feature_set.features.reject{ |f| f.group.try(:key) == :production }
|
|
|
|
- admin_features.each do |feature|
|
|
|
|
%tr
|
|
|
|
%td= feature.title
|
|
|
|
%td
|
|
|
|
= check_box_tag "enable-feature", "enable", field.data[feature.name], data: { url: url, key: feature.key }
|