config/routes.rb in prosperity-0.0.1 vs config/routes.rb in prosperity-0.0.2
- old
+ new
@@ -1,5 +1,15 @@
-Prosperity::Engine.routes.draw do
- resources :metrics
+Prosperity::Engine.routes.draw do
+ resources :dashboards do
+ post "graphs/:graph_id", to: "dashboard_graphs#create", as: :dashboard_graphs
+ delete "graphs/:graph_id", to: "dashboard_graphs#destroy"
+ end
+ resources :metrics do
+ member do
+ get :data
+ end
+ end
+
+ resources :graphs
root to: 'metrics#index'
end