aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers
diff options
context:
space:
mode:
authorTeddy Wing2017-07-10 12:33:15 +0200
committerTeddy Wing2017-07-12 11:11:14 +0200
commit09aef0d99cd86a75afe6aa81297cc7d3e7d8cae4 (patch)
treed2f1cdad211b7836b8815745b51dfb4b87b48a1f /app/controllers
parent2215e9696dc435940a8a40ffb45c1a11d95e3ee9 (diff)
downloadchouette-core-09aef0d99cd86a75afe6aa81297cc7d3e7d8cae4.tar.bz2
RoutingConstraintZones#index: Use new table builder helper
Render table of `RoutingConstraintZones` using the new table builder. Refs #3479
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/routing_constraint_zones_controller.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/app/controllers/routing_constraint_zones_controller.rb b/app/controllers/routing_constraint_zones_controller.rb
index f019b5ea9..3d0ee19ed 100644
--- a/app/controllers/routing_constraint_zones_controller.rb
+++ b/app/controllers/routing_constraint_zones_controller.rb
@@ -10,6 +10,21 @@ class RoutingConstraintZonesController < ChouetteController
belongs_to :line, parent_class: Chouette::Line
end
+ def index
+ index! do |format|
+ @routing_constraint_zones = ModelDecorator.decorate(
+ @routing_constraint_zones,
+ with: RoutingConstraintZoneDecorator,
+ context: {
+ referential: referential,
+ line: parent
+ }
+ )
+
+ build_breadcrumb :index
+ end
+ end
+
def show
show! do |format|
@routing_constraint_zone = @routing_constraint_zone.decorate(context: {